woozlit 2.1.0 → 2.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (52) hide show
  1. package/dist/auth/login.js +1 -1
  2. package/dist/browser/index.js +1 -1
  3. package/dist/browser/server.js +1 -1
  4. package/dist/browser/tools.js +1 -1
  5. package/dist/chat/agent.js +1 -1
  6. package/dist/config/mcp.js +1 -1
  7. package/dist/config/settings.js +1 -1
  8. package/dist/discord/client.js +1 -1
  9. package/dist/discord/config.js +1 -1
  10. package/dist/discord/index.js +1 -1
  11. package/dist/discord/setup.js +1 -1
  12. package/dist/email/config.js +1 -1
  13. package/dist/email/index.js +1 -1
  14. package/dist/email/service.js +1 -1
  15. package/dist/email/setup.js +1 -1
  16. package/dist/github/api.js +1 -1
  17. package/dist/github/auth.js +1 -1
  18. package/dist/github/auto-setup.js +1 -1
  19. package/dist/github/index.js +1 -1
  20. package/dist/github/manual-setup.js +1 -1
  21. package/dist/index.js +1 -1
  22. package/dist/mcp-servers/computer-use.js +1 -1
  23. package/dist/services/bot-manager.js +1 -1
  24. package/dist/services/voice-agent.js +1 -1
  25. package/dist/telegram/bot.js +1 -1
  26. package/dist/telegram/config.js +1 -1
  27. package/dist/telegram/index.js +1 -1
  28. package/dist/telegram/reminders.js +1 -1
  29. package/dist/telegram/setup.js +1 -1
  30. package/dist/tools/command.js +1 -1
  31. package/dist/tools/file.js +1 -1
  32. package/dist/tools/index.js +1 -1
  33. package/dist/tools/mcp.js +1 -1
  34. package/dist/tools/rollback.js +1 -1
  35. package/dist/tools/rules.js +1 -1
  36. package/dist/twilio/config.js +1 -1
  37. package/dist/twilio/index.js +1 -1
  38. package/dist/twilio/server.js +1 -1
  39. package/dist/twilio/setup.js +1 -1
  40. package/dist/ui/output.js +1 -1
  41. package/dist/ui/select.js +1 -1
  42. package/dist/ui/themes.js +1 -1
  43. package/dist/utils/api.js +1 -1
  44. package/dist/utils/chat-history.d.ts +15 -0
  45. package/dist/utils/chat-history.js +1 -0
  46. package/dist/utils/history.js +1 -1
  47. package/dist/utils/mcp-installer.js +1 -1
  48. package/dist/utils/platform.js +1 -1
  49. package/dist/utils/storage.js +1 -1
  50. package/dist/utils/update-check.js +1 -1
  51. package/dist/verify_repro.js +1 -1
  52. package/package.json +1 -1
@@ -1 +1 @@
1
- function a13_0x3a4f(){const _0x5f595f=['1723497JJGQpR','user','length','info','INBOX','imap',':\x0aSubject:\x20','from','1036910jQaGVp','UNSEEN','smtp','9qondmR','error','\x0a\x0aDraft\x20a\x20helpful\x20reply.\x20Structure\x20it\x20clearly.','interval','openBox','sendMail','search','\x20new\x20messages','794958AsLYAD','NODE_TLS_REJECT_UNAUTHORIZED','\x0aBody:\x0a','\x20(not\x20allowed)','1007841qxJYwW','1617335qvvDmm','[Email]\x20From:\x20','body','find','[Email]\x20Reply\x20sent\x20to\x20','You\x20received\x20an\x20email\x20from\x20','5323036vXXEGn','which','allowedSenders','subject','isConfigured','getConfig','content','parts','message','match','connect','41027944lVtfcn','success','HEADER','24mvandn','[Email]\x20Ignored\x20mail\x20from\x20','end'];a13_0x3a4f=function(){return _0x5f595f;};return a13_0x3a4f();}(function(_0x560a5f,_0x33d1fc){const _0x548312=a13_0x597a,_0x162d3c=_0x560a5f();while(!![]){try{const _0x20c1ee=-parseInt(_0x548312(0x1fa))/0x1+-parseInt(_0x548312(0x1de))/0x2+parseInt(_0x548312(0x1e2))/0x3+-parseInt(_0x548312(0x1e9))/0x4+parseInt(_0x548312(0x1e3))/0x5*(-parseInt(_0x548312(0x1f7))/0x6)+parseInt(_0x548312(0x202))/0x7+-parseInt(_0x548312(0x1f4))/0x8*(-parseInt(_0x548312(0x205))/0x9);if(_0x20c1ee===_0x33d1fc)break;else _0x162d3c['push'](_0x162d3c['shift']());}catch(_0x3a59ea){_0x162d3c['push'](_0x162d3c['shift']());}}}(a13_0x3a4f,0xd3a97));import a13_0x7cde61 from'imap-simple';import a13_0x5a6030 from'nodemailer';import*as a13_0x1225d2 from'./config.js';import*as a13_0x266db4 from'../ui/output.js';import{getSelectedModel}from'../utils/storage.js';import{sendChatMessage}from'../utils/api.js';let intervalId=null,isRunning=![];function a13_0x597a(_0x48698f,_0x5bde69){_0x48698f=_0x48698f-0x1dc;const _0x3a4f29=a13_0x3a4f();let _0x597afc=_0x3a4f29[_0x48698f];return _0x597afc;}async function checkEmails(){const _0x85c9ae=a13_0x597a,_0x14a48d=a13_0x1225d2[_0x85c9ae(0x1ee)]();try{const _0x470506=await a13_0x7cde61[_0x85c9ae(0x1f3)]({'imap':_0x14a48d[_0x85c9ae(0x1ff)]});await _0x470506[_0x85c9ae(0x209)](_0x85c9ae(0x1fe));const _0x248d42=[_0x85c9ae(0x203)],_0x3e55c7={'bodies':[_0x85c9ae(0x1f6),'TEXT'],'markSeen':!![]},_0x2e2344=await _0x470506[_0x85c9ae(0x1dc)](_0x248d42,_0x3e55c7);_0x2e2344['length']>0x0&&a13_0x266db4[_0x85c9ae(0x1fd)]('[Email]\x20Found\x20'+_0x2e2344['length']+_0x85c9ae(0x1dd));for(const _0x156748 of _0x2e2344){const _0x3f2bef=_0x156748['parts'][_0x85c9ae(0x1e6)](_0x2ba711=>_0x2ba711[_0x85c9ae(0x1ea)]===_0x85c9ae(0x1f6)),_0x3d4dde=_0x3f2bef[_0x85c9ae(0x1e5)][_0x85c9ae(0x201)]?.[0x0]||'',_0x3d1191=_0x3f2bef[_0x85c9ae(0x1e5)][_0x85c9ae(0x1ec)]?.[0x0]||'No\x20Subject';if(_0x14a48d['allowedSenders'][_0x85c9ae(0x1fc)]>0x0){const _0x47a26c=_0x3d4dde[_0x85c9ae(0x1f2)](/<(.+)>/)?.[0x1]||_0x3d4dde;if(!_0x14a48d[_0x85c9ae(0x1eb)]['includes'](_0x47a26c)){a13_0x266db4['dim'](_0x85c9ae(0x1f8)+_0x3d4dde+_0x85c9ae(0x1e1));continue;}}const _0x4e045d=_0x156748[_0x85c9ae(0x1f0)][_0x85c9ae(0x1e6)](_0x4efb90=>_0x4efb90[_0x85c9ae(0x1ea)]==='TEXT'),_0x1ee799=_0x4e045d?.[_0x85c9ae(0x1e5)]||'';a13_0x266db4['info'](_0x85c9ae(0x1e4)+_0x3d4dde+'\x20|\x20Subj:\x20'+_0x3d1191);try{const _0x2ebc0b=_0x85c9ae(0x1e8)+_0x3d4dde+_0x85c9ae(0x200)+_0x3d1191+_0x85c9ae(0x1e0)+_0x1ee799+_0x85c9ae(0x207),_0x3ee8df=await sendChatMessage(getSelectedModel(),[{'role':_0x85c9ae(0x1fb),'content':_0x2ebc0b}]),_0x53fb71=a13_0x5a6030['createTransport'](_0x14a48d[_0x85c9ae(0x204)]);await _0x53fb71[_0x85c9ae(0x20a)]({'from':_0x14a48d[_0x85c9ae(0x204)]['auth'][_0x85c9ae(0x1fb)],'to':_0x3d4dde,'subject':'Re:\x20'+_0x3d1191,'text':_0x3ee8df[_0x85c9ae(0x1ef)]}),a13_0x266db4[_0x85c9ae(0x1f5)](_0x85c9ae(0x1e7)+_0x3d4dde);}catch(_0xcbc016){a13_0x266db4[_0x85c9ae(0x206)]('[Email]\x20Processing/Reply\x20error:\x20'+_0xcbc016[_0x85c9ae(0x1f1)]);}}_0x470506[_0x85c9ae(0x1f9)]();}catch(_0x32d122){}}export async function startBot(){const _0x15193b=a13_0x597a;if(!a13_0x1225d2[_0x15193b(0x1ed)]())return![];if(isRunning)return!![];process['env'][_0x15193b(0x1df)]='0',checkEmails();const _0x4a3380=a13_0x1225d2[_0x15193b(0x1ee)]()[_0x15193b(0x208)]||0x5;return intervalId=setInterval(checkEmails,_0x4a3380*0x3c*0x3e8),isRunning=!![],!![];}export function stopBot(){intervalId&&(clearInterval(intervalId),intervalId=null),isRunning=![];}export function isBotRunning(){return isRunning;}export{isConfigured}from'./config.js';
1
+ (function(_0x216c7d,_0x7c6302){const _0x512fe0=a13_0x13b6,_0x16cec8=_0x216c7d();while(!![]){try{const _0x56759e=parseInt(_0x512fe0(0xe9))/0x1*(-parseInt(_0x512fe0(0xd9))/0x2)+parseInt(_0x512fe0(0xd8))/0x3*(-parseInt(_0x512fe0(0xd7))/0x4)+parseInt(_0x512fe0(0xfe))/0x5*(parseInt(_0x512fe0(0xde))/0x6)+parseInt(_0x512fe0(0xd1))/0x7*(parseInt(_0x512fe0(0xcf))/0x8)+parseInt(_0x512fe0(0xd2))/0x9+parseInt(_0x512fe0(0xe7))/0xa+parseInt(_0x512fe0(0xe5))/0xb;if(_0x56759e===_0x7c6302)break;else _0x16cec8['push'](_0x16cec8['shift']());}catch(_0x3a0b4b){_0x16cec8['push'](_0x16cec8['shift']());}}}(a13_0x3b8d,0x7b42e));import a13_0x4735 from'imap-simple';import a13_0x25b7db from'nodemailer';import*as a13_0x86a645 from'./config.js';function a13_0x3b8d(){const _0x25bdcd=['70406RBfznD','search','interval','info','which','12bcyiJN','body','getConfig','Re:\x20','content','from','find','11328636sgRAcO','INBOX','666060FXTIma','env','17tQIlGM','No\x20Subject','allowedSenders','parts','message','smtp','TEXT','HEADER','match','\x20|\x20Subj:\x20','[Email]\x20Found\x20','openBox','\x20new\x20messages','error','UNSEEN','\x20(not\x20allowed)','You\x20received\x20an\x20email\x20from\x20','isConfigured','NODE_TLS_REJECT_UNAUTHORIZED','end','sendMail','62515aoWzWP','[Email]\x20Reply\x20sent\x20to\x20','user','4503704IqFPlL','length','7pgdvCO','3570066cOaakU','createTransport','includes','auth','success','108644ooMYJC','108wiPXLW'];a13_0x3b8d=function(){return _0x25bdcd;};return a13_0x3b8d();}import*as a13_0x3f5789 from'../ui/output.js';import{getSelectedModel}from'../utils/storage.js';import{sendChatMessage}from'../utils/api.js';let intervalId=null,isRunning=![];async function checkEmails(){const _0x1a3f06=a13_0x13b6,_0x4eab8b=a13_0x86a645[_0x1a3f06(0xe0)]();try{const _0x51a909=await a13_0x4735['connect']({'imap':_0x4eab8b['imap']});await _0x51a909[_0x1a3f06(0xf4)](_0x1a3f06(0xe6));const _0xfd84e0=[_0x1a3f06(0xf7)],_0x3f4ad3={'bodies':['HEADER',_0x1a3f06(0xef)],'markSeen':!![]},_0x581d5c=await _0x51a909[_0x1a3f06(0xda)](_0xfd84e0,_0x3f4ad3);_0x581d5c['length']>0x0&&a13_0x3f5789[_0x1a3f06(0xdc)](_0x1a3f06(0xf3)+_0x581d5c[_0x1a3f06(0xd0)]+_0x1a3f06(0xf5));for(const _0x55c058 of _0x581d5c){const _0x7d78b5=_0x55c058[_0x1a3f06(0xec)][_0x1a3f06(0xe4)](_0x24c478=>_0x24c478[_0x1a3f06(0xdd)]===_0x1a3f06(0xf0)),_0x241ef0=_0x7d78b5[_0x1a3f06(0xdf)][_0x1a3f06(0xe3)]?.[0x0]||'',_0x41cc9c=_0x7d78b5[_0x1a3f06(0xdf)]['subject']?.[0x0]||_0x1a3f06(0xea);if(_0x4eab8b[_0x1a3f06(0xeb)][_0x1a3f06(0xd0)]>0x0){const _0x5243c5=_0x241ef0[_0x1a3f06(0xf1)](/<(.+)>/)?.[0x1]||_0x241ef0;if(!_0x4eab8b[_0x1a3f06(0xeb)][_0x1a3f06(0xd4)](_0x5243c5)){a13_0x3f5789['dim']('[Email]\x20Ignored\x20mail\x20from\x20'+_0x241ef0+_0x1a3f06(0xf8));continue;}}const _0x40d6d6=_0x55c058[_0x1a3f06(0xec)]['find'](_0x3247f0=>_0x3247f0[_0x1a3f06(0xdd)]===_0x1a3f06(0xef)),_0x5d420b=_0x40d6d6?.[_0x1a3f06(0xdf)]||'';a13_0x3f5789[_0x1a3f06(0xdc)]('[Email]\x20From:\x20'+_0x241ef0+_0x1a3f06(0xf2)+_0x41cc9c);try{const _0x2a0673=_0x1a3f06(0xf9)+_0x241ef0+':\x0aSubject:\x20'+_0x41cc9c+'\x0aBody:\x0a'+_0x5d420b+'\x0a\x0aDraft\x20a\x20helpful\x20reply.\x20Structure\x20it\x20clearly.',_0x52e999=await sendChatMessage(getSelectedModel(),[{'role':_0x1a3f06(0xce),'content':_0x2a0673}]),_0x3ff840=a13_0x25b7db[_0x1a3f06(0xd3)](_0x4eab8b[_0x1a3f06(0xee)]);await _0x3ff840[_0x1a3f06(0xfd)]({'from':_0x4eab8b[_0x1a3f06(0xee)][_0x1a3f06(0xd5)]['user'],'to':_0x241ef0,'subject':_0x1a3f06(0xe1)+_0x41cc9c,'text':_0x52e999[_0x1a3f06(0xe2)]}),a13_0x3f5789[_0x1a3f06(0xd6)](_0x1a3f06(0xcd)+_0x241ef0);}catch(_0x5bfb24){a13_0x3f5789[_0x1a3f06(0xf6)]('[Email]\x20Processing/Reply\x20error:\x20'+_0x5bfb24[_0x1a3f06(0xed)]);}}_0x51a909[_0x1a3f06(0xfc)]();}catch(_0xab2e0c){}}export async function startBot(){const _0x12560c=a13_0x13b6;if(!a13_0x86a645[_0x12560c(0xfa)]())return![];if(isRunning)return!![];process[_0x12560c(0xe8)][_0x12560c(0xfb)]='0',checkEmails();const _0x20af3c=a13_0x86a645['getConfig']()[_0x12560c(0xdb)]||0x5;return intervalId=setInterval(checkEmails,_0x20af3c*0x3c*0x3e8),isRunning=!![],!![];}function a13_0x13b6(_0x1254ba,_0x3598f3){_0x1254ba=_0x1254ba-0xcd;const _0x3b8d2c=a13_0x3b8d();let _0x13b63a=_0x3b8d2c[_0x1254ba];return _0x13b63a;}export function stopBot(){intervalId&&(clearInterval(intervalId),intervalId=null),isRunning=![];}export function isBotRunning(){return isRunning;}export{isConfigured}from'./config.js';
@@ -1 +1 @@
1
- function a14_0x48cc(_0x10b305,_0x46f601){_0x10b305=_0x10b305-0x1a5;const _0x504b4a=a14_0x504b();let _0x48cc5c=_0x504b4a[_0x10b305];return _0x48cc5c;}(function(_0x4e8c73,_0x23dc89){const _0x5b66b1=a14_0x48cc,_0x358de4=_0x4e8c73();while(!![]){try{const _0xa4b3bc=parseInt(_0x5b66b1(0x1bc))/0x1+-parseInt(_0x5b66b1(0x1b2))/0x2*(-parseInt(_0x5b66b1(0x1ba))/0x3)+-parseInt(_0x5b66b1(0x1c2))/0x4+parseInt(_0x5b66b1(0x1a7))/0x5+-parseInt(_0x5b66b1(0x1ae))/0x6+-parseInt(_0x5b66b1(0x1a6))/0x7*(-parseInt(_0x5b66b1(0x1b6))/0x8)+-parseInt(_0x5b66b1(0x1a8))/0x9*(parseInt(_0x5b66b1(0x1aa))/0xa);if(_0xa4b3bc===_0x23dc89)break;else _0x358de4['push'](_0x358de4['shift']());}catch(_0x19ba41){_0x358de4['push'](_0x358de4['shift']());}}}(a14_0x504b,0xa976b));import{password,input,confirm}from'@inquirer/prompts';function a14_0x504b(){const _0x4bf952=['setEnabled','setCredentials','IMAP\x20Port:','192Djlzpi','Restart\x20the\x20CLI\x20to\x20start\x20the\x20Email\x20Agent.','IMAP\x20Host:','warn','726RZVdis','SMTP\x20Port:','976577XutiSz','info','Configure\x20advanced\x20server\x20settings?','Email\x20Provider\x20(gmail/outlook/other):','gmail','toLowerCase','316636YEQtDG','This\x20setup\x20will\x20configure\x20Woozlit\x20to\x20check\x20your\x20email\x20and\x20reply.','Email\x20Address:','81487lUGkUI','2072085RQHxzj','9JEZtyW','993','9766990KTnTct','587','imap.gmail.com','Password\x20(or\x20App\x20Password):','5073378NZWhXI','addAllowedSender','Your\x20personal\x20email\x20(that\x20you\x20will\x20send\x20FROM):','Only\x20allow\x20emails\x20from\x20yourself\x20(recommended)?','7646mmqIqk'];a14_0x504b=function(){return _0x4bf952;};return a14_0x504b();}import*as a14_0x261fca from'./config.js';import*as a14_0x5c2f42 from'../ui/output.js';export async function setupEmail(){const _0x919238=a14_0x48cc;a14_0x5c2f42[_0x919238(0x1bd)](_0x919238(0x1c3)),a14_0x5c2f42[_0x919238(0x1b9)]('Use\x20an\x20App\x20Password\x20if\x20you\x20are\x20using\x20Gmail\x20(2FA\x20enabled).');const _0x1d7fd2=await input({'message':_0x919238(0x1bf),'default':_0x919238(0x1c0)}),_0x2cfc76=await input({'message':_0x919238(0x1a5)}),_0x52850f=await password({'message':_0x919238(0x1ad)});let _0x42b320=_0x919238(0x1ac),_0x3af739=0x3e1,_0x3a0224='smtp.gmail.com',_0x35c463=0x24b;if(_0x1d7fd2[_0x919238(0x1c1)]()!==_0x919238(0x1c0)){const _0x1606dc=await confirm({'message':_0x919238(0x1be),'default':![]});if(_0x1606dc){_0x42b320=await input({'message':_0x919238(0x1b8),'default':_0x42b320});const _0x22771b=await input({'message':_0x919238(0x1b5),'default':_0x919238(0x1a9)});_0x3af739=parseInt(_0x22771b),_0x3a0224=await input({'message':'SMTP\x20Host:','default':_0x3a0224});const _0x568044=await input({'message':_0x919238(0x1bb),'default':_0x919238(0x1ab)});_0x35c463=parseInt(_0x568044);}}a14_0x261fca[_0x919238(0x1b4)](_0x2cfc76,_0x52850f,_0x42b320,_0x3af739),a14_0x261fca[_0x919238(0x1b3)](!![]);const _0x3b7978=await confirm({'message':_0x919238(0x1b1),'default':!![]});if(_0x3b7978){a14_0x261fca[_0x919238(0x1af)](_0x2cfc76);const _0x424d4c=await input({'message':_0x919238(0x1b0)});if(_0x424d4c)a14_0x261fca['addAllowedSender'](_0x424d4c);}a14_0x5c2f42['success']('Email\x20configuration\x20saved!'),a14_0x5c2f42[_0x919238(0x1bd)](_0x919238(0x1b7));}
1
+ function a14_0x46aa(_0x258c6e,_0x29644c){_0x258c6e=_0x258c6e-0x12f;const _0x1c05ac=a14_0x1c05();let _0x46aa2b=_0x1c05ac[_0x258c6e];return _0x46aa2b;}(function(_0xb8c5e5,_0x3b2c3d){const _0x3c5495=a14_0x46aa,_0x4a15ab=_0xb8c5e5();while(!![]){try{const _0x596bab=parseInt(_0x3c5495(0x135))/0x1*(-parseInt(_0x3c5495(0x13d))/0x2)+-parseInt(_0x3c5495(0x149))/0x3*(parseInt(_0x3c5495(0x137))/0x4)+parseInt(_0x3c5495(0x14a))/0x5*(parseInt(_0x3c5495(0x140))/0x6)+parseInt(_0x3c5495(0x145))/0x7*(-parseInt(_0x3c5495(0x141))/0x8)+parseInt(_0x3c5495(0x146))/0x9+parseInt(_0x3c5495(0x139))/0xa+-parseInt(_0x3c5495(0x14c))/0xb*(-parseInt(_0x3c5495(0x13a))/0xc);if(_0x596bab===_0x3b2c3d)break;else _0x4a15ab['push'](_0x4a15ab['shift']());}catch(_0x3fec2b){_0x4a15ab['push'](_0x4a15ab['shift']());}}}(a14_0x1c05,0xf08eb));function a14_0x1c05(){const _0x3dec61=['Use\x20an\x20App\x20Password\x20if\x20you\x20are\x20using\x20Gmail\x20(2FA\x20enabled).','4372JMcChe','imap.gmail.com','17075820ekUkzN','123528rESWhm','success','Restart\x20the\x20CLI\x20to\x20start\x20the\x20Email\x20Agent.','10fZykHk','info','setEnabled','6RxGFEL','1382104TSxbLD','gmail','Configure\x20advanced\x20server\x20settings?','toLowerCase','56LxcauV','7192917MRFCLS','Email\x20Provider\x20(gmail/outlook/other):','587','3450ZNdJzT','4479520NoVCRy','SMTP\x20Host:','572EJJcxz','Email\x20Address:','This\x20setup\x20will\x20configure\x20Woozlit\x20to\x20check\x20your\x20email\x20and\x20reply.','Password\x20(or\x20App\x20Password):','Your\x20personal\x20email\x20(that\x20you\x20will\x20send\x20FROM):','warn','addAllowedSender','Email\x20configuration\x20saved!','62722mtnbZW'];a14_0x1c05=function(){return _0x3dec61;};return a14_0x1c05();}import{password,input,confirm}from'@inquirer/prompts';import*as a14_0x345446 from'./config.js';import*as a14_0x3e7c74 from'../ui/output.js';export async function setupEmail(){const _0x319f0a=a14_0x46aa;a14_0x3e7c74[_0x319f0a(0x13e)](_0x319f0a(0x12f)),a14_0x3e7c74[_0x319f0a(0x132)](_0x319f0a(0x136));const _0x43315c=await input({'message':_0x319f0a(0x147),'default':_0x319f0a(0x142)}),_0x39276c=await input({'message':_0x319f0a(0x14d)}),_0x51071d=await password({'message':_0x319f0a(0x130)});let _0x4f82c2=_0x319f0a(0x138),_0x17c0af=0x3e1,_0x16ea1a='smtp.gmail.com',_0x3afbe8=0x24b;if(_0x43315c[_0x319f0a(0x144)]()!==_0x319f0a(0x142)){const _0x2563a3=await confirm({'message':_0x319f0a(0x143),'default':![]});if(_0x2563a3){_0x4f82c2=await input({'message':'IMAP\x20Host:','default':_0x4f82c2});const _0x5100fa=await input({'message':'IMAP\x20Port:','default':'993'});_0x17c0af=parseInt(_0x5100fa),_0x16ea1a=await input({'message':_0x319f0a(0x14b),'default':_0x16ea1a});const _0x42f970=await input({'message':'SMTP\x20Port:','default':_0x319f0a(0x148)});_0x3afbe8=parseInt(_0x42f970);}}a14_0x345446['setCredentials'](_0x39276c,_0x51071d,_0x4f82c2,_0x17c0af),a14_0x345446[_0x319f0a(0x13f)](!![]);const _0x16bd01=await confirm({'message':'Only\x20allow\x20emails\x20from\x20yourself\x20(recommended)?','default':!![]});if(_0x16bd01){a14_0x345446['addAllowedSender'](_0x39276c);const _0x554266=await input({'message':_0x319f0a(0x131)});if(_0x554266)a14_0x345446[_0x319f0a(0x133)](_0x554266);}a14_0x3e7c74[_0x319f0a(0x13b)](_0x319f0a(0x134)),a14_0x3e7c74[_0x319f0a(0x13e)](_0x319f0a(0x13c));}
@@ -1 +1 @@
1
- function a15_0x5bae(_0x5357ba,_0x468046){_0x5357ba=_0x5357ba-0x127;const _0x35eb93=a15_0x35eb();let _0x5baee9=_0x35eb93[_0x5357ba];return _0x5baee9;}const a15_0x54c3e0=a15_0x5bae;(function(_0x34a170,_0x424e9d){const _0xd23d6c=a15_0x5bae,_0x4c3aaa=_0x34a170();while(!![]){try{const _0x221a19=parseInt(_0xd23d6c(0x135))/0x1*(-parseInt(_0xd23d6c(0x12f))/0x2)+-parseInt(_0xd23d6c(0x13f))/0x3+-parseInt(_0xd23d6c(0x14a))/0x4*(-parseInt(_0xd23d6c(0x133))/0x5)+-parseInt(_0xd23d6c(0x138))/0x6*(parseInt(_0xd23d6c(0x12c))/0x7)+parseInt(_0xd23d6c(0x144))/0x8*(-parseInt(_0xd23d6c(0x12d))/0x9)+-parseInt(_0xd23d6c(0x136))/0xa+parseInt(_0xd23d6c(0x141))/0xb;if(_0x221a19===_0x424e9d)break;else _0x4c3aaa['push'](_0x4c3aaa['shift']());}catch(_0x4fac59){_0x4c3aaa['push'](_0x4c3aaa['shift']());}}}(a15_0x35eb,0x97df8));function a15_0x35eb(){const _0x5f2da9=['/installation/repositories?per_page=1','total_count','login','/git/refs','GitHub\x20API\x20error:\x20','2471ALZhPn','45keAdKD','utf-8','159764fDjqtv','/contents/','/pulls','GitHub\x20App','479785YlzMSM','toString','6EiguDi','5136390OcPiKo','PUT','5316fRfEnH','owner','/repos/','open','POST','refs/heads/','from','2812284KRPXJZ','2022-11-28','35723039oRztQJ','repositories','stringify','1379432NRKKpn','main','&per_page=50','sha','/comments','/user/repos?per_page=100&sort=updated','20GimENx','application/vnd.github+json','https://api.github.com','/pulls?state=','Bearer\x20','/git/ref/heads/','base64','/issues/','Not\x20authenticated\x20with\x20GitHub.\x20Run\x20\x27/github\x20login\x27\x20first.','status'];a15_0x35eb=function(){return _0x5f2da9;};return a15_0x35eb();}import{getGitHubToken}from'./auth.js';async function githubRequest(_0x48e0a3,_0x35f53a={}){const _0x1a2e29=a15_0x5bae,_0x3ee364=await getGitHubToken();if(!_0x3ee364)throw new Error(_0x1a2e29(0x152));const _0x3d5e9f=await fetch(_0x1a2e29(0x14c)+_0x48e0a3,{..._0x35f53a,'headers':{'Authorization':_0x1a2e29(0x14e)+_0x3ee364,'Accept':_0x1a2e29(0x14b),'X-GitHub-Api-Version':_0x1a2e29(0x140),..._0x35f53a['headers']}});if(!_0x3d5e9f['ok']){const _0x4311fe=await _0x3d5e9f['text']();throw new Error(_0x1a2e29(0x12b)+_0x3d5e9f[_0x1a2e29(0x153)]+'\x20-\x20'+_0x4311fe);}return _0x3d5e9f['json']();}export async function listRepos(){const _0x507516=a15_0x5bae;return githubRequest(_0x507516(0x149));}export async function getRepo(_0x41df3a,_0x4b285a){return githubRequest('/repos/'+_0x41df3a+'/'+_0x4b285a);}export async function readFile(_0x181d4e,_0xbe7fc5,_0x1939c8,_0xb26460=a15_0x54c3e0(0x145)){const _0x5acfa3=a15_0x54c3e0,_0x2c360c=await githubRequest(_0x5acfa3(0x13a)+_0x181d4e+'/'+_0xbe7fc5+_0x5acfa3(0x130)+_0x1939c8+'?ref='+_0xb26460),_0x11fa0e=Buffer[_0x5acfa3(0x13e)](_0x2c360c['content'],_0x5acfa3(0x150))[_0x5acfa3(0x134)](_0x5acfa3(0x12e));return _0x11fa0e;}export async function createOrUpdateFile(_0x2865a8,_0x4ee6bd,_0x52c7b2,_0x279c61,_0x238438,_0x105ceb='main',_0x40ae14){const _0x13aa6a=a15_0x54c3e0,_0x2db825=Buffer[_0x13aa6a(0x13e)](_0x279c61)[_0x13aa6a(0x134)](_0x13aa6a(0x150));return githubRequest(_0x13aa6a(0x13a)+_0x2865a8+'/'+_0x4ee6bd+_0x13aa6a(0x130)+_0x52c7b2,{'method':_0x13aa6a(0x137),'body':JSON[_0x13aa6a(0x143)]({'message':_0x238438,'content':_0x2db825,'branch':_0x105ceb,..._0x40ae14&&{'sha':_0x40ae14}})});}export async function createPullRequest(_0x5bbbad,_0x2bfe44,_0x290c12,_0x1a99d9,_0x474515=a15_0x54c3e0(0x145),_0x11cc7e){const _0x21fa45=a15_0x54c3e0;return githubRequest(_0x21fa45(0x13a)+_0x5bbbad+'/'+_0x2bfe44+_0x21fa45(0x131),{'method':_0x21fa45(0x13c),'body':JSON['stringify']({'title':_0x290c12,'head':_0x1a99d9,'base':_0x474515,'body':_0x11cc7e||''})});}export async function listPullRequests(_0x544ed9,_0x255a30,_0xd59b4c=a15_0x54c3e0(0x13b)){const _0x569770=a15_0x54c3e0;return githubRequest(_0x569770(0x13a)+_0x544ed9+'/'+_0x255a30+_0x569770(0x14d)+_0xd59b4c+_0x569770(0x146));}export async function commentOnPR(_0x15aca3,_0x1aaf3f,_0x5b750e,_0xc80377){const _0x305cc2=a15_0x54c3e0;return githubRequest(_0x305cc2(0x13a)+_0x15aca3+'/'+_0x1aaf3f+_0x305cc2(0x151)+_0x5b750e+_0x305cc2(0x148),{'method':_0x305cc2(0x13c),'body':JSON[_0x305cc2(0x143)]({'body':_0xc80377})});}export async function createBranch(_0x15d45f,_0x113807,_0x34f3b4,_0x291b1a=a15_0x54c3e0(0x145)){const _0xcab2c6=a15_0x54c3e0,_0x195cba=await githubRequest(_0xcab2c6(0x13a)+_0x15d45f+'/'+_0x113807+_0xcab2c6(0x14f)+_0x291b1a);return githubRequest(_0xcab2c6(0x13a)+_0x15d45f+'/'+_0x113807+_0xcab2c6(0x12a),{'method':_0xcab2c6(0x13c),'body':JSON[_0xcab2c6(0x143)]({'ref':_0xcab2c6(0x13d)+_0x34f3b4,'sha':_0x195cba['object'][_0xcab2c6(0x147)]})});}export async function getAppStatus(){const _0x4632ec=a15_0x54c3e0;try{const _0x5da08d=await githubRequest(_0x4632ec(0x127)),_0x10b312=_0x5da08d[_0x4632ec(0x128)];let _0x102814=_0x4632ec(0x132);return _0x5da08d[_0x4632ec(0x142)]&&_0x5da08d['repositories']['length']>0x0&&(_0x102814=_0x5da08d[_0x4632ec(0x142)][0x0][_0x4632ec(0x139)][_0x4632ec(0x129)]),{'valid':!![],'repoCount':_0x10b312,'accountName':_0x102814};}catch(_0x26c6b0){throw _0x26c6b0;}}
1
+ const a15_0x4a3e72=a15_0x2c3f;(function(_0x4abaaa,_0xd82084){const _0x15f5cd=a15_0x2c3f,_0x29cb2b=_0x4abaaa();while(!![]){try{const _0x4b3224=-parseInt(_0x15f5cd(0x146))/0x1*(-parseInt(_0x15f5cd(0x14e))/0x2)+-parseInt(_0x15f5cd(0x15e))/0x3*(parseInt(_0x15f5cd(0x15f))/0x4)+-parseInt(_0x15f5cd(0x14b))/0x5+parseInt(_0x15f5cd(0x137))/0x6*(-parseInt(_0x15f5cd(0x145))/0x7)+parseInt(_0x15f5cd(0x153))/0x8+parseInt(_0x15f5cd(0x142))/0x9*(parseInt(_0x15f5cd(0x151))/0xa)+parseInt(_0x15f5cd(0x13d))/0xb;if(_0x4b3224===_0xd82084)break;else _0x29cb2b['push'](_0x29cb2b['shift']());}catch(_0x727a9a){_0x29cb2b['push'](_0x29cb2b['shift']());}}}(a15_0x2f19,0xb75bb));import{getGitHubToken}from'./auth.js';async function githubRequest(_0x46ea5a,_0x1a41de={}){const _0x183822=a15_0x2c3f,_0x3a5643=await getGitHubToken();if(!_0x3a5643)throw new Error('Not\x20authenticated\x20with\x20GitHub.\x20Run\x20\x27/github\x20login\x27\x20first.');const _0x301d17=await fetch(_0x183822(0x13f)+_0x46ea5a,{..._0x1a41de,'headers':{'Authorization':_0x183822(0x14f)+_0x3a5643,'Accept':_0x183822(0x150),'X-GitHub-Api-Version':_0x183822(0x13a),..._0x1a41de[_0x183822(0x13e)]}});if(!_0x301d17['ok']){const _0x277a9c=await _0x301d17['text']();throw new Error(_0x183822(0x159)+_0x301d17[_0x183822(0x162)]+_0x183822(0x161)+_0x277a9c);}return _0x301d17['json']();}export async function listRepos(){const _0x25fadb=a15_0x2c3f;return githubRequest(_0x25fadb(0x15a));}export async function getRepo(_0x5641e1,_0x3d8ef9){return githubRequest('/repos/'+_0x5641e1+'/'+_0x3d8ef9);}export async function readFile(_0x119bc5,_0x49d367,_0x2c8fa2,_0x1d0206='main'){const _0x308533=a15_0x2c3f,_0x25ec99=await githubRequest('/repos/'+_0x119bc5+'/'+_0x49d367+_0x308533(0x13b)+_0x2c8fa2+_0x308533(0x138)+_0x1d0206),_0x172815=Buffer[_0x308533(0x15b)](_0x25ec99[_0x308533(0x141)],'base64')['toString'](_0x308533(0x14c));return _0x172815;}export async function createOrUpdateFile(_0x4f90c2,_0x2850f9,_0x5cbaff,_0x2dbb8a,_0xb6cba,_0x37bbe9='main',_0x52dd34){const _0x38af58=a15_0x2c3f,_0x52a802=Buffer['from'](_0x2dbb8a)[_0x38af58(0x157)](_0x38af58(0x152));return githubRequest(_0x38af58(0x154)+_0x4f90c2+'/'+_0x2850f9+_0x38af58(0x13b)+_0x5cbaff,{'method':_0x38af58(0x139),'body':JSON[_0x38af58(0x147)]({'message':_0xb6cba,'content':_0x52a802,'branch':_0x37bbe9,..._0x52dd34&&{'sha':_0x52dd34}})});}function a15_0x2c3f(_0xc0187c,_0x20b8fd){_0xc0187c=_0xc0187c-0x137;const _0x2f1939=a15_0x2f19();let _0x2c3f7b=_0x2f1939[_0xc0187c];return _0x2c3f7b;}export async function createPullRequest(_0x372940,_0x2f39b4,_0x1add9f,_0x11fa1d,_0x40f2fb='main',_0x28993f){const _0x4416fc=a15_0x2c3f;return githubRequest(_0x4416fc(0x154)+_0x372940+'/'+_0x2f39b4+_0x4416fc(0x160),{'method':_0x4416fc(0x148),'body':JSON[_0x4416fc(0x147)]({'title':_0x1add9f,'head':_0x11fa1d,'base':_0x40f2fb,'body':_0x28993f||''})});}export async function listPullRequests(_0x5e4a00,_0x2b2e76,_0x5ee921=a15_0x4a3e72(0x15c)){const _0x1ff994=a15_0x4a3e72;return githubRequest(_0x1ff994(0x154)+_0x5e4a00+'/'+_0x2b2e76+_0x1ff994(0x156)+_0x5ee921+_0x1ff994(0x14a));}function a15_0x2f19(){const _0x722f00=['5075567TDyQDz','393CqozJl','stringify','POST','total_count','&per_page=50','7383940eDbdlR','utf-8','main','6372DQMVmE','Bearer\x20','application/vnd.github+json','82090NYvclS','base64','11750600IkdMkn','/repos/','length','/pulls?state=','toString','/installation/repositories?per_page=1','GitHub\x20API\x20error:\x20','/user/repos?per_page=100&sort=updated','from','open','repositories','767229PazaZY','12QgFGKs','/pulls','\x20-\x20','status','6gyykMS','?ref=','PUT','2022-11-28','/contents/','owner','9456227aoKzKH','headers','https://api.github.com','/comments','content','153jccztt','/git/refs','object'];a15_0x2f19=function(){return _0x722f00;};return a15_0x2f19();}export async function commentOnPR(_0xfbf49e,_0x45e3bd,_0x1220a8,_0x36f729){const _0x2b5088=a15_0x4a3e72;return githubRequest(_0x2b5088(0x154)+_0xfbf49e+'/'+_0x45e3bd+'/issues/'+_0x1220a8+_0x2b5088(0x140),{'method':_0x2b5088(0x148),'body':JSON[_0x2b5088(0x147)]({'body':_0x36f729})});}export async function createBranch(_0x5abf8c,_0x290ec0,_0x4f7441,_0x1c2b6c=a15_0x4a3e72(0x14d)){const _0x496522=a15_0x4a3e72,_0x2ed4cb=await githubRequest(_0x496522(0x154)+_0x5abf8c+'/'+_0x290ec0+'/git/ref/heads/'+_0x1c2b6c);return githubRequest(_0x496522(0x154)+_0x5abf8c+'/'+_0x290ec0+_0x496522(0x143),{'method':_0x496522(0x148),'body':JSON[_0x496522(0x147)]({'ref':'refs/heads/'+_0x4f7441,'sha':_0x2ed4cb[_0x496522(0x144)]['sha']})});}export async function getAppStatus(){const _0x2381a8=a15_0x4a3e72;try{const _0x497ee0=await githubRequest(_0x2381a8(0x158)),_0x136f94=_0x497ee0[_0x2381a8(0x149)];let _0x29c346='GitHub\x20App';return _0x497ee0[_0x2381a8(0x15d)]&&_0x497ee0[_0x2381a8(0x15d)][_0x2381a8(0x155)]>0x0&&(_0x29c346=_0x497ee0[_0x2381a8(0x15d)][0x0][_0x2381a8(0x13c)]['login']),{'valid':!![],'repoCount':_0x136f94,'accountName':_0x29c346};}catch(_0x5937fb){throw _0x5937fb;}}
@@ -1 +1 @@
1
- const a16_0x5a1a9b=a16_0x2427;function a16_0x2427(_0xfd1262,_0x406932){_0xfd1262=_0xfd1262-0x188;const _0x485eee=a16_0x485e();let _0x24276d=_0x485eee[_0xfd1262];return _0x24276d;}(function(_0x23e75b,_0x3a39d4){const _0x550536=a16_0x2427,_0x282924=_0x23e75b();while(!![]){try{const _0x39879e=-parseInt(_0x550536(0x1a0))/0x1+parseInt(_0x550536(0x197))/0x2+-parseInt(_0x550536(0x19b))/0x3+-parseInt(_0x550536(0x19f))/0x4+parseInt(_0x550536(0x188))/0x5+parseInt(_0x550536(0x189))/0x6+parseInt(_0x550536(0x1a7))/0x7;if(_0x39879e===_0x3a39d4)break;else _0x282924['push'](_0x282924['shift']());}catch(_0x2aa14b){_0x282924['push'](_0x282924['shift']());}}}(a16_0x485e,0xa63ff));import{promises as a16_0x171163}from'fs';import{join}from'path';import{createAppAuth}from'@octokit/auth-app';import{homedir}from'os';function a16_0x485e(){const _0x35c73d=['3021060lDIyfm','GitHub\x20App\x20auth\x20failed:','\x0a❌\x20GitHub\x20App\x20not\x20configured','readFile','1562868oNaUwI','157676DRHvJP','.woozlit','installationId','token','utf8','catch','You\x20can\x20now\x20access\x20private\x20repositories','7268758mgyNpN','4487225dpgiJZ','833040EEuARt','appId','✓\x20GitHub\x20session\x20cleared','parse','unlink','expiresAt','❌\x20Authentication\x20failed:','installation','access','error','then','github-app-config.json','Try\x20running\x20/github\x20setup\x20again','Error\x20clearing\x20session:','323386RODudq','privateKey','✓\x20GitHub\x20App\x20authenticated!','log'];a16_0x485e=function(){return _0x35c73d;};return a16_0x485e();}const GLOBAL_CONFIG_DIR=join(homedir(),a16_0x5a1a9b(0x1a1)),CONFIG_FILE=join(GLOBAL_CONFIG_DIR,a16_0x5a1a9b(0x194)),KEY_FILE=join(GLOBAL_CONFIG_DIR,'github-app.pem');let appAuth=null,installationToken=null;async function getGitHubAppConfig(){const _0x294ba1=a16_0x5a1a9b;try{const _0x42f9fa=await a16_0x171163['access'](CONFIG_FILE)[_0x294ba1(0x193)](()=>!![])['catch'](()=>![]),_0x1ebc91=await a16_0x171163[_0x294ba1(0x191)](KEY_FILE)['then'](()=>!![])[_0x294ba1(0x1a5)](()=>![]);if(!_0x42f9fa||!_0x1ebc91)return null;const _0x244cd1=await a16_0x171163[_0x294ba1(0x19e)](CONFIG_FILE,'utf8'),{appId:_0x44206b,installationId:_0x55bdc4}=JSON[_0x294ba1(0x18c)](_0x244cd1),_0x37c094=await a16_0x171163[_0x294ba1(0x19e)](KEY_FILE,_0x294ba1(0x1a4));if(!_0x44206b||!_0x55bdc4||!_0x37c094)return null;return{'appId':_0x44206b,'privateKey':_0x37c094,'installationId':_0x55bdc4};}catch(_0x270eb8){return null;}}async function initAppAuth(){const _0x187069=a16_0x5a1a9b;if(appAuth)return;const _0xa05a10=await getGitHubAppConfig();if(!_0xa05a10)throw new Error('GitHub\x20App\x20not\x20configured.\x20Run\x20/github\x20setup');appAuth=createAppAuth({'appId':_0xa05a10[_0x187069(0x18a)],'privateKey':_0xa05a10[_0x187069(0x198)],'installationId':_0xa05a10[_0x187069(0x1a2)]});}async function getInstallationToken(){const _0x2c20e4=a16_0x5a1a9b;await initAppAuth();if(installationToken&&installationToken[_0x2c20e4(0x18e)]>new Date())return installationToken[_0x2c20e4(0x1a3)];const {token:_0x282a8b,expiresAt:_0x1b9ed5}=await appAuth({'type':_0x2c20e4(0x190)});return installationToken={'token':_0x282a8b,'expiresAt':new Date(_0x1b9ed5)},_0x282a8b;}export async function getGitHubToken(){const _0x432722=a16_0x5a1a9b;try{return await getInstallationToken();}catch(_0x3b1c2d){return console[_0x432722(0x192)](_0x432722(0x19c),_0x3b1c2d),null;}}export async function isGitHubAuthenticated(){const _0xacb258=await getGitHubAppConfig();return _0xacb258!==null;}export async function loginGitHub(){const _0x3540d5=a16_0x5a1a9b,_0xcee37b=await getGitHubAppConfig();if(!_0xcee37b){console['log'](_0x3540d5(0x19d)),console['log']('Run\x20/github\x20setup\x20to\x20configure\x20automatically');return;}try{const _0x2dd007=await getInstallationToken();console[_0x3540d5(0x19a)](_0x3540d5(0x199)),console[_0x3540d5(0x19a)](_0x3540d5(0x1a6));}catch(_0x428eb2){console[_0x3540d5(0x192)](_0x3540d5(0x18f),_0x428eb2),console[_0x3540d5(0x19a)](_0x3540d5(0x195));}}export async function logoutGitHub(){const _0x149c07=a16_0x5a1a9b;try{await a16_0x171163['unlink'](CONFIG_FILE)[_0x149c07(0x1a5)](()=>{}),await a16_0x171163[_0x149c07(0x18d)](KEY_FILE)['catch'](()=>{}),installationToken=null,appAuth=null,console['log'](_0x149c07(0x18b));}catch(_0x3ee804){console['error'](_0x149c07(0x196),_0x3ee804);}}
1
+ const a16_0x10b16c=a16_0x2f8b;(function(_0x10cbf0,_0x2f0731){const _0x113282=a16_0x2f8b,_0x3d0d7a=_0x10cbf0();while(!![]){try{const _0x44f8b1=-parseInt(_0x113282(0xbc))/0x1+-parseInt(_0x113282(0xbb))/0x2*(parseInt(_0x113282(0xb3))/0x3)+parseInt(_0x113282(0xaf))/0x4*(-parseInt(_0x113282(0xac))/0x5)+-parseInt(_0x113282(0xb2))/0x6*(parseInt(_0x113282(0xa3))/0x7)+-parseInt(_0x113282(0xb9))/0x8*(-parseInt(_0x113282(0xad))/0x9)+parseInt(_0x113282(0xba))/0xa+parseInt(_0x113282(0xc4))/0xb;if(_0x44f8b1===_0x2f0731)break;else _0x3d0d7a['push'](_0x3d0d7a['shift']());}catch(_0x2633ba){_0x3d0d7a['push'](_0x3d0d7a['shift']());}}}(a16_0x5d4f,0x81d85));function a16_0x5d4f(){const _0x5828aa=['7200OnsqgZ','186884sViUJE','✓\x20GitHub\x20App\x20authenticated!','token','log','parse','access','then','GitHub\x20App\x20auth\x20failed:','17884493PBrFig','readFile','73717bDutJx','installation','error','privateKey','.woozlit','utf8','github-app-config.json','❌\x20Authentication\x20failed:','Try\x20running\x20/github\x20setup\x20again','539615lgnLZL','800937LhYLch','installationId','24VlqMAU','Run\x20/github\x20setup\x20to\x20configure\x20automatically','expiresAt','186IyUlOm','54CSqHdC','catch','\x0a❌\x20GitHub\x20App\x20not\x20configured','✓\x20GitHub\x20session\x20cleared','GitHub\x20App\x20not\x20configured.\x20Run\x20/github\x20setup','github-app.pem','8JRNjPF','426720BYwsTa'];a16_0x5d4f=function(){return _0x5828aa;};return a16_0x5d4f();}import{promises as a16_0x151ad5}from'fs';function a16_0x2f8b(_0x7dfcda,_0x452796){_0x7dfcda=_0x7dfcda-0xa2;const _0x5d4f56=a16_0x5d4f();let _0x2f8baa=_0x5d4f56[_0x7dfcda];return _0x2f8baa;}import{join}from'path';import{createAppAuth}from'@octokit/auth-app';import{homedir}from'os';const GLOBAL_CONFIG_DIR=join(homedir(),a16_0x10b16c(0xa7)),CONFIG_FILE=join(GLOBAL_CONFIG_DIR,a16_0x10b16c(0xa9)),KEY_FILE=join(GLOBAL_CONFIG_DIR,a16_0x10b16c(0xb8));let appAuth=null,installationToken=null;async function getGitHubAppConfig(){const _0x35dfa2=a16_0x10b16c;try{const _0x72bd5b=await a16_0x151ad5[_0x35dfa2(0xc1)](CONFIG_FILE)[_0x35dfa2(0xc2)](()=>!![])[_0x35dfa2(0xb4)](()=>![]),_0x233675=await a16_0x151ad5[_0x35dfa2(0xc1)](KEY_FILE)[_0x35dfa2(0xc2)](()=>!![])['catch'](()=>![]);if(!_0x72bd5b||!_0x233675)return null;const _0x2b966a=await a16_0x151ad5['readFile'](CONFIG_FILE,_0x35dfa2(0xa8)),{appId:_0x150aaf,installationId:_0x603d64}=JSON[_0x35dfa2(0xc0)](_0x2b966a),_0x252642=await a16_0x151ad5[_0x35dfa2(0xa2)](KEY_FILE,_0x35dfa2(0xa8));if(!_0x150aaf||!_0x603d64||!_0x252642)return null;return{'appId':_0x150aaf,'privateKey':_0x252642,'installationId':_0x603d64};}catch(_0x3bbd13){return null;}}async function initAppAuth(){const _0x21c2de=a16_0x10b16c;if(appAuth)return;const _0x2b9315=await getGitHubAppConfig();if(!_0x2b9315)throw new Error(_0x21c2de(0xb7));appAuth=createAppAuth({'appId':_0x2b9315['appId'],'privateKey':_0x2b9315[_0x21c2de(0xa6)],'installationId':_0x2b9315[_0x21c2de(0xae)]});}async function getInstallationToken(){const _0x241e63=a16_0x10b16c;await initAppAuth();if(installationToken&&installationToken[_0x241e63(0xb1)]>new Date())return installationToken[_0x241e63(0xbe)];const {token:_0x15cea0,expiresAt:_0x1111b1}=await appAuth({'type':_0x241e63(0xa4)});return installationToken={'token':_0x15cea0,'expiresAt':new Date(_0x1111b1)},_0x15cea0;}export async function getGitHubToken(){const _0x5a6f1a=a16_0x10b16c;try{return await getInstallationToken();}catch(_0x1e0449){return console[_0x5a6f1a(0xa5)](_0x5a6f1a(0xc3),_0x1e0449),null;}}export async function isGitHubAuthenticated(){const _0x319042=await getGitHubAppConfig();return _0x319042!==null;}export async function loginGitHub(){const _0x23a130=a16_0x10b16c,_0x29cac3=await getGitHubAppConfig();if(!_0x29cac3){console[_0x23a130(0xbf)](_0x23a130(0xb5)),console[_0x23a130(0xbf)](_0x23a130(0xb0));return;}try{const _0x5ee2cd=await getInstallationToken();console[_0x23a130(0xbf)](_0x23a130(0xbd)),console[_0x23a130(0xbf)]('You\x20can\x20now\x20access\x20private\x20repositories');}catch(_0x43ab67){console[_0x23a130(0xa5)](_0x23a130(0xaa),_0x43ab67),console[_0x23a130(0xbf)](_0x23a130(0xab));}}export async function logoutGitHub(){const _0x181b85=a16_0x10b16c;try{await a16_0x151ad5['unlink'](CONFIG_FILE)[_0x181b85(0xb4)](()=>{}),await a16_0x151ad5['unlink'](KEY_FILE)[_0x181b85(0xb4)](()=>{}),installationToken=null,appAuth=null,console[_0x181b85(0xbf)](_0x181b85(0xb6));}catch(_0x3ecf19){console[_0x181b85(0xa5)]('Error\x20clearing\x20session:',_0x3ecf19);}}
@@ -1 +1 @@
1
- (function(_0x3539a5,_0x11dc5f){const _0x31f9b5=a17_0x3da1,_0x5d4e6b=_0x3539a5();while(!![]){try{const _0x4cdf9f=-parseInt(_0x31f9b5(0x102))/0x1*(-parseInt(_0x31f9b5(0xe6))/0x2)+parseInt(_0x31f9b5(0xed))/0x3+-parseInt(_0x31f9b5(0xeb))/0x4*(parseInt(_0x31f9b5(0xfd))/0x5)+parseInt(_0x31f9b5(0xe2))/0x6+parseInt(_0x31f9b5(0xdb))/0x7*(parseInt(_0x31f9b5(0xfb))/0x8)+parseInt(_0x31f9b5(0xfe))/0x9+-parseInt(_0x31f9b5(0xf6))/0xa;if(_0x4cdf9f===_0x11dc5f)break;else _0x5d4e6b['push'](_0x5d4e6b['shift']());}catch(_0x282ff4){_0x5d4e6b['push'](_0x5d4e6b['shift']());}}}(a17_0x2eff,0x3dac8));import{promises as a17_0x8e4ac0}from'fs';import{join}from'path';function a17_0x3da1(_0x5b93ce,_0x4ed35e){_0x5b93ce=_0x5b93ce-0xbd;const _0x2eff22=a17_0x2eff();let _0x3da1de=_0x2eff22[_0x5b93ce];return _0x3da1de;}import*as a17_0x278794 from'../ui/output.js';import{createServer}from'http';import a17_0x36d221 from'open';import{homedir}from'os';import{createAppAuth}from'@octokit/auth-app';import{input}from'@inquirer/prompts';async function createGitHubAppManifestFlow(){return new Promise(async(_0x2ef24a,_0x5ecd9e)=>{const _0x1f8d49=a17_0x3da1;let _0x190492=![];const _0x5c615f=createServer(async(_0x530c2d,_0x4af304)=>{const _0x589914=a17_0x3da1;if(_0x530c2d['url']==='/favicon.ico'){_0x4af304[_0x589914(0xc5)](0x194),_0x4af304[_0x589914(0xf3)]();return;}a17_0x278794[_0x589914(0xdd)]('Received\x20request:\x20'+_0x530c2d[_0x589914(0xd0)]+'\x20'+_0x530c2d['url']);const _0xc29020=new URL(_0x530c2d[_0x589914(0xd5)]||'/',_0x589914(0xd1)),_0xa1bbd8=_0xc29020[_0x589914(0xc2)][_0x589914(0xe1)](_0x589914(0xdf));_0xa1bbd8?(_0x4af304[_0x589914(0xc5)](0xc8,{'Content-Type':'text/html'}),_0x4af304[_0x589914(0xf3)](_0x589914(0xc6)),_0x4af304[_0x589914(0xce)](),!_0x190492&&(_0x190492=!![],_0x5c615f['close'](),_0x46a0fa(_0xa1bbd8))):(_0x4af304[_0x589914(0xc5)](0x190),_0x4af304[_0x589914(0xf3)](_0x589914(0xbe)));}),_0x46a0fa=async _0x247a25=>{const _0x3e3d22=a17_0x3da1;try{a17_0x278794['info']('\x0aStep\x202:\x20Registering\x20GitHub\x20App...');const _0x1ac22a=await fetch(_0x3e3d22(0xc3)+_0x247a25+_0x3e3d22(0xd9),{'method':'POST','headers':{'Accept':_0x3e3d22(0xbd)}});if(!_0x1ac22a['ok'])throw new Error('Failed\x20to\x20exchange\x20code:\x20'+await _0x1ac22a['text']());const _0x30ec40=await _0x1ac22a[_0x3e3d22(0xf0)]();_0x2ef24a(_0x30ec40);}catch(_0x266b6f){_0x5ecd9e(_0x266b6f);}};_0x5c615f[_0x1f8d49(0xec)](0xbb8,'127.0.0.1',async()=>{const _0x4f1939=_0x1f8d49,_0x88b892={'name':_0x4f1939(0xef)+Date[_0x4f1939(0xd4)](),'url':_0x4f1939(0xd1),'hook_attributes':{'url':'http://127.0.0.1:3000/webhook'},'redirect_url':_0x4f1939(0xcc),'public':![],'default_permissions':{'contents':_0x4f1939(0xf9),'pull_requests':_0x4f1939(0xf9),'metadata':_0x4f1939(0xd6)},'default_events':[]},_0x11d2d2=new URLSearchParams({'manifest':JSON[_0x4f1939(0xee)](_0x88b892)}),_0x5cdb2e='https://github.com/settings/apps/new?'+_0x11d2d2[_0x4f1939(0xea)]();a17_0x278794['info']('Step\x201:\x20Opening\x20GitHub\x20to\x20create\x20App...'),a17_0x278794[_0x4f1939(0xdd)](_0x4f1939(0xfa)+_0x5cdb2e);try{await a17_0x36d221(_0x5cdb2e),a17_0x278794['success']('Browser\x20opened!\x20Please\x20click\x20\x22Create\x20GitHub\x20App\x22\x20on\x20the\x20page.'),a17_0x278794[_0x4f1939(0xf7)]('\x0awaiting\x20for\x20browser\x20callback...'),a17_0x278794[_0x4f1939(0xdd)]('(If\x20nothing\x20happens,\x20copy\x20the\x20\x22code\x22\x20parameter\x20from\x20the\x20browser\x20URL\x20address\x20bar\x20and\x20paste\x20it\x20below,\x20or\x20simply\x20press\x20Enter\x20to\x20start\x20manual\x20entry)');try{const _0x332810=await input({'message':'Paste\x20code\x20(or\x20wait\x20for\x20automatic\x20redirect):','transformer':_0x3f8689=>_0x3f8689[_0x4f1939(0xcf)]()});_0x332810&&!_0x190492&&(_0x190492=!![],_0x5c615f[_0x4f1939(0xe7)](),_0x46a0fa(_0x332810));}catch(_0x1cceb5){}}catch(_0x170866){a17_0x278794['error'](_0x4f1939(0xd8)),a17_0x278794[_0x4f1939(0xf7)](_0x4f1939(0xde)+_0x5cdb2e);}}),_0x5c615f['on'](_0x1f8d49(0xbf),_0x23dae4=>{const _0x1dbf75=_0x1f8d49;a17_0x278794[_0x1dbf75(0xbf)](_0x1dbf75(0xdc)+_0x23dae4),_0x5ecd9e(_0x23dae4);});});}async function saveConfig(_0x2f66fc,_0x4d33ef,_0xf6e1de){const _0x9128df=a17_0x3da1,_0x470b76=join(homedir(),_0x9128df(0xf4));try{await a17_0x8e4ac0[_0x9128df(0x101)](_0x470b76);}catch{await a17_0x8e4ac0['mkdir'](_0x470b76,{'recursive':!![]});}const _0x2b0dd1=join(_0x470b76,'github-app-config.json'),_0x2a10d6=join(_0x470b76,_0x9128df(0xc7));await a17_0x8e4ac0[_0x9128df(0xcd)](_0x2a10d6,_0x4d33ef,_0x9128df(0xe9)),await a17_0x8e4ac0['writeFile'](_0x2b0dd1,JSON[_0x9128df(0xee)]({'appId':_0x2f66fc,'installationId':_0xf6e1de},null,0x2),_0x9128df(0xe9));}function a17_0x2eff(){const _0x5cbf87=['Press\x20Enter\x20after\x20you\x20have\x20installed\x20the\x20app...','Please\x20install\x20the\x20app\x20on\x20your\x20account/repositories.','957778biLOSj','close','Configuration\x20saved\x20globally\x20to\x20~/.woozlit/','utf8','toString','1120huxgqL','listen','1510956fSsxJX','stringify','Woozlit\x20CLI\x20','json','\x0aYou\x20can\x20try\x20manual\x20setup\x20with:\x20/github\x20manual','html_url','end','.woozlit','Opened:\x20','15032600mLrHKd','info','exit','write','Url:\x20','16FXIWkS','App\x20ID:\x20','820djRynW','426150vaAmgd','name','success','access','1jHpcYg','GitHub\x20App\x20Auto-Setup','application/vnd.github+json','No\x20code\x20found','error','length','/app/installations','searchParams','https://api.github.com/app-manifests/','pem','writeHead','<h1>Setup\x20Complete!</h1><p>You\x20can\x20close\x20this\x20tab\x20and\x20return\x20to\x20the\x20terminal.</p>','github-app.pem','\x0aSetup\x20failed:\x20','hook','\x0a✓\x20GitHub\x20App\x20created!','App\x20created\x20but\x20not\x20installed\x20yet.','http://127.0.0.1:3000/callback','writeFile','destroy','trim','method','http://127.0.0.1:3000','/installations/new','\x0aStep\x203:\x20Checking\x20installation...','now','url','read','stdin','Failed\x20to\x20open\x20browser\x20automatically.','/conversions','\x0a✓\x20GitHub\x20App\x20setup\x20complete!','943971wrHEKQ','Server\x20error:\x20','dim','Please\x20visit\x20this\x20URL\x20manually:\x0a','code','once','get','3013194NQOQwZ','Could\x20not\x20find\x20installation.\x20Please\x20try\x20again.'];a17_0x2eff=function(){return _0x5cbf87;};return a17_0x2eff();}async function installAppIfNeeded(_0x3b2758){const _0x220e2b=a17_0x3da1;a17_0x278794[_0x220e2b(0xf7)](_0x220e2b(0xd3));const _0x1220bc=createAppAuth({'appId':_0x3b2758['id'],'privateKey':_0x3b2758[_0x220e2b(0xc4)]});try{const {data:_0x40b485}=await _0x1220bc[_0x220e2b(0xc9)]((_0x5b11c3,_0x53267b)=>_0x5b11c3(_0x53267b),{'method':'GET','url':_0x220e2b(0xc1)});if(_0x40b485&&_0x40b485['length']>0x0)return _0x40b485[0x0]['id'];}catch(_0x2d1b31){}a17_0x278794[_0x220e2b(0xf7)](_0x220e2b(0xcb)),a17_0x278794[_0x220e2b(0xf7)](_0x220e2b(0xe5));const _0x20720e=_0x3b2758[_0x220e2b(0xf2)]+_0x220e2b(0xd2);await a17_0x36d221(_0x20720e),a17_0x278794[_0x220e2b(0xf7)](_0x220e2b(0xf5)+_0x20720e),a17_0x278794[_0x220e2b(0xf7)](_0x220e2b(0xe4)),await new Promise(_0x42797f=>process[_0x220e2b(0xd7)][_0x220e2b(0xe0)]('data',_0x42797f));const _0x3d5b17=createAppAuth({'appId':_0x3b2758['id'],'privateKey':_0x3b2758['pem']}),{data:_0x2c319c}=await _0x3d5b17[_0x220e2b(0xc9)]((_0x4b109c,_0x3f3e57)=>_0x4b109c(_0x3f3e57),{'method':'GET','url':_0x220e2b(0xc1)});if(_0x2c319c&&_0x2c319c[_0x220e2b(0xc0)]>0x0)return _0x2c319c[0x0]['id'];throw new Error(_0x220e2b(0xe3));}export async function autoSetupGitHub(){const _0x593a1d=a17_0x3da1;a17_0x278794['header'](_0x593a1d(0x103)),a17_0x278794[_0x593a1d(0xdd)]('This\x20will\x20create\x20a\x20GitHub\x20App\x20automatically\x20via\x20Manifest\x20Flow\x0a');try{const _0x215fee=await createGitHubAppManifestFlow();a17_0x278794[_0x593a1d(0x100)](_0x593a1d(0xca));const _0x5407e9=await installAppIfNeeded(_0x215fee);a17_0x278794[_0x593a1d(0x100)]('✓\x20App\x20installed!'),a17_0x278794[_0x593a1d(0xf7)]('\x0aStep\x204:\x20Saving\x20configuration...'),await saveConfig(_0x215fee['id'],_0x215fee['pem'],_0x5407e9),a17_0x278794[_0x593a1d(0x100)](_0x593a1d(0xda)),a17_0x278794[_0x593a1d(0xdd)](_0x593a1d(0xfc)+_0x215fee['id']),a17_0x278794[_0x593a1d(0xdd)]('App\x20Name:\x20'+_0x215fee[_0x593a1d(0xff)]),a17_0x278794[_0x593a1d(0xdd)](_0x593a1d(0xe8)),a17_0x278794['success']('You\x20can\x20now\x20access\x20private\x20repositories!');}catch(_0x2cfdcc){a17_0x278794[_0x593a1d(0xbf)](_0x593a1d(0xc8)+_0x2cfdcc),a17_0x278794[_0x593a1d(0xdd)](_0x593a1d(0xf1)),process[_0x593a1d(0xf8)](0x1);}}
1
+ (function(_0x136c17,_0x2448df){const _0x30664f=a17_0x30a0,_0x5f0490=_0x136c17();while(!![]){try{const _0x3e5fab=parseInt(_0x30664f(0x22d))/0x1*(parseInt(_0x30664f(0x1ef))/0x2)+parseInt(_0x30664f(0x201))/0x3*(parseInt(_0x30664f(0x202))/0x4)+-parseInt(_0x30664f(0x21b))/0x5+parseInt(_0x30664f(0x20d))/0x6+parseInt(_0x30664f(0x20a))/0x7+parseInt(_0x30664f(0x20c))/0x8+parseInt(_0x30664f(0x214))/0x9*(-parseInt(_0x30664f(0x226))/0xa);if(_0x3e5fab===_0x2448df)break;else _0x5f0490['push'](_0x5f0490['shift']());}catch(_0x2cb264){_0x5f0490['push'](_0x5f0490['shift']());}}}(a17_0x4a45,0xbc777));import{promises as a17_0x3bf3b4}from'fs';import{join}from'path';import*as a17_0x33ecc3 from'../ui/output.js';import{createServer}from'http';function a17_0x4a45(){const _0xaeb0de=['App\x20Name:\x20','length','GET','(If\x20nothing\x20happens,\x20copy\x20the\x20\x22code\x22\x20parameter\x20from\x20the\x20browser\x20URL\x20address\x20bar\x20and\x20paste\x20it\x20below,\x20or\x20simply\x20press\x20Enter\x20to\x20start\x20manual\x20entry)','stdin','method','github-app.pem','4024902mOqGRr','This\x20will\x20create\x20a\x20GitHub\x20App\x20automatically\x20via\x20Manifest\x20Flow\x0a','9713808RJYMqq','4559178JurqBE','Please\x20install\x20the\x20app\x20on\x20your\x20account/repositories.','/installations/new','code','now','toString','searchParams','243459jTFznP','writeFile','text/html','destroy','success','Failed\x20to\x20exchange\x20code:\x20','html_url','3532165ddKaLl','json','\x0awaiting\x20for\x20browser\x20callback...','text','.woozlit','error','https://api.github.com/app-manifests/','\x0a✓\x20GitHub\x20App\x20setup\x20complete!','read','App\x20ID:\x20','\x0aYou\x20can\x20try\x20manual\x20setup\x20with:\x20/github\x20manual','970kbrLMc','/app/installations','Press\x20Enter\x20after\x20you\x20have\x20installed\x20the\x20app...','\x0a✓\x20GitHub\x20App\x20created!','writeHead','write','http://127.0.0.1:3000','143svyPks','hook','/favicon.ico','You\x20can\x20now\x20access\x20private\x20repositories!','info','<h1>Setup\x20Complete!</h1><p>You\x20can\x20close\x20this\x20tab\x20and\x20return\x20to\x20the\x20terminal.</p>','data','Paste\x20code\x20(or\x20wait\x20for\x20automatic\x20redirect):','utf8','Woozlit\x20CLI\x20','Server\x20error:\x20','pem','github-app-config.json','Opened:\x20','Browser\x20opened!\x20Please\x20click\x20\x22Create\x20GitHub\x20App\x22\x20on\x20the\x20page.','866QZOpwR','dim','✓\x20App\x20installed!','listen','end','GitHub\x20App\x20Auto-Setup','url','http://127.0.0.1:3000/callback','\x0aStep\x204:\x20Saving\x20configuration...','Please\x20visit\x20this\x20URL\x20manually:\x0a','close','Step\x201:\x20Opening\x20GitHub\x20to\x20create\x20App...','POST','trim','No\x20code\x20found','exit','stringify','access','45jgRZeE','397692nKARjY'];a17_0x4a45=function(){return _0xaeb0de;};return a17_0x4a45();}import a17_0x32f480 from'open';function a17_0x30a0(_0x23dc89,_0x279cf7){_0x23dc89=_0x23dc89-0x1e9;const _0x4a458b=a17_0x4a45();let _0x30a0b4=_0x4a458b[_0x23dc89];return _0x30a0b4;}import{homedir}from'os';import{createAppAuth}from'@octokit/auth-app';import{input}from'@inquirer/prompts';async function createGitHubAppManifestFlow(){return new Promise(async(_0x5a6ca5,_0x5d7a2a)=>{const _0x21ed57=a17_0x30a0;let _0x550861=![];const _0xfe47d7=createServer(async(_0x35cb3b,_0x250f8a)=>{const _0x247d6b=a17_0x30a0;if(_0x35cb3b[_0x247d6b(0x1f5)]===_0x247d6b(0x22f)){_0x250f8a[_0x247d6b(0x22a)](0x194),_0x250f8a[_0x247d6b(0x1f3)]();return;}a17_0x33ecc3[_0x247d6b(0x1f0)]('Received\x20request:\x20'+_0x35cb3b[_0x247d6b(0x208)]+'\x20'+_0x35cb3b[_0x247d6b(0x1f5)]);const _0x22fd24=new URL(_0x35cb3b[_0x247d6b(0x1f5)]||'/','http://127.0.0.1:3000'),_0x3b7b6c=_0x22fd24[_0x247d6b(0x213)]['get'](_0x247d6b(0x210));_0x3b7b6c?(_0x250f8a[_0x247d6b(0x22a)](0xc8,{'Content-Type':_0x247d6b(0x216)}),_0x250f8a['end'](_0x247d6b(0x232)),_0x250f8a[_0x247d6b(0x217)](),!_0x550861&&(_0x550861=!![],_0xfe47d7[_0x247d6b(0x1f9)](),_0x247c6f(_0x3b7b6c))):(_0x250f8a[_0x247d6b(0x22a)](0x190),_0x250f8a['end'](_0x247d6b(0x1fd)));}),_0x247c6f=async _0x483b80=>{const _0x27ff0f=a17_0x30a0;try{a17_0x33ecc3[_0x27ff0f(0x231)]('\x0aStep\x202:\x20Registering\x20GitHub\x20App...');const _0xc2adf=await fetch(_0x27ff0f(0x221)+_0x483b80+'/conversions',{'method':_0x27ff0f(0x1fb),'headers':{'Accept':'application/vnd.github+json'}});if(!_0xc2adf['ok'])throw new Error(_0x27ff0f(0x219)+await _0xc2adf[_0x27ff0f(0x21e)]());const _0x4a0309=await _0xc2adf[_0x27ff0f(0x21c)]();_0x5a6ca5(_0x4a0309);}catch(_0x14ff46){_0x5d7a2a(_0x14ff46);}};_0xfe47d7[_0x21ed57(0x1f2)](0xbb8,'127.0.0.1',async()=>{const _0x2da881=_0x21ed57,_0x53a01f={'name':_0x2da881(0x1e9)+Date[_0x2da881(0x211)](),'url':_0x2da881(0x22c),'hook_attributes':{'url':'http://127.0.0.1:3000/webhook'},'redirect_url':_0x2da881(0x1f6),'public':![],'default_permissions':{'contents':_0x2da881(0x22b),'pull_requests':_0x2da881(0x22b),'metadata':_0x2da881(0x223)},'default_events':[]},_0x1e3d03=new URLSearchParams({'manifest':JSON[_0x2da881(0x1ff)](_0x53a01f)}),_0x5a3e55='https://github.com/settings/apps/new?'+_0x1e3d03[_0x2da881(0x212)]();a17_0x33ecc3['info'](_0x2da881(0x1fa)),a17_0x33ecc3[_0x2da881(0x1f0)]('Url:\x20'+_0x5a3e55);try{await a17_0x32f480(_0x5a3e55),a17_0x33ecc3[_0x2da881(0x218)](_0x2da881(0x1ee)),a17_0x33ecc3[_0x2da881(0x231)](_0x2da881(0x21d)),a17_0x33ecc3[_0x2da881(0x1f0)](_0x2da881(0x206));try{const _0x1ad4f6=await input({'message':_0x2da881(0x234),'transformer':_0x44d00d=>_0x44d00d[_0x2da881(0x1fc)]()});_0x1ad4f6&&!_0x550861&&(_0x550861=!![],_0xfe47d7['close'](),_0x247c6f(_0x1ad4f6));}catch(_0x875707){}}catch(_0x3b37b5){a17_0x33ecc3[_0x2da881(0x220)]('Failed\x20to\x20open\x20browser\x20automatically.'),a17_0x33ecc3[_0x2da881(0x231)](_0x2da881(0x1f8)+_0x5a3e55);}}),_0xfe47d7['on'](_0x21ed57(0x220),_0x4e0a84=>{const _0x4ded2f=_0x21ed57;a17_0x33ecc3[_0x4ded2f(0x220)](_0x4ded2f(0x1ea)+_0x4e0a84),_0x5d7a2a(_0x4e0a84);});});}async function saveConfig(_0x2f3dc0,_0x4db859,_0x10bfb){const _0x2fa9c8=a17_0x30a0,_0xcd9dbe=join(homedir(),_0x2fa9c8(0x21f));try{await a17_0x3bf3b4[_0x2fa9c8(0x200)](_0xcd9dbe);}catch{await a17_0x3bf3b4['mkdir'](_0xcd9dbe,{'recursive':!![]});}const _0x3f60bc=join(_0xcd9dbe,_0x2fa9c8(0x1ec)),_0x45e17b=join(_0xcd9dbe,_0x2fa9c8(0x209));await a17_0x3bf3b4[_0x2fa9c8(0x215)](_0x45e17b,_0x4db859,_0x2fa9c8(0x235)),await a17_0x3bf3b4[_0x2fa9c8(0x215)](_0x3f60bc,JSON[_0x2fa9c8(0x1ff)]({'appId':_0x2f3dc0,'installationId':_0x10bfb},null,0x2),_0x2fa9c8(0x235));}async function installAppIfNeeded(_0x5cdf16){const _0x1b14f4=a17_0x30a0;a17_0x33ecc3[_0x1b14f4(0x231)]('\x0aStep\x203:\x20Checking\x20installation...');const _0x505405=createAppAuth({'appId':_0x5cdf16['id'],'privateKey':_0x5cdf16[_0x1b14f4(0x1eb)]});try{const {data:_0x506151}=await _0x505405[_0x1b14f4(0x22e)]((_0x38b0b2,_0x16a8bd)=>_0x38b0b2(_0x16a8bd),{'method':_0x1b14f4(0x205),'url':_0x1b14f4(0x227)});if(_0x506151&&_0x506151[_0x1b14f4(0x204)]>0x0)return _0x506151[0x0]['id'];}catch(_0x1a8009){}a17_0x33ecc3[_0x1b14f4(0x231)]('App\x20created\x20but\x20not\x20installed\x20yet.'),a17_0x33ecc3[_0x1b14f4(0x231)](_0x1b14f4(0x20e));const _0x2bd23c=_0x5cdf16[_0x1b14f4(0x21a)]+_0x1b14f4(0x20f);await a17_0x32f480(_0x2bd23c),a17_0x33ecc3[_0x1b14f4(0x231)](_0x1b14f4(0x1ed)+_0x2bd23c),a17_0x33ecc3['info'](_0x1b14f4(0x228)),await new Promise(_0xe3b72e=>process[_0x1b14f4(0x207)]['once'](_0x1b14f4(0x233),_0xe3b72e));const _0x3a5296=createAppAuth({'appId':_0x5cdf16['id'],'privateKey':_0x5cdf16[_0x1b14f4(0x1eb)]}),{data:_0x1d8600}=await _0x3a5296[_0x1b14f4(0x22e)]((_0xc1e482,_0x45c3f4)=>_0xc1e482(_0x45c3f4),{'method':_0x1b14f4(0x205),'url':_0x1b14f4(0x227)});if(_0x1d8600&&_0x1d8600[_0x1b14f4(0x204)]>0x0)return _0x1d8600[0x0]['id'];throw new Error('Could\x20not\x20find\x20installation.\x20Please\x20try\x20again.');}export async function autoSetupGitHub(){const _0x26932e=a17_0x30a0;a17_0x33ecc3['header'](_0x26932e(0x1f4)),a17_0x33ecc3[_0x26932e(0x1f0)](_0x26932e(0x20b));try{const _0xfc0f78=await createGitHubAppManifestFlow();a17_0x33ecc3[_0x26932e(0x218)](_0x26932e(0x229));const _0x5c4f3e=await installAppIfNeeded(_0xfc0f78);a17_0x33ecc3[_0x26932e(0x218)](_0x26932e(0x1f1)),a17_0x33ecc3[_0x26932e(0x231)](_0x26932e(0x1f7)),await saveConfig(_0xfc0f78['id'],_0xfc0f78[_0x26932e(0x1eb)],_0x5c4f3e),a17_0x33ecc3['success'](_0x26932e(0x222)),a17_0x33ecc3['dim'](_0x26932e(0x224)+_0xfc0f78['id']),a17_0x33ecc3['dim'](_0x26932e(0x203)+_0xfc0f78['name']),a17_0x33ecc3[_0x26932e(0x1f0)]('Configuration\x20saved\x20globally\x20to\x20~/.woozlit/'),a17_0x33ecc3[_0x26932e(0x218)](_0x26932e(0x230));}catch(_0x2104f0){a17_0x33ecc3[_0x26932e(0x220)]('\x0aSetup\x20failed:\x20'+_0x2104f0),a17_0x33ecc3[_0x26932e(0x1f0)](_0x26932e(0x225)),process[_0x26932e(0x1fe)](0x1);}}
@@ -1 +1 @@
1
- (function(_0x87b80,_0x21e7b3){const _0x2506a8=a18_0x5304,_0x57e112=_0x87b80();while(!![]){try{const _0x5eee7c=parseInt(_0x2506a8(0x208))/0x1*(-parseInt(_0x2506a8(0x1ea))/0x2)+parseInt(_0x2506a8(0x200))/0x3*(-parseInt(_0x2506a8(0x211))/0x4)+-parseInt(_0x2506a8(0x20e))/0x5+parseInt(_0x2506a8(0x212))/0x6*(-parseInt(_0x2506a8(0x214))/0x7)+-parseInt(_0x2506a8(0x20a))/0x8*(-parseInt(_0x2506a8(0x1f1))/0x9)+parseInt(_0x2506a8(0x1eb))/0xa+parseInt(_0x2506a8(0x1ff))/0xb;if(_0x5eee7c===_0x21e7b3)break;else _0x57e112['push'](_0x57e112['shift']());}catch(_0x1c3491){_0x57e112['push'](_0x57e112['shift']());}}}(a18_0x542d,0xd21bc));import*as a18_0x260cad from'../ui/output.js';import{loginGitHub,logoutGitHub,isGitHubAuthenticated}from'./auth.js';import{listRepos}from'./api.js';function a18_0x542d(){const _0x1ca0e6=['37032bFcHzr','197058YkaTFB','(private)','231dScjwi','length','Access\x20to\x20','login','slice','dim','4RuCSit','7854530Miqipm','success','\x20\x20...\x20and\x20','repos','Your\x20GitHub\x20Repositories','Failed\x20to\x20fetch\x20repos:\x20','1053iHeLWf','warn','Token\x20may\x20be\x20invalid\x20or\x20app\x20has\x20no\x20repo\x20access:\x20','\x20\x20/github\x20setup\x20\x20\x20-\x20Auto-create\x20GitHub\x20App\x20(recommended)','info','(public)','repoCount','config','createSpinner','private','error','manual','\x20\x20/github\x20login\x20\x20\x20-\x20Test\x20GitHub\x20App\x20authentication','Not\x20logged\x20in\x20to\x20GitHub\x20App','34707948FzzAOg','381cjYLhh','full_name','stop','start','\x20more','Not\x20logged\x20in.\x20Run\x20\x27/github\x20setup\x27\x20first','./api.js','header','336210LzIZDi','\x20\x20/github\x20repos\x20\x20\x20-\x20List\x20your\x20repositories\x20(including\x20private)','88696tGSpNX','Installed\x20on\x20account:\x20','✓\x20Authenticated\x20as\x20GitHub\x20App','accountName','7226455slDQVc','logout','forEach'];a18_0x542d=function(){return _0x1ca0e6;};return a18_0x542d();}import{autoSetupGitHub}from'./auto-setup.js';import{manualSetupGitHub}from'./manual-setup.js';function a18_0x5304(_0x32a9b5,_0x1bcb60){_0x32a9b5=_0x32a9b5-0x1e7;const _0x542d00=a18_0x542d();let _0x530468=_0x542d00[_0x32a9b5];return _0x530468;}export async function handleGitHubCommand(_0x29910e){const _0x55a42c=a18_0x5304;if(_0x29910e==='setup'){await autoSetupGitHub();return;}if(_0x29910e===_0x55a42c(0x1fc)||_0x29910e===_0x55a42c(0x1f8)){await manualSetupGitHub();return;}if(_0x29910e===_0x55a42c(0x1e7)){await loginGitHub();return;}if(_0x29910e===_0x55a42c(0x20f)){await logoutGitHub();return;}if(_0x29910e==='status'){const _0x209d76=await isGitHubAuthenticated();if(_0x209d76)try{const {getAppStatus:_0x2e8176}=await import(_0x55a42c(0x206)),_0x4dd5da=await _0x2e8176();a18_0x260cad[_0x55a42c(0x1ec)](_0x55a42c(0x20c)),_0x4dd5da[_0x55a42c(0x20d)]&&a18_0x260cad[_0x55a42c(0x1f5)](_0x55a42c(0x20b)+_0x4dd5da[_0x55a42c(0x20d)]),a18_0x260cad[_0x55a42c(0x1e9)](_0x55a42c(0x216)+_0x4dd5da[_0x55a42c(0x1f7)]+'\x20repositories');}catch(_0x1f5d2b){a18_0x260cad[_0x55a42c(0x1f2)](_0x55a42c(0x1f3)+_0x1f5d2b);}else a18_0x260cad[_0x55a42c(0x1e9)](_0x55a42c(0x1fe));return;}if(_0x29910e===_0x55a42c(0x1ee)){const _0x84d146=await isGitHubAuthenticated();if(!_0x84d146){a18_0x260cad[_0x55a42c(0x1fb)](_0x55a42c(0x205));return;}a18_0x260cad[_0x55a42c(0x207)](_0x55a42c(0x1ef));const _0x2b4fdc=a18_0x260cad[_0x55a42c(0x1f9)]('Fetching\x20repos...');_0x2b4fdc[_0x55a42c(0x203)]();try{const _0x13e4a6=await listRepos();_0x2b4fdc[_0x55a42c(0x202)](),_0x13e4a6[_0x55a42c(0x1e8)](0x0,0xa)[_0x55a42c(0x210)](_0x4d5a66=>{const _0x17b055=_0x55a42c,_0x377ceb=_0x4d5a66[_0x17b055(0x1fa)]?_0x17b055(0x213):_0x17b055(0x1f6);a18_0x260cad[_0x17b055(0x1e9)]('\x20\x20'+_0x4d5a66[_0x17b055(0x201)]+'\x20'+_0x377ceb);}),_0x13e4a6[_0x55a42c(0x215)]>0xa&&a18_0x260cad[_0x55a42c(0x1e9)](_0x55a42c(0x1ed)+(_0x13e4a6[_0x55a42c(0x215)]-0xa)+_0x55a42c(0x204));}catch(_0xba8670){_0x2b4fdc[_0x55a42c(0x202)](),a18_0x260cad[_0x55a42c(0x1fb)](_0x55a42c(0x1f0)+_0xba8670);}return;}a18_0x260cad[_0x55a42c(0x207)]('GitHub\x20Commands'),a18_0x260cad['dim'](_0x55a42c(0x1f4)),a18_0x260cad[_0x55a42c(0x1e9)](_0x55a42c(0x1fd)),a18_0x260cad['dim']('\x20\x20/github\x20logout\x20\x20-\x20Clear\x20GitHub\x20App\x20credentials'),a18_0x260cad['dim']('\x20\x20/github\x20status\x20\x20-\x20Check\x20authentication\x20status'),a18_0x260cad['dim'](_0x55a42c(0x209));}
1
+ (function(_0x47c58c,_0x1e39c7){const _0x2a933f=a18_0x2573,_0xff0816=_0x47c58c();while(!![]){try{const _0x1ce4af=parseInt(_0x2a933f(0x13a))/0x1+parseInt(_0x2a933f(0x129))/0x2*(parseInt(_0x2a933f(0x11d))/0x3)+-parseInt(_0x2a933f(0x12b))/0x4+parseInt(_0x2a933f(0x134))/0x5+parseInt(_0x2a933f(0x12c))/0x6+-parseInt(_0x2a933f(0x11b))/0x7*(-parseInt(_0x2a933f(0x119))/0x8)+parseInt(_0x2a933f(0x13b))/0x9*(-parseInt(_0x2a933f(0x122))/0xa);if(_0x1ce4af===_0x1e39c7)break;else _0xff0816['push'](_0xff0816['shift']());}catch(_0x5eb112){_0xff0816['push'](_0xff0816['shift']());}}}(a18_0x1f24,0xa996f));import*as a18_0x1877c6 from'../ui/output.js';import{loginGitHub,logoutGitHub,isGitHubAuthenticated}from'./auth.js';function a18_0x2573(_0x19b837,_0x2683f2){_0x19b837=_0x19b837-0x115;const _0x1f24be=a18_0x1f24();let _0x25732e=_0x1f24be[_0x19b837];return _0x25732e;}import{listRepos}from'./api.js';function a18_0x1f24(){const _0x127cfd=['23242oQsQmp','manual','726164iqoVcO','8061702NFMdXJ','setup','repoCount','Installed\x20on\x20account:\x20','length','./api.js','Not\x20logged\x20in.\x20Run\x20\x27/github\x20setup\x27\x20first','login','665620gEbihI','success','start','Your\x20GitHub\x20Repositories','error','dim','648516HdIeZp','279QQshar','(public)','\x20\x20/github\x20repos\x20\x20\x20-\x20List\x20your\x20repositories\x20(including\x20private)','GitHub\x20Commands','Failed\x20to\x20fetch\x20repos:\x20','Access\x20to\x20','✓\x20Authenticated\x20as\x20GitHub\x20App','accountName','8qalGbC','\x20repositories','9441215iUjgOR','header','156ewWvWF','stop','forEach','config','status','1032940RtnCXt','repos','Fetching\x20repos...','warn','createSpinner','\x20\x20/github\x20login\x20\x20\x20-\x20Test\x20GitHub\x20App\x20authentication','\x20more'];a18_0x1f24=function(){return _0x127cfd;};return a18_0x1f24();}import{autoSetupGitHub}from'./auto-setup.js';import{manualSetupGitHub}from'./manual-setup.js';export async function handleGitHubCommand(_0x1a1f78){const _0xae5501=a18_0x2573;if(_0x1a1f78===_0xae5501(0x12d)){await autoSetupGitHub();return;}if(_0x1a1f78===_0xae5501(0x12a)||_0x1a1f78===_0xae5501(0x120)){await manualSetupGitHub();return;}if(_0x1a1f78===_0xae5501(0x133)){await loginGitHub();return;}if(_0x1a1f78==='logout'){await logoutGitHub();return;}if(_0x1a1f78===_0xae5501(0x121)){const _0x324132=await isGitHubAuthenticated();if(_0x324132)try{const {getAppStatus:_0x39f037}=await import(_0xae5501(0x131)),_0x9080da=await _0x39f037();a18_0x1877c6[_0xae5501(0x135)](_0xae5501(0x117)),_0x9080da[_0xae5501(0x118)]&&a18_0x1877c6['info'](_0xae5501(0x12f)+_0x9080da[_0xae5501(0x118)]),a18_0x1877c6[_0xae5501(0x139)](_0xae5501(0x116)+_0x9080da[_0xae5501(0x12e)]+_0xae5501(0x11a));}catch(_0x18d0c1){a18_0x1877c6[_0xae5501(0x125)]('Token\x20may\x20be\x20invalid\x20or\x20app\x20has\x20no\x20repo\x20access:\x20'+_0x18d0c1);}else a18_0x1877c6[_0xae5501(0x139)]('Not\x20logged\x20in\x20to\x20GitHub\x20App');return;}if(_0x1a1f78===_0xae5501(0x123)){const _0x5054c8=await isGitHubAuthenticated();if(!_0x5054c8){a18_0x1877c6['error'](_0xae5501(0x132));return;}a18_0x1877c6[_0xae5501(0x11c)](_0xae5501(0x137));const _0x5267ef=a18_0x1877c6[_0xae5501(0x126)](_0xae5501(0x124));_0x5267ef[_0xae5501(0x136)]();try{const _0x2d4ead=await listRepos();_0x5267ef[_0xae5501(0x11e)](),_0x2d4ead['slice'](0x0,0xa)[_0xae5501(0x11f)](_0x5f4a4f=>{const _0x5f28b8=_0xae5501,_0x5a6dc9=_0x5f4a4f['private']?'(private)':_0x5f28b8(0x13c);a18_0x1877c6[_0x5f28b8(0x139)]('\x20\x20'+_0x5f4a4f['full_name']+'\x20'+_0x5a6dc9);}),_0x2d4ead[_0xae5501(0x130)]>0xa&&a18_0x1877c6[_0xae5501(0x139)]('\x20\x20...\x20and\x20'+(_0x2d4ead[_0xae5501(0x130)]-0xa)+_0xae5501(0x128));}catch(_0x47b0b8){_0x5267ef[_0xae5501(0x11e)](),a18_0x1877c6[_0xae5501(0x138)](_0xae5501(0x115)+_0x47b0b8);}return;}a18_0x1877c6[_0xae5501(0x11c)](_0xae5501(0x13e)),a18_0x1877c6[_0xae5501(0x139)]('\x20\x20/github\x20setup\x20\x20\x20-\x20Auto-create\x20GitHub\x20App\x20(recommended)'),a18_0x1877c6[_0xae5501(0x139)](_0xae5501(0x127)),a18_0x1877c6[_0xae5501(0x139)]('\x20\x20/github\x20logout\x20\x20-\x20Clear\x20GitHub\x20App\x20credentials'),a18_0x1877c6[_0xae5501(0x139)]('\x20\x20/github\x20status\x20\x20-\x20Check\x20authentication\x20status'),a18_0x1877c6['dim'](_0xae5501(0x13d));}
@@ -1 +1 @@
1
- (function(_0x3e448a,_0x4af32e){const _0x12a34b=a19_0x1c29,_0x2c8cbd=_0x3e448a();while(!![]){try{const _0x4da31a=parseInt(_0x12a34b(0x1da))/0x1*(parseInt(_0x12a34b(0x1dd))/0x2)+parseInt(_0x12a34b(0x1ea))/0x3*(-parseInt(_0x12a34b(0x1ef))/0x4)+parseInt(_0x12a34b(0x1de))/0x5+parseInt(_0x12a34b(0x1e6))/0x6+parseInt(_0x12a34b(0x1ec))/0x7+-parseInt(_0x12a34b(0x1e2))/0x8+parseInt(_0x12a34b(0x1f0))/0x9*(parseInt(_0x12a34b(0x1e1))/0xa);if(_0x4da31a===_0x4af32e)break;else _0x2c8cbd['push'](_0x2c8cbd['shift']());}catch(_0x5187b6){_0x2c8cbd['push'](_0x2c8cbd['shift']());}}}(a19_0x5f12,0x4e89f));import{promises as a19_0x5ece41}from'fs';import{join}from'path';import*as a19_0x48355a from'../ui/output.js';import{homedir}from'os';function a19_0x1c29(_0x4ddbb5,_0x2251d6){_0x4ddbb5=_0x4ddbb5-0x1d0;const _0x5f1254=a19_0x5f12();let _0x1c2960=_0x5f1254[_0x4ddbb5];return _0x1c2960;}import{input,editor}from'@inquirer/prompts';async function saveConfig(_0x2adf79,_0x9bdd10,_0x8df74a){const _0x356ced=a19_0x1c29,_0x752a9b=join(homedir(),_0x356ced(0x1db));try{await a19_0x5ece41[_0x356ced(0x1d5)](_0x752a9b);}catch{await a19_0x5ece41[_0x356ced(0x1e4)](_0x752a9b,{'recursive':!![]});}const _0x222d7d=join(_0x752a9b,_0x356ced(0x1df)),_0x5cabf9=join(_0x752a9b,'github-app.pem');await a19_0x5ece41['writeFile'](_0x5cabf9,_0x9bdd10,_0x356ced(0x1ee)),await a19_0x5ece41[_0x356ced(0x1f3)](_0x222d7d,JSON['stringify']({'appId':_0x2adf79,'installationId':_0x8df74a},null,0x2),_0x356ced(0x1ee));}export async function manualSetupGitHub(){const _0xbf3e52=a19_0x1c29;a19_0x48355a[_0xbf3e52(0x1d1)](_0xbf3e52(0x1d9)),a19_0x48355a['dim'](_0xbf3e52(0x1d2));try{const _0x2157b5=await input({'message':_0xbf3e52(0x1d6),'validate':_0x48d3f2=>_0x48d3f2['length']>0x0?!![]:'App\x20ID\x20is\x20required'});a19_0x48355a['info'](_0xbf3e52(0x1f1)),a19_0x48355a[_0xbf3e52(0x1e8)](_0xbf3e52(0x1f6)),await new Promise(_0xec889b=>setTimeout(_0xec889b,0x7d0));const _0x29dde1=await editor({'message':_0xbf3e52(0x1f4),'validate':_0x5b916d=>_0x5b916d[_0xbf3e52(0x1e3)](_0xbf3e52(0x1e5))||_0x5b916d[_0xbf3e52(0x1e3)](_0xbf3e52(0x1d7))?!![]:_0xbf3e52(0x1ed)}),_0x14536a=await input({'message':_0xbf3e52(0x1d0),'validate':_0x1e50a6=>_0x1e50a6[_0xbf3e52(0x1e0)]>0x0?!![]:'Installation\x20ID\x20is\x20required'});a19_0x48355a[_0xbf3e52(0x1e8)]('\x0aSaving\x20configuration...'),await saveConfig(_0x2157b5,_0x29dde1,_0x14536a),a19_0x48355a[_0xbf3e52(0x1f5)](_0xbf3e52(0x1e9)),a19_0x48355a[_0xbf3e52(0x1eb)](_0xbf3e52(0x1f2));}catch(_0xa2feb5){if(_0xa2feb5 instanceof Error&&_0xa2feb5[_0xbf3e52(0x1d4)]['includes'](_0xbf3e52(0x1d8))){a19_0x48355a['warn'](_0xbf3e52(0x1e7));return;}a19_0x48355a[_0xbf3e52(0x1d3)](_0xbf3e52(0x1dc)+_0xa2feb5);}}function a19_0x5f12(){const _0x224467=['10PqjRhh','4688656PCcdrR','includes','mkdir','BEGIN\x20RSA\x20PRIVATE\x20KEY','1809990dFClxJ','\x0aSetup\x20cancelled.','info','\x0a✓\x20Configuration\x20saved!','62448HedTyv','dim','2397717rDMxhx','Invalid\x20PEM\x20format','utf8','104NXvcVP','2000925nDqDnK','\x0aFor\x20the\x20Private\x20Key,\x20your\x20default\x20editor\x20will\x20open.','To\x20verify,\x20run:\x20/github\x20status','writeFile','Private\x20Key\x20(PEM\x20format):','success','Paste\x20the\x20entire\x20content\x20of\x20your\x20.pem\x20file,\x20save,\x20and\x20close.','Installation\x20ID:','header','Enter\x20your\x20existing\x20GitHub\x20App\x20credentials\x20manually.\x0a','error','message','access','App\x20ID:','BEGIN\x20PRIVATE\x20KEY','force\x20closed','GitHub\x20App\x20Manual\x20Configuration','537663XgCaiP','.woozlit','\x0aSetup\x20failed:\x20','2dptrbx','224045TcCzVf','github-app-config.json','length'];a19_0x5f12=function(){return _0x224467;};return a19_0x5f12();}
1
+ (function(_0x2acf6f,_0x467dc2){const _0x3d5125=a19_0x3c2f,_0x472b44=_0x2acf6f();while(!![]){try{const _0x146c7f=parseInt(_0x3d5125(0x140))/0x1+parseInt(_0x3d5125(0x145))/0x2+parseInt(_0x3d5125(0x15d))/0x3*(-parseInt(_0x3d5125(0x13d))/0x4)+-parseInt(_0x3d5125(0x147))/0x5*(-parseInt(_0x3d5125(0x15c))/0x6)+-parseInt(_0x3d5125(0x15b))/0x7*(parseInt(_0x3d5125(0x149))/0x8)+-parseInt(_0x3d5125(0x15f))/0x9+-parseInt(_0x3d5125(0x14c))/0xa;if(_0x146c7f===_0x467dc2)break;else _0x472b44['push'](_0x472b44['shift']());}catch(_0x2b73c4){_0x472b44['push'](_0x472b44['shift']());}}}(a19_0x98a1,0x71b9a));function a19_0x3c2f(_0x3723da,_0x32466){_0x3723da=_0x3723da-0x138;const _0x98a1c3=a19_0x98a1();let _0x3c2fa7=_0x98a1c3[_0x3723da];return _0x3c2fa7;}import{promises as a19_0x55782f}from'fs';import{join}from'path';import*as a19_0x143dce from'../ui/output.js';function a19_0x98a1(){const _0x180690=['5096000uLjWxu','mkdir','length','\x0aSetup\x20failed:\x20','BEGIN\x20RSA\x20PRIVATE\x20KEY','github-app.pem','success','writeFile','includes','Enter\x20your\x20existing\x20GitHub\x20App\x20credentials\x20manually.\x0a','To\x20verify,\x20run:\x20/github\x20status','info','dim','warn','error','2330153hESvaG','2022TomGrF','909ELpqIb','utf8','597483MDVoRR','Private\x20Key\x20(PEM\x20format):','Installation\x20ID\x20is\x20required','GitHub\x20App\x20Manual\x20Configuration','\x0aSaving\x20configuration...','BEGIN\x20PRIVATE\x20KEY','3956IANKJE','message','App\x20ID:','497044wyMzDu','access','.woozlit','Paste\x20the\x20entire\x20content\x20of\x20your\x20.pem\x20file,\x20save,\x20and\x20close.','\x0aFor\x20the\x20Private\x20Key,\x20your\x20default\x20editor\x20will\x20open.','576602rHAqSv','App\x20ID\x20is\x20required','13190KDGVoJ','header','8gPBaxv','stringify','Invalid\x20PEM\x20format'];a19_0x98a1=function(){return _0x180690;};return a19_0x98a1();}import{homedir}from'os';import{input,editor}from'@inquirer/prompts';async function saveConfig(_0x1d540d,_0x252c7a,_0x5edb4d){const _0x40d5d2=a19_0x3c2f,_0x1ec90a=join(homedir(),_0x40d5d2(0x142));try{await a19_0x55782f[_0x40d5d2(0x141)](_0x1ec90a);}catch{await a19_0x55782f[_0x40d5d2(0x14d)](_0x1ec90a,{'recursive':!![]});}const _0x137b87=join(_0x1ec90a,'github-app-config.json'),_0x45bc31=join(_0x1ec90a,_0x40d5d2(0x151));await a19_0x55782f[_0x40d5d2(0x153)](_0x45bc31,_0x252c7a,'utf8'),await a19_0x55782f[_0x40d5d2(0x153)](_0x137b87,JSON[_0x40d5d2(0x14a)]({'appId':_0x1d540d,'installationId':_0x5edb4d},null,0x2),_0x40d5d2(0x15e));}export async function manualSetupGitHub(){const _0x18f79a=a19_0x3c2f;a19_0x143dce[_0x18f79a(0x148)](_0x18f79a(0x13a)),a19_0x143dce[_0x18f79a(0x158)](_0x18f79a(0x155));try{const _0x2182da=await input({'message':_0x18f79a(0x13f),'validate':_0x3b462c=>_0x3b462c['length']>0x0?!![]:_0x18f79a(0x146)});a19_0x143dce[_0x18f79a(0x157)](_0x18f79a(0x144)),a19_0x143dce[_0x18f79a(0x157)](_0x18f79a(0x143)),await new Promise(_0x5ed76a=>setTimeout(_0x5ed76a,0x7d0));const _0x378e04=await editor({'message':_0x18f79a(0x138),'validate':_0x336602=>_0x336602['includes'](_0x18f79a(0x150))||_0x336602['includes'](_0x18f79a(0x13c))?!![]:_0x18f79a(0x14b)}),_0x4919c1=await input({'message':'Installation\x20ID:','validate':_0x41ce8b=>_0x41ce8b[_0x18f79a(0x14e)]>0x0?!![]:_0x18f79a(0x139)});a19_0x143dce[_0x18f79a(0x157)](_0x18f79a(0x13b)),await saveConfig(_0x2182da,_0x378e04,_0x4919c1),a19_0x143dce[_0x18f79a(0x152)]('\x0a✓\x20Configuration\x20saved!'),a19_0x143dce[_0x18f79a(0x158)](_0x18f79a(0x156));}catch(_0x9cc93c){if(_0x9cc93c instanceof Error&&_0x9cc93c[_0x18f79a(0x13e)][_0x18f79a(0x154)]('force\x20closed')){a19_0x143dce[_0x18f79a(0x159)]('\x0aSetup\x20cancelled.');return;}a19_0x143dce[_0x18f79a(0x15a)](_0x18f79a(0x14f)+_0x9cc93c);}}
package/dist/index.js CHANGED
@@ -1,2 +1,2 @@
1
1
  #!/usr/bin/env node
2
- const a20_0x4af9e9=a20_0xd6bd;(function(_0x4a796d,_0x277677){const _0x3019ae=a20_0xd6bd,_0x3ff555=_0x4a796d();while(!![]){try{const _0x16316d=-parseInt(_0x3019ae(0x1ac))/0x1*(-parseInt(_0x3019ae(0x1f3))/0x2)+parseInt(_0x3019ae(0x190))/0x3+-parseInt(_0x3019ae(0x193))/0x4+-parseInt(_0x3019ae(0x206))/0x5+parseInt(_0x3019ae(0x1a0))/0x6*(-parseInt(_0x3019ae(0x1cd))/0x7)+parseInt(_0x3019ae(0x1d5))/0x8+parseInt(_0x3019ae(0x20b))/0x9;if(_0x16316d===_0x277677)break;else _0x3ff555['push'](_0x3ff555['shift']());}catch(_0x164c69){_0x3ff555['push'](_0x3ff555['shift']());}}}(a20_0x5496,0x970de));import{Command}from'commander';import a20_0x438baf from'chalk';import{login,logout,isLoggedIn}from'./auth/login.js';import{startChat}from'./chat/agent.js';function a20_0x5496(){const _0x12c0a9=[':\x20[stdio]\x20','remove-all','Configure\x20Telegram\x20Bot\x20Token','.woozlit/context.md','remove\x20<name>','./email/index.js','clean','services','hex','wipe','env','start','Logout\x20from\x20your\x20Woozlit\x20account','command','@inquirer/prompts','Background\x20Services','logout','.woozlit/rules.md','theme','stdout','entries','Remove\x20all\x20MCP\x20servers','Model:\x20','16052CgYsqC','\x0aUse\x20\x27woozlit\x20<service>\x20setup\x27\x20to\x20configure\x20services.','You\x20can\x20also\x20add\x20servers\x20via\x20mcp.json\x20in\x20your\x20project\x20directory','delete','length','configured','Current\x20User','displayName','Config\x20file:\x20','Are\x20you\x20sure\x20you\x20want\x20to\x20completely\x20WIPE\x20all\x20CLI\x20data,\x20rules,\x20and\x20configs?','chat\x20[message]','description','Added\x20HTTP\x20MCP\x20server:\x20','.woozlit','All\x20rules\x20cleared','stop','join','bold','./discord/index.js','4177730gkuDNv','No\x20services\x20registered.','config','init','\x27\x20not\x20found','20135880GUMAOa','Not\x20logged\x20in.\x20Use\x20\x27woozlit\x20login\x27\x20to\x20authenticate.','header','./telegram/index.js','Select\x20UI\x20theme\x20(alias\x20for\x20config\x20theme)','Waiting\x20for\x20authentication...','Select\x20AI\x20model','N/A','keys','delete-all','gray','Configure\x20Discord\x20Bot\x20Token','Manage\x20GitHub\x20tool\x20integration','Added\x20stdio\x20MCP\x20server:\x20','Logged\x20out\x20successfully','./github/index.js','Initialize\x20Woozlit\x20in\x20current\x20directory','Manage\x20Telegram\x20integration','./utils/storage.js','Added\x20rule:\x20','All\x20MCP\x20servers\x20removed','Are\x20you\x20sure\x20you\x20want\x20to\x20remove\x20ALL\x20MCP\x20servers?','924594WPFMwf','Wipe\x20all\x20data,\x20rules,\x20settings,\x20and\x20MCP\x20configs','Opening\x20browser\x20for\x20login...','1830040WAELNo','MCP\x20server\x20\x27','url','ask\x20<message>','createSpinner','Please\x20restart\x20the\x20CLI.','NODE_TLS_REJECT_UNAUTHORIZED','woozlit','You\x20must\x20be\x20logged\x20in\x20to\x20use\x20chat.','forEach','MCP\x20Servers','email','Logged\x20in\x20as\x20','2917590WuNONI','rules','getStatus','Running','model','version','Removed\x20MCP\x20server:\x20','./ui/themes.js','./services/bot-manager.js','Login\x20failed\x20or\x20timed\x20out','mcp','action','22orqEqs','Add\x20a\x20stdio\x20MCP\x20server','warn','aliases','Initialized\x20Woozlit\x20in\x20current\x20directory','Stopped','2.1.0','write','some','#\x20Project\x20Rules\x0a\x0aAdd\x20your\x20project-specific\x20rules\x20here.\x0a','showLogo','Rules','dim','whoami','Show\x20current\x20user\x20info','Default\x20servers\x20will\x20be\x20restored\x20on\x20next\x20restart\x20unless\x20you\x20remove\x20them\x20again.','green','success','telegram','Woozlit\x20AI\x20-\x20Agentic\x20Coding\x20Assistant','Not\x20Configured','#\x20Project\x20Context\x0a\x0aDescribe\x20your\x20project\x20here.\x0a','Manage\x20AI\x20behavior\x20rules','Manage\x20Email\x20integration','name','setup','No\x20MCP\x20servers\x20configured','All\x20data,\x20configs,\x20and\x20MCP\x20servers\x20have\x20been\x20wiped.','Ask\x20a\x20single\x20question','Model\x20set\x20to:\x20','#3b82f6','add-http\x20<name>\x20<url>','parse','14VkofEd','Operation\x20cancelled','discord','Login\x20with\x20your\x20Woozlit\x20account','info','streamable-http','Show\x20status\x20of\x20background\x20services/bots','Manage\x20Discord\x20integration','1297712mUxnXr','error','list','refresh','Already\x20logged\x20in\x20as\x20','List\x20all\x20rules','Add\x20an\x20HTTP\x20MCP\x20server\x20(streamable-http)'];a20_0x5496=function(){return _0x12c0a9;};return a20_0x5496();}import{selectModel,getSelectedModel}from'./ui/select.js';import{listRules,addRule,clearRules}from'./tools/rules.js';import{getUser}from'./utils/storage.js';function a20_0xd6bd(_0x4e276c,_0x3353b3){_0x4e276c=_0x4e276c-0x190;const _0x5496f2=a20_0x5496();let _0xd6bd3f=_0x5496f2[_0x4e276c];return _0xd6bd3f;}import{addMcpServer,addMcpHttpServer,removeMcpServer,clearMcpServers,getMcpServers,ensureDefaultServers,getConfigFilePath}from'./config/mcp.js';import{createFile,listDirectory}from'./tools/file.js';import*as a20_0x3e8c10 from'./ui/output.js';const VERSION=a20_0x4af9e9(0x1b2),program=new Command();process[a20_0x4af9e9(0x1e6)][a20_0x4af9e9(0x199)]='0',program['name'](a20_0x4af9e9(0x19a))[a20_0x4af9e9(0x1fe)](a20_0x4af9e9(0x1bf))[a20_0x4af9e9(0x1a5)](VERSION)['action'](async()=>{const _0x5c5c35=a20_0x4af9e9;ensureDefaultServers();const {botManager:_0x378059}=await import('./services/bot-manager.js');await _0x378059['startAllConfigured'](),a20_0x3e8c10[_0x5c5c35(0x1b6)](VERSION);if(!isLoggedIn()){a20_0x3e8c10[_0x5c5c35(0x1ae)](_0x5c5c35(0x19b)),a20_0x3e8c10[_0x5c5c35(0x1b8)](''),a20_0x3e8c10[_0x5c5c35(0x1d1)]('Opening\x20browser\x20for\x20login...');const _0x312663=a20_0x3e8c10[_0x5c5c35(0x197)](_0x5c5c35(0x210));_0x312663[_0x5c5c35(0x1e7)]();const _0x3636e8=await login();_0x312663[_0x5c5c35(0x202)]();if(!_0x3636e8){a20_0x3e8c10[_0x5c5c35(0x1d6)]('Login\x20failed\x20or\x20timed\x20out');return;}const _0x170302=getUser();a20_0x3e8c10[_0x5c5c35(0x1bd)](_0x5c5c35(0x19f)+(_0x170302[_0x5c5c35(0x1fa)]||_0x170302[_0x5c5c35(0x19e)]));}await startChat();}),program[a20_0x4af9e9(0x1e9)]('login')[a20_0x4af9e9(0x1fe)](a20_0x4af9e9(0x1d0))[a20_0x4af9e9(0x1ab)](async()=>{const _0x46206a=a20_0x4af9e9;if(isLoggedIn()){const _0x488b9b=getUser();a20_0x3e8c10[_0x46206a(0x1d1)](_0x46206a(0x1d9)+_0x488b9b[_0x46206a(0x19e)]);return;}a20_0x3e8c10[_0x46206a(0x1d1)](_0x46206a(0x192));const _0x4c4202=a20_0x3e8c10['createSpinner'](_0x46206a(0x210));_0x4c4202[_0x46206a(0x1e7)]();const _0x11e9d3=await login();_0x4c4202[_0x46206a(0x202)]();if(_0x11e9d3){const _0x4e7bde=getUser();a20_0x3e8c10[_0x46206a(0x1bd)]('Logged\x20in\x20as\x20'+(_0x4e7bde[_0x46206a(0x1fa)]||_0x4e7bde[_0x46206a(0x19e)]));}else a20_0x3e8c10['error'](_0x46206a(0x1a9));}),program[a20_0x4af9e9(0x1e9)](a20_0x4af9e9(0x1ec))[a20_0x4af9e9(0x1fe)](a20_0x4af9e9(0x1e8))[a20_0x4af9e9(0x1ab)](()=>{const _0x2f3f9b=a20_0x4af9e9;logout(),a20_0x3e8c10[_0x2f3f9b(0x1bd)](_0x2f3f9b(0x219));}),program['command'](a20_0x4af9e9(0x1b9))['description'](a20_0x4af9e9(0x1ba))[a20_0x4af9e9(0x1ab)](()=>{const _0x3bb91e=a20_0x4af9e9;if(!isLoggedIn()){a20_0x3e8c10[_0x3bb91e(0x1ae)](_0x3bb91e(0x20c));return;}const _0x34340d=getUser();a20_0x3e8c10[_0x3bb91e(0x20d)](_0x3bb91e(0x1f9)),a20_0x3e8c10[_0x3bb91e(0x1d1)]('Name:\x20'+(_0x34340d[_0x3bb91e(0x1fa)]||_0x3bb91e(0x212))),a20_0x3e8c10[_0x3bb91e(0x1d1)]('Email:\x20'+(_0x34340d[_0x3bb91e(0x19e)]||'N/A')),a20_0x3e8c10['info'](_0x3bb91e(0x1f2)+getSelectedModel());}),program[a20_0x4af9e9(0x1e9)](a20_0x4af9e9(0x1fd))['description']('Start\x20an\x20AI\x20chat\x20session')[a20_0x4af9e9(0x1ab)](async _0x11b90c=>{const _0x3cd095=a20_0x4af9e9;a20_0x3e8c10['showLogo'](VERSION);if(!isLoggedIn()){a20_0x3e8c10['warn']('You\x20must\x20be\x20logged\x20in\x20to\x20use\x20chat.'),a20_0x3e8c10[_0x3cd095(0x1b8)](''),a20_0x3e8c10[_0x3cd095(0x1d1)](_0x3cd095(0x192));const _0xed36cf=a20_0x3e8c10[_0x3cd095(0x197)](_0x3cd095(0x210));_0xed36cf['start']();const _0x436d0c=await login();_0xed36cf[_0x3cd095(0x202)]();if(!_0x436d0c){a20_0x3e8c10['error'](_0x3cd095(0x1a9));return;}const _0x21d3b2=getUser();a20_0x3e8c10[_0x3cd095(0x1bd)](_0x3cd095(0x19f)+(_0x21d3b2[_0x3cd095(0x1fa)]||_0x21d3b2[_0x3cd095(0x19e)]));}await startChat(_0x11b90c);}),program[a20_0x4af9e9(0x1e9)](a20_0x4af9e9(0x196))['description'](a20_0x4af9e9(0x1c8))[a20_0x4af9e9(0x1ab)](async _0x353917=>{const _0x3dd91f=a20_0x4af9e9;a20_0x3e8c10[_0x3dd91f(0x1b6)](VERSION);if(!isLoggedIn()){a20_0x3e8c10['warn'](_0x3dd91f(0x19b)),a20_0x3e8c10[_0x3dd91f(0x1b8)](''),a20_0x3e8c10[_0x3dd91f(0x1d1)]('Opening\x20browser\x20for\x20login...');const _0x5c5920=a20_0x3e8c10['createSpinner'](_0x3dd91f(0x210));_0x5c5920['start']();const _0x505c53=await login();_0x5c5920['stop']();if(!_0x505c53){a20_0x3e8c10['error'](_0x3dd91f(0x1a9));return;}const _0x10396e=getUser();a20_0x3e8c10['success'](_0x3dd91f(0x19f)+(_0x10396e['displayName']||_0x10396e[_0x3dd91f(0x19e)]));}await startChat(_0x353917);});const configCmd=program['command'](a20_0x4af9e9(0x208))[a20_0x4af9e9(0x1fe)]('Configure\x20CLI\x20settings');configCmd[a20_0x4af9e9(0x1e9)](a20_0x4af9e9(0x1a4))[a20_0x4af9e9(0x1fe)](a20_0x4af9e9(0x211))[a20_0x4af9e9(0x1ab)](async()=>{const _0x3e8649=a20_0x4af9e9,_0x4e20a1=await selectModel();a20_0x3e8c10['success'](_0x3e8649(0x1c9)+_0x4e20a1);}),configCmd[a20_0x4af9e9(0x1e9)]('theme')[a20_0x4af9e9(0x1fe)]('Select\x20UI\x20theme')[a20_0x4af9e9(0x1ab)](async()=>{const _0x487311=a20_0x4af9e9,{selectTheme:_0x41495a}=await import(_0x487311(0x1a7)),_0x25a27f=await _0x41495a();a20_0x3e8c10[_0x487311(0x1bd)]('Theme\x20set\x20to:\x20'+_0x25a27f);}),program[a20_0x4af9e9(0x1e9)](a20_0x4af9e9(0x1ee))[a20_0x4af9e9(0x1fe)](a20_0x4af9e9(0x20f))[a20_0x4af9e9(0x1ab)](async()=>{const _0x1d5435=a20_0x4af9e9,{selectTheme:_0x405075}=await import(_0x1d5435(0x1a7)),_0x3011a7=await _0x405075();a20_0x3e8c10[_0x1d5435(0x1bd)]('Theme\x20set\x20to:\x20'+_0x3011a7);});const rulesCmd=program[a20_0x4af9e9(0x1e9)](a20_0x4af9e9(0x1a1))[a20_0x4af9e9(0x1fe)](a20_0x4af9e9(0x1c2));rulesCmd[a20_0x4af9e9(0x1e9)](a20_0x4af9e9(0x1d7))[a20_0x4af9e9(0x1fe)](a20_0x4af9e9(0x1da))[a20_0x4af9e9(0x1ab)](()=>{const _0x471bdb=a20_0x4af9e9,_0x556ea5=listRules();if(_0x556ea5['length']===0x0){a20_0x3e8c10[_0x471bdb(0x1d1)]('No\x20rules\x20defined');return;}a20_0x3e8c10[_0x471bdb(0x20d)](_0x471bdb(0x1b7)),_0x556ea5['forEach']((_0x51fd1b,_0x1c942c)=>{const _0x46377a=_0x471bdb;process[_0x46377a(0x1ef)][_0x46377a(0x1b3)](_0x1c942c+0x1+'.\x20'+_0x51fd1b+'\x0a');});}),rulesCmd[a20_0x4af9e9(0x1e9)]('add\x20<rule>')[a20_0x4af9e9(0x1fe)]('Add\x20a\x20new\x20rule')[a20_0x4af9e9(0x1ab)](_0x5e3409=>{const _0x45426d=a20_0x4af9e9;addRule(_0x5e3409),a20_0x3e8c10['success'](_0x45426d(0x21e)+_0x5e3409);})[a20_0x4af9e9(0x1ab)](()=>{const _0x4e7120=a20_0x4af9e9;clearRules(),a20_0x3e8c10[_0x4e7120(0x1bd)](_0x4e7120(0x201));});const mcpCmd=program[a20_0x4af9e9(0x1e9)](a20_0x4af9e9(0x1aa))[a20_0x4af9e9(0x1fe)]('Manage\x20MCP\x20servers');mcpCmd[a20_0x4af9e9(0x1e9)](a20_0x4af9e9(0x1d7))[a20_0x4af9e9(0x1fe)]('List\x20all\x20MCP\x20servers')[a20_0x4af9e9(0x1ab)](()=>{const _0x317c66=a20_0x4af9e9,_0x35ccbb=getMcpServers(),_0x4ab819=Object[_0x317c66(0x213)](_0x35ccbb);if(_0x4ab819[_0x317c66(0x1f7)]===0x0){a20_0x3e8c10[_0x317c66(0x1d1)](_0x317c66(0x1c6)),a20_0x3e8c10[_0x317c66(0x1b8)](_0x317c66(0x1fb)+getConfigFilePath());return;}a20_0x3e8c10['header'](_0x317c66(0x19d)),_0x4ab819[_0x317c66(0x19c)](_0x58c97c=>{const _0x1b1a1d=_0x317c66,_0x3f6087=_0x35ccbb[_0x58c97c];_0x3f6087['type']===_0x1b1a1d(0x1d2)?a20_0x3e8c10[_0x1b1a1d(0x1d1)]('-\x20'+_0x58c97c+':\x20[HTTP]\x20'+_0x3f6087[_0x1b1a1d(0x195)]):a20_0x3e8c10[_0x1b1a1d(0x1d1)]('-\x20'+_0x58c97c+_0x1b1a1d(0x1dc)+_0x3f6087['command']+'\x20'+(_0x3f6087['args']?.[_0x1b1a1d(0x203)]('\x20')||''));}),a20_0x3e8c10[_0x317c66(0x1b8)]('\x0aConfig\x20file:\x20'+getConfigFilePath()),a20_0x3e8c10[_0x317c66(0x1b8)](_0x317c66(0x1f5));}),mcpCmd[a20_0x4af9e9(0x1e9)]('add\x20<name>\x20<command>\x20[args...]')[a20_0x4af9e9(0x1fe)](a20_0x4af9e9(0x1ad))['action']((_0x433d03,_0x1ecdcd,_0x1d65c2)=>{const _0x99f5db=a20_0x4af9e9;addMcpServer(_0x433d03,_0x1ecdcd,_0x1d65c2),a20_0x3e8c10[_0x99f5db(0x1bd)](_0x99f5db(0x218)+_0x433d03);}),mcpCmd['command'](a20_0x4af9e9(0x1cb))[a20_0x4af9e9(0x1fe)](a20_0x4af9e9(0x1db))[a20_0x4af9e9(0x1ab)]((_0x1c997f,_0xb61e26)=>{const _0x1320f8=a20_0x4af9e9;addMcpHttpServer(_0x1c997f,_0xb61e26),a20_0x3e8c10[_0x1320f8(0x1bd)](_0x1320f8(0x1ff)+_0x1c997f),a20_0x3e8c10[_0x1320f8(0x1b8)]('URL:\x20'+_0xb61e26);}),mcpCmd['command'](a20_0x4af9e9(0x1e0))[a20_0x4af9e9(0x1af)]([a20_0x4af9e9(0x1f6),'rm'])[a20_0x4af9e9(0x1fe)]('Remove\x20an\x20MCP\x20server')[a20_0x4af9e9(0x1ab)](_0x2a7206=>{const _0x45fc8e=a20_0x4af9e9;removeMcpServer(_0x2a7206)?a20_0x3e8c10[_0x45fc8e(0x1bd)](_0x45fc8e(0x1a6)+_0x2a7206):a20_0x3e8c10[_0x45fc8e(0x1d6)](_0x45fc8e(0x194)+_0x2a7206+_0x45fc8e(0x20a));}),mcpCmd[a20_0x4af9e9(0x1e9)](a20_0x4af9e9(0x1dd))[a20_0x4af9e9(0x1af)]([a20_0x4af9e9(0x214),'clear'])[a20_0x4af9e9(0x1fe)](a20_0x4af9e9(0x1f1))[a20_0x4af9e9(0x1ab)](async()=>{const _0x27ea17=a20_0x4af9e9,{confirm:_0x569be1}=await import('@inquirer/prompts'),_0x30d0de=await _0x569be1({'message':_0x27ea17(0x220),'default':![]});_0x30d0de?(clearMcpServers(),a20_0x3e8c10['success'](_0x27ea17(0x21f)),a20_0x3e8c10[_0x27ea17(0x1b8)](_0x27ea17(0x1bb))):a20_0x3e8c10['info'](_0x27ea17(0x1ce));}),program[a20_0x4af9e9(0x1e9)](a20_0x4af9e9(0x1d8))[a20_0x4af9e9(0x1af)](['reset',a20_0x4af9e9(0x1e5),a20_0x4af9e9(0x1e2)])[a20_0x4af9e9(0x1fe)](a20_0x4af9e9(0x191))[a20_0x4af9e9(0x1ab)](async()=>{const _0x87e646=a20_0x4af9e9,{confirm:_0x592ba1}=await import(_0x87e646(0x1ea)),_0x4afbda=await _0x592ba1({'message':a20_0x438baf[_0x87e646(0x204)][_0x87e646(0x1e4)](_0x87e646(0x1ca))(_0x87e646(0x1fc)),'default':![],'theme':{'prefix':{'idle':a20_0x438baf['bold'][_0x87e646(0x1e4)]('#3b82f6')('>'),'done':a20_0x438baf[_0x87e646(0x1e4)](_0x87e646(0x1ca))('●')}}});if(_0x4afbda){const {wipeAll:_0x2f7ca4}=await import(_0x87e646(0x21d));_0x2f7ca4();try{const {clearMcpServers:_0xdc3ccc}=await import('./config/mcp.js');_0xdc3ccc();}catch(_0x4410e0){}a20_0x3e8c10[_0x87e646(0x1bd)](_0x87e646(0x1c7)),a20_0x3e8c10[_0x87e646(0x1b8)](_0x87e646(0x198));}else a20_0x3e8c10['info']('Refresh\x20cancelled.');}),program[a20_0x4af9e9(0x1e9)](a20_0x4af9e9(0x209))[a20_0x4af9e9(0x1fe)](a20_0x4af9e9(0x21b))['action'](()=>{const _0x6e366c=a20_0x4af9e9,_0x3d471a=listDirectory('.'),_0x397243=_0x3d471a[_0x6e366c(0x1f0)]?.[_0x6e366c(0x1b4)](_0x1b65a8=>_0x1b65a8[_0x6e366c(0x1c4)]===_0x6e366c(0x200));if(_0x397243){a20_0x3e8c10[_0x6e366c(0x1ae)]('Woozlit\x20already\x20initialized\x20in\x20this\x20directory');return;}createFile(_0x6e366c(0x1ed),_0x6e366c(0x1b5)),createFile(_0x6e366c(0x1df),_0x6e366c(0x1c1)),a20_0x3e8c10[_0x6e366c(0x1bd)](_0x6e366c(0x1b0)),a20_0x3e8c10[_0x6e366c(0x1b8)]('Created\x20.woozlit/rules.md\x20and\x20.woozlit/context.md');}),program[a20_0x4af9e9(0x1e9)](a20_0x4af9e9(0x1e3))[a20_0x4af9e9(0x1fe)](a20_0x4af9e9(0x1d3))[a20_0x4af9e9(0x1ab)](async()=>{const _0x8c1c70=a20_0x4af9e9,{botManager:_0x392200}=await import(_0x8c1c70(0x1a8)),_0x29632e=_0x392200[_0x8c1c70(0x1a2)]();a20_0x3e8c10[_0x8c1c70(0x20d)](_0x8c1c70(0x1eb));if(_0x29632e[_0x8c1c70(0x1f7)]===0x0){a20_0x3e8c10['info'](_0x8c1c70(0x207));return;}_0x29632e['forEach'](_0x45b3bd=>{const _0x1eeeef=_0x8c1c70,_0x13e38a=_0x45b3bd['running']?a20_0x438baf[_0x1eeeef(0x1bc)](_0x1eeeef(0x1a3)):_0x45b3bd[_0x1eeeef(0x1f8)]?a20_0x438baf['yellow'](_0x1eeeef(0x1b1)):a20_0x438baf[_0x1eeeef(0x215)](_0x1eeeef(0x1c0));a20_0x3e8c10[_0x1eeeef(0x1d1)]('-\x20'+_0x45b3bd[_0x1eeeef(0x1c4)]+':\x20'+_0x13e38a);}),a20_0x3e8c10['dim'](_0x8c1c70(0x1f4));});const discordCmd=program[a20_0x4af9e9(0x1e9)](a20_0x4af9e9(0x1cf))[a20_0x4af9e9(0x1fe)](a20_0x4af9e9(0x1d4));discordCmd[a20_0x4af9e9(0x1e9)](a20_0x4af9e9(0x1c5))[a20_0x4af9e9(0x1fe)](a20_0x4af9e9(0x216))[a20_0x4af9e9(0x1ab)](async()=>{const _0x37bb5e=a20_0x4af9e9,{setupDiscord:_0x5eb0c1}=await import(_0x37bb5e(0x205));await _0x5eb0c1();});const githubCmd=program[a20_0x4af9e9(0x1e9)]('github\x20[subcmd]')['description'](a20_0x4af9e9(0x217))[a20_0x4af9e9(0x1ab)](async _0x4a463d=>{const _0x5772b0=a20_0x4af9e9,{handleGitHubCommand:_0x12f13f}=await import(_0x5772b0(0x21a));await _0x12f13f(_0x4a463d||'');}),telegramCmd=program['command'](a20_0x4af9e9(0x1be))['description'](a20_0x4af9e9(0x21c));telegramCmd[a20_0x4af9e9(0x1e9)](a20_0x4af9e9(0x1c5))[a20_0x4af9e9(0x1fe)](a20_0x4af9e9(0x1de))[a20_0x4af9e9(0x1ab)](async()=>{const _0x1de451=a20_0x4af9e9,{setupTelegram:_0x4df5d2}=await import(_0x1de451(0x20e));await _0x4df5d2();});const emailCmd=program[a20_0x4af9e9(0x1e9)](a20_0x4af9e9(0x19e))[a20_0x4af9e9(0x1fe)](a20_0x4af9e9(0x1c3));emailCmd['command'](a20_0x4af9e9(0x1c5))[a20_0x4af9e9(0x1fe)]('Configure\x20email\x20credentials')['action'](async()=>{const _0xb20fd1=a20_0x4af9e9,{setupEmail:_0x26c49d}=await import(_0xb20fd1(0x1e1));await _0x26c49d();}),program[a20_0x4af9e9(0x1cc)]();
2
+ const a20_0x3dbaac=a20_0x1960;(function(_0x1b1efe,_0x306bec){const _0x505759=a20_0x1960,_0x4c08a3=_0x1b1efe();while(!![]){try{const _0x52fc40=-parseInt(_0x505759(0x1ca))/0x1*(-parseInt(_0x505759(0x1a2))/0x2)+parseInt(_0x505759(0x1aa))/0x3+-parseInt(_0x505759(0x210))/0x4*(-parseInt(_0x505759(0x208))/0x5)+-parseInt(_0x505759(0x1f8))/0x6+parseInt(_0x505759(0x21b))/0x7+-parseInt(_0x505759(0x1d2))/0x8+-parseInt(_0x505759(0x1cb))/0x9;if(_0x52fc40===_0x306bec)break;else _0x4c08a3['push'](_0x4c08a3['shift']());}catch(_0x411a22){_0x4c08a3['push'](_0x4c08a3['shift']());}}}(a20_0x10bd,0x63418));import{Command}from'commander';import a20_0x19060e from'chalk';import{login,logout,isLoggedIn}from'./auth/login.js';import{startChat}from'./chat/agent.js';import{selectModel,getSelectedModel}from'./ui/select.js';import{listRules,addRule,clearRules}from'./tools/rules.js';import{getUser}from'./utils/storage.js';import{addMcpServer,addMcpHttpServer,removeMcpServer,clearMcpServers,getMcpServers,ensureDefaultServers,getConfigFilePath}from'./config/mcp.js';import{createFile,listDirectory}from'./tools/file.js';import*as a20_0x25187c from'./ui/output.js';const VERSION=a20_0x3dbaac(0x213),program=new Command();process[a20_0x3dbaac(0x1e9)][a20_0x3dbaac(0x1cf)]='0',program[a20_0x3dbaac(0x209)](a20_0x3dbaac(0x20c))[a20_0x3dbaac(0x1df)](a20_0x3dbaac(0x1a6))[a20_0x3dbaac(0x1a7)](VERSION)['action'](async()=>{const _0x3efdaf=a20_0x3dbaac;ensureDefaultServers();const {botManager:_0xfac8fc}=await import(_0x3efdaf(0x214));await _0xfac8fc[_0x3efdaf(0x21e)](),a20_0x25187c[_0x3efdaf(0x1e0)](VERSION);if(!isLoggedIn()){a20_0x25187c[_0x3efdaf(0x1b0)](_0x3efdaf(0x207)),a20_0x25187c[_0x3efdaf(0x1bd)](''),a20_0x25187c[_0x3efdaf(0x1be)](_0x3efdaf(0x1f9));const _0x5714d2=a20_0x25187c[_0x3efdaf(0x1d5)]('Waiting\x20for\x20authentication...');_0x5714d2[_0x3efdaf(0x1c5)]();const _0x4e3809=await login();_0x5714d2['stop']();if(!_0x4e3809){a20_0x25187c[_0x3efdaf(0x21a)](_0x3efdaf(0x1f4));return;}const _0x570749=getUser();a20_0x25187c[_0x3efdaf(0x1f6)]('Logged\x20in\x20as\x20'+(_0x570749['displayName']||_0x570749[_0x3efdaf(0x1b2)]));}await startChat();}),program[a20_0x3dbaac(0x20b)](a20_0x3dbaac(0x220))[a20_0x3dbaac(0x1df)](a20_0x3dbaac(0x199))[a20_0x3dbaac(0x19d)](async()=>{const _0x27fbef=a20_0x3dbaac;if(isLoggedIn()){const _0x4257d5=getUser();a20_0x25187c[_0x27fbef(0x1be)](_0x27fbef(0x1b9)+_0x4257d5[_0x27fbef(0x1b2)]);return;}a20_0x25187c[_0x27fbef(0x1be)](_0x27fbef(0x1f9));const _0x14560f=a20_0x25187c['createSpinner'](_0x27fbef(0x1ee));_0x14560f[_0x27fbef(0x1c5)]();const _0x4e232b=await login();_0x14560f[_0x27fbef(0x1f5)]();if(_0x4e232b){const _0x35458d=getUser();a20_0x25187c[_0x27fbef(0x1f6)](_0x27fbef(0x1a8)+(_0x35458d[_0x27fbef(0x1e7)]||_0x35458d['email']));}else a20_0x25187c[_0x27fbef(0x21a)](_0x27fbef(0x1f4));}),program[a20_0x3dbaac(0x20b)](a20_0x3dbaac(0x1d6))[a20_0x3dbaac(0x1df)](a20_0x3dbaac(0x197))[a20_0x3dbaac(0x19d)](()=>{const _0x44335a=a20_0x3dbaac;logout(),a20_0x25187c[_0x44335a(0x1f6)](_0x44335a(0x1c9));}),program[a20_0x3dbaac(0x20b)](a20_0x3dbaac(0x192))['description'](a20_0x3dbaac(0x205))[a20_0x3dbaac(0x19d)](()=>{const _0x361371=a20_0x3dbaac;if(!isLoggedIn()){a20_0x25187c[_0x361371(0x1b0)](_0x361371(0x1c6));return;}const _0x383b69=getUser();a20_0x25187c[_0x361371(0x1f2)](_0x361371(0x1db)),a20_0x25187c[_0x361371(0x1be)](_0x361371(0x1de)+(_0x383b69[_0x361371(0x1e7)]||_0x361371(0x204))),a20_0x25187c['info'](_0x361371(0x1fe)+(_0x383b69['email']||_0x361371(0x204))),a20_0x25187c[_0x361371(0x1be)](_0x361371(0x1b6)+getSelectedModel());}),program[a20_0x3dbaac(0x20b)](a20_0x3dbaac(0x1eb))[a20_0x3dbaac(0x1df)]('Start\x20an\x20AI\x20chat\x20session')[a20_0x3dbaac(0x19d)](async _0x3ccea0=>{const _0x29ff53=a20_0x3dbaac;a20_0x25187c[_0x29ff53(0x1e0)](VERSION);if(!isLoggedIn()){a20_0x25187c[_0x29ff53(0x1b0)](_0x29ff53(0x207)),a20_0x25187c[_0x29ff53(0x1bd)](''),a20_0x25187c[_0x29ff53(0x1be)](_0x29ff53(0x1f9));const _0x32c434=a20_0x25187c['createSpinner'](_0x29ff53(0x1ee));_0x32c434[_0x29ff53(0x1c5)]();const _0x1d027c=await login();_0x32c434['stop']();if(!_0x1d027c){a20_0x25187c[_0x29ff53(0x21a)]('Login\x20failed\x20or\x20timed\x20out');return;}const _0x598ab4=getUser();a20_0x25187c[_0x29ff53(0x1f6)](_0x29ff53(0x1a8)+(_0x598ab4[_0x29ff53(0x1e7)]||_0x598ab4[_0x29ff53(0x1b2)]));}await startChat(_0x3ccea0);}),program[a20_0x3dbaac(0x20b)](a20_0x3dbaac(0x1f3))[a20_0x3dbaac(0x1df)](a20_0x3dbaac(0x194))[a20_0x3dbaac(0x19d)](async _0x4bf947=>{const _0x5f0d0c=a20_0x3dbaac;a20_0x25187c[_0x5f0d0c(0x1e0)](VERSION);if(!isLoggedIn()){a20_0x25187c['warn'](_0x5f0d0c(0x207)),a20_0x25187c[_0x5f0d0c(0x1bd)](''),a20_0x25187c[_0x5f0d0c(0x1be)]('Opening\x20browser\x20for\x20login...');const _0x5f502d=a20_0x25187c[_0x5f0d0c(0x1d5)](_0x5f0d0c(0x1ee));_0x5f502d[_0x5f0d0c(0x1c5)]();const _0x206394=await login();_0x5f502d[_0x5f0d0c(0x1f5)]();if(!_0x206394){a20_0x25187c['error'](_0x5f0d0c(0x1f4));return;}const _0x535678=getUser();a20_0x25187c['success']('Logged\x20in\x20as\x20'+(_0x535678[_0x5f0d0c(0x1e7)]||_0x535678['email']));}await startChat(_0x4bf947);});function a20_0x10bd(){const _0x3acc6c=['green','./config/mcp.js','./ui/themes.js','Configure\x20CLI\x20settings','Add\x20a\x20new\x20rule','error','5004559PYBiOQ','list','forEach','startAllConfigured','Manage\x20MCP\x20servers','login','theme','args','whoami','Running','Ask\x20a\x20single\x20question','Manage\x20Discord\x20integration','You\x20can\x20also\x20add\x20servers\x20via\x20mcp.json\x20in\x20your\x20project\x20directory','Logout\x20from\x20your\x20Woozlit\x20account','./telegram/index.js','Login\x20with\x20your\x20Woozlit\x20account','bold','entries','config','action','\x0aUse\x20\x27woozlit\x20<service>\x20setup\x27\x20to\x20configure\x20services.','./email/index.js','Show\x20status\x20of\x20background\x20services/bots','getStatus','2438dqXDpE','Are\x20you\x20sure\x20you\x20want\x20to\x20remove\x20ALL\x20MCP\x20servers?','#\x20Project\x20Rules\x0a\x0aAdd\x20your\x20project-specific\x20rules\x20here.\x0a','Are\x20you\x20sure\x20you\x20want\x20to\x20completely\x20WIPE\x20all\x20CLI\x20data,\x20rules,\x20and\x20configs?','Woozlit\x20AI\x20-\x20Agentic\x20Coding\x20Assistant','version','Logged\x20in\x20as\x20','.woozlit/rules.md','1235832oNtxns','Configure\x20Discord\x20Bot\x20Token','All\x20MCP\x20servers\x20removed','Theme\x20set\x20to:\x20','Created\x20.woozlit/rules.md\x20and\x20.woozlit/context.md','length','warn','parse','email',':\x20[HTTP]\x20','#3b82f6','services','Model:\x20','Configure\x20Telegram\x20Bot\x20Token','Select\x20UI\x20theme','Already\x20logged\x20in\x20as\x20','Select\x20UI\x20theme\x20(alias\x20for\x20config\x20theme)','Remove\x20all\x20MCP\x20servers','Manage\x20GitHub\x20tool\x20integration','dim','info','delete-all','Default\x20servers\x20will\x20be\x20restored\x20on\x20next\x20restart\x20unless\x20you\x20remove\x20them\x20again.','telegram','./utils/storage.js','List\x20all\x20MCP\x20servers','yellow','start','Not\x20logged\x20in.\x20Use\x20\x27woozlit\x20login\x27\x20to\x20authenticate.','No\x20MCP\x20servers\x20configured','@inquirer/prompts','Logged\x20out\x20successfully','47DecFsR','4821705zqdcPQ','MCP\x20server\x20\x27','stdout','\x27\x20not\x20found','NODE_TLS_REJECT_UNAUTHORIZED','Wipe\x20all\x20data,\x20rules,\x20settings,\x20and\x20MCP\x20configs','Woozlit\x20already\x20initialized\x20in\x20this\x20directory','1391792nfWjJX','type','Stopped','createSpinner','logout','All\x20rules\x20cleared','Operation\x20cancelled','Manage\x20Telegram\x20integration','remove\x20<name>','Current\x20User','configured','Added\x20HTTP\x20MCP\x20server:\x20','Name:\x20','description','showLogo','Manage\x20AI\x20behavior\x20rules','add\x20<rule>','Remove\x20an\x20MCP\x20server','running',':\x20[stdio]\x20','.woozlit','displayName','Select\x20AI\x20model','env','mcp','chat\x20[message]','Initialized\x20Woozlit\x20in\x20current\x20directory','./discord/index.js','Waiting\x20for\x20authentication...','reset','aliases','gray','header','ask\x20<message>','Login\x20failed\x20or\x20timed\x20out','stop','success','Please\x20restart\x20the\x20CLI.','2132478sFiSgT','Opening\x20browser\x20for\x20login...','Removed\x20MCP\x20server:\x20','init','delete','Added\x20stdio\x20MCP\x20server:\x20','Email:\x20','Rules','Model\x20set\x20to:\x20','clear','github\x20[subcmd]','remove-all','N/A','Show\x20current\x20user\x20info','wipe','You\x20must\x20be\x20logged\x20in\x20to\x20use\x20chat.','50EOdgbV','name','url','command','woozlit','Config\x20file:\x20','Add\x20an\x20HTTP\x20MCP\x20server\x20(streamable-http)','hex','115004kXEdmM','setup','No\x20services\x20registered.','2.1.1','./services/bot-manager.js'];a20_0x10bd=function(){return _0x3acc6c;};return a20_0x10bd();}const configCmd=program[a20_0x3dbaac(0x20b)](a20_0x3dbaac(0x19c))[a20_0x3dbaac(0x1df)](a20_0x3dbaac(0x218));configCmd[a20_0x3dbaac(0x20b)]('model')[a20_0x3dbaac(0x1df)](a20_0x3dbaac(0x1e8))['action'](async()=>{const _0x17365c=a20_0x3dbaac,_0x5d531d=await selectModel();a20_0x25187c[_0x17365c(0x1f6)](_0x17365c(0x200)+_0x5d531d);}),configCmd[a20_0x3dbaac(0x20b)](a20_0x3dbaac(0x221))[a20_0x3dbaac(0x1df)](a20_0x3dbaac(0x1b8))[a20_0x3dbaac(0x19d)](async()=>{const _0x200cf8=a20_0x3dbaac,{selectTheme:_0x3cf69c}=await import(_0x200cf8(0x217)),_0x3287b7=await _0x3cf69c();a20_0x25187c[_0x200cf8(0x1f6)]('Theme\x20set\x20to:\x20'+_0x3287b7);}),program[a20_0x3dbaac(0x20b)](a20_0x3dbaac(0x221))[a20_0x3dbaac(0x1df)](a20_0x3dbaac(0x1ba))[a20_0x3dbaac(0x19d)](async()=>{const _0x5c2a7b=a20_0x3dbaac,{selectTheme:_0x458fb8}=await import(_0x5c2a7b(0x217)),_0x5a4c1e=await _0x458fb8();a20_0x25187c['success'](_0x5c2a7b(0x1ad)+_0x5a4c1e);});const rulesCmd=program[a20_0x3dbaac(0x20b)]('rules')[a20_0x3dbaac(0x1df)](a20_0x3dbaac(0x1e1));rulesCmd[a20_0x3dbaac(0x20b)](a20_0x3dbaac(0x21c))[a20_0x3dbaac(0x1df)]('List\x20all\x20rules')[a20_0x3dbaac(0x19d)](()=>{const _0x3ac6b2=a20_0x3dbaac,_0xbd8517=listRules();if(_0xbd8517['length']===0x0){a20_0x25187c['info']('No\x20rules\x20defined');return;}a20_0x25187c[_0x3ac6b2(0x1f2)](_0x3ac6b2(0x1ff)),_0xbd8517[_0x3ac6b2(0x21d)]((_0x184d7d,_0xf93953)=>{const _0xc6f645=_0x3ac6b2;process[_0xc6f645(0x1cd)]['write'](_0xf93953+0x1+'.\x20'+_0x184d7d+'\x0a');});}),rulesCmd[a20_0x3dbaac(0x20b)](a20_0x3dbaac(0x1e2))[a20_0x3dbaac(0x1df)](a20_0x3dbaac(0x219))[a20_0x3dbaac(0x19d)](_0x28c69f=>{const _0x164b34=a20_0x3dbaac;addRule(_0x28c69f),a20_0x25187c[_0x164b34(0x1f6)]('Added\x20rule:\x20'+_0x28c69f);})[a20_0x3dbaac(0x19d)](()=>{const _0x45fb94=a20_0x3dbaac;clearRules(),a20_0x25187c['success'](_0x45fb94(0x1d7));});const mcpCmd=program['command'](a20_0x3dbaac(0x1ea))[a20_0x3dbaac(0x1df)](a20_0x3dbaac(0x21f));mcpCmd[a20_0x3dbaac(0x20b)](a20_0x3dbaac(0x21c))[a20_0x3dbaac(0x1df)](a20_0x3dbaac(0x1c3))[a20_0x3dbaac(0x19d)](()=>{const _0x49d00b=a20_0x3dbaac,_0x527d6b=getMcpServers(),_0x30edd3=Object['keys'](_0x527d6b);if(_0x30edd3[_0x49d00b(0x1af)]===0x0){a20_0x25187c[_0x49d00b(0x1be)](_0x49d00b(0x1c7)),a20_0x25187c[_0x49d00b(0x1bd)](_0x49d00b(0x20d)+getConfigFilePath());return;}a20_0x25187c[_0x49d00b(0x1f2)]('MCP\x20Servers'),_0x30edd3[_0x49d00b(0x21d)](_0xd7a6e3=>{const _0x2e526=_0x49d00b,_0x14c5db=_0x527d6b[_0xd7a6e3];_0x14c5db[_0x2e526(0x1d3)]==='streamable-http'?a20_0x25187c['info']('-\x20'+_0xd7a6e3+_0x2e526(0x1b3)+_0x14c5db[_0x2e526(0x20a)]):a20_0x25187c[_0x2e526(0x1be)]('-\x20'+_0xd7a6e3+_0x2e526(0x1e5)+_0x14c5db['command']+'\x20'+(_0x14c5db[_0x2e526(0x222)]?.['join']('\x20')||''));}),a20_0x25187c[_0x49d00b(0x1bd)]('\x0aConfig\x20file:\x20'+getConfigFilePath()),a20_0x25187c['dim'](_0x49d00b(0x196));}),mcpCmd[a20_0x3dbaac(0x20b)]('add\x20<name>\x20<command>\x20[args...]')[a20_0x3dbaac(0x1df)]('Add\x20a\x20stdio\x20MCP\x20server')['action']((_0x151296,_0x5e0c9b,_0x4fd9a6)=>{const _0x1686de=a20_0x3dbaac;addMcpServer(_0x151296,_0x5e0c9b,_0x4fd9a6),a20_0x25187c[_0x1686de(0x1f6)](_0x1686de(0x1fd)+_0x151296);}),mcpCmd[a20_0x3dbaac(0x20b)]('add-http\x20<name>\x20<url>')[a20_0x3dbaac(0x1df)](a20_0x3dbaac(0x20e))[a20_0x3dbaac(0x19d)]((_0x14120c,_0xe8aef1)=>{const _0x1c6aeb=a20_0x3dbaac;addMcpHttpServer(_0x14120c,_0xe8aef1),a20_0x25187c[_0x1c6aeb(0x1f6)](_0x1c6aeb(0x1dd)+_0x14120c),a20_0x25187c['dim']('URL:\x20'+_0xe8aef1);}),mcpCmd[a20_0x3dbaac(0x20b)](a20_0x3dbaac(0x1da))[a20_0x3dbaac(0x1f0)]([a20_0x3dbaac(0x1fc),'rm'])['description'](a20_0x3dbaac(0x1e3))['action'](_0x771c75=>{const _0x39b33c=a20_0x3dbaac;removeMcpServer(_0x771c75)?a20_0x25187c[_0x39b33c(0x1f6)](_0x39b33c(0x1fa)+_0x771c75):a20_0x25187c['error'](_0x39b33c(0x1cc)+_0x771c75+_0x39b33c(0x1ce));}),mcpCmd[a20_0x3dbaac(0x20b)](a20_0x3dbaac(0x203))[a20_0x3dbaac(0x1f0)]([a20_0x3dbaac(0x1bf),a20_0x3dbaac(0x201)])[a20_0x3dbaac(0x1df)](a20_0x3dbaac(0x1bb))['action'](async()=>{const _0x1a8dfd=a20_0x3dbaac,{confirm:_0x4fb735}=await import(_0x1a8dfd(0x1c8)),_0x575cf0=await _0x4fb735({'message':_0x1a8dfd(0x1a3),'default':![]});_0x575cf0?(clearMcpServers(),a20_0x25187c[_0x1a8dfd(0x1f6)](_0x1a8dfd(0x1ac)),a20_0x25187c[_0x1a8dfd(0x1bd)](_0x1a8dfd(0x1c0))):a20_0x25187c[_0x1a8dfd(0x1be)](_0x1a8dfd(0x1d8));}),program[a20_0x3dbaac(0x20b)]('refresh')[a20_0x3dbaac(0x1f0)]([a20_0x3dbaac(0x1ef),a20_0x3dbaac(0x206),'clean'])['description'](a20_0x3dbaac(0x1d0))[a20_0x3dbaac(0x19d)](async()=>{const _0x30368d=a20_0x3dbaac,{confirm:_0x1032e7}=await import(_0x30368d(0x1c8)),_0x9636a2=await _0x1032e7({'message':a20_0x19060e[_0x30368d(0x19a)]['hex'](_0x30368d(0x1b4))(_0x30368d(0x1a5)),'default':![],'theme':{'prefix':{'idle':a20_0x19060e[_0x30368d(0x19a)][_0x30368d(0x20f)]('#3b82f6')('>'),'done':a20_0x19060e[_0x30368d(0x20f)](_0x30368d(0x1b4))('●')}}});if(_0x9636a2){const {wipeAll:_0x280b78}=await import(_0x30368d(0x1c2));_0x280b78();try{const {clearMcpServers:_0x439a13}=await import(_0x30368d(0x216));_0x439a13();}catch(_0x117d49){}a20_0x25187c[_0x30368d(0x1f6)]('All\x20data,\x20configs,\x20and\x20MCP\x20servers\x20have\x20been\x20wiped.'),a20_0x25187c[_0x30368d(0x1bd)](_0x30368d(0x1f7));}else a20_0x25187c[_0x30368d(0x1be)]('Refresh\x20cancelled.');}),program[a20_0x3dbaac(0x20b)](a20_0x3dbaac(0x1fb))['description']('Initialize\x20Woozlit\x20in\x20current\x20directory')[a20_0x3dbaac(0x19d)](()=>{const _0x137525=a20_0x3dbaac,_0x456746=listDirectory('.'),_0x164c26=_0x456746[_0x137525(0x19b)]?.['some'](_0x5ca504=>_0x5ca504[_0x137525(0x209)]===_0x137525(0x1e6));if(_0x164c26){a20_0x25187c['warn'](_0x137525(0x1d1));return;}createFile(_0x137525(0x1a9),_0x137525(0x1a4)),createFile('.woozlit/context.md','#\x20Project\x20Context\x0a\x0aDescribe\x20your\x20project\x20here.\x0a'),a20_0x25187c[_0x137525(0x1f6)](_0x137525(0x1ec)),a20_0x25187c['dim'](_0x137525(0x1ae));}),program[a20_0x3dbaac(0x20b)](a20_0x3dbaac(0x1b5))['description'](a20_0x3dbaac(0x1a0))[a20_0x3dbaac(0x19d)](async()=>{const _0x6fb5f8=a20_0x3dbaac,{botManager:_0x5a2278}=await import(_0x6fb5f8(0x214)),_0x115a8c=_0x5a2278[_0x6fb5f8(0x1a1)]();a20_0x25187c[_0x6fb5f8(0x1f2)]('Background\x20Services');if(_0x115a8c['length']===0x0){a20_0x25187c[_0x6fb5f8(0x1be)](_0x6fb5f8(0x212));return;}_0x115a8c['forEach'](_0x18cbe5=>{const _0x1d9013=_0x6fb5f8,_0x50c0ed=_0x18cbe5[_0x1d9013(0x1e4)]?a20_0x19060e[_0x1d9013(0x215)](_0x1d9013(0x193)):_0x18cbe5[_0x1d9013(0x1dc)]?a20_0x19060e[_0x1d9013(0x1c4)](_0x1d9013(0x1d4)):a20_0x19060e[_0x1d9013(0x1f1)]('Not\x20Configured');a20_0x25187c[_0x1d9013(0x1be)]('-\x20'+_0x18cbe5[_0x1d9013(0x209)]+':\x20'+_0x50c0ed);}),a20_0x25187c[_0x6fb5f8(0x1bd)](_0x6fb5f8(0x19e));});const discordCmd=program[a20_0x3dbaac(0x20b)]('discord')[a20_0x3dbaac(0x1df)](a20_0x3dbaac(0x195));discordCmd[a20_0x3dbaac(0x20b)](a20_0x3dbaac(0x211))[a20_0x3dbaac(0x1df)](a20_0x3dbaac(0x1ab))[a20_0x3dbaac(0x19d)](async()=>{const _0x3527f5=a20_0x3dbaac,{setupDiscord:_0x471c13}=await import(_0x3527f5(0x1ed));await _0x471c13();});function a20_0x1960(_0x3a0b05,_0x351ba7){_0x3a0b05=_0x3a0b05-0x192;const _0x10bd06=a20_0x10bd();let _0x196016=_0x10bd06[_0x3a0b05];return _0x196016;}const githubCmd=program[a20_0x3dbaac(0x20b)](a20_0x3dbaac(0x202))[a20_0x3dbaac(0x1df)](a20_0x3dbaac(0x1bc))[a20_0x3dbaac(0x19d)](async _0x4c5a7d=>{const {handleGitHubCommand:_0x4f31de}=await import('./github/index.js');await _0x4f31de(_0x4c5a7d||'');}),telegramCmd=program[a20_0x3dbaac(0x20b)](a20_0x3dbaac(0x1c1))[a20_0x3dbaac(0x1df)](a20_0x3dbaac(0x1d9));telegramCmd[a20_0x3dbaac(0x20b)]('setup')[a20_0x3dbaac(0x1df)](a20_0x3dbaac(0x1b7))[a20_0x3dbaac(0x19d)](async()=>{const _0x1c6832=a20_0x3dbaac,{setupTelegram:_0x3dc172}=await import(_0x1c6832(0x198));await _0x3dc172();});const emailCmd=program['command'](a20_0x3dbaac(0x1b2))[a20_0x3dbaac(0x1df)]('Manage\x20Email\x20integration');emailCmd['command'](a20_0x3dbaac(0x211))[a20_0x3dbaac(0x1df)]('Configure\x20email\x20credentials')[a20_0x3dbaac(0x19d)](async()=>{const _0x10573d=a20_0x3dbaac,{setupEmail:_0x5099b3}=await import(_0x10573d(0x19f));await _0x5099b3();}),program[a20_0x3dbaac(0x1b1)]();
@@ -1 +1 @@
1
- const a21_0x50665b=a21_0x1770;function a21_0x3509(){const _0x5b2a6e=['width','Y\x20coordinate','8548REDOsQ','Type\x20a\x20string\x20of\x20text.','Error:\x20','with\x20','Text\x20to\x20type','object','text','getBuffer','383362fwRgVj','computer_mouse_move','alt','1.0.0','resize','screen','X\x20coordinate','Key\x20to\x20tap\x20(e.g.\x20\x27enter\x27,\x20\x27a\x27,\x20\x27backspace\x27)','Screenshot\x20taken.','3910290dnYvpe','array','bitmap','base64','Tapped\x20key:\x20','Clicked\x20','length','data','left','middle','typeString','Modifier\x20keys','computer_mouse_click','params','Unknown\x20tool:\x20','120AUAXNG','string','mouseClick','boolean','Screen\x20size:\x20','468888OocRJF','keyTap','command','height','image/jpeg','computer_screenshot','210wBNYso','computer_key_tap','toString','moveMouse','shift','getScreenSize','computer_screen_size','setRequestHandler','1244865jeySmk','\x20(double)','number','computer_type','key','424566bPRyXs','image','right','\x20button','4wGJPvR','Tap\x20a\x20single\x20key\x20with\x20optional\x20modifiers.','89495oRrxgu','capture'];a21_0x3509=function(){return _0x5b2a6e;};return a21_0x3509();}(function(_0x3d7d23,_0x3b82ef){const _0x48089d=a21_0x1770,_0x1f474e=_0x3d7d23();while(!![]){try{const _0x4eb8ad=parseInt(_0x48089d(0x20d))/0x1+parseInt(_0x48089d(0x205))/0x2*(parseInt(_0x48089d(0x1e3))/0x3)+-parseInt(_0x48089d(0x1ff))/0x4*(parseInt(_0x48089d(0x1f6))/0x5)+parseInt(_0x48089d(0x1ee))/0x6*(-parseInt(_0x48089d(0x201))/0x7)+parseInt(_0x48089d(0x1e8))/0x8+-parseInt(_0x48089d(0x1fb))/0x9+parseInt(_0x48089d(0x216))/0xa;if(_0x4eb8ad===_0x3b82ef)break;else _0x1f474e['push'](_0x1f474e['shift']());}catch(_0x201305){_0x1f474e['push'](_0x1f474e['shift']());}}}(a21_0x3509,0x3f8f4));import{Server}from'@modelcontextprotocol/sdk/server/index.js';function a21_0x1770(_0x46e67b,_0x419bec){_0x46e67b=_0x46e67b-0x1d5;const _0x3509e9=a21_0x3509();let _0x177006=_0x3509e9[_0x46e67b];return _0x177006;}import{StdioServerTransport}from'@modelcontextprotocol/sdk/server/stdio.js';import{CallToolRequestSchema,ListToolsRequestSchema}from'@modelcontextprotocol/sdk/types.js';import{Jimp}from'jimp';import{createRequire}from'module';const require=createRequire(import.meta.url);let robot;try{robot=require('@hurdlegroup/robotjs');}catch(a21_0x1d31cf){}const AUTO=-0x1,MIME_JPEG=a21_0x50665b(0x1ec),server=new Server({'name':'computer-use','version':a21_0x50665b(0x210)},{'capabilities':{'tools':{}}});server[a21_0x50665b(0x1f5)](ListToolsRequestSchema,async()=>{const _0x326917=a21_0x50665b;return{'tools':[{'name':_0x326917(0x1ed),'description':'Take\x20a\x20screenshot\x20of\x20the\x20primary\x20display.\x20Returns\x20base64\x20encoded\x20image.','inputSchema':{'type':'object','properties':{}}},{'name':_0x326917(0x20e),'description':'Move\x20the\x20mouse\x20cursor\x20to\x20specific\x20coordinates.','inputSchema':{'type':_0x326917(0x20a),'properties':{'x':{'type':_0x326917(0x1f8),'description':_0x326917(0x213)},'y':{'type':_0x326917(0x1f8),'description':_0x326917(0x204)}},'required':['x','y']}},{'name':_0x326917(0x1e0),'description':'Click\x20the\x20mouse\x20button.','inputSchema':{'type':_0x326917(0x20a),'properties':{'button':{'type':'string','enum':[_0x326917(0x1dc),_0x326917(0x1fd),_0x326917(0x1dd)],'default':'left'},'double':{'type':_0x326917(0x1e6),'default':![]}}}},{'name':_0x326917(0x1f9),'description':_0x326917(0x206),'inputSchema':{'type':_0x326917(0x20a),'properties':{'text':{'type':'string','description':_0x326917(0x209)}},'required':[_0x326917(0x20b)]}},{'name':_0x326917(0x1ef),'description':_0x326917(0x200),'inputSchema':{'type':_0x326917(0x20a),'properties':{'key':{'type':_0x326917(0x1e4),'description':_0x326917(0x214)},'modifiers':{'type':_0x326917(0x1d5),'items':{'type':'string','enum':[_0x326917(0x20f),_0x326917(0x1ea),'control',_0x326917(0x1f2)]},'description':_0x326917(0x1df)}},'required':[_0x326917(0x1fa)]}},{'name':_0x326917(0x1f4),'description':'Get\x20the\x20screen\x20resolution.','inputSchema':{'type':_0x326917(0x20a),'properties':{}}}]};}),server['setRequestHandler'](CallToolRequestSchema,async _0x507fd5=>{const _0x3ec3f6=a21_0x50665b,{name:_0x422f04,arguments:_0x5c9996}=_0x507fd5[_0x3ec3f6(0x1e1)];try{if(_0x422f04===_0x3ec3f6(0x1ed)){const _0x120454=robot[_0x3ec3f6(0x1f3)](),_0x4fe6cb=robot[_0x3ec3f6(0x212)][_0x3ec3f6(0x202)](0x0,0x0,_0x120454[_0x3ec3f6(0x203)],_0x120454[_0x3ec3f6(0x1eb)]),_0xbb3797=new Jimp({'width':_0x4fe6cb[_0x3ec3f6(0x203)],'height':_0x4fe6cb[_0x3ec3f6(0x1eb)]});for(let _0x4613ec=0x0;_0x4613ec<_0x4fe6cb[_0x3ec3f6(0x1fc)][_0x3ec3f6(0x1da)];_0x4613ec+=0x4){_0xbb3797[_0x3ec3f6(0x1d6)][_0x3ec3f6(0x1db)][_0x4613ec]=_0x4fe6cb[_0x3ec3f6(0x1fc)][_0x4613ec+0x2],_0xbb3797[_0x3ec3f6(0x1d6)]['data'][_0x4613ec+0x1]=_0x4fe6cb[_0x3ec3f6(0x1fc)][_0x4613ec+0x1],_0xbb3797[_0x3ec3f6(0x1d6)]['data'][_0x4613ec+0x2]=_0x4fe6cb[_0x3ec3f6(0x1fc)][_0x4613ec],_0xbb3797[_0x3ec3f6(0x1d6)][_0x3ec3f6(0x1db)][_0x4613ec+0x3]=_0x4fe6cb[_0x3ec3f6(0x1fc)][_0x4613ec+0x3];}_0xbb3797[_0x3ec3f6(0x1d6)][_0x3ec3f6(0x203)]>0x400&&_0xbb3797[_0x3ec3f6(0x211)]({'w':0x400});const _0x2761bc=await _0xbb3797[_0x3ec3f6(0x20c)](MIME_JPEG),_0x54b8c9=_0x2761bc[_0x3ec3f6(0x1f0)](_0x3ec3f6(0x1d7));return{'content':[{'type':_0x3ec3f6(0x20b),'text':_0x3ec3f6(0x215)},{'type':_0x3ec3f6(0x1fc),'data':_0x54b8c9,'mimeType':_0x3ec3f6(0x1ec)}]};}if(_0x422f04===_0x3ec3f6(0x20e)){const {x:_0x534bbe,y:_0x46ee0a}=_0x5c9996;return robot[_0x3ec3f6(0x1f1)](_0x534bbe,_0x46ee0a),{'content':[{'type':'text','text':'Moved\x20mouse\x20to\x20'+_0x534bbe+',\x20'+_0x46ee0a}]};}if(_0x422f04==='computer_mouse_click'){const {button:button=_0x3ec3f6(0x1dc),double:double=![]}=_0x5c9996;return robot[_0x3ec3f6(0x1e5)](button,double),{'content':[{'type':'text','text':_0x3ec3f6(0x1d9)+button+_0x3ec3f6(0x1fe)+(double?_0x3ec3f6(0x1f7):'')}]};}if(_0x422f04===_0x3ec3f6(0x1f9)){const {text:_0x3988ea}=_0x5c9996;return robot[_0x3ec3f6(0x1de)](_0x3988ea),{'content':[{'type':_0x3ec3f6(0x20b),'text':'Typed:\x20\x22'+_0x3988ea+'\x22'}]};}if(_0x422f04===_0x3ec3f6(0x1ef)){const {key:_0x375952,modifiers:_0x11c1cd}=_0x5c9996;return robot[_0x3ec3f6(0x1e9)](_0x375952,_0x11c1cd),{'content':[{'type':_0x3ec3f6(0x20b),'text':_0x3ec3f6(0x1d8)+_0x375952+'\x20'+(_0x11c1cd?_0x3ec3f6(0x208)+_0x11c1cd['join']('+'):'')}]};}if(_0x422f04===_0x3ec3f6(0x1f4)){const _0x59150e=robot['getScreenSize']();return{'content':[{'type':'text','text':_0x3ec3f6(0x1e7)+_0x59150e[_0x3ec3f6(0x203)]+'x'+_0x59150e[_0x3ec3f6(0x1eb)]}]};}throw new Error(_0x3ec3f6(0x1e2)+_0x422f04);}catch(_0xb97294){return{'content':[{'type':_0x3ec3f6(0x20b),'text':_0x3ec3f6(0x207)+_0xb97294}],'isError':!![]};}});const transport=new StdioServerTransport();await server['connect'](transport);
1
+ const a21_0x3039f1=a21_0x3492;(function(_0x24451f,_0x591db7){const _0x56dd9b=a21_0x3492,_0x318d04=_0x24451f();while(!![]){try{const _0x3d9678=parseInt(_0x56dd9b(0x20b))/0x1*(-parseInt(_0x56dd9b(0x221))/0x2)+parseInt(_0x56dd9b(0x200))/0x3*(parseInt(_0x56dd9b(0x1f5))/0x4)+parseInt(_0x56dd9b(0x213))/0x5+-parseInt(_0x56dd9b(0x1fa))/0x6+-parseInt(_0x56dd9b(0x206))/0x7+parseInt(_0x56dd9b(0x21a))/0x8+parseInt(_0x56dd9b(0x215))/0x9;if(_0x3d9678===_0x591db7)break;else _0x318d04['push'](_0x318d04['shift']());}catch(_0x29a0b6){_0x318d04['push'](_0x318d04['shift']());}}}(a21_0x26fb,0x45e39));import{Server}from'@modelcontextprotocol/sdk/server/index.js';import{StdioServerTransport}from'@modelcontextprotocol/sdk/server/stdio.js';function a21_0x26fb(){const _0x1e69e6=['join','60Vifllf','key','with\x20','number','computer_screen_size','typeString','Screenshot\x20taken.','bitmap','1.0.0','control','Tap\x20a\x20single\x20key\x20with\x20optional\x20modifiers.','array','middle','width','length','screen','left','command','589660sUeDUY','Type\x20a\x20string\x20of\x20text.','computer_screenshot','image/jpeg','object','3349746jKHUdC','boolean','\x20(double)','image','Moved\x20mouse\x20to\x20','string','6ERXpsT','setRequestHandler','Click\x20the\x20mouse\x20button.','connect','getScreenSize','keyTap','3009020QqjpAF','Typed:\x20\x22','@hurdlegroup/robotjs','computer_type','alt','2685yVIWfm','Get\x20the\x20screen\x20resolution.','shift','Key\x20to\x20tap\x20(e.g.\x20\x27enter\x27,\x20\x27a\x27,\x20\x27backspace\x27)','computer_key_tap','Y\x20coordinate','Move\x20the\x20mouse\x20cursor\x20to\x20specific\x20coordinates.','computer_mouse_click','2790530oktktu','data','2708352rnnAAD','height','Unknown\x20tool:\x20','capture','Clicked\x20','1608816DhjsQm','Screen\x20size:\x20','text','computer_mouse_move','toString','getBuffer'];a21_0x26fb=function(){return _0x1e69e6;};return a21_0x26fb();}import{CallToolRequestSchema,ListToolsRequestSchema}from'@modelcontextprotocol/sdk/types.js';import{Jimp}from'jimp';import{createRequire}from'module';const require=createRequire(import.meta.url);let robot;try{robot=require(a21_0x3039f1(0x208));}catch(a21_0x426390){}const AUTO=-0x1,MIME_JPEG='image/jpeg',server=new Server({'name':'computer-use','version':a21_0x3039f1(0x229)},{'capabilities':{'tools':{}}});function a21_0x3492(_0x9d94c1,_0x59a5fe){_0x9d94c1=_0x9d94c1-0x1f1;const _0x26fba5=a21_0x26fb();let _0x349267=_0x26fba5[_0x9d94c1];return _0x349267;}server['setRequestHandler'](ListToolsRequestSchema,async()=>{const _0x390972=a21_0x3039f1;return{'tools':[{'name':'computer_screenshot','description':'Take\x20a\x20screenshot\x20of\x20the\x20primary\x20display.\x20Returns\x20base64\x20encoded\x20image.','inputSchema':{'type':_0x390972(0x1f9),'properties':{}}},{'name':'computer_mouse_move','description':_0x390972(0x211),'inputSchema':{'type':_0x390972(0x1f9),'properties':{'x':{'type':'number','description':'X\x20coordinate'},'y':{'type':_0x390972(0x224),'description':_0x390972(0x210)}},'required':['x','y']}},{'name':_0x390972(0x212),'description':_0x390972(0x202),'inputSchema':{'type':_0x390972(0x1f9),'properties':{'button':{'type':_0x390972(0x1ff),'enum':[_0x390972(0x1f3),'right',_0x390972(0x22d)],'default':_0x390972(0x1f3)},'double':{'type':_0x390972(0x1fb),'default':![]}}}},{'name':'computer_type','description':_0x390972(0x1f6),'inputSchema':{'type':'object','properties':{'text':{'type':_0x390972(0x1ff),'description':'Text\x20to\x20type'}},'required':[_0x390972(0x21c)]}},{'name':_0x390972(0x20f),'description':_0x390972(0x22b),'inputSchema':{'type':_0x390972(0x1f9),'properties':{'key':{'type':_0x390972(0x1ff),'description':_0x390972(0x20e)},'modifiers':{'type':_0x390972(0x22c),'items':{'type':_0x390972(0x1ff),'enum':[_0x390972(0x20a),_0x390972(0x1f4),_0x390972(0x22a),_0x390972(0x20d)]},'description':'Modifier\x20keys'}},'required':[_0x390972(0x222)]}},{'name':_0x390972(0x225),'description':_0x390972(0x20c),'inputSchema':{'type':_0x390972(0x1f9),'properties':{}}}]};}),server[a21_0x3039f1(0x201)](CallToolRequestSchema,async _0x57c487=>{const _0x47a76c=a21_0x3039f1,{name:_0x237bff,arguments:_0x154128}=_0x57c487['params'];try{if(_0x237bff===_0x47a76c(0x1f7)){const _0x3381b1=robot[_0x47a76c(0x204)](),_0x3213c7=robot[_0x47a76c(0x1f2)][_0x47a76c(0x218)](0x0,0x0,_0x3381b1[_0x47a76c(0x22e)],_0x3381b1[_0x47a76c(0x216)]),_0x1710e9=new Jimp({'width':_0x3213c7[_0x47a76c(0x22e)],'height':_0x3213c7[_0x47a76c(0x216)]});for(let _0x27f326=0x0;_0x27f326<_0x3213c7['image'][_0x47a76c(0x1f1)];_0x27f326+=0x4){_0x1710e9[_0x47a76c(0x228)][_0x47a76c(0x214)][_0x27f326]=_0x3213c7[_0x47a76c(0x1fd)][_0x27f326+0x2],_0x1710e9['bitmap'][_0x47a76c(0x214)][_0x27f326+0x1]=_0x3213c7[_0x47a76c(0x1fd)][_0x27f326+0x1],_0x1710e9[_0x47a76c(0x228)][_0x47a76c(0x214)][_0x27f326+0x2]=_0x3213c7[_0x47a76c(0x1fd)][_0x27f326],_0x1710e9[_0x47a76c(0x228)]['data'][_0x27f326+0x3]=_0x3213c7[_0x47a76c(0x1fd)][_0x27f326+0x3];}_0x1710e9[_0x47a76c(0x228)][_0x47a76c(0x22e)]>0x400&&_0x1710e9['resize']({'w':0x400});const _0xaa06ad=await _0x1710e9[_0x47a76c(0x21f)](MIME_JPEG),_0x2ce40e=_0xaa06ad[_0x47a76c(0x21e)]('base64');return{'content':[{'type':'text','text':_0x47a76c(0x227)},{'type':_0x47a76c(0x1fd),'data':_0x2ce40e,'mimeType':_0x47a76c(0x1f8)}]};}if(_0x237bff===_0x47a76c(0x21d)){const {x:_0x2c27a6,y:_0x46d04d}=_0x154128;return robot['moveMouse'](_0x2c27a6,_0x46d04d),{'content':[{'type':_0x47a76c(0x21c),'text':_0x47a76c(0x1fe)+_0x2c27a6+',\x20'+_0x46d04d}]};}if(_0x237bff===_0x47a76c(0x212)){const {button:button=_0x47a76c(0x1f3),double:double=![]}=_0x154128;return robot['mouseClick'](button,double),{'content':[{'type':_0x47a76c(0x21c),'text':_0x47a76c(0x219)+button+'\x20button'+(double?_0x47a76c(0x1fc):'')}]};}if(_0x237bff===_0x47a76c(0x209)){const {text:_0x188467}=_0x154128;return robot[_0x47a76c(0x226)](_0x188467),{'content':[{'type':'text','text':_0x47a76c(0x207)+_0x188467+'\x22'}]};}if(_0x237bff===_0x47a76c(0x20f)){const {key:_0x4f600a,modifiers:_0x32ed87}=_0x154128;return robot[_0x47a76c(0x205)](_0x4f600a,_0x32ed87),{'content':[{'type':_0x47a76c(0x21c),'text':'Tapped\x20key:\x20'+_0x4f600a+'\x20'+(_0x32ed87?_0x47a76c(0x223)+_0x32ed87[_0x47a76c(0x220)]('+'):'')}]};}if(_0x237bff===_0x47a76c(0x225)){const _0x796ab2=robot['getScreenSize']();return{'content':[{'type':'text','text':_0x47a76c(0x21b)+_0x796ab2['width']+'x'+_0x796ab2[_0x47a76c(0x216)]}]};}throw new Error(_0x47a76c(0x217)+_0x237bff);}catch(_0x13d495){return{'content':[{'type':_0x47a76c(0x21c),'text':'Error:\x20'+_0x13d495}],'isError':!![]};}});const transport=new StdioServerTransport();await server[a21_0x3039f1(0x203)](transport);
@@ -1 +1 @@
1
- const a22_0x3d72e8=a22_0x1be6;(function(_0x4c4c93,_0x55221b){const _0x432e0c=a22_0x1be6,_0x4fe510=_0x4c4c93();while(!![]){try{const _0x56fcd7=parseInt(_0x432e0c(0x1d4))/0x1+parseInt(_0x432e0c(0x1e1))/0x2+-parseInt(_0x432e0c(0x1cd))/0x3+-parseInt(_0x432e0c(0x1d1))/0x4*(parseInt(_0x432e0c(0x1df))/0x5)+-parseInt(_0x432e0c(0x1e3))/0x6+-parseInt(_0x432e0c(0x1ce))/0x7+parseInt(_0x432e0c(0x1cc))/0x8;if(_0x56fcd7===_0x55221b)break;else _0x4fe510['push'](_0x4fe510['shift']());}catch(_0x22ef8b){_0x4fe510['push'](_0x4fe510['shift']());}}}(a22_0x3a09,0x65fd0));import*as a22_0x56888a from'../telegram/index.js';import*as a22_0x289284 from'../discord/index.js';import*as a22_0x255bf5 from'../email/index.js';function a22_0x3a09(){const _0x1cc6da=['1553982qZROUN','isConfigured','start','services','stopBot','startAllConfigured','name','getStatus','all','2613952qMXuLe','785796pQfdvN','187936DwelTn','success','\x20services\x20active\x20in\x20background','7376fEAjhc','Email','length','73131hfHcac','Telegram','Failed\x20to\x20start\x20','forEach','map','isRunning','isBotRunning','dim','push','stop','startBot','115AeGbgZ','error','1216116mGhDPT','filter'];a22_0x3a09=function(){return _0x1cc6da;};return a22_0x3a09();}import*as a22_0x1d4596 from'../ui/output.js';class BotManager{['services']=[];constructor(){const _0x294b86=a22_0x1be6;this['services']['push']({'name':_0x294b86(0x1d5),'start':a22_0x56888a[_0x294b86(0x1de)],'stop':a22_0x56888a[_0x294b86(0x1c7)],'isRunning':a22_0x56888a[_0x294b86(0x1da)],'isConfigured':a22_0x56888a['isConfigured']}),this[_0x294b86(0x1e6)][_0x294b86(0x1dc)]({'name':'Discord','start':a22_0x289284['startBot'],'stop':a22_0x289284[_0x294b86(0x1c7)],'isRunning':a22_0x289284[_0x294b86(0x1da)],'isConfigured':a22_0x289284[_0x294b86(0x1e4)]}),this['services'][_0x294b86(0x1dc)]({'name':_0x294b86(0x1d2),'start':a22_0x255bf5[_0x294b86(0x1de)],'stop':a22_0x255bf5[_0x294b86(0x1c7)],'isRunning':a22_0x255bf5['isBotRunning'],'isConfigured':a22_0x255bf5[_0x294b86(0x1e4)]});}async[a22_0x3d72e8(0x1c8)](){const _0x17e58a=a22_0x3d72e8,_0x5d9a08=this[_0x17e58a(0x1e6)][_0x17e58a(0x1e2)](_0x45b8d2=>_0x45b8d2[_0x17e58a(0x1e4)]());if(_0x5d9a08[_0x17e58a(0x1d3)]===0x0)return;a22_0x1d4596[_0x17e58a(0x1db)]('\x0a[Bot\x20Manager]\x20Starting\x20background\x20services...');const _0x27ed0b=await Promise[_0x17e58a(0x1cb)](_0x5d9a08[_0x17e58a(0x1d8)](async _0x391aef=>{const _0x5762b3=_0x17e58a;try{if(_0x391aef[_0x5762b3(0x1d9)]())return!![];const _0x1bb49b=await _0x391aef[_0x5762b3(0x1e5)]();return _0x1bb49b;}catch(_0x243b2e){return a22_0x1d4596[_0x5762b3(0x1e0)](_0x5762b3(0x1d6)+_0x391aef[_0x5762b3(0x1c9)]+':\x20'+_0x243b2e),![];}})),_0x44c155=_0x27ed0b[_0x17e58a(0x1e2)](_0x4543a8=>_0x4543a8)['length'];_0x44c155>0x0&&a22_0x1d4596[_0x17e58a(0x1cf)]('[Bot\x20Manager]\x20'+_0x44c155+'/'+_0x5d9a08[_0x17e58a(0x1d3)]+_0x17e58a(0x1d0));}['stopAll'](){const _0x9ef1f8=a22_0x3d72e8;this['services'][_0x9ef1f8(0x1d7)](_0x36eca6=>{const _0x5a9f47=_0x9ef1f8;_0x36eca6[_0x5a9f47(0x1d9)]()&&_0x36eca6[_0x5a9f47(0x1dd)]();});}[a22_0x3d72e8(0x1ca)](){const _0x158594=a22_0x3d72e8;return this[_0x158594(0x1e6)][_0x158594(0x1d8)](_0x59512a=>({'name':_0x59512a['name'],'running':_0x59512a['isRunning'](),'configured':_0x59512a['isConfigured']()}));}}function a22_0x1be6(_0xff3fea,_0x32f143){_0xff3fea=_0xff3fea-0x1c7;const _0x3a0926=a22_0x3a09();let _0x1be62e=_0x3a0926[_0xff3fea];return _0x1be62e;}export const botManager=new BotManager();
1
+ const a22_0x26e339=a22_0x5000;(function(_0xcc24a3,_0x113e0c){const _0x3ec6d6=a22_0x5000,_0x4ac810=_0xcc24a3();while(!![]){try{const _0x13a380=-parseInt(_0x3ec6d6(0x105))/0x1*(parseInt(_0x3ec6d6(0xf0))/0x2)+-parseInt(_0x3ec6d6(0xec))/0x3*(-parseInt(_0x3ec6d6(0xf9))/0x4)+-parseInt(_0x3ec6d6(0xe7))/0x5+parseInt(_0x3ec6d6(0xed))/0x6+parseInt(_0x3ec6d6(0xef))/0x7*(-parseInt(_0x3ec6d6(0x104))/0x8)+parseInt(_0x3ec6d6(0xfc))/0x9*(-parseInt(_0x3ec6d6(0xfa))/0xa)+parseInt(_0x3ec6d6(0x102))/0xb;if(_0x13a380===_0x113e0c)break;else _0x4ac810['push'](_0x4ac810['shift']());}catch(_0x43075e){_0x4ac810['push'](_0x4ac810['shift']());}}}(a22_0x31d8,0x8064c));import*as a22_0x59034b from'../telegram/index.js';function a22_0x5000(_0x26fa71,_0x51b234){_0x26fa71=_0x26fa71-0xe5;const _0x31d8a7=a22_0x31d8();let _0x50005f=_0x31d8a7[_0x26fa71];return _0x50005f;}import*as a22_0x1c4f37 from'../discord/index.js';import*as a22_0x8f40b8 from'../email/index.js';import*as a22_0x428494 from'../ui/output.js';class BotManager{[a22_0x26e339(0xfe)]=[];constructor(){const _0x399431=a22_0x26e339;this[_0x399431(0xfe)][_0x399431(0xfd)]({'name':_0x399431(0xf2),'start':a22_0x59034b['startBot'],'stop':a22_0x59034b[_0x399431(0xe6)],'isRunning':a22_0x59034b[_0x399431(0xee)],'isConfigured':a22_0x59034b[_0x399431(0xf6)]}),this['services'][_0x399431(0xfd)]({'name':_0x399431(0xeb),'start':a22_0x1c4f37[_0x399431(0xf5)],'stop':a22_0x1c4f37['stopBot'],'isRunning':a22_0x1c4f37[_0x399431(0xee)],'isConfigured':a22_0x1c4f37[_0x399431(0xf6)]}),this[_0x399431(0xfe)][_0x399431(0xfd)]({'name':_0x399431(0x106),'start':a22_0x8f40b8[_0x399431(0xf5)],'stop':a22_0x8f40b8[_0x399431(0xe6)],'isRunning':a22_0x8f40b8[_0x399431(0xee)],'isConfigured':a22_0x8f40b8[_0x399431(0xf6)]});}async['startAllConfigured'](){const _0x3b59ee=a22_0x26e339,_0x2c9bc7=this[_0x3b59ee(0xfe)]['filter'](_0x759fbd=>_0x759fbd['isConfigured']());if(_0x2c9bc7[_0x3b59ee(0xe8)]===0x0)return;a22_0x428494[_0x3b59ee(0x100)]('\x0a[Bot\x20Manager]\x20Starting\x20background\x20services...');const _0x50199e=await Promise[_0x3b59ee(0xe5)](_0x2c9bc7[_0x3b59ee(0xea)](async _0x54247f=>{const _0x1b3f6e=_0x3b59ee;try{if(_0x54247f[_0x1b3f6e(0xf4)]())return!![];const _0x5635d3=await _0x54247f['start']();return _0x5635d3;}catch(_0x2dc6bc){return a22_0x428494[_0x1b3f6e(0x103)](_0x1b3f6e(0xf8)+_0x54247f[_0x1b3f6e(0xff)]+':\x20'+_0x2dc6bc),![];}})),_0x283784=_0x50199e[_0x3b59ee(0x101)](_0x3edad9=>_0x3edad9)['length'];_0x283784>0x0&&a22_0x428494[_0x3b59ee(0xe9)](_0x3b59ee(0xf1)+_0x283784+'/'+_0x2c9bc7[_0x3b59ee(0xe8)]+'\x20services\x20active\x20in\x20background');}[a22_0x26e339(0xfb)](){const _0x1d8930=a22_0x26e339;this['services'][_0x1d8930(0xf3)](_0x2f31dd=>{const _0x15615e=_0x1d8930;_0x2f31dd[_0x15615e(0xf4)]()&&_0x2f31dd['stop']();});}[a22_0x26e339(0xf7)](){const _0x23748c=a22_0x26e339;return this['services'][_0x23748c(0xea)](_0x447ce2=>({'name':_0x447ce2['name'],'running':_0x447ce2[_0x23748c(0xf4)](),'configured':_0x447ce2['isConfigured']()}));}}export const botManager=new BotManager();function a22_0x31d8(){const _0x76b20b=['14042116ZBuPVK','error','9832DcGgTw','155GjUWds','Email','all','stopBot','371945ckMHHJ','length','success','map','Discord','173067tcYZEx','5465388wNpbmc','isBotRunning','2065PvOvrK','8974MxCyIS','[Bot\x20Manager]\x20','Telegram','forEach','isRunning','startBot','isConfigured','getStatus','Failed\x20to\x20start\x20','8QQDths','10uCgrFF','stopAll','5800527djsGuI','push','services','name','dim','filter'];a22_0x31d8=function(){return _0x76b20b;};return a22_0x31d8();}
@@ -1 +1 @@
1
- (function(_0x4c7097,_0xbd160c){const _0x210697=a23_0x4466,_0xc63d72=_0x4c7097();while(!![]){try{const _0x526403=-parseInt(_0x210697(0xfb))/0x1+parseInt(_0x210697(0xec))/0x2*(-parseInt(_0x210697(0xf8))/0x3)+parseInt(_0x210697(0xf9))/0x4+-parseInt(_0x210697(0xf6))/0x5*(-parseInt(_0x210697(0xf5))/0x6)+parseInt(_0x210697(0xfc))/0x7*(parseInt(_0x210697(0xf1))/0x8)+parseInt(_0x210697(0xeb))/0x9+parseInt(_0x210697(0xfa))/0xa*(-parseInt(_0x210697(0xf3))/0xb);if(_0x526403===_0xbd160c)break;else _0xc63d72['push'](_0xc63d72['shift']());}catch(_0xf8f181){_0xc63d72['push'](_0xc63d72['shift']());}}}(a23_0x5c47,0x8d30c));function a23_0x4466(_0x55bc60,_0x275e04){_0x55bc60=_0x55bc60-0xea;const _0x5c4705=a23_0x5c47();let _0x44665e=_0x5c4705[_0x55bc60];return _0x44665e;}import{GoogleGenerativeAI}from'@google/generative-ai';import{promises as a23_0xb11678}from'fs';function a23_0x5c47(){const _0x195891=['6cLVdeL','generateContent','getGenerativeModel','gemini-2.0-flash-exp','message','989240DzLceD','toString','2540054XCNxEp','readFile','1302CPMQne','13010zjiwxR','set','187548CdeJbd','1831296TaHsSw','30DeqzBw','50934wFoSwF','7DYdUQM','get','geminiKey','Voice\x20processing\x20failed:\x20','audio/ogg','response','3270843WQDAjb'];a23_0x5c47=function(){return _0x195891;};return a23_0x5c47();}import*as a23_0x440dd3 from'../ui/output.js';import a23_0x1c7d05 from'conf';const config=new a23_0x1c7d05({'projectName':'woozlit-cli-voice'});export function setGeminiKey(_0x30cb88){const _0x37112a=a23_0x4466;config[_0x37112a(0xf7)]('geminiKey',_0x30cb88);}export function getGeminiKey(){const _0x2ab1d3=a23_0x4466;return config[_0x2ab1d3(0xfd)](_0x2ab1d3(0xfe))||'';}export async function processVoiceMessage(_0x294441){const _0x23df13=a23_0x4466,_0x5649c6=getGeminiKey();if(!_0x5649c6)throw new Error('Gemini\x20API\x20Key\x20not\x20configured.\x20Run\x20\x27/voice\x20setup\x27\x20first.');const _0x48a87e=new GoogleGenerativeAI(_0x5649c6),_0x5b6f17=_0x48a87e[_0x23df13(0xee)]({'model':_0x23df13(0xef)});try{const _0x4636d1=await a23_0xb11678[_0x23df13(0xf4)](_0x294441),_0x45d8c9=_0x4636d1[_0x23df13(0xf2)]('base64'),_0x4bcc4f=_0x23df13(0x100),_0x20b45f=await _0x5b6f17[_0x23df13(0xed)](['Listen\x20to\x20this\x20audio\x20and\x20respond\x20helpfully.\x20If\x20it\x27s\x20a\x20command,\x20execute\x20it\x20or\x20say\x20you\x20can\x27t.',{'inlineData':{'mimeType':_0x4bcc4f,'data':_0x45d8c9}}]),_0xc2b3d3=_0x20b45f[_0x23df13(0xea)]['text']();return{'text':_0xc2b3d3};}catch(_0x303fcc){a23_0x440dd3['error'](_0x23df13(0xff)+_0x303fcc[_0x23df13(0xf0)]);throw _0x303fcc;}}
1
+ const a23_0x633a9d=a23_0x4ed4;(function(_0x4288da,_0x247b37){const _0x49269c=a23_0x4ed4,_0x4dceb4=_0x4288da();while(!![]){try{const _0x16b7a3=parseInt(_0x49269c(0x175))/0x1*(-parseInt(_0x49269c(0x167))/0x2)+-parseInt(_0x49269c(0x15f))/0x3+parseInt(_0x49269c(0x15e))/0x4+parseInt(_0x49269c(0x161))/0x5*(parseInt(_0x49269c(0x169))/0x6)+parseInt(_0x49269c(0x173))/0x7*(parseInt(_0x49269c(0x160))/0x8)+parseInt(_0x49269c(0x166))/0x9+-parseInt(_0x49269c(0x15d))/0xa;if(_0x16b7a3===_0x247b37)break;else _0x4dceb4['push'](_0x4dceb4['shift']());}catch(_0x3ebe35){_0x4dceb4['push'](_0x4dceb4['shift']());}}}(a23_0x4fd3,0x5c82d));import{GoogleGenerativeAI}from'@google/generative-ai';import{promises as a23_0xf34ca0}from'fs';import*as a23_0x871d2f from'../ui/output.js';function a23_0x4fd3(){const _0x57c413=['1662EIjlfL','getGenerativeModel','response','gemini-2.0-flash-exp','Listen\x20to\x20this\x20audio\x20and\x20respond\x20helpfully.\x20If\x20it\x27s\x20a\x20command,\x20execute\x20it\x20or\x20say\x20you\x20can\x27t.','Gemini\x20API\x20Key\x20not\x20configured.\x20Run\x20\x27/voice\x20setup\x27\x20first.','audio/ogg','text','readFile','get','103691MtQvZy','base64','10XqHOeX','6004640NwAfne','2088344yBmfVh','637005MkveNJ','128bsLdNM','4820fUghnX','set','woozlit-cli-voice','Voice\x20processing\x20failed:\x20','toString','3645288EKGLFz','47886XUHjqS','geminiKey'];a23_0x4fd3=function(){return _0x57c413;};return a23_0x4fd3();}function a23_0x4ed4(_0x4d1f82,_0x829b96){_0x4d1f82=_0x4d1f82-0x15d;const _0x4fd33c=a23_0x4fd3();let _0x4ed454=_0x4fd33c[_0x4d1f82];return _0x4ed454;}import a23_0x1ec1c9 from'conf';const config=new a23_0x1ec1c9({'projectName':a23_0x633a9d(0x163)});export function setGeminiKey(_0x526645){const _0x31ec3b=a23_0x633a9d;config[_0x31ec3b(0x162)](_0x31ec3b(0x168),_0x526645);}export function getGeminiKey(){const _0x5e58b1=a23_0x633a9d;return config[_0x5e58b1(0x172)]('geminiKey')||'';}export async function processVoiceMessage(_0x2edc7d){const _0x4c5c87=a23_0x633a9d,_0xe7ebe1=getGeminiKey();if(!_0xe7ebe1)throw new Error(_0x4c5c87(0x16e));const _0x4d8c33=new GoogleGenerativeAI(_0xe7ebe1),_0x486f34=_0x4d8c33[_0x4c5c87(0x16a)]({'model':_0x4c5c87(0x16c)});try{const _0x17027a=await a23_0xf34ca0[_0x4c5c87(0x171)](_0x2edc7d),_0x1a446e=_0x17027a[_0x4c5c87(0x165)](_0x4c5c87(0x174)),_0x16a4b0=_0x4c5c87(0x16f),_0xd7a10b=await _0x486f34['generateContent']([_0x4c5c87(0x16d),{'inlineData':{'mimeType':_0x16a4b0,'data':_0x1a446e}}]),_0xe9bec1=_0xd7a10b[_0x4c5c87(0x16b)][_0x4c5c87(0x170)]();return{'text':_0xe9bec1};}catch(_0x240e8a){a23_0x871d2f['error'](_0x4c5c87(0x164)+_0x240e8a['message']);throw _0x240e8a;}}