@ranger-testing/ranger-cli 3.1.0 → 3.1.1-alpha.b22d278-38

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (85) hide show
  1. package/build/cli.js +1 -1
  2. package/build/commands/addEnv.js +1 -1
  3. package/build/commands/authEncrypt.js +1 -1
  4. package/build/commands/clean.js +1 -1
  5. package/build/commands/config.js +1 -1
  6. package/build/commands/deleteProfile.js +1 -1
  7. package/build/commands/env.js +1 -1
  8. package/build/commands/feature.js +1 -1
  9. package/build/commands/hook.js +1 -1
  10. package/build/commands/hooks/autoPrompt.js +1 -1
  11. package/build/commands/hooks/disable.js +1 -1
  12. package/build/commands/hooks/enable.js +1 -1
  13. package/build/commands/hooks/exitPlanMode.js +1 -1
  14. package/build/commands/hooks/index.js +1 -1
  15. package/build/commands/hooks/output.js +1 -1
  16. package/build/commands/hooks/planReminder.js +1 -1
  17. package/build/commands/hooks/planStart.js +1 -1
  18. package/build/commands/hooks/postEdit.js +1 -1
  19. package/build/commands/hooks/preCompact.js +1 -1
  20. package/build/commands/hooks/sessionEnd.js +1 -1
  21. package/build/commands/hooks/sessionStart.js +1 -1
  22. package/build/commands/hooks/stopHook.js +1 -1
  23. package/build/commands/index.js +1 -1
  24. package/build/commands/login.js +1 -1
  25. package/build/commands/mcpBootstrap.js +1 -1
  26. package/build/commands/migrateProfile.js +1 -1
  27. package/build/commands/setup/claude.js +1 -1
  28. package/build/commands/setup/opencode.js +1 -1
  29. package/build/commands/setupCi.js +1 -1
  30. package/build/commands/skillup.js +1 -1
  31. package/build/commands/start.js +1 -1
  32. package/build/commands/status.js +1 -1
  33. package/build/commands/update.js +1 -1
  34. package/build/commands/updateEnv.js +1 -1
  35. package/build/commands/useEnv.js +1 -1
  36. package/build/commands/utils/activeProfile.js +1 -1
  37. package/build/commands/utils/agentEnv.js +1 -1
  38. package/build/commands/utils/browserSessionsApi.js +1 -1
  39. package/build/commands/utils/claudeConfig.js +1 -1
  40. package/build/commands/utils/claudeOverrideSettings.js +1 -1
  41. package/build/commands/utils/claudePlugin.js +1 -1
  42. package/build/commands/utils/cloudProfile.js +1 -1
  43. package/build/commands/utils/cloudProfileSession.js +1 -1
  44. package/build/commands/utils/crypto.js +1 -1
  45. package/build/commands/utils/desirePathLog.js +1 -1
  46. package/build/commands/utils/deviceAuth.js +1 -1
  47. package/build/commands/utils/environment.js +1 -1
  48. package/build/commands/utils/featureApi.js +1 -1
  49. package/build/commands/utils/fixWebmDuration.js +1 -1
  50. package/build/commands/utils/gitTracked.js +1 -1
  51. package/build/commands/utils/keychain.js +1 -1
  52. package/build/commands/utils/legacyWarning.js +1 -1
  53. package/build/commands/utils/localAgentInstallationsApi.js +1 -1
  54. package/build/commands/utils/matchAuthEnvironment.js +1 -1
  55. package/build/commands/utils/mcpImageBase64.js +1 -1
  56. package/build/commands/utils/model.js +1 -1
  57. package/build/commands/utils/novaActCli.js +1 -1
  58. package/build/commands/utils/opencodeConfig.js +1 -1
  59. package/build/commands/utils/organizationEnvApi.js +1 -1
  60. package/build/commands/utils/playwrightCli.js +1 -1
  61. package/build/commands/utils/profileMessages.js +1 -1
  62. package/build/commands/utils/profileSetupBanner.js +1 -1
  63. package/build/commands/utils/projectsConfig.js +1 -1
  64. package/build/commands/utils/rangerConfig.js +1 -1
  65. package/build/commands/utils/rangerRoot.js +1 -1
  66. package/build/commands/utils/rangerwrightCli.js +1 -1
  67. package/build/commands/utils/resolveProfileContext.js +1 -1
  68. package/build/commands/utils/resolveProfileUrl.js +1 -1
  69. package/build/commands/utils/retry.js +1 -1
  70. package/build/commands/utils/sessionCache.js +1 -1
  71. package/build/commands/utils/settings.js +1 -1
  72. package/build/commands/utils/skillContent.js +1 -1
  73. package/build/commands/utils/skills.js +1 -1
  74. package/build/commands/utils/stitchWebmFiles.js +1 -1
  75. package/build/commands/utils/telemetry.js +1 -1
  76. package/build/commands/utils/tokenRefresh.js +1 -1
  77. package/build/commands/utils/traceSnapshotMapper.js +1 -1
  78. package/build/commands/utils/tunnelClient.js +1 -1
  79. package/build/commands/utils/userApi.js +1 -1
  80. package/build/commands/utils/version.js +1 -1
  81. package/build/commands/verifyFeature.js +1 -1
  82. package/build/commands/verifyFeatureCli.js +1 -1
  83. package/build/commands/verifyFeatureNovaCli.js +1 -1
  84. package/build/commands/verifyFeatureRangerwrightCli.js +1 -1
  85. package/package.json +1 -1
@@ -1 +1 @@
1
- const _0x5ead82=_0x5bda;(function(_0x599cea,_0x670c1a){const _0x54a706=_0x5bda,_0x49ffe8=_0x599cea();while(!![]){try{const _0x5a123b=-parseInt(_0x54a706(0x1d6))/0x1+-parseInt(_0x54a706(0x188))/0x2+parseInt(_0x54a706(0x192))/0x3+parseInt(_0x54a706(0x1a8))/0x4+-parseInt(_0x54a706(0x1d7))/0x5*(-parseInt(_0x54a706(0x1b1))/0x6)+-parseInt(_0x54a706(0x1ab))/0x7*(parseInt(_0x54a706(0x1bf))/0x8)+parseInt(_0x54a706(0x1b6))/0x9;if(_0x5a123b===_0x670c1a)break;else _0x49ffe8['push'](_0x49ffe8['shift']());}catch(_0x5092e7){_0x49ffe8['push'](_0x49ffe8['shift']());}}}(_0x5ccb,0xf20c7));import{spawn}from'child_process';import{existsSync}from'fs';import{readFile,writeFile}from'fs/promises';import{installSkill,removeSkill,RANGER_MANAGED_SKILLS,DEPRECATED_SKILLS}from'./utils/skills.js';import{PACKAGE_NAME,getCurrentVersion,getLatestVersion,compareVersions}from'./utils/version.js';function _0x5ccb(){const _0x2f88c1=['\x0aCould\x20not\x20check\x20latest\x20version:\x20','\x0aInstalling\x20','eZcpp','VgNsR','545989ofJGmE','5ZqimIS','Latest\x20version:\x20\x20','sLMws','AMoID','ODiED','FCduB','gtzXa','vQPpi','ICiAQ','\x0aSuccessfully\x20installed\x20','\x0aCurrent\x20version:\x20','NpGgB','zqunN','paJNP','TQZvf','1288086cgIHZw','log','project','trailhead','CKdLt','oaPNL','ujDZv','claude','close','Claude\x20plugin\x20update\x20failed\x20for\x20','1272255LFuBZU','pvfcI','oVRBl','marketplace','JxIdj','.0.0','ranger@trailhead','\x20ranger-managed\x20skill(s)...','\x0aNo\x20ranger-managed\x20skills\x20found\x20to\x20reinstall.','version','\x0aClaude\x20plugin\x20updated\x20(user\x20scope).','npm','xIlVl','Update\x20failed.','.gitignore','\x20skill\x20','inherit','latest','...\x0a','edczp','user','trim','2018488AKipek','Checking\x20for\x20updates...','isFinite','10834943KgntVa',')\x20is\x20newer\x20than\x20the\x20published\x20version\x20(','platform','QPrCT','rLfyo','stdio','2997222fdbQWs','xhxCu','xxbqq','aMPTx','LWIrl','20709612MtjNqI','\x0a✅\x20Update\x20complete!','some','warn','RggKu','ACKQM','split','\x0aSuccessfully\x20installed\x20latest\x20version.','WJrRv','8QDqIWT','active-profile.txt','fcmiC','test','\x0aYour\x20version\x20(','length','\x0aYou\x20are\x20already\x20on\x20the\x20latest\x20version.','plugin','uhgMl','\x20channel.','\x20—\x20reinstalling\x20@','Attempting\x20install\x20anyway...','gMcIB','beta','error','win32','local','active-feature.txt','update'];_0x5ccb=function(){return _0x2f88c1;};return _0x5ccb();}import{getProjectRoot,getSkillsDir}from'./utils/claudeConfig.js';import{getOpencodeSkillsDir}from'./utils/opencodeConfig.js';import{join}from'path';import{getRangerDir}from'./utils/rangerRoot.js';import{getPluginInfo,isMarketplaceAdded,isPluginInstalled}from'./utils/claudePlugin.js';const CLAUDE_COMMAND_TIMEOUT_MS=0x1d4c0;async function runCommand(_0x53f580,_0x68954c,_0x2c2c28){const _0x2a82b7=_0x5bda,_0x2476d3={'TQZvf':function(_0x525993,_0x13d554){return _0x525993(_0x13d554);},'pvfcI':'ignore','CKdLt':_0x2a82b7(0x1a2),'xhxCu':_0x2a82b7(0x1ce),'cbyfA':function(_0x22f253,_0x12fe16,_0x34c0f6){return _0x22f253(_0x12fe16,_0x34c0f6);},'WvjmA':_0x2a82b7(0x190),'sLMws':_0x2a82b7(0x1cd)};return new Promise(_0x2f49a7=>{const _0x5694b2=_0x2a82b7,_0x28e187={'IchVM':function(_0x176b66,_0x2a11bf){return _0x176b66(_0x2a11bf);}};let _0x11cf1f=![],_0x4a0af3;const _0x2d5af0=_0x56a6f7=>{if(_0x11cf1f)return;_0x11cf1f=!![],_0x4a0af3&&_0x28e187['IchVM'](clearTimeout,_0x4a0af3),_0x2f49a7(_0x56a6f7);},_0x5d73e7=spawn(_0x53f580,_0x68954c,{'stdio':[_0x2476d3[_0x5694b2(0x193)],_0x2c2c28?.[_0x5694b2(0x1b0)]??_0x2476d3[_0x5694b2(0x18c)],_0x2c2c28?.['stdio']??_0x2476d3[_0x5694b2(0x18c)]],'cwd':_0x2c2c28?.['cwd'],'shell':process['platform']===_0x2476d3[_0x5694b2(0x1b2)]});_0x4a0af3=_0x2c2c28?.['timeoutMs']?_0x2476d3['cbyfA'](setTimeout,()=>{_0x5d73e7['kill'](),_0x5d73e7['unref'](),_0x2d5af0(![]);},_0x2c2c28['timeoutMs']):undefined,_0x5d73e7['on'](_0x2476d3['WvjmA'],_0x2d863f=>{_0x2d5af0(_0x2d863f===0x0);}),_0x5d73e7['on'](_0x2476d3[_0x5694b2(0x1d9)],()=>{const _0x1767b4=_0x5694b2;_0x2476d3[_0x1767b4(0x187)](_0x2d5af0,![]);});});}export function resolveDistTag(_0x5304aa){const _0x5e8018=_0x5bda,_0x2662e7={'AMoID':'alpha'};if(/-alpha\./i['test'](_0x5304aa))return _0x2662e7[_0x5e8018(0x1da)];if(/-beta\./i[_0x5e8018(0x1c2)](_0x5304aa))return _0x5e8018(0x1cc);if(/-rc\./i['test'](_0x5304aa))return'rc';return'latest';}export function resolveInstallTarget(_0x12fba4){const _0x2b8bec=_0x5bda,_0x86bc7c={'alMSk':function(_0x318f7c,_0x1897a4){return _0x318f7c!==_0x1897a4;},'zqunN':'latest'},_0x545d03=resolveDistTag(_0x12fba4);if(_0x86bc7c['alMSk'](_0x545d03,_0x86bc7c['zqunN']))return _0x545d03;const _0x242736=_0x12fba4['split']('.')[0x0],_0x5ed3fa=parseInt(_0x242736,0xa);if(!Number[_0x2b8bec(0x1aa)](_0x5ed3fa))return _0x86bc7c[_0x2b8bec(0x185)];return'^'+_0x5ed3fa+_0x2b8bec(0x197);}async function runInstall(_0x1c8686){const _0x8ff383=_0x5bda,_0x2414eb={'MnsKR':function(_0x1d0fb7,_0x52fff2){return _0x1d0fb7(_0x52fff2);},'LWIrl':function(_0x3452e4,_0x480085,_0x2e78f6,_0x4734d7){return _0x3452e4(_0x480085,_0x2e78f6,_0x4734d7);},'paJNP':_0x8ff383(0x19d),'gLqLI':'install','pKQai':'inherit','aNhlk':'win32','aMPTx':'close','NprDV':_0x8ff383(0x1cd)},_0x4e5c9d=resolveInstallTarget(_0x1c8686);return new Promise(_0x4ea797=>{const _0x54bf48=_0x8ff383,_0x5783a1={'WRRsC':function(_0x2b5f70,_0x12193c){return _0x2414eb['MnsKR'](_0x2b5f70,_0x12193c);},'gtzXa':function(_0xc502ea,_0x5a4c14){return _0xc502ea===_0x5a4c14;},'BNiXa':function(_0x11ade6,_0x23d953){return _0x11ade6(_0x23d953);}};console['log'](_0x54bf48(0x1d3)+PACKAGE_NAME+'@'+_0x4e5c9d+_0x54bf48(0x1a4));const _0xf015a7=_0x2414eb[_0x54bf48(0x1b5)](spawn,_0x2414eb[_0x54bf48(0x186)],[_0x2414eb['gLqLI'],'-g',PACKAGE_NAME+'@'+_0x4e5c9d],{'stdio':['ignore',_0x2414eb['pKQai'],'inherit'],'shell':process[_0x54bf48(0x1ad)]===_0x2414eb['aNhlk']});_0xf015a7['on'](_0x2414eb[_0x54bf48(0x1b4)],_0x412f4f=>{const _0x5df62d=_0x54bf48;_0x5783a1['WRRsC'](_0x4ea797,_0x5783a1[_0x5df62d(0x17f)](_0x412f4f,0x0));}),_0xf015a7['on'](_0x2414eb['NprDV'],()=>{_0x5783a1['BNiXa'](_0x4ea797,![]);});});}function _0x5bda(_0x382083,_0x52eb12){_0x382083=_0x382083-0x17d;const _0x5ccb94=_0x5ccb();let _0x5bda79=_0x5ccb94[_0x382083];return _0x5bda79;}async function updateClaudeMarketplace(){const _0x190b8c=_0x5bda,_0x5af3b7={'FCduB':_0x190b8c(0x195)},_0xdce88a=await runCommand(_0x190b8c(0x18f),['plugin',_0x5af3b7[_0x190b8c(0x17e)],_0x190b8c(0x1d1),_0x190b8c(0x18b)],{'timeoutMs':CLAUDE_COMMAND_TIMEOUT_MS});if(!_0xdce88a)throw new Error('Claude\x20marketplace\x20update\x20command\x20failed\x20(timed\x20out,\x20failed\x20to\x20start,\x20or\x20exited\x20with\x20a\x20non-zero\x20status).');}async function updateClaudePlugin(_0x40dd78=_0x5ead82(0x1a6)){const _0x156707=_0x5ead82,_0x1f81c7={'rLfyo':_0x156707(0x1c6),'VGlUX':_0x156707(0x1d1),'fcmiC':'ranger@trailhead','WJrRv':'user','gAznN':_0x156707(0x18f),'JpfDB':function(_0x16fceb,_0x27b808){return _0x16fceb===_0x27b808;},'ACKQM':'local','RggKu':function(_0x5c99fd){return _0x5c99fd();}},_0x5edd30=[_0x1f81c7[_0x156707(0x1af)],_0x1f81c7['VGlUX'],_0x1f81c7[_0x156707(0x1c1)]];_0x40dd78!==_0x1f81c7[_0x156707(0x1be)]&&_0x5edd30['push']('--scope',_0x40dd78);const _0xf26272=await runCommand(_0x1f81c7['gAznN'],_0x5edd30,{'timeoutMs':CLAUDE_COMMAND_TIMEOUT_MS,'cwd':_0x40dd78===_0x156707(0x18a)||_0x1f81c7['JpfDB'](_0x40dd78,_0x1f81c7[_0x156707(0x1bb)])?_0x1f81c7[_0x156707(0x1ba)](getProjectRoot):undefined});if(!_0xf26272)throw new Error(_0x156707(0x191)+_0x40dd78+'\x20scope\x20(timed\x20out,\x20failed\x20to\x20start,\x20or\x20exited\x20with\x20a\x20non-zero\x20status).');}function isSkillInstalled(_0x24cb27,_0x2d9521,_0x336f51){const _0x17fe9e={'MRZfU':'opencode','Rgczw':function(_0x3f4a25,_0x33058e){return _0x3f4a25(_0x33058e);},'sGQOk':function(_0x2293fd,_0x269288){return _0x2293fd(_0x269288);}},_0x539e11=_0x336f51===_0x17fe9e['MRZfU']?_0x17fe9e['Rgczw'](getOpencodeSkillsDir,_0x2d9521):_0x17fe9e['sGQOk'](getSkillsDir,_0x2d9521),_0x2bf68b=join(_0x539e11,_0x24cb27);return existsSync(_0x2bf68b);}async function reinstallSkills(_0x42f843){const _0x2e45e1=_0x5ead82,_0x534e31={'oVRBl':function(_0x1ad6e0,_0x55d417,_0x593b72,_0x4bd8da){return _0x1ad6e0(_0x55d417,_0x593b72,_0x4bd8da);},'qrOLT':'opencode','eZcpp':function(_0xd6557f,_0x35c2fe){return _0xd6557f===_0x35c2fe;},'yryPL':function(_0x97d271,_0x3b2579,_0x1de5a1){return _0x97d271(_0x3b2579,_0x1de5a1);}},_0x5b6756=[_0x2e45e1(0x18a),_0x2e45e1(0x1a6)],_0x4cc9bb=[];for(const _0x221fb7 of _0x5b6756){for(const _0x144449 of RANGER_MANAGED_SKILLS){_0x534e31[_0x2e45e1(0x194)](isSkillInstalled,_0x144449,_0x221fb7,_0x2e45e1(0x18f))&&_0x4cc9bb['push']({'skillName':_0x144449,'level':_0x221fb7,'platform':_0x2e45e1(0x18f)}),isSkillInstalled(_0x144449,_0x221fb7,'opencode')&&_0x4cc9bb['push']({'skillName':_0x144449,'level':_0x221fb7,'platform':_0x534e31['qrOLT']});}}for(const _0x107cbe of _0x5b6756){for(const _0x2b9d4f of DEPRECATED_SKILLS){await removeSkill(_0x2b9d4f,_0x107cbe);}}if(_0x534e31[_0x2e45e1(0x1d4)](_0x4cc9bb['length'],0x0)){console['log'](_0x2e45e1(0x19a));return;}console['log']('\x0aReinstalling\x20'+_0x4cc9bb['length']+_0x2e45e1(0x199));for(const {skillName:_0x417cc2,level:_0x4def25,platform:_0x3dd7de}of _0x4cc9bb){try{await _0x534e31['yryPL'](installSkill,_0x417cc2,{'level':_0x4def25,'cliVersion':_0x42f843,'platform':_0x3dd7de});}catch(_0x4f5b1d){console['warn']('\x20\x20Failed\x20to\x20reinstall\x20'+_0x3dd7de+'\x20'+_0x4def25+_0x2e45e1(0x1a1)+_0x417cc2+':',_0x4f5b1d);}}}async function ensureActiveProfileGitignored(){const _0x588519=_0x5ead82,_0x2231d3={'ICiAQ':function(_0x56e413,_0xd9e6f0,_0x232a79){return _0x56e413(_0xd9e6f0,_0x232a79);},'zBHAN':function(_0xf6d634){return _0xf6d634();},'EtwJq':function(_0x29c260,_0x16a572){return _0x29c260(_0x16a572);},'kfKiD':function(_0xc1667f,_0x2b3a8d,_0x1e5bea){return _0xc1667f(_0x2b3a8d,_0x1e5bea);}},_0x4ab4ea=_0x2231d3[_0x588519(0x181)](join,_0x2231d3['zBHAN'](getRangerDir),_0x588519(0x1a0));if(!_0x2231d3['EtwJq'](existsSync,_0x4ab4ea))return![];let _0x4e7824='';try{_0x4e7824=await _0x2231d3['kfKiD'](readFile,_0x4ab4ea,'utf-8');}catch{return![];}const _0x58724e=_0x4e7824['split'](/\r?\n/);if(_0x58724e[_0x588519(0x1b8)](_0x431562=>_0x431562[_0x588519(0x1a7)]()==='active-profile.txt'))return![];let _0x168092=_0x58724e['findIndex'](_0x326f59=>_0x326f59[_0x588519(0x1a7)]()===_0x588519(0x1d0));_0x168092===-0x1&&(_0x168092=_0x58724e[_0x588519(0x1c4)]);_0x58724e['splice'](_0x168092,0x0,_0x588519(0x1c0));let _0x5f9245=_0x58724e['join']('\x0a');!_0x5f9245['endsWith']('\x0a')&&(_0x5f9245+='\x0a');try{await writeFile(_0x4ab4ea,_0x5f9245,'utf-8');}catch{return![];}return!![];}export async function update(){const _0x398559=_0x5ead82,_0x87550a={'oaPNL':function(_0x4d86a8){return _0x4d86a8();},'dmejV':_0x398559(0x1a3),'uhgMl':function(_0x907129,_0xb1fc43){return _0x907129(_0xb1fc43);},'kfRxZ':function(_0x39f4d9){return _0x39f4d9();},'edczp':'\x0a✅\x20Update\x20complete!','xxbqq':function(_0x41887d,_0x3a7f04){return _0x41887d+_0x3a7f04;},'nEgko':_0x398559(0x1ca),'JxIdj':_0x398559(0x1bd),'NpGgB':function(_0x25e218){return _0x25e218();},'wFvUr':function(_0x1c984,_0x2b06eb,_0x2f4f56){return _0x1c984(_0x2b06eb,_0x2f4f56);},'UWIzZ':function(_0x2911c9,_0x430f56){return _0x2911c9===_0x430f56;},'QPrCT':_0x398559(0x1c5),'EtXHr':function(_0x3e7641,_0x3f94dd){return _0x3e7641<_0x3f94dd;},'VgNsR':function(_0x2c7d3f,_0x212c1e){return _0x2c7d3f(_0x212c1e);},'ujDZv':_0x398559(0x18b),'ODiED':_0x398559(0x198),'gMcIB':'\x0aClaude\x20marketplace\x20updated\x20(trailhead).','vQPpi':_0x398559(0x1a6),'xIlVl':function(_0x14ecaa,_0x4f14b4){return _0x14ecaa(_0x4f14b4);},'DvPih':_0x398559(0x18a),'Elneo':_0x398559(0x1cf)},_0x2a1187=_0x87550a[_0x398559(0x18d)](getCurrentVersion);console[_0x398559(0x189)](_0x398559(0x183)+_0x2a1187);const _0x18a42c=resolveDistTag(_0x2a1187);if(_0x18a42c!==_0x87550a['dmejV']){console[_0x398559(0x189)]('Prerelease\x20channel\x20detected\x20(@'+_0x18a42c+').\x20Staying\x20on\x20'+_0x18a42c+_0x398559(0x1c9)+_0x18a42c+'...');const _0x2da1bc=await _0x87550a[_0x398559(0x1c7)](runInstall,_0x2a1187);if(!_0x2da1bc)throw new Error('Update\x20failed\x20for\x20@'+_0x18a42c+_0x398559(0x1c8));const _0x131aa7=getCurrentVersion();console['log'](_0x398559(0x182)+PACKAGE_NAME+'@'+_0x18a42c+'.'),await _0x87550a['uhgMl'](reinstallSkills,_0x131aa7),await _0x87550a['kfRxZ'](ensureActiveProfileGitignored),console['log'](_0x87550a[_0x398559(0x1a5)]);return;}console['log'](_0x398559(0x1a9));const _0x5c158d=parseInt(_0x2a1187[_0x398559(0x1bc)]('.')[0x0],0xa);if(!Number['isFinite'](_0x5c158d))throw new Error(_0x87550a['xxbqq'](_0x87550a[_0x398559(0x1b3)]('Could\x20not\x20determine\x20the\x20current\x20major\x20version\x20from\x20\x22'+_0x2a1187+'\x22.\x20','Aborting\x20to\x20avoid\x20a\x20cross-major\x20upgrade.\x20Reinstall\x20explicitly\x20with:\x20'),'npm\x20i\x20-g\x20'+PACKAGE_NAME+'@latest'));const _0x49c460=getLatestVersion(_0x5c158d);let _0x447278=_0x2a1187;if(!_0x49c460['version']){console[_0x398559(0x1b9)](_0x398559(0x1d2)+_0x49c460['error']),console['log'](_0x87550a['nEgko']);const _0x5163e6=await runInstall(_0x2a1187);if(_0x5163e6)console[_0x398559(0x189)](_0x87550a[_0x398559(0x196)]),_0x447278=_0x87550a[_0x398559(0x184)](getCurrentVersion);else throw new Error('Update\x20failed:\x20'+_0x49c460['error']);}else{const _0x4699de=_0x49c460[_0x398559(0x19b)];console['log'](_0x398559(0x1d8)+_0x4699de);const _0x5875c9=_0x87550a['wFvUr'](compareVersions,_0x2a1187,_0x4699de);if(_0x87550a['UWIzZ'](_0x5875c9,0x0))console['log'](_0x87550a[_0x398559(0x1ae)]);else{if(_0x87550a['EtXHr'](_0x5875c9,0x0))console['log'](_0x398559(0x1c3)+_0x2a1187+_0x398559(0x1ac)+_0x4699de+').');else{const _0x46fc6b=await _0x87550a[_0x398559(0x1d5)](runInstall,_0x2a1187);if(_0x46fc6b)console[_0x398559(0x189)]('\x0aSuccessfully\x20updated\x20to\x20version\x20'+_0x4699de),_0x447278=_0x4699de;else throw new Error(_0x398559(0x19f));}}}await _0x87550a['uhgMl'](reinstallSkills,_0x447278);const _0x413e98=await isMarketplaceAdded(_0x87550a[_0x398559(0x18e)]),_0x451513=await isPluginInstalled(_0x87550a[_0x398559(0x17d)]);_0x413e98&&(await _0x87550a['NpGgB'](updateClaudeMarketplace),console['log'](_0x87550a[_0x398559(0x1cb)]));if(_0x451513){const _0x11ffad=await getPluginInfo('ranger@trailhead'),_0x24177a=_0x11ffad?.['scope']??_0x87550a[_0x398559(0x180)];await _0x87550a[_0x398559(0x19e)](updateClaudePlugin,_0x24177a);if(_0x87550a['UWIzZ'](_0x24177a,_0x87550a['DvPih']))console['log']('\x0aClaude\x20plugin\x20updated\x20(project\x20scope).');else _0x24177a===_0x87550a['Elneo']?console['log']('\x0aClaude\x20plugin\x20updated\x20(local\x20scope).'):console[_0x398559(0x189)](_0x398559(0x19c));}const _0x45e9a4=await ensureActiveProfileGitignored();console['log'](_0x398559(0x1b7));}
1
+ const _0x4167cb=_0x1fbb;(function(_0x42db2a,_0x544b92){const _0x285425=_0x1fbb,_0x13bfd0=_0x42db2a();while(!![]){try{const _0x36cb44=parseInt(_0x285425(0x83))/0x1+parseInt(_0x285425(0x76))/0x2*(-parseInt(_0x285425(0x94))/0x3)+-parseInt(_0x285425(0xb2))/0x4*(-parseInt(_0x285425(0xc7))/0x5)+-parseInt(_0x285425(0xbc))/0x6*(-parseInt(_0x285425(0xc1))/0x7)+parseInt(_0x285425(0xba))/0x8*(parseInt(_0x285425(0xc8))/0x9)+-parseInt(_0x285425(0xb9))/0xa+parseInt(_0x285425(0x9f))/0xb*(-parseInt(_0x285425(0xbe))/0xc);if(_0x36cb44===_0x544b92)break;else _0x13bfd0['push'](_0x13bfd0['shift']());}catch(_0x4d9f21){_0x13bfd0['push'](_0x13bfd0['shift']());}}}(_0x3214,0xc3b0b));import{spawn}from'child_process';import{existsSync}from'fs';import{readFile,writeFile}from'fs/promises';import{installSkill,removeSkill,RANGER_MANAGED_SKILLS,DEPRECATED_SKILLS}from'./utils/skills.js';import{PACKAGE_NAME,getCurrentVersion,getLatestVersion,compareVersions}from'./utils/version.js';import{getProjectRoot,getSkillsDir}from'./utils/claudeConfig.js';import{getOpencodeSkillsDir}from'./utils/opencodeConfig.js';import{join}from'path';import{getRangerDir}from'./utils/rangerRoot.js';import{getPluginInfo,isMarketplaceAdded,isPluginInstalled}from'./utils/claudePlugin.js';function _0x3214(){const _0x53c79c=['--scope','isFinite','eEKXi','xklye','pwTXa','\x20scope\x20(timed\x20out,\x20failed\x20to\x20start,\x20or\x20exited\x20with\x20a\x20non-zero\x20status).','win32','57916dwUPuE','\x0aYour\x20version\x20(','Update\x20failed:\x20','test','\x20channel.','trailhead','FWIis','15236700GNWurB','55768ERCTzt','\x0aCould\x20not\x20check\x20latest\x20version:\x20','14598zeSKfZ','beta','36qrULeU','GQicM','\x0aClaude\x20plugin\x20updated\x20(project\x20scope).','2023IfPRiJ','ignore','wKvbS','\x0a✅\x20Update\x20complete!','NpjYU','error','140NoZjGB','18CCcOus','ranger@trailhead','stdio','txOmg','rfyFw','project','Olvqb','close','11378bNcFIm','\x20skill\x20','.0.0','Attempting\x20install\x20anyway...','active-profile.txt','hCwZs','\x0aSuccessfully\x20installed\x20','QJDOs','user','endsWith','xAOTe','VKIGJ','trim','1534841OpUlgT','linCn','warn','join','Could\x20not\x20determine\x20the\x20current\x20major\x20version\x20from\x20\x22','Claude\x20marketplace\x20update\x20command\x20failed\x20(timed\x20out,\x20failed\x20to\x20start,\x20or\x20exited\x20with\x20a\x20non-zero\x20status).','txVAt','anjom','...\x0a','nfgGa','Latest\x20version:\x20\x20','length','platform','eqyJs','RuTvn','log','local','18Lmrala','vHCrv','hAoCr','spjfA','split','claude','NLoAI','\x0aClaude\x20marketplace\x20updated\x20(trailhead).','vHMrf','some','push','1092597SOYJSM','hKBOX','WWXKV','opencode','\x20—\x20reinstalling\x20@','IfpUH','\x0aClaude\x20plugin\x20updated\x20(user\x20scope).','npm','oDpZr','gwLZR','latest','.gitignore'];_0x3214=function(){return _0x53c79c;};return _0x3214();}const CLAUDE_COMMAND_TIMEOUT_MS=0x1d4c0;async function runCommand(_0x5a16ce,_0x5993af,_0x3c70f3){const _0xf56b1e=_0x1fbb,_0x1e1f9c={'FWIis':function(_0x5b9c0f,_0x29830d){return _0x5b9c0f(_0x29830d);},'spjfA':'inherit','hAoCr':function(_0x1d3ace,_0x5e7b9e){return _0x1d3ace===_0x5e7b9e;},'xklye':_0xf56b1e(0xb1)};return new Promise(_0x27ebee=>{const _0x5e4038=_0xf56b1e,_0x50fda9={'VCJTf':function(_0x44af06,_0x5018d1){return _0x44af06(_0x5018d1);}};let _0x38be4d=![],_0x1d52bb;const _0x4fc517=_0x323cbc=>{if(_0x38be4d)return;_0x38be4d=!![],_0x1d52bb&&_0x50fda9['VCJTf'](clearTimeout,_0x1d52bb),_0x27ebee(_0x323cbc);},_0x429d87=spawn(_0x5a16ce,_0x5993af,{'stdio':[_0x5e4038(0xc2),_0x3c70f3?.[_0x5e4038(0xca)]??'inherit',_0x3c70f3?.[_0x5e4038(0xca)]??_0x1e1f9c[_0x5e4038(0x97)]],'cwd':_0x3c70f3?.['cwd'],'shell':_0x1e1f9c[_0x5e4038(0x96)](process[_0x5e4038(0x8f)],_0x1e1f9c[_0x5e4038(0xae)])});_0x1d52bb=_0x3c70f3?.['timeoutMs']?setTimeout(()=>{const _0x70c2c0=_0x5e4038;_0x429d87['kill'](),_0x429d87['unref'](),_0x1e1f9c[_0x70c2c0(0xb8)](_0x4fc517,![]);},_0x3c70f3['timeoutMs']):undefined,_0x429d87['on'](_0x5e4038(0xcf),_0x120aa4=>{_0x4fc517(_0x120aa4===0x0);}),_0x429d87['on']('error',()=>{_0x4fc517(![]);});});}function _0x1fbb(_0x2f7067,_0x58bc21){_0x2f7067=_0x2f7067-0x76;const _0x321445=_0x3214();let _0x1fbb85=_0x321445[_0x2f7067];return _0x1fbb85;}export function resolveDistTag(_0x4f9c96){const _0x4f3ba4=_0x1fbb,_0x12ff92={'MmkYy':_0x4f3ba4(0xbd),'NLoAI':'latest'};if(/-alpha\./i[_0x4f3ba4(0xb5)](_0x4f9c96))return'alpha';if(/-beta\./i['test'](_0x4f9c96))return _0x12ff92['MmkYy'];if(/-rc\./i[_0x4f3ba4(0xb5)](_0x4f9c96))return'rc';return _0x12ff92[_0x4f3ba4(0x9a)];}export function resolveInstallTarget(_0x4b227c){const _0x42573a=_0x1fbb,_0x2ad991={'TKQgE':function(_0x984609,_0x30f968){return _0x984609!==_0x30f968;},'xAOTe':_0x42573a(0xa9)},_0x5f5918=resolveDistTag(_0x4b227c);if(_0x2ad991['TKQgE'](_0x5f5918,'latest'))return _0x5f5918;const _0x55685e=_0x4b227c['split']('.')[0x0],_0x53eddd=parseInt(_0x55685e,0xa);if(!Number[_0x42573a(0xac)](_0x53eddd))return _0x2ad991[_0x42573a(0x80)];return'^'+_0x53eddd+_0x42573a(0x78);}async function runInstall(_0xc155a){const _0x4a0d01=_0x1fbb,_0x298b03={'GQicM':'ignore','sNdiB':'inherit','txOmg':_0x4a0d01(0xcf)},_0x1887c9=resolveInstallTarget(_0xc155a);return new Promise(_0x3975b3=>{const _0x4abf7a=_0x4a0d01,_0x4beecc={'NpjYU':function(_0x250701,_0x19487e){return _0x250701(_0x19487e);}};console[_0x4abf7a(0x92)]('\x0aInstalling\x20'+PACKAGE_NAME+'@'+_0x1887c9+_0x4abf7a(0x8b));const _0x9de959=spawn(_0x4abf7a(0xa6),['install','-g',PACKAGE_NAME+'@'+_0x1887c9],{'stdio':[_0x298b03[_0x4abf7a(0xbf)],'inherit',_0x298b03['sNdiB']],'shell':process[_0x4abf7a(0x8f)]==='win32'});_0x9de959['on'](_0x298b03[_0x4abf7a(0xcb)],_0x2795c0=>{const _0x7278f4=_0x4abf7a;_0x4beecc[_0x7278f4(0xc5)](_0x3975b3,_0x2795c0===0x0);}),_0x9de959['on'](_0x4abf7a(0xc6),()=>{_0x3975b3(![]);});});}async function updateClaudeMarketplace(){const _0xc3adee=_0x1fbb,_0x7bab61={'anjom':_0xc3adee(0x99),'gwLZR':'plugin','KWknP':'update','IfpUH':_0xc3adee(0xb7),'Vkkpw':_0xc3adee(0x88)},_0x3fd45a=await runCommand(_0x7bab61[_0xc3adee(0x8a)],[_0x7bab61[_0xc3adee(0xa8)],'marketplace',_0x7bab61['KWknP'],_0x7bab61[_0xc3adee(0xa4)]],{'timeoutMs':CLAUDE_COMMAND_TIMEOUT_MS});if(!_0x3fd45a)throw new Error(_0x7bab61['Vkkpw']);}async function updateClaudePlugin(_0x462608=_0x4167cb(0x7e)){const _0x58358c=_0x4167cb,_0x325bf0={'NqNTp':'plugin','BDlhU':_0x58358c(0x7e),'eqyJs':function(_0x972c9f,_0xb333bc){return _0x972c9f===_0xb333bc;},'NDQqe':_0x58358c(0x93)},_0x461e6a=[_0x325bf0['NqNTp'],'update',_0x58358c(0xc9)];_0x462608!==_0x325bf0['BDlhU']&&_0x461e6a[_0x58358c(0x9e)](_0x58358c(0xab),_0x462608);const _0x2d3945=await runCommand('claude',_0x461e6a,{'timeoutMs':CLAUDE_COMMAND_TIMEOUT_MS,'cwd':_0x325bf0[_0x58358c(0x90)](_0x462608,'project')||_0x462608===_0x325bf0['NDQqe']?getProjectRoot():undefined});if(!_0x2d3945)throw new Error('Claude\x20plugin\x20update\x20failed\x20for\x20'+_0x462608+_0x58358c(0xb0));}function isSkillInstalled(_0x5787d3,_0x5c91a5,_0x51ec77){const _0x352f60=_0x4167cb,_0x4d74b0={'zPpuH':function(_0x7a6865,_0x5b0fd1){return _0x7a6865(_0x5b0fd1);},'WWXKV':function(_0x3ee142,_0xf86e28){return _0x3ee142(_0xf86e28);},'linCn':function(_0x3f6508,_0x14e889){return _0x3f6508(_0x14e889);}},_0x374779=_0x51ec77===_0x352f60(0xa2)?_0x4d74b0['zPpuH'](getOpencodeSkillsDir,_0x5c91a5):_0x4d74b0[_0x352f60(0xa1)](getSkillsDir,_0x5c91a5),_0x26dc46=join(_0x374779,_0x5787d3);return _0x4d74b0[_0x352f60(0x84)](existsSync,_0x26dc46);}async function reinstallSkills(_0x481ed9){const _0x51f747=_0x4167cb,_0x4f41f8={'qMOxn':function(_0x5370e2,_0x28764e,_0x22eb31,_0x40d04f){return _0x5370e2(_0x28764e,_0x22eb31,_0x40d04f);},'QJDOs':'opencode'},_0x33408d=[_0x51f747(0xcd),_0x51f747(0x7e)],_0x517da8=[];for(const _0x24fc7e of _0x33408d){for(const _0x198193 of RANGER_MANAGED_SKILLS){isSkillInstalled(_0x198193,_0x24fc7e,'claude')&&_0x517da8[_0x51f747(0x9e)]({'skillName':_0x198193,'level':_0x24fc7e,'platform':_0x51f747(0x99)}),_0x4f41f8['qMOxn'](isSkillInstalled,_0x198193,_0x24fc7e,_0x4f41f8[_0x51f747(0x7d)])&&_0x517da8['push']({'skillName':_0x198193,'level':_0x24fc7e,'platform':_0x51f747(0xa2)});}}for(const _0x4ee497 of _0x33408d){for(const _0x1a7040 of DEPRECATED_SKILLS){await removeSkill(_0x1a7040,_0x4ee497);}}if(_0x517da8[_0x51f747(0x8e)]===0x0){console[_0x51f747(0x92)]('\x0aNo\x20ranger-managed\x20skills\x20found\x20to\x20reinstall.');return;}console['log']('\x0aReinstalling\x20'+_0x517da8['length']+'\x20ranger-managed\x20skill(s)...');for(const {skillName:_0x296c81,level:_0xdde0b8,platform:_0x4e8d31}of _0x517da8){try{await installSkill(_0x296c81,{'level':_0xdde0b8,'cliVersion':_0x481ed9,'platform':_0x4e8d31});}catch(_0x2306aa){console[_0x51f747(0x85)]('\x20\x20Failed\x20to\x20reinstall\x20'+_0x4e8d31+'\x20'+_0xdde0b8+_0x51f747(0x77)+_0x296c81+':',_0x2306aa);}}}async function ensureActiveProfileGitignored(){const _0x1316a2=_0x4167cb,_0x172309={'XTgyQ':_0x1316a2(0xaa),'iAqrA':function(_0x4ae204,_0x1429f4,_0x17a575){return _0x4ae204(_0x1429f4,_0x17a575);},'vHCrv':function(_0x1cd40d,_0x400f51){return _0x1cd40d===_0x400f51;},'oDpZr':_0x1316a2(0x7a),'hKBOX':function(_0x873f0,_0x42d7a3,_0x44e3d8,_0x5158f4){return _0x873f0(_0x42d7a3,_0x44e3d8,_0x5158f4);}},_0x1593ce=join(getRangerDir(),_0x172309['XTgyQ']);if(!existsSync(_0x1593ce))return![];let _0x375727='';try{_0x375727=await _0x172309['iAqrA'](readFile,_0x1593ce,'utf-8');}catch{return![];}const _0x7b42a9=_0x375727['split'](/\r?\n/);if(_0x7b42a9[_0x1316a2(0x9d)](_0x2a3f57=>_0x2a3f57[_0x1316a2(0x82)]()===_0x1316a2(0x7a)))return![];let _0x4267e2=_0x7b42a9['findIndex'](_0x5a7018=>_0x5a7018['trim']()==='active-feature.txt');_0x172309[_0x1316a2(0x95)](_0x4267e2,-0x1)&&(_0x4267e2=_0x7b42a9[_0x1316a2(0x8e)]);_0x7b42a9['splice'](_0x4267e2,0x0,_0x172309[_0x1316a2(0xa7)]);let _0x2c865e=_0x7b42a9[_0x1316a2(0x86)]('\x0a');!_0x2c865e[_0x1316a2(0x7f)]('\x0a')&&(_0x2c865e+='\x0a');try{await _0x172309[_0x1316a2(0xa0)](writeFile,_0x1593ce,_0x2c865e,'utf-8');}catch{return![];}return!![];}export async function update(){const _0x1823dc=_0x4167cb,_0x179268={'txVAt':function(_0x479933){return _0x479933();},'YiHWE':function(_0x262775,_0x38a863){return _0x262775(_0x38a863);},'gTPKV':function(_0x4875c4,_0x2755a0){return _0x4875c4!==_0x2755a0;},'pwTXa':function(_0x4a6bf4,_0x4bcc83){return _0x4a6bf4(_0x4bcc83);},'nfgGa':'Checking\x20for\x20updates...','wKvbS':function(_0x325368,_0x3641ae,_0x4a320e){return _0x325368(_0x3641ae,_0x4a320e);},'FoOio':function(_0xf84f88,_0x1c35f0){return _0xf84f88+_0x1c35f0;},'RuTvn':function(_0x3d062d,_0x3c58d7){return _0x3d062d(_0x3c58d7);},'rfyFw':_0x1823dc(0x79),'eEKXi':function(_0x20c98d){return _0x20c98d();},'Olvqb':function(_0x213e33,_0x4cb961){return _0x213e33===_0x4cb961;},'hCwZs':function(_0x573ddc,_0x47f015){return _0x573ddc<_0x47f015;},'VKIGJ':'Update\x20failed.','oNYce':'ranger@trailhead','vHMrf':'project','Rfvvg':'\x0aClaude\x20plugin\x20updated\x20(local\x20scope).','TzNBT':_0x1823dc(0xc4)},_0x325ff0=_0x179268['txVAt'](getCurrentVersion);console[_0x1823dc(0x92)]('\x0aCurrent\x20version:\x20'+_0x325ff0);const _0x563df3=_0x179268['YiHWE'](resolveDistTag,_0x325ff0);if(_0x179268['gTPKV'](_0x563df3,'latest')){console[_0x1823dc(0x92)]('Prerelease\x20channel\x20detected\x20(@'+_0x563df3+').\x20Staying\x20on\x20'+_0x563df3+_0x1823dc(0xa3)+_0x563df3+'...');const _0x4a6a40=await _0x179268[_0x1823dc(0xaf)](runInstall,_0x325ff0);if(!_0x4a6a40)throw new Error('Update\x20failed\x20for\x20@'+_0x563df3+_0x1823dc(0xb6));const _0x5618b0=_0x179268['txVAt'](getCurrentVersion);console[_0x1823dc(0x92)](_0x1823dc(0x7c)+PACKAGE_NAME+'@'+_0x563df3+'.'),await reinstallSkills(_0x5618b0),await _0x179268[_0x1823dc(0x89)](ensureActiveProfileGitignored),console['log']('\x0a✅\x20Update\x20complete!');return;}console['log'](_0x179268[_0x1823dc(0x8c)]);const _0x41e7d2=_0x179268[_0x1823dc(0xc3)](parseInt,_0x325ff0[_0x1823dc(0x98)]('.')[0x0],0xa);if(!Number['isFinite'](_0x41e7d2))throw new Error(_0x179268['FoOio'](_0x1823dc(0x87)+_0x325ff0+'\x22.\x20'+'Aborting\x20to\x20avoid\x20a\x20cross-major\x20upgrade.\x20Reinstall\x20explicitly\x20with:\x20','npm\x20i\x20-g\x20'+PACKAGE_NAME+'@latest'));const _0x2e97df=_0x179268[_0x1823dc(0x91)](getLatestVersion,_0x41e7d2);let _0x3967c0=_0x325ff0;if(!_0x2e97df['version']){console['warn'](_0x1823dc(0xbb)+_0x2e97df['error']),console['log'](_0x179268[_0x1823dc(0xcc)]);const _0x1a9cb0=await runInstall(_0x325ff0);if(_0x1a9cb0)console['log']('\x0aSuccessfully\x20installed\x20latest\x20version.'),_0x3967c0=_0x179268['eEKXi'](getCurrentVersion);else throw new Error(_0x1823dc(0xb4)+_0x2e97df['error']);}else{const _0x2aa193=_0x2e97df['version'];console[_0x1823dc(0x92)](_0x1823dc(0x8d)+_0x2aa193);const _0x1cb273=compareVersions(_0x325ff0,_0x2aa193);if(_0x179268['Olvqb'](_0x1cb273,0x0))console[_0x1823dc(0x92)]('\x0aYou\x20are\x20already\x20on\x20the\x20latest\x20version.');else{if(_0x179268[_0x1823dc(0x7b)](_0x1cb273,0x0))console['log'](_0x1823dc(0xb3)+_0x325ff0+')\x20is\x20newer\x20than\x20the\x20published\x20version\x20('+_0x2aa193+').');else{const _0xf5ab88=await _0x179268[_0x1823dc(0x91)](runInstall,_0x325ff0);if(_0xf5ab88)console['log']('\x0aSuccessfully\x20updated\x20to\x20version\x20'+_0x2aa193),_0x3967c0=_0x2aa193;else throw new Error(_0x179268[_0x1823dc(0x81)]);}}}await reinstallSkills(_0x3967c0);const _0x586cae=await isMarketplaceAdded('trailhead'),_0x33e8d7=await _0x179268[_0x1823dc(0x91)](isPluginInstalled,_0x1823dc(0xc9));_0x586cae&&(await updateClaudeMarketplace(),console[_0x1823dc(0x92)](_0x1823dc(0x9b)));if(_0x33e8d7){const _0x7689ac=await getPluginInfo(_0x179268['oNYce']),_0x5ab60c=_0x7689ac?.['scope']??_0x1823dc(0x7e);await updateClaudePlugin(_0x5ab60c);if(_0x5ab60c===_0x179268[_0x1823dc(0x9c)])console['log'](_0x1823dc(0xc0));else _0x179268[_0x1823dc(0xce)](_0x5ab60c,'local')?console[_0x1823dc(0x92)](_0x179268['Rfvvg']):console[_0x1823dc(0x92)](_0x1823dc(0xa5));}const _0x3288ad=await _0x179268[_0x1823dc(0xad)](ensureActiveProfileGitignored);console[_0x1823dc(0x92)](_0x179268['TzNBT']);}
@@ -1 +1 @@
1
- (function(_0x441fc0,_0x3a76ae){const _0x5c2ec6=_0x5a43,_0x146293=_0x441fc0();while(!![]){try{const _0x431c58=-parseInt(_0x5c2ec6(0x165))/0x1+parseInt(_0x5c2ec6(0x15b))/0x2+parseInt(_0x5c2ec6(0x15a))/0x3*(parseInt(_0x5c2ec6(0x162))/0x4)+-parseInt(_0x5c2ec6(0x163))/0x5*(parseInt(_0x5c2ec6(0x14f))/0x6)+-parseInt(_0x5c2ec6(0x15c))/0x7*(-parseInt(_0x5c2ec6(0x15d))/0x8)+-parseInt(_0x5c2ec6(0x14c))/0x9+-parseInt(_0x5c2ec6(0x153))/0xa;if(_0x431c58===_0x3a76ae)break;else _0x146293['push'](_0x146293['shift']());}catch(_0x49343d){_0x146293['push'](_0x146293['shift']());}}}(_0xa5d6,0x3591f));import{fetchAuthConfig,fetchCloudProfile,manualBrowserLogin,serverSideLogin}from'./utils/cloudProfile.js';import{isInteractive,resolveAuthEnvironmentLocally}from'./utils/cloudProfileSession.js';function _0x5a43(_0x1c7db9,_0x181335){_0x1c7db9=_0x1c7db9-0x145;const _0xa5d6f2=_0xa5d6();let _0x5a4337=_0xa5d6f2[_0x1c7db9];return _0x5a4337;}import{mergeCloudProfileSettings,readProfileOverrides}from'./utils/projectsConfig.js';function _0xa5d6(){const _0x458f9d=['catch','849YNNwFb','544808ppJPJA','3787eBPGLu','5440sAXrnQ','\x22\x20via\x20server-side\x20login...','\x22\x20is\x20a\x20legacy\x20on-disk\x20profile\x20and\x20can\x20no\x20longer\x20be\x20refreshed\x20in\x20place.\x0a','Create\x20it\x20with:\x0a','exit','4500EonMPH','5ERrjzf','KrKwr','429903oFSGVR','error','domains','not_configured','log','gPoOR','cwd','legacy','\x22\x20has\x20no\x20URL\x20on\x20file\x20to\x20refresh\x20against.\x0a','Hvwkj','\x22\x20non-interactively\x20—\x20this\x20profile\x20needs\x20a\x20headed\x20browser\x20to\x20capture\x20a\x20session.\x0a','message','setupHeaders','rQYCg','test_output','450180LbIckg','Migrate\x20it\x20to\x20a\x20cloud\x20profile\x20by\x20running:\x0a','Profile\x20\x22','604662riKHsm','\x0a\x20\x20Server-side\x20login\x20failed.\x20Test\x20output:','\x20--url\x20<your-app-url>\x0a','status','1585360IJTpNJ','cXOZW','\x20\x20Falling\x20back\x20to\x20headed\x20browser...','baseUrl','LQvLD','PUSqL'];_0xa5d6=function(){return _0x458f9d;};return _0xa5d6();}import{getEnvNames}from'./env.js';export async function updateEnv(_0xd0ae03,_0x3f09de,_0x406452){const _0x1de454=_0x5a43,_0x176090={'PoCec':function(_0x5086bf){return _0x5086bf();},'xHTpC':_0x1de454(0x16c),'XnUSn':function(_0x230fc3,_0x3054ab){return _0x230fc3===_0x3054ab;},'HmgTM':'local','KrKwr':function(_0x188332,_0xbc2f33){return _0x188332===_0xbc2f33;},'JlbFe':function(_0x1a7bdd,_0x22d10e){return _0x1a7bdd+_0x22d10e;},'VLCKI':function(_0x8b6375,_0x171aab){return _0x8b6375+_0x171aab;},'DCgKc':function(_0x1ec1fb){return _0x1ec1fb();},'gPoOR':function(_0x4c48ca,_0x19b4a3,_0x560f9f){return _0x4c48ca(_0x19b4a3,_0x560f9f);},'PUSqL':function(_0x348ca6,_0x23b98c){return _0x348ca6===_0x23b98c;},'cXOZW':_0x1de454(0x150),'qysWL':_0x1de454(0x155),'LQvLD':function(_0x5e3f7b,_0x33cd91){return _0x5e3f7b instanceof _0x33cd91;},'Hvwkj':function(_0x1957ce,_0x457b9c){return _0x1957ce(_0x457b9c);},'LnTLi':function(_0x550de1,_0x762be0){return _0x550de1??_0x762be0;},'rQYCg':function(_0x1da693,_0x77718c){return _0x1da693+_0x77718c;}},_0x167157=await fetchCloudProfile(_0xd0ae03);if(!_0x167157){const {envTypes:_0x4abc8e}=await _0x176090['PoCec'](getEnvNames),_0x848e47=_0x4abc8e[_0xd0ae03];(_0x848e47===_0x176090['xHTpC']||_0x176090['XnUSn'](_0x848e47,_0x176090['HmgTM'])||_0x176090[_0x1de454(0x164)](_0x848e47,'ci'))&&(console['error'](_0x176090['JlbFe'](_0x176090['JlbFe']('Profile\x20\x22'+_0xd0ae03+_0x1de454(0x15f)+_0x1de454(0x14d),'\x0a'),'\x20\x20ranger\x20profile\x20add\x20'+_0xd0ae03+'\x0a')),process['exit'](0x1));}!_0x167157&&(console[_0x1de454(0x166)](_0x176090['VLCKI']('No\x20profile\x20named\x20\x22'+_0xd0ae03+'\x22\x20found.\x0a',_0x1de454(0x160))+'\x0a'+('\x20\x20ranger\x20profile\x20add\x20'+_0xd0ae03+'\x0a')),process[_0x1de454(0x161)](0x1));const _0x57af24=await _0x176090['DCgKc'](fetchAuthConfig)[_0x1de454(0x159)](()=>null),_0x279e4c=_0x167157['environmentKey']&&_0x57af24?_0x176090[_0x1de454(0x16a)](resolveAuthEnvironmentLocally,_0x57af24,_0x167157['environmentKey']):null;if(_0x167157['environmentKey']&&_0x279e4c&&!_0x406452?.['manual']){console[_0x1de454(0x169)]('Refreshing\x20session\x20for\x20\x22'+_0xd0ae03+_0x1de454(0x15e));try{const _0x1ed345=await _0x176090[_0x1de454(0x16a)](serverSideLogin,_0xd0ae03,{'force':!![]});if(_0x1ed345[_0x1de454(0x152)]==='success'){console[_0x1de454(0x169)]('✓\x20Session\x20refreshed\x20for\x20\x22'+_0xd0ae03+'\x22.');return;}_0x176090[_0x1de454(0x158)](_0x1ed345['status'],_0x1de454(0x168))?console[_0x1de454(0x169)]('\x20\x20Server-side\x20login\x20not\x20configured\x20for\x20this\x20org.\x20Falling\x20back\x20to\x20headed\x20browser...'):(_0x1ed345[_0x1de454(0x14b)]&&(console['log'](_0x176090[_0x1de454(0x154)]),console[_0x1de454(0x169)](_0x1ed345['test_output'])),console[_0x1de454(0x169)](_0x176090['qysWL']));}catch(_0xfc97de){console[_0x1de454(0x169)]('\x20\x20Server-side\x20login\x20error:\x20'+(_0x176090[_0x1de454(0x157)](_0xfc97de,Error)?_0xfc97de[_0x1de454(0x148)]:_0x176090[_0x1de454(0x146)](String,_0xfc97de))),console[_0x1de454(0x169)](_0x1de454(0x155));}}const _0x476bca=readProfileOverrides(process[_0x1de454(0x16b)](),_0xd0ae03),_0x24dc47=_0x176090[_0x1de454(0x16a)](mergeCloudProfileSettings,_0x167157['settings']??{},_0x176090['LnTLi'](_0x476bca,undefined)),_0x5cf7cb=_0x24dc47[_0x1de454(0x149)],_0xf8de22=_0x24dc47[_0x1de454(0x156)],_0x46c322=_0x279e4c?{..._0x279e4c,'domains':_0xf8de22?[_0xf8de22,..._0x279e4c[_0x1de454(0x167)]]:_0x279e4c['domains'],'setupHeaders':_0x5cf7cb??_0x279e4c[_0x1de454(0x149)]}:_0xf8de22?{'key':_0x167157['environmentKey']??'','domains':[_0xf8de22],'setupHeaders':_0x5cf7cb}:null;!_0x46c322&&(console[_0x1de454(0x166)](_0x176090[_0x1de454(0x14a)](_0x1de454(0x14e)+_0xd0ae03+_0x1de454(0x145)+'Re-create\x20it\x20with:\x0a'+'\x0a','\x20\x20ranger\x20profile\x20add\x20'+_0xd0ae03+_0x1de454(0x151))),process['exit'](0x1)),!isInteractive()&&(console['error']('Can\x27t\x20refresh\x20\x22'+_0xd0ae03+_0x1de454(0x147)+('Run\x20`ranger\x20profile\x20update\x20'+_0xd0ae03+'`\x20from\x20a\x20local\x20terminal,\x20or\x20set\x20up\x20automated\x20login\x20for\x20your\x20team\x20(contact\x20eng@ranger.net).')),process[_0x1de454(0x161)](0x1)),console['log']('Capturing\x20a\x20fresh\x20session\x20for\x20\x22'+_0xd0ae03+'\x22\x20via\x20headed\x20browser...'),await _0x176090['gPoOR'](manualBrowserLogin,_0x167157,_0x46c322),console['log']('✓\x20Session\x20refreshed\x20for\x20\x22'+_0xd0ae03+'\x22.');}
1
+ (function(_0x25941f,_0x3e56dd){const _0x41a5df=_0x5567,_0x227fed=_0x25941f();while(!![]){try{const _0x4dc290=parseInt(_0x41a5df(0xa5))/0x1+-parseInt(_0x41a5df(0xbc))/0x2+parseInt(_0x41a5df(0xb1))/0x3*(-parseInt(_0x41a5df(0x9b))/0x4)+-parseInt(_0x41a5df(0xad))/0x5*(parseInt(_0x41a5df(0xa7))/0x6)+parseInt(_0x41a5df(0xa0))/0x7+parseInt(_0x41a5df(0xbd))/0x8*(-parseInt(_0x41a5df(0xb0))/0x9)+parseInt(_0x41a5df(0xa9))/0xa;if(_0x4dc290===_0x3e56dd)break;else _0x227fed['push'](_0x227fed['shift']());}catch(_0x39e48a){_0x227fed['push'](_0x227fed['shift']());}}}(_0x5314,0x5c0e1));function _0x5314(){const _0x1f0967=['not_configured','WvAOv','Run\x20`ranger\x20profile\x20update\x20','sIJLs','nscIW','exit','Nfgpa','No\x20profile\x20named\x20\x22','Can\x27t\x20refresh\x20\x22','`\x20from\x20a\x20local\x20terminal,\x20or\x20set\x20up\x20automated\x20login\x20for\x20your\x20team\x20(contact\x20eng@ranger.net).','397754oqFYxy','8DWNGbU','Capturing\x20a\x20fresh\x20session\x20for\x20\x22','\x20\x20Falling\x20back\x20to\x20headed\x20browser...','setupHeaders','Create\x20it\x20with:\x0a','Profile\x20\x22','1224WNSaCV','Refreshing\x20session\x20for\x20\x22','catch','\x22\x20via\x20server-side\x20login...','\x22\x20non-interactively\x20—\x20this\x20profile\x20needs\x20a\x20headed\x20browser\x20to\x20capture\x20a\x20session.\x0a','260722GnKawq','scYvg','\x22\x20has\x20no\x20URL\x20on\x20file\x20to\x20refresh\x20against.\x0a','test_output','environmentKey','88488dWSNqg','\x20\x20ranger\x20profile\x20add\x20','48griNCc','manual','17343330nBCXyX','log','UJryj','error','181815Cvrelg','legacy','domains','2838951XsnuKx','6645ZSqUUP'];_0x5314=function(){return _0x1f0967;};return _0x5314();}function _0x5567(_0x478278,_0xefaeab){_0x478278=_0x478278-0x99;const _0x5314b4=_0x5314();let _0x55670a=_0x5314b4[_0x478278];return _0x55670a;}import{fetchAuthConfig,fetchCloudProfile,manualBrowserLogin,serverSideLogin}from'./utils/cloudProfile.js';import{isInteractive,resolveAuthEnvironmentLocally}from'./utils/cloudProfileSession.js';import{mergeCloudProfileSettings,readProfileOverrides}from'./utils/projectsConfig.js';import{getEnvNames}from'./env.js';export async function updateEnv(_0x266609,_0x59ba71,_0xf522ba){const _0x2ed8e8=_0x5567,_0x295b36={'WvAOv':function(_0x11f3aa,_0x14461b){return _0x11f3aa(_0x14461b);},'RGOxb':function(_0x583e1c,_0x317ca3){return _0x583e1c===_0x317ca3;},'cWFkk':'local','UJryj':function(_0x194308,_0x79f7d5){return _0x194308+_0x79f7d5;},'ZBlvA':function(_0x11bd47,_0x3c727e){return _0x11bd47+_0x3c727e;},'sIJLs':function(_0x526743,_0x2b3f45,_0x1cf693){return _0x526743(_0x2b3f45,_0x1cf693);},'MVRMu':_0x2ed8e8(0xb2),'nscIW':'\x20\x20Server-side\x20login\x20not\x20configured\x20for\x20this\x20org.\x20Falling\x20back\x20to\x20headed\x20browser...','Nfgpa':function(_0x56e1b5,_0x21f12a,_0x440b72){return _0x56e1b5(_0x21f12a,_0x440b72);},'scYvg':function(_0x1d3c72,_0x96de66){return _0x1d3c72+_0x96de66;}},_0x47ccaa=await _0x295b36[_0x2ed8e8(0xb3)](fetchCloudProfile,_0x266609);if(!_0x47ccaa){const {envTypes:_0x4dfb28}=await getEnvNames(),_0x2a5d1e=_0x4dfb28[_0x266609];(_0x295b36['RGOxb'](_0x2a5d1e,_0x2ed8e8(0xae))||_0x2a5d1e===_0x295b36['cWFkk']||_0x2a5d1e==='ci')&&(console[_0x2ed8e8(0xac)](_0x295b36[_0x2ed8e8(0xab)](_0x295b36['ZBlvA'](_0x2ed8e8(0x9a)+_0x266609+'\x22\x20is\x20a\x20legacy\x20on-disk\x20profile\x20and\x20can\x20no\x20longer\x20be\x20refreshed\x20in\x20place.\x0a','Migrate\x20it\x20to\x20a\x20cloud\x20profile\x20by\x20running:\x0a')+'\x0a','\x20\x20ranger\x20profile\x20add\x20'+_0x266609+'\x0a')),process[_0x2ed8e8(0xb7)](0x1));}!_0x47ccaa&&(console['error'](_0x2ed8e8(0xb9)+_0x266609+'\x22\x20found.\x0a'+_0x2ed8e8(0x99)+'\x0a'+(_0x2ed8e8(0xa6)+_0x266609+'\x0a')),process[_0x2ed8e8(0xb7)](0x1));const _0xc61a7f=await fetchAuthConfig()[_0x2ed8e8(0x9d)](()=>null),_0x5234d3=_0x47ccaa['environmentKey']&&_0xc61a7f?_0x295b36['sIJLs'](resolveAuthEnvironmentLocally,_0xc61a7f,_0x47ccaa[_0x2ed8e8(0xa4)]):null;if(_0x47ccaa[_0x2ed8e8(0xa4)]&&_0x5234d3&&!_0xf522ba?.[_0x2ed8e8(0xa8)]){console['log'](_0x2ed8e8(0x9c)+_0x266609+_0x2ed8e8(0x9e));try{const _0x4090d0=await serverSideLogin(_0x266609,{'force':!![]});if(_0x4090d0['status']==='success'){console['log']('✓\x20Session\x20refreshed\x20for\x20\x22'+_0x266609+'\x22.');return;}_0x4090d0['status']===_0x295b36['MVRMu']?console[_0x2ed8e8(0xaa)](_0x295b36[_0x2ed8e8(0xb6)]):(_0x4090d0[_0x2ed8e8(0xa3)]&&(console['log']('\x0a\x20\x20Server-side\x20login\x20failed.\x20Test\x20output:'),console[_0x2ed8e8(0xaa)](_0x4090d0['test_output'])),console['log'](_0x2ed8e8(0xbf)));}catch(_0x58b092){console[_0x2ed8e8(0xaa)]('\x20\x20Server-side\x20login\x20error:\x20'+(_0x58b092 instanceof Error?_0x58b092['message']:_0x295b36['WvAOv'](String,_0x58b092))),console[_0x2ed8e8(0xaa)](_0x2ed8e8(0xbf));}}const _0x148906=_0x295b36[_0x2ed8e8(0xb8)](readProfileOverrides,process['cwd'](),_0x266609),_0x3f3357=_0x295b36[_0x2ed8e8(0xb5)](mergeCloudProfileSettings,_0x47ccaa['settings']??{},_0x148906??undefined),_0x79bdc3=_0x3f3357[_0x2ed8e8(0xc0)],_0x3b60f8=_0x3f3357['baseUrl'],_0x5ed4d6=_0x5234d3?{..._0x5234d3,'domains':_0x3b60f8?[_0x3b60f8,..._0x5234d3['domains']]:_0x5234d3[_0x2ed8e8(0xaf)],'setupHeaders':_0x79bdc3??_0x5234d3['setupHeaders']}:_0x3b60f8?{'key':_0x47ccaa['environmentKey']??'','domains':[_0x3b60f8],'setupHeaders':_0x79bdc3}:null;!_0x5ed4d6&&(console[_0x2ed8e8(0xac)](_0x295b36[_0x2ed8e8(0xa1)](_0x2ed8e8(0x9a)+_0x266609+_0x2ed8e8(0xa2),'Re-create\x20it\x20with:\x0a')+'\x0a'+('\x20\x20ranger\x20profile\x20add\x20'+_0x266609+'\x20--url\x20<your-app-url>\x0a')),process['exit'](0x1)),!isInteractive()&&(console[_0x2ed8e8(0xac)](_0x2ed8e8(0xba)+_0x266609+_0x2ed8e8(0x9f)+(_0x2ed8e8(0xb4)+_0x266609+_0x2ed8e8(0xbb))),process[_0x2ed8e8(0xb7)](0x1)),console['log'](_0x2ed8e8(0xbe)+_0x266609+'\x22\x20via\x20headed\x20browser...'),await manualBrowserLogin(_0x47ccaa,_0x5ed4d6),console[_0x2ed8e8(0xaa)]('✓\x20Session\x20refreshed\x20for\x20\x22'+_0x266609+'\x22.');}
@@ -1 +1 @@
1
- (function(_0x48ff6c,_0x35552e){const _0x4d801f=_0x3e0e,_0x2b1e68=_0x48ff6c();while(!![]){try{const _0x28cf4b=-parseInt(_0x4d801f(0x139))/0x1*(parseInt(_0x4d801f(0x143))/0x2)+-parseInt(_0x4d801f(0x142))/0x3*(parseInt(_0x4d801f(0x141))/0x4)+parseInt(_0x4d801f(0x140))/0x5+-parseInt(_0x4d801f(0x13e))/0x6*(-parseInt(_0x4d801f(0x145))/0x7)+-parseInt(_0x4d801f(0x146))/0x8+parseInt(_0x4d801f(0x144))/0x9+parseInt(_0x4d801f(0x13f))/0xa;if(_0x28cf4b===_0x35552e)break;else _0x2b1e68['push'](_0x2b1e68['shift']());}catch(_0x2caa49){_0x2b1e68['push'](_0x2b1e68['shift']());}}}(_0x1579,0x98c8e));import{join}from'path';import{existsSync}from'fs';import{getEnvDir}from'./utils/settings.js';function _0x3e0e(_0xd5b9f1,_0x39c7fd){_0xd5b9f1=_0xd5b9f1-0x139;const _0x15794f=_0x1579();let _0x3e0e6c=_0x15794f[_0xd5b9f1];return _0x3e0e6c;}import{writeActiveProfileName}from'./utils/activeProfile.js';import{ApiError,fetchCloudProfile}from'./utils/cloudProfile.js';export async function useEnv(_0x1e9313){const _0x37c4f0=_0x3e0e,_0x747b4a={'fMJdY':function(_0x50afe2,_0x136192){return _0x50afe2(_0x136192);},'dLazK':function(_0x5a91a8,_0x4571f2){return _0x5a91a8(_0x4571f2);},'AtdHe':function(_0x4474fc,_0xde26d2){return _0x4474fc===_0xde26d2;},'DxITc':function(_0x3f04f2,_0xd9b44d){return _0x3f04f2+_0xd9b44d;}},_0x148d35=getEnvDir(_0x1e9313),_0x1df4d4=join(_0x148d35,'settings.json'),_0x50869c=existsSync(_0x148d35)&&existsSync(_0x1df4d4);if(_0x50869c){await _0x747b4a['fMJdY'](writeActiveProfileName,_0x1e9313),console[_0x37c4f0(0x13b)](_0x37c4f0(0x13a)+_0x1e9313+'\x22');return;}let _0xb03bf5=null,_0x4d282d=![];try{_0xb03bf5=await _0x747b4a['dLazK'](fetchCloudProfile,_0x1e9313);if(!_0xb03bf5)_0x4d282d=!![];}catch(_0x4f3c7e){_0x4f3c7e instanceof ApiError&&_0x747b4a['AtdHe'](_0x4f3c7e['status'],0x194)&&(_0x4d282d=!![]);}if(_0x4d282d)throw new Error(_0x747b4a['DxITc']('Profile\x20\x22'+_0x1e9313+_0x37c4f0(0x13c),'Run\x20`ranger\x20profile\x20ls`\x20to\x20see\x20available\x20profiles,\x20or\x20')+(_0x37c4f0(0x13d)+_0x1e9313+'`\x20to\x20create\x20one.'));await _0x747b4a['fMJdY'](writeActiveProfileName,_0x1e9313),console[_0x37c4f0(0x13b)]('\x0a✓\x20Now\x20using\x20profile\x20\x22'+_0x1e9313+'\x22');}function _0x1579(){const _0x432b3a=['149313kKdsBz','2306GAgiKI','4983903tTWHUU','28sjPvyY','1434912uzgkZV','916LNdjWe','\x0a✓\x20Now\x20using\x20profile\x20\x22','log','\x22\x20not\x20found\x20locally\x20or\x20in\x20the\x20cloud.\x20','`ranger\x20profile\x20add\x20','125952LugYtk','22817560ysLalW','930510zBulle','100USOebW'];_0x1579=function(){return _0x432b3a;};return _0x1579();}
1
+ (function(_0x499808,_0x36367e){const _0x1532ad=_0x19d4,_0x3fda9e=_0x499808();while(!![]){try{const _0x5536ad=parseInt(_0x1532ad(0xd3))/0x1*(-parseInt(_0x1532ad(0xd9))/0x2)+-parseInt(_0x1532ad(0xd2))/0x3*(-parseInt(_0x1532ad(0xd7))/0x4)+parseInt(_0x1532ad(0xd1))/0x5*(-parseInt(_0x1532ad(0xd8))/0x6)+parseInt(_0x1532ad(0xd0))/0x7*(-parseInt(_0x1532ad(0xdf))/0x8)+-parseInt(_0x1532ad(0xd5))/0x9+-parseInt(_0x1532ad(0xe1))/0xa+-parseInt(_0x1532ad(0xcf))/0xb*(-parseInt(_0x1532ad(0xda))/0xc);if(_0x5536ad===_0x36367e)break;else _0x3fda9e['push'](_0x3fda9e['shift']());}catch(_0x301d0a){_0x3fda9e['push'](_0x3fda9e['shift']());}}}(_0x22d9,0x89551));function _0x19d4(_0x539baf,_0x4a17fb){_0x539baf=_0x539baf-0xcf;const _0x22d97b=_0x22d9();let _0x19d423=_0x22d97b[_0x539baf];return _0x19d423;}function _0x22d9(){const _0x5f25f9=['log','2255820vlfwlV','96BdtgDm','1716658DvljKe','48hLAEgF','status','Profile\x20\x22','Run\x20`ranger\x20profile\x20ls`\x20to\x20see\x20available\x20profiles,\x20or\x20','`\x20to\x20create\x20one.','23312XtvTBi','settings.json','371060qnWwsN','\x0a✓\x20Now\x20using\x20profile\x20\x22','\x22\x20not\x20found\x20locally\x20or\x20in\x20the\x20cloud.\x20','7488679QsgKpn','1505KQurAn','224300DklBLx','3XmxJzR','1mLOzwJ','qdECi','4364037OAiMYz'];_0x22d9=function(){return _0x5f25f9;};return _0x22d9();}import{join}from'path';import{existsSync}from'fs';import{getEnvDir}from'./utils/settings.js';import{writeActiveProfileName}from'./utils/activeProfile.js';import{ApiError,fetchCloudProfile}from'./utils/cloudProfile.js';export async function useEnv(_0x32c300){const _0x54b947=_0x19d4,_0x5592f7={'uDYEQ':function(_0x1e75ec,_0x217a2f,_0x174dbb){return _0x1e75ec(_0x217a2f,_0x174dbb);},'GnFVN':function(_0x5ce123,_0x5430a4){return _0x5ce123(_0x5430a4);},'qdECi':function(_0x64f40e,_0x3392a7){return _0x64f40e instanceof _0x3392a7;}},_0x3b8a22=getEnvDir(_0x32c300),_0x183afb=_0x5592f7['uDYEQ'](join,_0x3b8a22,_0x54b947(0xe0)),_0x162be6=_0x5592f7['GnFVN'](existsSync,_0x3b8a22)&&existsSync(_0x183afb);if(_0x162be6){await writeActiveProfileName(_0x32c300),console[_0x54b947(0xd6)](_0x54b947(0xe2)+_0x32c300+'\x22');return;}let _0x3a781b=null,_0x38e3b1=![];try{_0x3a781b=await fetchCloudProfile(_0x32c300);if(!_0x3a781b)_0x38e3b1=!![];}catch(_0x31aa64){_0x5592f7[_0x54b947(0xd4)](_0x31aa64,ApiError)&&_0x31aa64[_0x54b947(0xdb)]===0x194&&(_0x38e3b1=!![]);}if(_0x38e3b1)throw new Error(_0x54b947(0xdc)+_0x32c300+_0x54b947(0xe3)+_0x54b947(0xdd)+('`ranger\x20profile\x20add\x20'+_0x32c300+_0x54b947(0xde)));await writeActiveProfileName(_0x32c300),console[_0x54b947(0xd6)](_0x54b947(0xe2)+_0x32c300+'\x22');}
@@ -1 +1 @@
1
- function _0x2a56(_0x359573,_0x143381){_0x359573=_0x359573-0x136;const _0x28abae=_0x28ab();let _0x2a56e6=_0x28abae[_0x359573];return _0x2a56e6;}const _0x3f4582=_0x2a56;(function(_0x529eed,_0x50cdb5){const _0x3a5c21=_0x2a56,_0x298fd7=_0x529eed();while(!![]){try{const _0x467bf6=parseInt(_0x3a5c21(0x147))/0x1*(parseInt(_0x3a5c21(0x13a))/0x2)+-parseInt(_0x3a5c21(0x139))/0x3*(-parseInt(_0x3a5c21(0x148))/0x4)+parseInt(_0x3a5c21(0x144))/0x5+-parseInt(_0x3a5c21(0x13c))/0x6+-parseInt(_0x3a5c21(0x14a))/0x7*(-parseInt(_0x3a5c21(0x138))/0x8)+parseInt(_0x3a5c21(0x146))/0x9*(parseInt(_0x3a5c21(0x13b))/0xa)+parseInt(_0x3a5c21(0x141))/0xb*(-parseInt(_0x3a5c21(0x140))/0xc);if(_0x467bf6===_0x50cdb5)break;else _0x298fd7['push'](_0x298fd7['shift']());}catch(_0xa10b98){_0x298fd7['push'](_0x298fd7['shift']());}}}(_0x28ab,0x4389f));import{existsSync}from'fs';function _0x28ab(){const _0x4e6f63=['eOpOI','PlIiH','37432zZvSGm','916494IIdfNf','902526SDSRZB','10rwjhTk','3088740aWSrQd','active-profile.txt','AlHIJ','utf-8','384GYqvuX','192599oEQTxB','ECUKN','DGfqs','1931965IvTuTj','active-env.txt','1708623HYyOyx','1ghNHsM','4UOMJfN','jbmuX','28nmqExh'];_0x28ab=function(){return _0x4e6f63;};return _0x28ab();}import{readFile}from'fs/promises';import{join}from'path';import{getRangerDir,getRangerHomeDir}from'./rangerRoot.js';import{readLastProfile,writeLastProfile}from'./projectsConfig.js';const LEGACY_ACTIVE_PROFILE_FILE=_0x3f4582(0x13d),LEGACY_ACTIVE_ENV_FILE=_0x3f4582(0x145);function readLegacyActiveProfileFile(){const _0x4d3826=_0x3f4582,_0x379dd4={'PlIiH':function(_0x34bceb,_0x417835,_0x29c922){return _0x34bceb(_0x417835,_0x29c922);},'jbmuX':function(_0x16412b){return _0x16412b();},'Lqyvc':function(_0x2c0768,_0x1a8a57,_0x4c1ad9){return _0x2c0768(_0x1a8a57,_0x4c1ad9);},'QBDrA':function(_0x887231){return _0x887231();}},_0x244dda=[join(getRangerDir(),LEGACY_ACTIVE_PROFILE_FILE),_0x379dd4[_0x4d3826(0x137)](join,_0x379dd4[_0x4d3826(0x149)](getRangerHomeDir),LEGACY_ACTIVE_PROFILE_FILE),_0x379dd4[_0x4d3826(0x137)](join,getRangerDir(),LEGACY_ACTIVE_ENV_FILE),_0x379dd4['Lqyvc'](join,_0x379dd4['QBDrA'](getRangerHomeDir),LEGACY_ACTIVE_ENV_FILE)];for(const _0x4ed0b3 of _0x244dda){if(existsSync(_0x4ed0b3))return _0x4ed0b3;}return null;}export async function readActiveProfileName(){const _0xdc5b9b=_0x3f4582,_0x2e3ff5={'ECUKN':function(_0x4cd535,_0x3c147f){return _0x4cd535(_0x3c147f);},'DGfqs':function(_0x98ef47,_0x54c231,_0x1f4e99){return _0x98ef47(_0x54c231,_0x1f4e99);},'AlHIJ':_0xdc5b9b(0x13f)},_0x906d17=_0x2e3ff5[_0xdc5b9b(0x142)](readLastProfile,process['cwd']());if(_0x906d17)return _0x906d17;const _0x2c6bbf=readLegacyActiveProfileFile();if(!_0x2c6bbf)return null;try{return(await _0x2e3ff5[_0xdc5b9b(0x143)](readFile,_0x2c6bbf,_0x2e3ff5[_0xdc5b9b(0x13e)]))['trim']()||null;}catch{return null;}}export async function writeActiveProfileName(_0x59c908){const _0x406d0f=_0x3f4582,_0x137b86={'eOpOI':function(_0x55d8e1,_0x3ef1f6,_0x3db80d){return _0x55d8e1(_0x3ef1f6,_0x3db80d);}};_0x137b86[_0x406d0f(0x136)](writeLastProfile,process['cwd'](),_0x59c908);}
1
+ const _0x498c33=_0x4f53;(function(_0x5dbfc6,_0x39b45c){const _0x1b5d49=_0x4f53,_0x32b38d=_0x5dbfc6();while(!![]){try{const _0x55e0bf=parseInt(_0x1b5d49(0x1a2))/0x1+parseInt(_0x1b5d49(0x1a8))/0x2*(parseInt(_0x1b5d49(0x1b0))/0x3)+parseInt(_0x1b5d49(0x1a0))/0x4+parseInt(_0x1b5d49(0x1a3))/0x5+-parseInt(_0x1b5d49(0x1a9))/0x6*(parseInt(_0x1b5d49(0x1ac))/0x7)+-parseInt(_0x1b5d49(0x1b1))/0x8+parseInt(_0x1b5d49(0x1a4))/0x9*(parseInt(_0x1b5d49(0x1ae))/0xa);if(_0x55e0bf===_0x39b45c)break;else _0x32b38d['push'](_0x32b38d['shift']());}catch(_0x1972a9){_0x32b38d['push'](_0x32b38d['shift']());}}}(_0x1c4e,0xcb959));import{existsSync}from'fs';import{readFile}from'fs/promises';import{join}from'path';import{getRangerDir,getRangerHomeDir}from'./rangerRoot.js';import{readLastProfile,writeLastProfile}from'./projectsConfig.js';const LEGACY_ACTIVE_PROFILE_FILE=_0x498c33(0x1a5),LEGACY_ACTIVE_ENV_FILE=_0x498c33(0x1af);function _0x4f53(_0x1bdc22,_0x26c609){_0x1bdc22=_0x1bdc22-0x1a0;const _0x1c4edf=_0x1c4e();let _0x4f531e=_0x1c4edf[_0x1bdc22];return _0x4f531e;}function readLegacyActiveProfileFile(){const _0x5e56ec=_0x498c33,_0xabc7c7={'PIrNc':function(_0x21fced,_0x43bb4e,_0x400add){return _0x21fced(_0x43bb4e,_0x400add);},'pWCZh':function(_0x17d16e,_0x14bf6a,_0x545e23){return _0x17d16e(_0x14bf6a,_0x545e23);},'cxDff':function(_0x3dac25){return _0x3dac25();},'Oayhe':function(_0x349e8e,_0x58a640){return _0x349e8e(_0x58a640);}},_0x121896=[_0xabc7c7[_0x5e56ec(0x1aa)](join,getRangerDir(),LEGACY_ACTIVE_PROFILE_FILE),join(getRangerHomeDir(),LEGACY_ACTIVE_PROFILE_FILE),_0xabc7c7[_0x5e56ec(0x1ab)](join,getRangerDir(),LEGACY_ACTIVE_ENV_FILE),join(_0xabc7c7['cxDff'](getRangerHomeDir),LEGACY_ACTIVE_ENV_FILE)];for(const _0x1d0eae of _0x121896){if(_0xabc7c7[_0x5e56ec(0x1a6)](existsSync,_0x1d0eae))return _0x1d0eae;}return null;}function _0x1c4e(){const _0x2413d0=['51950pwATQu','active-env.txt','3AnoZlb','10069912ULvbqs','4544800vGlOTm','PYjJO','1567488CWAgjy','3182310sVXHmH','423IipvZV','active-profile.txt','Oayhe','cwd','245978SgcORs','6756XEySyE','PIrNc','pWCZh','10038oXFNhD','utf-8'];_0x1c4e=function(){return _0x2413d0;};return _0x1c4e();}export async function readActiveProfileName(){const _0x4c2716=_0x498c33,_0x568d2e=readLastProfile(process[_0x4c2716(0x1a7)]());if(_0x568d2e)return _0x568d2e;const _0x9cd0ee=readLegacyActiveProfileFile();if(!_0x9cd0ee)return null;try{return(await readFile(_0x9cd0ee,_0x4c2716(0x1ad)))['trim']()||null;}catch{return null;}}export async function writeActiveProfileName(_0x3f12){const _0x392e3a=_0x498c33,_0x5a63ce={'PYjJO':function(_0x198920,_0x20dce0,_0x56ed9c){return _0x198920(_0x20dce0,_0x56ed9c);}};_0x5a63ce[_0x392e3a(0x1a1)](writeLastProfile,process[_0x392e3a(0x1a7)](),_0x3f12);}
@@ -1 +1 @@
1
- const _0x5a8599=_0x4d99;function _0xb955(){const _0x919cf=['%PATH%','AWS_WEB_IDENTITY_TOKEN_FILE','1152568lPgrkE','x-ranger-','461424BfxJab','push','NNjHf','PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD','PLAYWRIGHT_BROWSERS_PATH','length','16KHrjZB','${PATH}','entries','trim','NPM_CONFIG_USERCONFIG','PATH\x20contains\x20an\x20unexpanded\x20placeholder\x20like\x20`${PATH}`\x20instead\x20of\x20the\x20expanded\x20current\x20PATH.','set','sessionToken','add','Your\x20PATH\x20looks\x20incomplete\x20for\x20browser\x20automation.\x20Ranger\x20will\x20keep\x20going,\x20but\x20browser\x20setup\x20may\x20fail.','fromEntries','2679486jfhawk','split','RANGERWRIGHT_FORCE_CLICK_TIMEOUT_MS','toLowerCase','644990oeUDBE','PepQc','XDG_CACHE_HOME','7EXRlOv','AWS_DEFAULT_REGION','PATH\x20is\x20missing\x20core\x20system\x20directories\x20like\x20`/usr/bin`\x20and\x20`/bin`.','TMP','NODE_ENV','platform','some','filter','metadata','13027239EiTLEk','includes','XDG_CONFIG_HOME','449702RKgsCC','map','npm_config_prefix','env','win32','1595466nMFnkf','from','true','AWS_REGION','ANTHROPIC_CUSTOM_HEADERS','RANGERWRIGHT_CLICK_TIMEOUT_MS','NOVA_ACT_API_KEY','AWS_ROLE_SESSION_NAME','ranger-claude-tmp','sPPXK','/bin','TMPDIR','byokEnabled'];_0xb955=function(){return _0x919cf;};return _0xb955();}(function(_0x262174,_0x41590b){const _0x398a1b=_0x4d99,_0x5eb96f=_0x262174();while(!![]){try{const _0x24a979=-parseInt(_0x398a1b(0x214))/0x1+-parseInt(_0x398a1b(0x219))/0x2+parseInt(_0x398a1b(0x1f0))/0x3+-parseInt(_0x398a1b(0x1f6))/0x4*(parseInt(_0x398a1b(0x205))/0x5)+-parseInt(_0x398a1b(0x201))/0x6*(-parseInt(_0x398a1b(0x208))/0x7)+parseInt(_0x398a1b(0x1ee))/0x8+parseInt(_0x398a1b(0x211))/0x9;if(_0x24a979===_0x41590b)break;else _0x5eb96f['push'](_0x5eb96f['shift']());}catch(_0x44f92e){_0x5eb96f['push'](_0x5eb96f['shift']());}}}(_0xb955,0x689d8));import{delimiter,join}from'path';import{tmpdir}from'os';import{mkdirSync}from'fs';function _0x4d99(_0x5226ca,_0xccf12f){_0x5226ca=_0x5226ca-0x1e1;const _0xb9550d=_0xb955();let _0x4d99d0=_0xb9550d[_0x5226ca];return _0x4d99d0;}import{getAiProxyUrl}from'./environment.js';const AI_PROXY_METADATA_HEADERS_ENV_VAR=_0x5a8599(0x1e3),AGENT_ENV_PASSTHROUGH_KEYS=['PATH','HOME',_0x5a8599(0x1ea),'TMP','TEMP','USERPROFILE','APPDATA','LOCALAPPDATA',_0x5a8599(0x207),_0x5a8599(0x213),_0x5a8599(0x1f4),_0x5a8599(0x1f3),'CHROME_BIN','CHROMIUM_BIN','npm_config_cache','NPM_CONFIG_CACHE','npm_config_userconfig',_0x5a8599(0x1fa),_0x5a8599(0x216),'NPM_CONFIG_PREFIX','npm_config_registry','NPM_CONFIG_REGISTRY','DEBUG',_0x5a8599(0x20c),'RANGER_TEST_SKIP_BROWSER_WAIT','RANGER_TRANSPORT','RANGERWRIGHT_DAEMON_START_TIMEOUT_MS',_0x5a8599(0x1e4),_0x5a8599(0x203),_0x5a8599(0x1e5),'AWS_PROFILE',_0x5a8599(0x1e2),_0x5a8599(0x209),'AWS_CONFIG_FILE','AWS_SHARED_CREDENTIALS_FILE','AWS_ACCESS_KEY_ID','AWS_SECRET_ACCESS_KEY','AWS_SESSION_TOKEN','AWS_SDK_LOAD_CONFIG',_0x5a8599(0x1ed),'AWS_ROLE_ARN',_0x5a8599(0x1e6),AI_PROXY_METADATA_HEADERS_ENV_VAR],UNEXPANDED_PATH_TOKEN_PATTERNS=[_0x5a8599(0x1f7),'$PATH',_0x5a8599(0x1ec)];function parseCustomHeaders(_0x7dffa1){const _0x2c2ad0=_0x5a8599,_0x57a5={'NNjHf':function(_0x127578,_0x573a2f){return _0x127578===_0x573a2f;},'tgsrI':function(_0x4fc68f,_0x3646b2){return _0x4fc68f+_0x3646b2;}};if(!_0x7dffa1)return[];return _0x7dffa1['split'](/\r?\n/)[_0x2c2ad0(0x215)](_0x156183=>_0x156183['trim']())['filter'](Boolean)['map'](_0x8ad4ef=>{const _0x165663=_0x2c2ad0,_0x5e7ad2=_0x8ad4ef['indexOf'](':');if(_0x57a5[_0x165663(0x1f2)](_0x5e7ad2,-0x1))return null;const _0x191a35=_0x8ad4ef['slice'](0x0,_0x5e7ad2)[_0x165663(0x1f9)](),_0x3f0f8c=_0x8ad4ef['slice'](_0x57a5['tgsrI'](_0x5e7ad2,0x1))['trim']();if(!_0x191a35)return null;return[_0x191a35,_0x3f0f8c];})[_0x2c2ad0(0x20f)](_0x11fccf=>_0x11fccf!==null);}export function getAgentPathHealthWarning(_0x48d0a1,_0x55d681=process[_0x5a8599(0x20d)]){const _0x100b52=_0x5a8599,_0x3d02cb={'iGclY':function(_0x344b1c,_0x5680c1){return _0x344b1c||_0x5680c1;},'LIAJc':'PATH\x20is\x20empty,\x20so\x20npm\x20and\x20core\x20system\x20tools\x20may\x20be\x20unavailable.','hoctF':_0x100b52(0x1fb),'Lvpks':function(_0x4dae63,_0x3e9763){return _0x4dae63!==_0x3e9763;},'sPPXK':_0x100b52(0x218),'ISbfN':function(_0x52a147,_0x98c5cd){return _0x52a147&&_0x98c5cd;},'Yagrl':_0x100b52(0x20a),'zpESB':function(_0x5bd491,_0x10a95e){return _0x5bd491===_0x10a95e;}},_0x268ee3=[],_0x4e9e58=_0x3d02cb['iGclY'](_0x48d0a1,'')[_0x100b52(0x202)](delimiter)['filter'](Boolean);_0x4e9e58['length']===0x0&&_0x268ee3['push'](_0x3d02cb['LIAJc']);UNEXPANDED_PATH_TOKEN_PATTERNS[_0x100b52(0x20e)](_0x1daa36=>(_0x48d0a1||'')[_0x100b52(0x212)](_0x1daa36))&&_0x268ee3['push'](_0x3d02cb['hoctF']);if(_0x3d02cb['Lvpks'](_0x55d681,_0x3d02cb[_0x100b52(0x1e8)])){const _0xc3e247=_0x4e9e58['includes']('/usr/bin'),_0x20c293=_0x4e9e58[_0x100b52(0x212)](_0x100b52(0x1e9));_0x3d02cb['ISbfN'](!_0xc3e247,!_0x20c293)&&_0x268ee3[_0x100b52(0x1f1)](_0x3d02cb['Yagrl']);}if(_0x3d02cb['zpESB'](_0x268ee3[_0x100b52(0x1f5)],0x0))return null;return{'summary':_0x100b52(0x1ff),'issues':_0x268ee3};}export function buildAgentEnv(_0x17553e){const _0x4709c4=_0x5a8599,_0x25a926={'PepQc':_0x4709c4(0x1ea),'JuUhZ':function(_0x289bfb){return _0x289bfb();},'LPfwf':function(_0xc52e16,_0x109b43,_0x36d67f){return _0xc52e16(_0x109b43,_0x36d67f);}};if(_0x17553e[_0x4709c4(0x1eb)])return Object[_0x4709c4(0x200)](Object['entries'](process[_0x4709c4(0x217)])['filter'](_0x33dadf=>typeof _0x33dadf[0x1]==='string'));if(!_0x17553e['sessionToken'])throw new Error('Session\x20token\x20is\x20required\x20when\x20RANGER_BYOK=false');const _0x100bbc={'ANTHROPIC_API_KEY':_0x17553e[_0x4709c4(0x1fd)],'ANTHROPIC_BASE_URL':getAiProxyUrl(),'DISABLE_TELEMETRY':_0x4709c4(0x1e1)};for(const _0x3e255c of AGENT_ENV_PASSTHROUGH_KEYS){const _0x59a18a=process['env'][_0x3e255c];_0x59a18a&&![_0x25a926[_0x4709c4(0x206)],_0x4709c4(0x20b),'TEMP'][_0x4709c4(0x212)](_0x3e255c)&&(_0x100bbc[_0x3e255c]=_0x59a18a);}const _0xb9d4ef=join(_0x25a926['JuUhZ'](tmpdir),_0x4709c4(0x1e7));try{_0x25a926['LPfwf'](mkdirSync,_0xb9d4ef,{'recursive':!![]});}catch{}_0x100bbc[_0x4709c4(0x1ea)]=_0xb9d4ef,_0x100bbc[_0x4709c4(0x20b)]=_0xb9d4ef,_0x100bbc['TEMP']=_0xb9d4ef;const _0x5e239a=parseCustomHeaders(process[_0x4709c4(0x217)][AI_PROXY_METADATA_HEADERS_ENV_VAR]),_0x57959a=new Map(_0x5e239a),_0x90c370=new Set(_0x5e239a['map'](([_0x5d83ef])=>_0x5d83ef[_0x4709c4(0x204)]()));if(_0x17553e['metadata'])for(const [_0x193c97,_0x2a5b96]of Object['entries'](_0x17553e[_0x4709c4(0x210)])){if(_0x2a5b96==null||_0x2a5b96==='')continue;const _0x3325ca=_0x4709c4(0x1ef)+_0x193c97;!_0x90c370['has'](_0x3325ca['toLowerCase']())&&(_0x57959a[_0x4709c4(0x1fc)](_0x3325ca,_0x2a5b96),_0x90c370[_0x4709c4(0x1fe)](_0x3325ca['toLowerCase']()));}const _0x32a374=Array[_0x4709c4(0x21a)](_0x57959a[_0x4709c4(0x1f8)]())[_0x4709c4(0x215)](([_0xb465b,_0x3ddee7])=>_0xb465b+':\x20'+_0x3ddee7)['join']('\x0a');return _0x32a374&&(_0x100bbc[AI_PROXY_METADATA_HEADERS_ENV_VAR]=_0x32a374),_0x100bbc;}
1
+ function _0x1efe(){const _0x538baf=['platform','KvDal','TEMP','win32','RANGERWRIGHT_DAEMON_START_TIMEOUT_MS','sessionToken','4278465ZdOHpq','filter','CHROMIUM_BIN','split','vssst','npm_config_cache','env','XDG_CACHE_HOME','npm_config_prefix','push','AWS_SHARED_CREDENTIALS_FILE','NPM_CONFIG_CACHE','byokEnabled','includes','Your\x20PATH\x20looks\x20incomplete\x20for\x20browser\x20automation.\x20Ranger\x20will\x20keep\x20going,\x20but\x20browser\x20setup\x20may\x20fail.','entries','PATH\x20is\x20missing\x20core\x20system\x20directories\x20like\x20`/usr/bin`\x20and\x20`/bin`.','RANGERWRIGHT_FORCE_CLICK_TIMEOUT_MS','NPM_CONFIG_PREFIX','XVPbe','PATH','metadata','map','9bnrnsm','set','IMuje','TMP','RANGERWRIGHT_CLICK_TIMEOUT_MS','length','12Xluvls','AWS_ROLE_ARN','bqGPR','2365360iuReju','NPM_CONFIG_REGISTRY','from','TMPDIR','rbHbM','true','fromEntries','1214660AdDZBb','59302FTRLaC','3622465PchPhN','$PATH','AWS_WEB_IDENTITY_TOKEN_FILE','RANGER_TRANSPORT','has','AWS_PROFILE','580012WUAIUG','PATH\x20is\x20empty,\x20so\x20npm\x20and\x20core\x20system\x20tools\x20may\x20be\x20unavailable.','string','/bin','AWS_ROLE_SESSION_NAME','toLowerCase','indexOf','add','slice','BgDHa','USERPROFILE','DEBUG','npm_config_userconfig','FZPQT','kWJOA','XDG_CONFIG_HOME','join','LOCALAPPDATA','650944atZBAN'];_0x1efe=function(){return _0x538baf;};return _0x1efe();}const _0x14475=_0x250a;(function(_0x28e7a4,_0x5aa39e){const _0x2a8347=_0x250a,_0x38de81=_0x28e7a4();while(!![]){try{const _0x4b0cdc=-parseInt(_0x2a8347(0xdb))/0x1+-parseInt(_0x2a8347(0xf4))/0x2+parseInt(_0x2a8347(0x112))/0x3*(-parseInt(_0x2a8347(0xe2))/0x4)+parseInt(_0x2a8347(0xda))/0x5*(parseInt(_0x2a8347(0xd0))/0x6)+parseInt(_0x2a8347(0xdc))/0x7+-parseInt(_0x2a8347(0xd3))/0x8+parseInt(_0x2a8347(0xfb))/0x9;if(_0x4b0cdc===_0x5aa39e)break;else _0x38de81['push'](_0x38de81['shift']());}catch(_0x1f04fc){_0x38de81['push'](_0x38de81['shift']());}}}(_0x1efe,0x58b1b));import{delimiter,join}from'path';function _0x250a(_0x212582,_0x2937ed){_0x212582=_0x212582-0xd0;const _0x1efe50=_0x1efe();let _0x250a0f=_0x1efe50[_0x212582];return _0x250a0f;}import{tmpdir}from'os';import{mkdirSync}from'fs';import{getAiProxyUrl}from'./environment.js';const AI_PROXY_METADATA_HEADERS_ENV_VAR='ANTHROPIC_CUSTOM_HEADERS',AGENT_ENV_PASSTHROUGH_KEYS=[_0x14475(0x10f),'HOME',_0x14475(0xd6),'TMP',_0x14475(0xf7),_0x14475(0xec),'APPDATA',_0x14475(0xf3),_0x14475(0x102),_0x14475(0xf1),'PLAYWRIGHT_BROWSERS_PATH','PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD','CHROME_BIN',_0x14475(0xfd),_0x14475(0x100),_0x14475(0x106),_0x14475(0xee),'NPM_CONFIG_USERCONFIG',_0x14475(0x103),_0x14475(0x10d),'npm_config_registry',_0x14475(0xd4),_0x14475(0xed),'NODE_ENV','RANGER_TEST_SKIP_BROWSER_WAIT',_0x14475(0xdf),_0x14475(0xf9),_0x14475(0x116),_0x14475(0x10c),'NOVA_ACT_API_KEY',_0x14475(0xe1),'AWS_REGION','AWS_DEFAULT_REGION','AWS_CONFIG_FILE',_0x14475(0x105),'AWS_ACCESS_KEY_ID','AWS_SECRET_ACCESS_KEY','AWS_SESSION_TOKEN','AWS_SDK_LOAD_CONFIG',_0x14475(0xde),_0x14475(0xd1),_0x14475(0xe6),AI_PROXY_METADATA_HEADERS_ENV_VAR],UNEXPANDED_PATH_TOKEN_PATTERNS=['${PATH}',_0x14475(0xdd),'%PATH%'];function parseCustomHeaders(_0x218ddd){const _0x51fc11=_0x14475,_0x10d30f={'XVPbe':function(_0x2fb4ac,_0x2f2073){return _0x2fb4ac+_0x2f2073;}};if(!_0x218ddd)return[];return _0x218ddd[_0x51fc11(0xfe)](/\r?\n/)['map'](_0x24ae5c=>_0x24ae5c['trim']())['filter'](Boolean)['map'](_0x2c00e0=>{const _0x3f23f3=_0x51fc11,_0x4452c4=_0x2c00e0[_0x3f23f3(0xe8)](':');if(_0x4452c4===-0x1)return null;const _0x582176=_0x2c00e0['slice'](0x0,_0x4452c4)['trim'](),_0xc33201=_0x2c00e0[_0x3f23f3(0xea)](_0x10d30f[_0x3f23f3(0x10e)](_0x4452c4,0x1))['trim']();if(!_0x582176)return null;return[_0x582176,_0xc33201];})[_0x51fc11(0xfc)](_0x2e4f76=>_0x2e4f76!==null);}export function getAgentPathHealthWarning(_0x52ee62,_0x26ecdd=process[_0x14475(0xf5)]){const _0x5ce5d3=_0x14475,_0x40e3fe={'BgDHa':function(_0x597191,_0x13b234){return _0x597191===_0x13b234;},'FZPQT':_0x5ce5d3(0xe3),'KvDal':function(_0x20de33,_0x466c56){return _0x20de33!==_0x466c56;},'bqGPR':_0x5ce5d3(0xe5)},_0x57a675=[],_0x8c0215=(_0x52ee62||'')[_0x5ce5d3(0xfe)](delimiter)['filter'](Boolean);_0x40e3fe[_0x5ce5d3(0xeb)](_0x8c0215[_0x5ce5d3(0x117)],0x0)&&_0x57a675['push'](_0x40e3fe[_0x5ce5d3(0xef)]);UNEXPANDED_PATH_TOKEN_PATTERNS['some'](_0x3c390e=>(_0x52ee62||'')['includes'](_0x3c390e))&&_0x57a675[_0x5ce5d3(0x104)]('PATH\x20contains\x20an\x20unexpanded\x20placeholder\x20like\x20`${PATH}`\x20instead\x20of\x20the\x20expanded\x20current\x20PATH.');if(_0x40e3fe[_0x5ce5d3(0xf6)](_0x26ecdd,_0x5ce5d3(0xf8))){const _0x12e124=_0x8c0215[_0x5ce5d3(0x108)]('/usr/bin'),_0x1bc7d5=_0x8c0215['includes'](_0x40e3fe[_0x5ce5d3(0xd2)]);!_0x12e124&&!_0x1bc7d5&&_0x57a675['push'](_0x5ce5d3(0x10b));}if(_0x40e3fe[_0x5ce5d3(0xeb)](_0x57a675['length'],0x0))return null;return{'summary':_0x5ce5d3(0x109),'issues':_0x57a675};}export function buildAgentEnv(_0x38786b){const _0x85e2a6=_0x14475,_0x3bf08a={'fhSYK':'Session\x20token\x20is\x20required\x20when\x20RANGER_BYOK=false','IMuje':_0x85e2a6(0xd8),'vssst':_0x85e2a6(0xf7),'kWJOA':function(_0x498853,_0x2b1fbe,_0x162a84){return _0x498853(_0x2b1fbe,_0x162a84);},'EssyD':function(_0x3904fb,_0x50f74b,_0x1d4ac4){return _0x3904fb(_0x50f74b,_0x1d4ac4);},'YLkdj':'TMPDIR','rbHbM':'TMP','NOxYf':function(_0x68d355,_0x1374c6){return _0x68d355(_0x1374c6);}};if(_0x38786b[_0x85e2a6(0x107)])return Object[_0x85e2a6(0xd9)](Object[_0x85e2a6(0x10a)](process[_0x85e2a6(0x101)])[_0x85e2a6(0xfc)](_0x4fb15a=>typeof _0x4fb15a[0x1]===_0x85e2a6(0xe4)));if(!_0x38786b['sessionToken'])throw new Error(_0x3bf08a['fhSYK']);const _0x5605b7={'ANTHROPIC_API_KEY':_0x38786b[_0x85e2a6(0xfa)],'ANTHROPIC_BASE_URL':getAiProxyUrl(),'DISABLE_TELEMETRY':_0x3bf08a[_0x85e2a6(0x114)]};for(const _0x14672f of AGENT_ENV_PASSTHROUGH_KEYS){const _0x2fd1a0=process[_0x85e2a6(0x101)][_0x14672f];_0x2fd1a0&&!['TMPDIR',_0x85e2a6(0x115),_0x3bf08a['vssst']]['includes'](_0x14672f)&&(_0x5605b7[_0x14672f]=_0x2fd1a0);}const _0x48561b=_0x3bf08a[_0x85e2a6(0xf0)](join,tmpdir(),'ranger-claude-tmp');try{_0x3bf08a['EssyD'](mkdirSync,_0x48561b,{'recursive':!![]});}catch{}_0x5605b7[_0x3bf08a['YLkdj']]=_0x48561b,_0x5605b7[_0x3bf08a[_0x85e2a6(0xd7)]]=_0x48561b,_0x5605b7[_0x3bf08a[_0x85e2a6(0xff)]]=_0x48561b;const _0x5a7b80=_0x3bf08a['NOxYf'](parseCustomHeaders,process['env'][AI_PROXY_METADATA_HEADERS_ENV_VAR]),_0xb1114a=new Map(_0x5a7b80),_0x1f59a3=new Set(_0x5a7b80[_0x85e2a6(0x111)](([_0x355aed])=>_0x355aed['toLowerCase']()));if(_0x38786b['metadata'])for(const [_0x21a62d,_0x1c5ecc]of Object[_0x85e2a6(0x10a)](_0x38786b[_0x85e2a6(0x110)])){if(_0x1c5ecc==null||_0x1c5ecc==='')continue;const _0x462b6f='x-ranger-'+_0x21a62d;!_0x1f59a3[_0x85e2a6(0xe0)](_0x462b6f[_0x85e2a6(0xe7)]())&&(_0xb1114a[_0x85e2a6(0x113)](_0x462b6f,_0x1c5ecc),_0x1f59a3[_0x85e2a6(0xe9)](_0x462b6f['toLowerCase']()));}const _0x22e261=Array[_0x85e2a6(0xd5)](_0xb1114a['entries']())['map'](([_0x548807,_0x2a478b])=>_0x548807+':\x20'+_0x2a478b)[_0x85e2a6(0xf2)]('\x0a');return _0x22e261&&(_0x5605b7[AI_PROXY_METADATA_HEADERS_ENV_VAR]=_0x22e261),_0x5605b7;}
@@ -1 +1 @@
1
- (function(_0x214fab,_0x1a3172){const _0x503b3f=_0x45b0,_0x449ab3=_0x214fab();while(!![]){try{const _0x47e0e7=parseInt(_0x503b3f(0x1ba))/0x1*(parseInt(_0x503b3f(0x1ac))/0x2)+parseInt(_0x503b3f(0x15f))/0x3*(parseInt(_0x503b3f(0x17e))/0x4)+parseInt(_0x503b3f(0x161))/0x5+parseInt(_0x503b3f(0x187))/0x6+parseInt(_0x503b3f(0x158))/0x7+-parseInt(_0x503b3f(0x1c2))/0x8+-parseInt(_0x503b3f(0x162))/0x9;if(_0x47e0e7===_0x1a3172)break;else _0x449ab3['push'](_0x449ab3['shift']());}catch(_0x112d48){_0x449ab3['push'](_0x449ab3['shift']());}}}(_0x467a,0x2dc58));const _0x158203=(function(){let _0x2b4328=!![];return function(_0x3f03aa,_0x463d23){const _0x53a9f2=_0x2b4328?function(){const _0xe9cc4e=_0x45b0;if(_0x463d23){const _0x30c749=_0x463d23[_0xe9cc4e(0x17a)](_0x3f03aa,arguments);return _0x463d23=null,_0x30c749;}}:function(){};return _0x2b4328=![],_0x53a9f2;};}()),_0x1159ca=_0x158203(this,function(){const _0x112fde=_0x45b0,_0x1ffa01={'QTkDY':'(((.+)+)+)+$'};return _0x1159ca[_0x112fde(0x18a)]()['search'](_0x1ffa01[_0x112fde(0x182)])[_0x112fde(0x18a)]()[_0x112fde(0x18d)](_0x1159ca)[_0x112fde(0x1b1)](_0x1ffa01[_0x112fde(0x182)]);});_0x1159ca();import{getToken}from'./keychain.js';import{getApiBaseUrl}from'./environment.js';function _0x467a(){const _0xa978ae=['uvrRrfK','u3PLsg4','ywTpz0S','uvPHqKi','DgfZAW','nJqYmJe2uNvUy2jj','rMfPBgvKihrVihvWzgf0zsb2zxjPzMLJyxrPB24GC3rLCdOG','Agf0rLe','Dg9tDhjPBMC','Bg5RvMW','rMfPBgvKihrVigDLDcb1CgXVywqGvvjmCZOG','y29UC3rYDwn0B3i','yuvkz3u','yMfZzty0','l2fWAs92ms9Ty3aVyNjVD3nLCI1ZzxnZAw9UCY8','sKPUEM0','ELHJBMy','Bwv0ywrHDge','q3rRu1O','zMzID3i','BgvUz3rO','DxbKyxrLqNjVD3nLCLnLC3nPB24','zM1tCeW','tgrHzxG','Aw1Hz2uVCg5N','y2HLy2TZDw0','rMfPBgvKihrVignYzwf0zsbICM93C2vYihnLC3nPB246ia','Ahbgvvi','D2XWsM0','vvH0EhK','tKTrENm','CLrvC24','l3n0zxbZlW','zevdzK4','zw52AxjVBM1LBNroyw1L','BxHQsvO','l2fWAs92ms9Ty3aVChjVEhKTC2vZC2LVBG','vgzLDLm','qMvHCMvYia','CeX6sgi','uefuq0G','t3bhy00','mtrnAwj0zLe','ruj2zxm','vMPqDM8','AM9vCM8','A09nDe4','C2vHCMnO','yxbWBgLJyxrPB24VANnVBG','C3rYAw5NAwz5','rNjOzMi','C2L6zq','C1bUzhm','A3rivfe','tgvAwfq','wuTkqxm','mZy3odD1zvjkswm','txz5uMe','rMfPBgvKihrVihvWBg9HzcbMAwXLoIa','ENjltgW','z0rwsue','ruTACvK','qNf6rMy','ALfwq0O','ndeXmZeYq0PAELjv','tuTbBMC','Dxb6ExC','s3jkz08','rgftqKe','yufYyxO','rMfPBgvKihrVigDLDcbWCM94EsbZzxnZAw9UihrVA2vUoIa','CujTvfG','y2HLy2TSAxn0sxrLBuLK','CMjYuhu','zNftBKe','quTqrhO','zgLNzxn0','y3zrEfG','r2rOu0e','rwfwqxO','l3n0zxbZ','AhzhtwC','ue9tva','DxbKyxrL','l2fZC2v0CW','A0ffzxi','mtK5ndiXnK5Ovfvjva','v0T0r2G','DMLKzw8VD2vIBq','zgHrEeO','DhnjvfG','EhzizKm','r0vu','nJq5nti3rM13quHN','wMPLwwu','mZi1mJe1Cfnxv1Lo','nJiYodGXow5mrfHuwG','BxHwChm','DMrewK8','tNHpsMq','z0XIAuy','wuvRDuy','B3zsq1q','C2vZC2LVBLrVA2vU','vwDYwg0','u1PRwuy','rwvMz24','zhjQDxy','l3vWBg9Hzc11CMXZ','ANnVBG','DxjS','Dgv4Da','yxvuwfy','tM8GqvbjihrVA2vUignVBMzPz3vYzwqUifj1BJOGCMfUz2vYihnLDhvWifT0B2TLBL0','rMfPBgvKihrVihvWzgf0zsbICM93C2vYihnLC3nPB246ia','q1LdvLK','zMvHDhvYzuLK','qNbwDK8','ENDdq2W','s0joA3C','yxbWBhK','kcGOlISPkYKRksSK','rMfPBgvKihrVignYzwf0zsb2zxjPzMLJyxrPB24GC3rLCdOG','z3L1vge','ngTxy1fYBa','DLfPBMW','BMLQq0S','u1vgwKe'];_0x467a=function(){return _0xa978ae;};return _0x467a();}import{createHash}from'crypto';import{withRetry}from'./retry.js';export async function createBrowserSession(_0x1d6ed1){const _0x1bcdf3=_0x45b0,_0x263461={'fmSpL':function(_0x3601ac,_0x4c2de1){return _0x3601ac(_0x4c2de1);},'kLKyF':'base64','EKZqY':function(_0x32d918){return _0x32d918();},'JJnzm':_0x1bcdf3(0x1c0),'nijCK':_0x1bcdf3(0x173),'mxVps':function(_0x5b0eaf){return _0x5b0eaf();},'CtkSZ':function(_0x925261,_0x399605,_0x2fdbbc){return _0x925261(_0x399605,_0x2fdbbc);},'xvHfC':_0x1bcdf3(0x1d4),'Eefgn':_0x1bcdf3(0x1b2)},_0x4250ea=await _0x263461[_0x1bcdf3(0x1bf)](getToken);if(!_0x4250ea){if(_0x263461[_0x1bcdf3(0x191)]!==_0x1bcdf3(0x18e))throw new Error(_0x263461[_0x1bcdf3(0x180)]);else return _0x263461[_0x1bcdf3(0x198)](_0x194ce1,'md5')['update'](_0x58dc8a)['digest'](_0x263461['kLKyF']);}const _0x4bfae2=_0x263461[_0x1bcdf3(0x163)](getApiBaseUrl),_0x5e6bc3=await _0x263461[_0x1bcdf3(0x194)](fetch,_0x4bfae2+'/api/v1/mcp/browser-sessions',{'method':_0x263461[_0x1bcdf3(0x15d)],'headers':{'Authorization':_0x1bcdf3(0x1a8)+_0x4250ea,'Content-Type':_0x263461[_0x1bcdf3(0x16c)]},'body':JSON['stringify']({'environmentName':_0x1d6ed1?.[_0x1bcdf3(0x1a4)],'settings':_0x1d6ed1?.['settings'],'task':_0x1d6ed1?.[_0x1bcdf3(0x186)],'url':_0x1d6ed1?.[_0x1bcdf3(0x170)],'featureId':_0x1d6ed1?.[_0x1bcdf3(0x176)],'checklistItemId':_0x1d6ed1?.[_0x1bcdf3(0x1ca)]})});if(!_0x5e6bc3['ok']){const _0x1c916a=await _0x5e6bc3['text']();throw new Error(_0x1bcdf3(0x19c)+_0x1c916a);}return _0x5e6bc3[_0x1bcdf3(0x16f)]();}export async function updateBrowserSession(_0x51dbcc,_0x464193){const _0x5a51f9=_0x45b0,_0x4ad9bd={'gLbiF':function(_0x3f5aa2,_0x417705,_0x1054ee,_0x42b2df){return _0x3f5aa2(_0x417705,_0x1054ee,_0x42b2df);},'lJsLb':'uoXHk','gyuTa':'No\x20API\x20token\x20configured.\x20Run:\x20ranger\x20setup\x20[token]','rqFzJ':function(_0x21fcb5){return _0x21fcb5();},'akOgK':function(_0x1920d4,_0x284571,_0x57993d){return _0x1920d4(_0x284571,_0x57993d);},'ovRCT':'application/json','fqSnA':function(_0x52368d,_0x437fc2,_0x5c77e8){return _0x52368d(_0x437fc2,_0x5c77e8);},'rTUsn':_0x5a51f9(0x197)};return _0x4ad9bd[_0x5a51f9(0x1cc)](withRetry,async()=>{const _0x152e5b=_0x5a51f9,_0x1b993d={'upzyw':function(_0x8de37b,_0xfa9d5a,_0x18f839,_0x50c02d){const _0x37316=_0x45b0;return _0x4ad9bd[_0x37316(0x166)](_0x8de37b,_0xfa9d5a,_0x18f839,_0x50c02d);}},_0x177190=await getToken();if(!_0x177190){if(_0x4ad9bd['lJsLb']===_0x4ad9bd['lJsLb'])throw new Error(_0x4ad9bd[_0x152e5b(0x17d)]);else return _0x1b993d[_0x152e5b(0x1c4)](_0xacfd7,_0x170e3d,_0x151556,_0x152e5b(0x15a));}const _0x4f9c5a=_0x4ad9bd['rqFzJ'](getApiBaseUrl),_0x3a0f84=await _0x4ad9bd[_0x152e5b(0x184)](fetch,_0x4f9c5a+_0x152e5b(0x190)+_0x51dbcc,{'method':_0x152e5b(0x1aa),'headers':{'Authorization':_0x152e5b(0x1a8)+_0x177190,'Content-Type':_0x4ad9bd[_0x152e5b(0x168)]},'body':JSON[_0x152e5b(0x1b3)](_0x464193)});if(!_0x3a0f84['ok']){const _0x2a2bee=await _0x3a0f84[_0x152e5b(0x171)]();throw new Error(_0x152e5b(0x174)+_0x2a2bee);}return _0x3a0f84[_0x152e5b(0x16f)]();},{'label':_0x4ad9bd[_0x5a51f9(0x1a1)]});}export async function getBrowserSession(_0x569e33){const _0x53264e=_0x45b0,_0x1529eb={'AKPDz':function(_0x4a65af,_0x38be12,_0x12673f,_0x3a6e4b){return _0x4a65af(_0x38be12,_0x12673f,_0x3a6e4b);},'gDVIA':'application/zip','UgrXm':_0x53264e(0x173),'Frhfb':function(_0x59394d){return _0x59394d();},'dECfN':function(_0x1fabb0,_0xd4f4ba,_0x4f0110){return _0x1fabb0(_0xd4f4ba,_0x4f0110);},'MiEGJ':'GET','MvyRa':function(_0x309024,_0x187230){return _0x309024===_0x187230;},'qBmTX':_0x53264e(0x19e)},_0x57101f=await getToken();if(!_0x57101f)throw new Error(_0x1529eb[_0x53264e(0x16a)]);const _0x550099=_0x1529eb[_0x53264e(0x1b4)](getApiBaseUrl),_0x469348=await _0x1529eb[_0x53264e(0x1a3)](fetch,_0x550099+_0x53264e(0x190)+_0x569e33,{'method':_0x1529eb['MiEGJ'],'headers':{'Authorization':_0x53264e(0x1a8)+_0x57101f}});if(!_0x469348['ok']){if(_0x1529eb[_0x53264e(0x1bb)](_0x1529eb[_0x53264e(0x1c9)],_0x1529eb[_0x53264e(0x1c9)])){const _0x36fe38=await _0x469348['text']();throw new Error('Failed\x20to\x20get\x20browser\x20session:\x20'+_0x36fe38);}else return _0x1529eb[_0x53264e(0x1cd)](_0x4056e5,_0x400ade,_0x4812c0,_0x1529eb[_0x53264e(0x1be)]);}return _0x469348[_0x53264e(0x16f)]();}export async function getUploadUrls(_0x569129,_0x101c80,_0x2ac56d,_0x22a77c){const _0x17a58e=_0x45b0,_0x3bbb99={'lnkVl':_0x17a58e(0x173),'TukIr':function(_0x55c3b4,_0x515aae,_0x3a0bed){return _0x55c3b4(_0x515aae,_0x3a0bed);},'KBNkw':_0x17a58e(0x1d4),'hatFQ':'application/json','aAraz':function(_0x5ab0e3,_0x18025b){return _0x5ab0e3!==_0x18025b;},'hvGMg':'FwWIC','CYCVY':_0x17a58e(0x164)},_0x516e19=await getToken();if(!_0x516e19)throw new Error(_0x17a58e(0x173));const _0x8bfb79=getApiBaseUrl(),_0x264b38=await _0x3bbb99['TukIr'](fetch,_0x8bfb79+'/api/v1/mcp/browser-sessions/'+_0x569129+_0x17a58e(0x16e),{'method':_0x3bbb99[_0x17a58e(0x179)],'headers':{'Authorization':_0x17a58e(0x1a8)+_0x516e19,'Content-Type':_0x3bbb99[_0x17a58e(0x189)]},'body':JSON[_0x17a58e(0x1b3)]({'filename':_0x101c80,'filetype':_0x2ac56d,..._0x3bbb99[_0x17a58e(0x1c7)](_0x22a77c?.[_0x17a58e(0x1b5)],undefined)&&{'size':_0x22a77c[_0x17a58e(0x1b5)]},..._0x3bbb99[_0x17a58e(0x1c7)](_0x22a77c?.[_0x17a58e(0x19b)],undefined)&&{'checksum':_0x22a77c[_0x17a58e(0x19b)]},..._0x3bbb99[_0x17a58e(0x1c7)](_0x22a77c?.['metadata'],undefined)&&{'metadata':_0x22a77c[_0x17a58e(0x193)]}})});if(!_0x264b38['ok']){if(_0x3bbb99[_0x17a58e(0x1d3)]!==_0x3bbb99[_0x17a58e(0x175)]){const _0x3d8830=await _0x264b38['text']();throw new Error(_0x17a58e(0x18c)+_0x3d8830);}else throw new _0x34f3ae(_0x3bbb99[_0x17a58e(0x18b)]);}return _0x264b38[_0x17a58e(0x16f)]();}export async function uploadFile(_0x26765c,_0x121821,_0x2dd943){const _0x1f6907=_0x45b0,_0x358b86={'NxOJd':'No\x20API\x20token\x20configured.\x20Run:\x20ranger\x20setup\x20[token]','OpGcM':function(_0x24db3d,_0x406fc9,_0x19db6e){return _0x24db3d(_0x406fc9,_0x19db6e);},'NKQzs':'PUT','joUro':function(_0x36f736,_0x39b8bf){return _0x36f736===_0x39b8bf;},'zXcnf':_0x1f6907(0x19d)},_0x193b27=await _0x358b86[_0x1f6907(0x1ab)](fetch,_0x26765c,{'method':_0x358b86[_0x1f6907(0x1a0)],'headers':{'Content-Type':_0x2dd943,'Content-Length':_0x121821[_0x1f6907(0x196)][_0x1f6907(0x18a)]()},'body':_0x121821});if(!_0x193b27['ok']){if(_0x358b86[_0x1f6907(0x1af)](_0x358b86[_0x1f6907(0x192)],_0x358b86[_0x1f6907(0x192)])){const _0x1f58a4=await _0x193b27[_0x1f6907(0x171)]();throw new Error(_0x1f6907(0x1bc)+_0x1f58a4);}else throw new _0x355182(_0x358b86[_0x1f6907(0x165)]);}}export async function uploadTrace(_0x1df769,_0x4060e9){const _0x42b9dd=_0x45b0,_0x1ee4d4={'MKAng':function(_0x325956,_0x58cf27,_0x2b50ec,_0x105e95){return _0x325956(_0x58cf27,_0x2b50ec,_0x105e95);},'vQinl':'application/zip'};return _0x1ee4d4[_0x42b9dd(0x1c3)](uploadFile,_0x1df769,_0x4060e9,_0x1ee4d4[_0x42b9dd(0x17f)]);}export async function uploadConversation(_0x2d43dc,_0x197122){return uploadFile(_0x2d43dc,_0x197122,'application/jsonl');}function _0x45b0(_0x5d6e20,_0x1e9df3){_0x5d6e20=_0x5d6e20-0x155;const _0x14ccc0=_0x467a();let _0x1159ca=_0x14ccc0[_0x5d6e20];if(_0x45b0['FvhZNO']===undefined){var _0x158203=function(_0x24ee1e){const _0x540dd4='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';let _0x1a6fbf='',_0x10ef2c='',_0x5eb4c8=_0x1a6fbf+_0x158203;for(let _0x47730a=0x0,_0x1f7daf,_0x20c307,_0x32cce9=0x0;_0x20c307=_0x24ee1e['charAt'](_0x32cce9++);~_0x20c307&&(_0x1f7daf=_0x47730a%0x4?_0x1f7daf*0x40+_0x20c307:_0x20c307,_0x47730a++%0x4)?_0x1a6fbf+=_0x5eb4c8['charCodeAt'](_0x32cce9+0xa)-0xa!==0x0?String['fromCharCode'](0xff&_0x1f7daf>>(-0x2*_0x47730a&0x6)):_0x47730a:0x0){_0x20c307=_0x540dd4['indexOf'](_0x20c307);}for(let _0x332ceb=0x0,_0x2fde7a=_0x1a6fbf['length'];_0x332ceb<_0x2fde7a;_0x332ceb++){_0x10ef2c+='%'+('00'+_0x1a6fbf['charCodeAt'](_0x332ceb)['toString'](0x10))['slice'](-0x2);}return decodeURIComponent(_0x10ef2c);};_0x45b0['fAWZLI']=_0x158203,_0x45b0['zUTQOs']={},_0x45b0['FvhZNO']=!![];}const _0x467a98=_0x14ccc0[0x0],_0x45b0a3=_0x5d6e20+_0x467a98,_0x54d231=_0x45b0['zUTQOs'][_0x45b0a3];if(!_0x54d231){const _0x49f732=function(_0x37b852){this['qdlxgd']=_0x37b852,this['feFbMd']=[0x1,0x0,0x0],this['mtxErU']=function(){return'newState';},this['wOlpLO']='\x5cw+\x20*\x5c(\x5c)\x20*{\x5cw+\x20*',this['iLQvui']='[\x27|\x22].+[\x27|\x22];?\x20*}';};_0x49f732['prototype']['BxKDwT']=function(){const _0x53b96d=new RegExp(this['wOlpLO']+this['iLQvui']),_0x5354bf=_0x53b96d['test'](this['mtxErU']['toString']())?--this['feFbMd'][0x1]:--this['feFbMd'][0x0];return this['vuNpBt'](_0x5354bf);},_0x49f732['prototype']['vuNpBt']=function(_0x43ccf8){if(!Boolean(~_0x43ccf8))return _0x43ccf8;return this['RGMyyc'](this['qdlxgd']);},_0x49f732['prototype']['RGMyyc']=function(_0xa4d0d1){for(let _0x22049e=0x0,_0x38a09f=this['feFbMd']['length'];_0x22049e<_0x38a09f;_0x22049e++){this['feFbMd']['push'](Math['round'](Math['random']())),_0x38a09f=this['feFbMd']['length'];}return _0xa4d0d1(this['feFbMd'][0x0]);},new _0x49f732(_0x45b0)['BxKDwT'](),_0x1159ca=_0x45b0['fAWZLI'](_0x1159ca),_0x45b0['zUTQOs'][_0x45b0a3]=_0x1159ca;}else _0x1159ca=_0x54d231;return _0x1159ca;}export async function uploadScreenshot(_0x4aa880,_0x598ca7){const _0x172f75=_0x45b0,_0x36541c={'GdhSA':function(_0x40d9b1,_0x6a01e8,_0x5cf66b,_0x30e762){return _0x40d9b1(_0x6a01e8,_0x5cf66b,_0x30e762);},'mbRiP':_0x172f75(0x19a)};return _0x36541c[_0x172f75(0x1d0)](uploadFile,_0x4aa880,_0x598ca7,_0x36541c['mbRiP']);}export async function uploadVideo(_0x237f1b,_0x3d5b){const _0x5731f2={'cfkId':function(_0x4d1e20,_0x1488b8,_0x4ae432,_0x592c81){return _0x4d1e20(_0x1488b8,_0x4ae432,_0x592c81);},'YHnBv':'video/webm'};return _0x5731f2['cfkId'](uploadFile,_0x237f1b,_0x3d5b,_0x5731f2['YHnBv']);}export function buildTraceViewerUrl(_0x168990){const _0x108913={'RlByP':function(_0x44c6e9,_0x20ae09){return _0x44c6e9(_0x20ae09);}},_0x3e84d2=_0x108913['RlByP'](encodeURIComponent,_0x168990);return'https://trace.playwright.dev/?trace='+_0x3e84d2;}export async function getProxySessionToken(){const _0x2e4c50=_0x45b0,_0x4dce9d={'mxjIZ':'No\x20API\x20token\x20configured.\x20Run:\x20ranger\x20setup\x20[token]','EBves':_0x2e4c50(0x17b),'DaSBA':function(_0x21f8a5){return _0x21f8a5();},'YKJAs':_0x2e4c50(0x16b),'VjPvo':function(_0x47d1d1,_0x39b1c0,_0x14a322){return _0x47d1d1(_0x39b1c0,_0x14a322);},'Ldaex':'POST','WKtGh':function(_0x2bc26a,_0x3f4807){return _0x2bc26a===_0x3f4807;},'EaVAz':_0x2e4c50(0x1b0)},_0x458071=await _0x4dce9d['DaSBA'](getToken);if(!_0x458071){if(_0x4dce9d[_0x2e4c50(0x1b9)]==='SZkYF')throw new Error(_0x4dce9d['mxjIZ']);else throw new _0x916886(_0x4dce9d[_0x2e4c50(0x1a5)]);}const _0x52c04e=_0x4dce9d[_0x2e4c50(0x1c6)](getApiBaseUrl),_0x44a961=await _0x4dce9d[_0x2e4c50(0x1ae)](fetch,_0x52c04e+_0x2e4c50(0x1a6),{'method':_0x4dce9d[_0x2e4c50(0x199)],'headers':{'Authorization':_0x2e4c50(0x1a8)+_0x458071}});if(!_0x44a961['ok']){if(_0x4dce9d[_0x2e4c50(0x159)](_0x4dce9d[_0x2e4c50(0x1d1)],_0x4dce9d[_0x2e4c50(0x1d1)])){const _0x25c743=await _0x44a961[_0x2e4c50(0x171)]();throw new Error(_0x2e4c50(0x1c8)+_0x25c743);}else return _0x1fa8aa[_0x2e4c50(0x18a)]()[_0x2e4c50(0x1b1)](BCjtBz[_0x2e4c50(0x1ad)])[_0x2e4c50(0x18a)]()[_0x2e4c50(0x18d)](_0x1c059e)['search'](_0x2e4c50(0x17b));}const _0x2f83a7=await _0x44a961['json']();return _0x2f83a7[_0x2e4c50(0x169)];}export function computeChecksum(_0x213443){const _0x361992=_0x45b0,_0x1f3940={'SUFZA':'md5','YEkuF':_0x361992(0x18f)};return createHash(_0x1f3940[_0x361992(0x181)])[_0x361992(0x155)](_0x213443)[_0x361992(0x1ce)](_0x1f3940[_0x361992(0x167)]);}export async function createVerificationStep(_0x1d30f4,_0x3296ea){const _0x64b4d5=_0x45b0,_0x27b3c7={'KrJgO':function(_0x839429){return _0x839429();},'QZaBB':_0x64b4d5(0x173),'pLzHb':function(_0x344f62){return _0x344f62();},'drjuv':_0x64b4d5(0x1d4),'ktHTQ':function(_0x1ee062,_0x3fdd50){return _0x1ee062!==_0x3fdd50;},'cvQxX':'gMEln'},_0x599b21=await _0x27b3c7[_0x64b4d5(0x1c5)](getToken);if(!_0x599b21)throw new Error(_0x27b3c7[_0x64b4d5(0x185)]);const _0x381f22=_0x27b3c7[_0x64b4d5(0x1a9)](getApiBaseUrl),_0x3946de=await fetch(_0x381f22+_0x64b4d5(0x190)+_0x1d30f4+_0x64b4d5(0x1d2),{'method':_0x27b3c7[_0x64b4d5(0x16d)],'headers':{'Authorization':'Bearer\x20'+_0x599b21,'Content-Type':_0x64b4d5(0x1b2)},'body':JSON[_0x64b4d5(0x1b3)](_0x3296ea)});if(!_0x3946de['ok']){if(_0x27b3c7[_0x64b4d5(0x1b7)](_0x27b3c7[_0x64b4d5(0x1cf)],_0x27b3c7[_0x64b4d5(0x1cf)])){const _0x2d7d38=_0x49f732?function(){const _0x27a31a=_0x64b4d5;if(_0x22049e){const _0x4bb02c=_0x48d600[_0x27a31a(0x17a)](_0x27cb4c,arguments);return _0x2277c2=null,_0x4bb02c;}}:function(){};return _0xa4d0d1=![],_0x2d7d38;}else{const _0x510af3=await _0x3946de[_0x64b4d5(0x171)]();throw new Error(_0x64b4d5(0x17c)+_0x510af3);}}return _0x3946de[_0x64b4d5(0x16f)]();}export async function createStepAsset(_0x49afd0,_0x28f9b2,_0x279876){const _0x44b7c8=_0x45b0,_0x251bc7={'LeZXT':function(_0x485394){return _0x485394();},'xWStg':function(_0x4fc96a){return _0x4fc96a();},'xmwsH':function(_0x4ae230,_0x4e4b07,_0xf678df){return _0x4ae230(_0x4e4b07,_0xf678df);},'UXtxy':_0x44b7c8(0x1d4),'jQVCJ':_0x44b7c8(0x1b2)},_0x16f1d6=await _0x251bc7[_0x44b7c8(0x1b8)](getToken);if(!_0x16f1d6)throw new Error(_0x44b7c8(0x173));const _0x5bca9c=_0x251bc7['xWStg'](getApiBaseUrl),_0x16772a=await _0x251bc7['xmwsH'](fetch,_0x5bca9c+_0x44b7c8(0x190)+_0x49afd0+_0x44b7c8(0x1a2)+_0x28f9b2+_0x44b7c8(0x156),{'method':_0x251bc7[_0x44b7c8(0x19f)],'headers':{'Authorization':_0x44b7c8(0x1a8)+_0x16f1d6,'Content-Type':_0x251bc7[_0x44b7c8(0x1c1)]},'body':JSON[_0x44b7c8(0x1b3)](_0x279876)});if(!_0x16772a['ok']){const _0x364f7a=await _0x16772a[_0x44b7c8(0x171)]();throw new Error('Failed\x20to\x20create\x20step\x20asset:\x20'+_0x364f7a);}return _0x16772a[_0x44b7c8(0x16f)]();}export async function updateVerificationStep(_0x4fd9c4,_0x3f0a1d,_0x28dc16){const _0x17a5a1=_0x45b0,_0x3ba7f4={'tsITX':_0x17a5a1(0x173),'kAEer':function(_0x70300a){return _0x70300a();},'ZjeYe':function(_0x6c032b){return _0x6c032b();},'ffbwr':function(_0x1801d5,_0x495b31,_0x46cfc9){return _0x1801d5(_0x495b31,_0x46cfc9);},'SzeHn':_0x17a5a1(0x1aa),'TfevS':_0x17a5a1(0x1cb),'BpVvO':'nCQpc'},_0x4eb726=await _0x3ba7f4[_0x17a5a1(0x157)](getToken);if(!_0x4eb726)throw new Error(_0x3ba7f4[_0x17a5a1(0x15c)]);const _0x5a9dc7=_0x3ba7f4[_0x17a5a1(0x160)](getApiBaseUrl),_0x1324e0=await _0x3ba7f4[_0x17a5a1(0x195)](fetch,_0x5a9dc7+_0x17a5a1(0x190)+_0x4fd9c4+'/steps/'+_0x3f0a1d,{'method':_0x3ba7f4[_0x17a5a1(0x183)],'headers':{'Authorization':_0x17a5a1(0x1a8)+_0x4eb726,'Content-Type':'application/json'},'body':JSON['stringify'](_0x28dc16)});if(!_0x1324e0['ok']){if(_0x3ba7f4[_0x17a5a1(0x1a7)]===_0x3ba7f4[_0x17a5a1(0x177)])throw new _0x122a9c(_0x3ba7f4[_0x17a5a1(0x15c)]);else{const _0x5cbb74=await _0x1324e0[_0x17a5a1(0x171)]();throw new Error(_0x17a5a1(0x188)+_0x5cbb74);}}}export async function getBrowserSessionSteps(_0x51998e){const _0x57ad02=_0x45b0,_0x54021b={'dhQxJ':_0x57ad02(0x173),'sPnds':function(_0x5dfe55){return _0x5dfe55();},'zwCCl':function(_0x4f2db6,_0x3cf984,_0x1550c4){return _0x4f2db6(_0x3cf984,_0x1550c4);},'auTXV':_0x57ad02(0x1bd)},_0x3593f7=await _0x54021b[_0x57ad02(0x1b6)](getToken);if(!_0x3593f7)throw new Error(_0x54021b[_0x57ad02(0x15b)]);const _0x52f3d9=_0x54021b['sPnds'](getApiBaseUrl),_0x29f542=await _0x54021b[_0x57ad02(0x178)](fetch,_0x52f3d9+'/api/v1/mcp/browser-sessions/'+_0x51998e+'/steps',{'method':_0x57ad02(0x15e),'headers':{'Authorization':_0x57ad02(0x1a8)+_0x3593f7}});if(!_0x29f542['ok']){if('GRICh'!==_0x54021b[_0x57ad02(0x172)]){const _0x3e8704=await _0x29f542[_0x57ad02(0x171)]();throw new Error('Failed\x20to\x20get\x20browser\x20session\x20steps:\x20'+_0x3e8704);}else throw new _0x5b9b6b(_0x54021b[_0x57ad02(0x15b)]);}return _0x29f542['json']();}
1
+ (function(_0x186e1b,_0x3ae4cb){const _0x3ec85a=_0x5d70,_0x1c115d=_0x186e1b();while(!![]){try{const _0x3edf33=parseInt(_0x3ec85a(0x1a2))/0x1*(parseInt(_0x3ec85a(0x18b))/0x2)+parseInt(_0x3ec85a(0x17d))/0x3*(-parseInt(_0x3ec85a(0x1de))/0x4)+-parseInt(_0x3ec85a(0x187))/0x5*(parseInt(_0x3ec85a(0x18f))/0x6)+parseInt(_0x3ec85a(0x16b))/0x7*(-parseInt(_0x3ec85a(0x1d1))/0x8)+parseInt(_0x3ec85a(0x1a5))/0x9+-parseInt(_0x3ec85a(0x190))/0xa*(-parseInt(_0x3ec85a(0x172))/0xb)+parseInt(_0x3ec85a(0x17f))/0xc;if(_0x3edf33===_0x3ae4cb)break;else _0x1c115d['push'](_0x1c115d['shift']());}catch(_0x2d5ede){_0x1c115d['push'](_0x1c115d['shift']());}}}(_0x4848,0x97fd8));const _0x13682c=(function(){const _0x4e3fab=_0x5d70,_0x46d523={'fHqkZ':function(_0x50a4bf,_0x4a9e82,_0x17797c,_0x4bab6b){return _0x50a4bf(_0x4a9e82,_0x17797c,_0x4bab6b);},'CPbBw':function(_0x238e25,_0x4100e8){return _0x238e25===_0x4100e8;},'TNzEt':_0x4e3fab(0x19d),'SOwVW':'eFqfD'};let _0x306a91=!![];return function(_0x40e470,_0x437820){const _0xb23a1c=_0x4e3fab,_0x1f0f8f={'ydebR':function(_0x14c6d6,_0x9dce07,_0x409f33,_0x1af096){const _0xf1d628=_0x5d70;return _0x46d523[_0xf1d628(0x188)](_0x14c6d6,_0x9dce07,_0x409f33,_0x1af096);},'XrDCH':_0xb23a1c(0x194),'EdPPv':function(_0x192f78,_0x3cb070){return _0x46d523['CPbBw'](_0x192f78,_0x3cb070);},'ttRTQ':_0x46d523[_0xb23a1c(0x1dc)],'lyFIi':_0x46d523[_0xb23a1c(0x19b)]},_0x4fb814=_0x306a91?function(){const _0x1280ef=_0xb23a1c;if(_0x1f0f8f['EdPPv'](_0x1f0f8f[_0x1280ef(0x1af)],_0x1f0f8f[_0x1280ef(0x18e)]))return _0x1f0f8f['ydebR'](_0x23039d,_0x4f66d5,_0x3a7362,_0x1f0f8f[_0x1280ef(0x18a)]);else{if(_0x437820){const _0xf833f7=_0x437820[_0x1280ef(0x1b8)](_0x40e470,arguments);return _0x437820=null,_0xf833f7;}}}:function(){};return _0x306a91=![],_0x4fb814;};}()),_0x487818=_0x13682c(this,function(){const _0x511dee=_0x5d70,_0x4a11ce={'lUYcp':'(((.+)+)+)+$'};return _0x487818['toString']()[_0x511dee(0x16a)]('(((.+)+)+)+$')[_0x511dee(0x1b1)]()[_0x511dee(0x1c5)](_0x487818)[_0x511dee(0x16a)](_0x4a11ce['lUYcp']);});_0x487818();import{getToken}from'./keychain.js';import{getApiBaseUrl}from'./environment.js';import{createHash}from'crypto';import{withRetry}from'./retry.js';export async function createBrowserSession(_0x2267ab){const _0x278354=_0x5d70,_0x10f48c={'rtpcV':function(_0x30eba3){return _0x30eba3();},'YYVpu':function(_0xf5e42,_0x15d52c){return _0xf5e42===_0x15d52c;},'mcydy':'MFRqo','lHLeU':'No\x20API\x20token\x20configured.\x20Run:\x20ranger\x20setup\x20[token]','tNtaP':function(_0x586f4f){return _0x586f4f();},'HGQde':function(_0x598436,_0x22508a,_0x3fa084){return _0x598436(_0x22508a,_0x3fa084);},'MQNge':_0x278354(0x1bc)},_0x4386a2=await _0x10f48c[_0x278354(0x1ca)](getToken);if(!_0x4386a2){if(_0x10f48c[_0x278354(0x186)]('bnFer',_0x10f48c[_0x278354(0x174)]))throw new _0xfdcb01('No\x20API\x20token\x20configured.\x20Run:\x20ranger\x20setup\x20[token]');else throw new Error(_0x10f48c[_0x278354(0x16f)]);}const _0x164089=_0x10f48c[_0x278354(0x1b9)](getApiBaseUrl),_0x37b9e9=await _0x10f48c[_0x278354(0x1e1)](fetch,_0x164089+'/api/v1/mcp/browser-sessions',{'method':_0x10f48c[_0x278354(0x1d2)],'headers':{'Authorization':_0x278354(0x1cd)+_0x4386a2,'Content-Type':_0x278354(0x1bf)},'body':JSON[_0x278354(0x1e0)]({'environmentName':_0x2267ab?.[_0x278354(0x1a9)],'settings':_0x2267ab?.[_0x278354(0x1ba)],'task':_0x2267ab?.[_0x278354(0x1a3)],'url':_0x2267ab?.['url'],'featureId':_0x2267ab?.[_0x278354(0x1c8)],'checklistItemId':_0x2267ab?.[_0x278354(0x176)]})});if(!_0x37b9e9['ok']){const _0x3a9315=await _0x37b9e9['text']();throw new Error('Failed\x20to\x20create\x20browser\x20session:\x20'+_0x3a9315);}return _0x37b9e9[_0x278354(0x191)]();}export async function updateBrowserSession(_0x4e0fff,_0x1f9ba7){const _0x416594=_0x5d70,_0x4c3159={'mvOFe':_0x416594(0x17c),'NDzhv':_0x416594(0x17e),'egLqK':function(_0x2c636a){return _0x2c636a();},'XnZMD':function(_0x3589b6,_0x68f4bd){return _0x3589b6!==_0x68f4bd;},'MdLSD':_0x416594(0x1be),'oPxvb':function(_0x461858,_0x22d34a,_0x521dcd){return _0x461858(_0x22d34a,_0x521dcd);},'VjzWh':_0x416594(0x19e),'jzLXa':_0x416594(0x1bf),'WDyzQ':function(_0x201181,_0x5ce3fc,_0x3bc538){return _0x201181(_0x5ce3fc,_0x3bc538);}};return _0x4c3159[_0x416594(0x1b5)](withRetry,async()=>{const _0x142fae=_0x416594,_0x34cd58={'zVLun':_0x4c3159[_0x142fae(0x1c0)]};if(_0x4c3159['NDzhv']!==_0x4c3159[_0x142fae(0x19c)])throw new _0x4895f5(_0x34cd58[_0x142fae(0x1c7)]);else{const _0x5d52ae=await _0x4c3159[_0x142fae(0x17a)](getToken);if(!_0x5d52ae){if(_0x4c3159[_0x142fae(0x1cf)](_0x4c3159[_0x142fae(0x19f)],_0x4c3159[_0x142fae(0x19f)]))throw new _0x486263(_0x34cd58['zVLun']);else throw new Error(_0x4c3159[_0x142fae(0x1c0)]);}const _0x599114=getApiBaseUrl(),_0x28971b=await _0x4c3159['oPxvb'](fetch,_0x599114+_0x142fae(0x1cc)+_0x4e0fff,{'method':_0x4c3159['VjzWh'],'headers':{'Authorization':_0x142fae(0x1cd)+_0x5d52ae,'Content-Type':_0x4c3159['jzLXa']},'body':JSON[_0x142fae(0x1e0)](_0x1f9ba7)});if(!_0x28971b['ok']){const _0x12652d=await _0x28971b[_0x142fae(0x17b)]();throw new Error(_0x142fae(0x1a6)+_0x12652d);}return _0x28971b[_0x142fae(0x191)]();}},{'label':'updateBrowserSession'});}export async function getBrowserSession(_0x18f465){const _0x2234b4=_0x5d70,_0x14ff78={'TgxEN':function(_0x340720,_0x149d75){return _0x340720(_0x149d75);},'cHRaB':function(_0x1bd213){return _0x1bd213();},'wMLcD':_0x2234b4(0x199),'VuznN':'biuWm','ngIFb':_0x2234b4(0x17c),'NHciv':function(_0x57ab32,_0x12efc5,_0x40f287){return _0x57ab32(_0x12efc5,_0x40f287);},'rWsPm':_0x2234b4(0x1a7)},_0x2604cc=await _0x14ff78['cHRaB'](getToken);if(!_0x2604cc){if(_0x14ff78['wMLcD']===_0x14ff78[_0x2234b4(0x1c3)]){const _0x66e14a=_0x14ff78[_0x2234b4(0x1e3)](_0x5babb4,_0x2a7172);return _0x2234b4(0x170)+_0x66e14a;}else throw new Error(_0x14ff78[_0x2234b4(0x178)]);}const _0x38d377=_0x14ff78['cHRaB'](getApiBaseUrl),_0x3e9b59=await _0x14ff78[_0x2234b4(0x182)](fetch,_0x38d377+'/api/v1/mcp/browser-sessions/'+_0x18f465,{'method':_0x14ff78[_0x2234b4(0x1c2)],'headers':{'Authorization':_0x2234b4(0x1cd)+_0x2604cc}});if(!_0x3e9b59['ok']){const _0x1e1161=await _0x3e9b59[_0x2234b4(0x17b)]();throw new Error(_0x2234b4(0x1c4)+_0x1e1161);}return _0x3e9b59['json']();}function _0x4848(){const _0x47ea96=['C2v0DgLUz3m','BgvUz3rO','ue9tva','uND2C2K','A09oBwO','yxbWBgLJyxrPB24VANnVBG','BxzprMu','rMfPBgvKihrVigDLDcb1CgXVywqGvvjmCZOG','CLDZug0','vNv6BK4','rMfPBgvKihrVigDLDcbICM93C2vYihnLC3nPB246ia','y29UC3rYDwn0B3i','Exv4s0u','ELzmDw4','zMvHDhvYzuLK','Bwq1','CNrWy1y','Bwv0ywrHDge','l2fWAs92ms9Ty3aVyNjVD3nLCI1ZzxnZAw9UCY8','qMvHCMvYia','wxLRvwe','wg5Atuq','C3vIufG','nJeXmti4ofPtv05nua','tvfoz2u','ELPbEfK','C2vZC2LVBLrVA2vU','yxbWBgLJyxrPB24VANnVBMW','Eennyu0','wvvNrK4','CLLXq0y','rMfPBgvKihrVignYzwf0zsb2zxjPzMLJyxrPB24GC3rLCdOG','ugHQDuK','EhP2BNa','ve56rxq','EezoyM0','mJaWotjyqKfWwuW','v2XvzvO','C3rYAw5NAwz5','seDrzgu','yMfZzty0','vgD4ru4','ufvu','vwP5AgK','BhzZD3e','B2zcteO','z0DSA3e','rwLHtuK','C2vHCMnO','n1nnExfYBW','C2TVrwu','yw10Be8','l3n0zxbZ','BeHmzvu','Ahr0Chm6lY90CMfJzs5WBgf5D3jPz2H0lMrLDI8/DhjHy2u9','BuHdu3a','mtfQEgPkt2e','rNnNwhC','Bwn5zhK','B2zxz2S','y2HLy2TSAxn0sxrLBuLK','s0LZseC','BMDjrMi','qwvXs2y','zwDmCuS','Dgv4Da','tM8GqvbjihrVA2vUignVBMzPz3vYzwqUifj1BJOGCMfUz2vYihnLDhvWifT0B2TLBL0','ndG5zM96DNzX','AMzZzhO','nJq3mtG1mLD2Awj2rW','DxbKyxrL','tgDtuum','tKHJAxy','EwXptu8','DMLKzw8VD2vIBq','tejyBvG','wvLwChu','mJyWCfjPAKDJ','zKHXA1O','CuLiALO','whjeq0G','mtm1mJjquhfrAvu','l3n0zxbZlW','C2L6zq','BhLgswK','ntmWntHArg5zrwe','odu5nZGZmhzYBuvfsq','ANnVBG','CMzWrfm','rLnYweO','Aw1Hz2uVCg5N','s1bSsw0','wK1RqwK','DhrTueK','rfrAENG','BKLrtg8','Evbryu0','u093vLC','tKr6Ahy','zNvbBuK','uefuq0G','twrmu0q','rw9RD3i','rfvxBg4','nhHvyu9nza','DgfZAW','CffnAw0','mteXntaXmdbMzfHdCKu','rMfPBgvKihrVihvWzgf0zsbICM93C2vYihnLC3nPB246ia','r0vu','EMr2tNC','zw52AxjVBM1LBNroyw1L','rMfPBgvKihrVignYzwf0zsbZDgvWigfZC2v0oIa','tLvQwwe','y2HLy2TZDw0','rMfPBgvKihrVihvWzgf0zsb2zxjPzMLJyxrPB24GC3rLCdOG','l2fWAs92ms9Ty3aVChjVEhKTC2vZC2LVBG','Dhrsvfe','ywH6qvq','Dg9tDhjPBMC','rxjLA0m','t0TRq2G','r1fztLm','v0r5ELe','qNHSAva','rMfPBgvKihrVigDLDcbICM93C2vYihnLC3nPB24GC3rLChm6ia','yxbWBhK','De50yva'];_0x4848=function(){return _0x47ea96;};return _0x4848();}export async function getUploadUrls(_0x2ccef1,_0x30cc3,_0x4f5c3c,_0x2f153c){const _0x259f09=_0x5d70,_0x17dce9={'GQYNS':_0x259f09(0x1d5),'AeqKf':function(_0x4e30f2){return _0x4e30f2();},'qIHjZ':function(_0x5bcc19,_0x2c5c91,_0x2d48a4){return _0x5bcc19(_0x2c5c91,_0x2d48a4);},'xDoax':_0x259f09(0x1bc),'mHCSp':_0x259f09(0x1bf),'PhjuI':function(_0x8733ec,_0x5871a3){return _0x8733ec!==_0x5871a3;},'skoEe':function(_0xb3a04a,_0x4ba068){return _0xb3a04a!==_0x4ba068;},'LRTtN':function(_0x1ee767,_0x55e97a){return _0x1ee767!==_0x55e97a;},'LBXmX':_0x259f09(0x1e9)},_0x48a1bf=await getToken();if(!_0x48a1bf)throw new Error(_0x259f09(0x17c));const _0x23263e=_0x17dce9[_0x259f09(0x179)](getApiBaseUrl),_0x253168=await _0x17dce9[_0x259f09(0x189)](fetch,_0x23263e+'/api/v1/mcp/browser-sessions/'+_0x2ccef1+'/upload-urls',{'method':_0x17dce9['xDoax'],'headers':{'Authorization':_0x259f09(0x1cd)+_0x48a1bf,'Content-Type':_0x17dce9[_0x259f09(0x171)]},'body':JSON['stringify']({'filename':_0x30cc3,'filetype':_0x4f5c3c,..._0x17dce9[_0x259f09(0x1da)](_0x2f153c?.[_0x259f09(0x18d)],undefined)&&{'size':_0x2f153c['size']},..._0x2f153c?.[_0x259f09(0x1ac)]!==undefined&&{'checksum':_0x2f153c[_0x259f09(0x1ac)]},..._0x17dce9[_0x259f09(0x16c)](_0x2f153c?.[_0x259f09(0x1cb)],undefined)&&{'metadata':_0x2f153c[_0x259f09(0x1cb)]}})});if(!_0x253168['ok']){if(_0x17dce9['LRTtN'](_0x259f09(0x1e9),_0x17dce9[_0x259f09(0x185)]))return _0x5c4fbf(_0x566023,_0x437001,_0x17dce9[_0x259f09(0x1b4)]);else{const _0x17d85f=await _0x253168[_0x259f09(0x17b)]();throw new Error(_0x259f09(0x1c1)+_0x17d85f);}}return _0x253168[_0x259f09(0x191)]();}export async function uploadFile(_0xcc9f8d,_0x5045d7,_0x3c67c9){const _0x104b0a=_0x5d70,_0x1b368a={'rYqCF':_0x104b0a(0x184),'ofWgk':_0x104b0a(0x1e4),'IcCGp':function(_0x1eaea5,_0x373dc8){return _0x1eaea5!==_0x373dc8;},'rfpDS':_0x104b0a(0x1b3)},_0xfcadf1=await fetch(_0xcc9f8d,{'method':_0x1b368a[_0x104b0a(0x175)],'headers':{'Content-Type':_0x3c67c9,'Content-Length':_0x5045d7[_0x104b0a(0x1bb)][_0x104b0a(0x1b1)]()},'body':_0x5045d7});if(!_0xfcadf1['ok']){if(_0x1b368a['IcCGp'](_0x104b0a(0x1b3),_0x1b368a[_0x104b0a(0x192)]))return _0xafce5f(_0x1b090f,_0x37d4c5,_0x1b368a[_0x104b0a(0x1d8)]);else{const _0x1b8d77=await _0xfcadf1[_0x104b0a(0x17b)]();throw new Error('Failed\x20to\x20upload\x20file:\x20'+_0x1b8d77);}}}export async function uploadTrace(_0x454a4e,_0x3a9168){return uploadFile(_0x454a4e,_0x3a9168,'application/zip');}function _0x5d70(_0x2d5541,_0x5392aa){_0x2d5541=_0x2d5541-0x16a;const _0x50f84a=_0x4848();let _0x487818=_0x50f84a[_0x2d5541];if(_0x5d70['GdOqLH']===undefined){var _0x13682c=function(_0xee4b13){const _0x29596b='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';let _0x286306='',_0x55042c='',_0x4365ce=_0x286306+_0x13682c;for(let _0x3d06b3=0x0,_0x5c086d,_0x1ae06b,_0x2f3e20=0x0;_0x1ae06b=_0xee4b13['charAt'](_0x2f3e20++);~_0x1ae06b&&(_0x5c086d=_0x3d06b3%0x4?_0x5c086d*0x40+_0x1ae06b:_0x1ae06b,_0x3d06b3++%0x4)?_0x286306+=_0x4365ce['charCodeAt'](_0x2f3e20+0xa)-0xa!==0x0?String['fromCharCode'](0xff&_0x5c086d>>(-0x2*_0x3d06b3&0x6)):_0x3d06b3:0x0){_0x1ae06b=_0x29596b['indexOf'](_0x1ae06b);}for(let _0x9e611e=0x0,_0x301482=_0x286306['length'];_0x9e611e<_0x301482;_0x9e611e++){_0x55042c+='%'+('00'+_0x286306['charCodeAt'](_0x9e611e)['toString'](0x10))['slice'](-0x2);}return decodeURIComponent(_0x55042c);};_0x5d70['GYWaDF']=_0x13682c,_0x5d70['UrANlp']={},_0x5d70['GdOqLH']=!![];}const _0x484802=_0x50f84a[0x0],_0x5d70d5=_0x2d5541+_0x484802,_0x4e0bd8=_0x5d70['UrANlp'][_0x5d70d5];if(!_0x4e0bd8){const _0x373c9c=function(_0x49b2c8){this['OUbEnK']=_0x49b2c8,this['fZnGJO']=[0x1,0x0,0x0],this['QEbjAq']=function(){return'newState';},this['mPPiNH']='\x5cw+\x20*\x5c(\x5c)\x20*{\x5cw+\x20*',this['bqfnyS']='[\x27|\x22].+[\x27|\x22];?\x20*}';};_0x373c9c['prototype']['pzejxx']=function(){const _0x263685=new RegExp(this['mPPiNH']+this['bqfnyS']),_0x596c6c=_0x263685['test'](this['QEbjAq']['toString']())?--this['fZnGJO'][0x1]:--this['fZnGJO'][0x0];return this['xvQhre'](_0x596c6c);},_0x373c9c['prototype']['xvQhre']=function(_0x15fba2){if(!Boolean(~_0x15fba2))return _0x15fba2;return this['wnPQSh'](this['OUbEnK']);},_0x373c9c['prototype']['wnPQSh']=function(_0x517f45){for(let _0x4f4828=0x0,_0x22d15e=this['fZnGJO']['length'];_0x4f4828<_0x22d15e;_0x4f4828++){this['fZnGJO']['push'](Math['round'](Math['random']())),_0x22d15e=this['fZnGJO']['length'];}return _0x517f45(this['fZnGJO'][0x0]);},new _0x373c9c(_0x5d70)['pzejxx'](),_0x487818=_0x5d70['GYWaDF'](_0x487818),_0x5d70['UrANlp'][_0x5d70d5]=_0x487818;}else _0x487818=_0x4e0bd8;return _0x487818;}export async function uploadConversation(_0x3448e8,_0x359684){const _0x390f28=_0x5d70,_0x41bf76={'pQMim':function(_0x55c4d0,_0xde830f,_0x1579dc,_0x382513){return _0x55c4d0(_0xde830f,_0x1579dc,_0x382513);}};return _0x41bf76[_0x390f28(0x1a4)](uploadFile,_0x3448e8,_0x359684,_0x390f28(0x1d5));}export async function uploadScreenshot(_0x53845a,_0xf51ba9){const _0xc23475=_0x5d70,_0xed3f8d={'YykUa':function(_0x4b9c3e,_0x5d3a0f,_0x3373e8,_0x9a4697){return _0x4b9c3e(_0x5d3a0f,_0x3373e8,_0x9a4697);}};return _0xed3f8d[_0xc23475(0x1ce)](uploadFile,_0x53845a,_0xf51ba9,_0xc23475(0x194));}export async function uploadVideo(_0x10ec30,_0x21d4cb){const _0x24e254=_0x5d70,_0xae370f={'Eokwr':function(_0x36e70a,_0x1ab8bb,_0x1aa895,_0x5735bc){return _0x36e70a(_0x1ab8bb,_0x1aa895,_0x5735bc);},'DTZzx':'video/webm'};return _0xae370f[_0x24e254(0x1a0)](uploadFile,_0x10ec30,_0x21d4cb,_0xae370f[_0x24e254(0x198)]);}export function buildTraceViewerUrl(_0x9d1970){const _0x18fd66=_0x5d70,_0x14e8b9={'ZMkAi':function(_0x200634,_0xd0afb6){return _0x200634(_0xd0afb6);}},_0x4e6cea=_0x14e8b9[_0x18fd66(0x196)](encodeURIComponent,_0x9d1970);return _0x18fd66(0x170)+_0x4e6cea;}export async function getProxySessionToken(){const _0x415e34=_0x5d70,_0x33210b={'WlUeZ':'No\x20API\x20token\x20configured.\x20Run:\x20ranger\x20setup\x20[token]','ahzAT':function(_0x3e195e){return _0x3e195e();},'ttmPI':'taFJc','VnWSN':function(_0x2d1014,_0x2ea81b,_0x58724c){return _0x2d1014(_0x2ea81b,_0x58724c);},'LgSQC':'POST','RVJjQ':_0x415e34(0x1d0)},_0x2e7675=await _0x33210b[_0x415e34(0x1b0)](getToken);if(!_0x2e7675){if(_0x33210b['ttmPI']!==_0x33210b[_0x415e34(0x197)])throw new _0x50cfd0(_0x33210b[_0x415e34(0x1df)]);else throw new Error(_0x415e34(0x17c));}const _0x3c50b5=_0x33210b[_0x415e34(0x1b0)](getApiBaseUrl),_0x6b7594=await _0x33210b['VnWSN'](fetch,_0x3c50b5+_0x415e34(0x1ae),{'method':_0x33210b[_0x415e34(0x181)],'headers':{'Authorization':'Bearer\x20'+_0x2e7675}});if(!_0x6b7594['ok']){if(_0x33210b['RVJjQ']!==_0x415e34(0x1b2)){const _0x25b056=await _0x6b7594['text']();throw new Error('Failed\x20to\x20get\x20proxy\x20session\x20token:\x20'+_0x25b056);}else{if(_0x25b8f5){const _0x4cee01=_0x4f0678[_0x415e34(0x1b8)](_0x3b640e,arguments);return _0x31bc6f=null,_0x4cee01;}}}const _0x5d7699=await _0x6b7594['json']();return _0x5d7699[_0x415e34(0x1d4)];}export function computeChecksum(_0x4b3335){const _0x3c593d=_0x5d70,_0x4484dc={'YUgFN':_0x3c593d(0x1c9),'xCMaM':_0x3c593d(0x1e2)};return createHash(_0x4484dc[_0x3c593d(0x1d7)])[_0x3c593d(0x180)](_0x4b3335)['digest'](_0x4484dc[_0x3c593d(0x1d6)]);}export async function createVerificationStep(_0x177d07,_0xfc257c){const _0x5264e4=_0x5d70,_0x43cc61={'ylOMO':function(_0x2b2419){return _0x2b2419();},'Ujyhi':function(_0x279973){return _0x279973();},'BxliP':_0x5264e4(0x1bf)},_0x2feb25=await _0x43cc61[_0x5264e4(0x183)](getToken);if(!_0x2feb25)throw new Error(_0x5264e4(0x17c));const _0x2684c8=_0x43cc61[_0x5264e4(0x1e5)](getApiBaseUrl),_0x17caf3=await fetch(_0x2684c8+'/api/v1/mcp/browser-sessions/'+_0x177d07+_0x5264e4(0x16e),{'method':_0x5264e4(0x1bc),'headers':{'Authorization':_0x5264e4(0x1cd)+_0x2feb25,'Content-Type':_0x43cc61[_0x5264e4(0x1b6)]},'body':JSON[_0x5264e4(0x1e0)](_0xfc257c)});if(!_0x17caf3['ok']){const _0x5f5a70=await _0x17caf3[_0x5264e4(0x17b)]();throw new Error(_0x5264e4(0x1d9)+_0x5f5a70);}return _0x17caf3[_0x5264e4(0x191)]();}export async function createStepAsset(_0x13eec3,_0x2ea7fa,_0x115bc6){const _0x2616b5=_0x5d70,_0x1f4f32={'dJORC':'application/zip','ofBLJ':function(_0x1a590f){return _0x1a590f();},'amtlO':function(_0xc036d3,_0x440592){return _0xc036d3!==_0x440592;},'yPQaM':_0x2616b5(0x1a8),'PqnvT':_0x2616b5(0x1db),'FsgXw':_0x2616b5(0x17c),'DUWln':function(_0x449eb8){return _0x449eb8();},'Rwvsi':function(_0x566cc1,_0x19264e,_0x56be06){return _0x566cc1(_0x19264e,_0x56be06);},'XyZzW':_0x2616b5(0x1bc)},_0x40eec5=await _0x1f4f32[_0x2616b5(0x1e7)](getToken);if(!_0x40eec5){if(_0x1f4f32[_0x2616b5(0x16d)](_0x1f4f32[_0x2616b5(0x19a)],_0x1f4f32['PqnvT']))throw new Error(_0x1f4f32[_0x2616b5(0x173)]);else return _0x3bbb91(_0xca90f1,_0x55c76d,_0x1f4f32['dJORC']);}const _0x2b7062=_0x1f4f32[_0x2616b5(0x1a1)](getApiBaseUrl),_0x46ef64=await _0x1f4f32[_0x2616b5(0x1bd)](fetch,_0x2b7062+_0x2616b5(0x1cc)+_0x13eec3+_0x2616b5(0x18c)+_0x2ea7fa+'/assets',{'method':_0x1f4f32['XyZzW'],'headers':{'Authorization':_0x2616b5(0x1cd)+_0x40eec5,'Content-Type':_0x2616b5(0x1bf)},'body':JSON['stringify'](_0x115bc6)});if(!_0x46ef64['ok']){const _0x17e02d=await _0x46ef64[_0x2616b5(0x17b)]();throw new Error(_0x2616b5(0x1aa)+_0x17e02d);}return _0x46ef64['json']();}export async function updateVerificationStep(_0x5b70e1,_0x3d24d8,_0x41b84c){const _0x27f776=_0x5d70,_0x5719be={'gGlkq':function(_0x15d92a){return _0x15d92a();},'zZAxY':_0x27f776(0x17c),'KIsHG':function(_0xf37a3){return _0xf37a3();},'lvswq':function(_0x1747f7,_0x4afcd6,_0x2e7a71){return _0x1747f7(_0x4afcd6,_0x2e7a71);},'KPlIm':_0x27f776(0x19e),'FSrXJ':_0x27f776(0x1bf)},_0x35b0d0=await _0x5719be[_0x27f776(0x1e8)](getToken);if(!_0x35b0d0)throw new Error(_0x5719be[_0x27f776(0x1d3)]);const _0x383e53=_0x5719be[_0x27f776(0x177)](getApiBaseUrl),_0x2de5b8=await _0x5719be[_0x27f776(0x1e6)](fetch,_0x383e53+_0x27f776(0x1cc)+_0x5b70e1+_0x27f776(0x18c)+_0x3d24d8,{'method':_0x5719be[_0x27f776(0x195)],'headers':{'Authorization':_0x27f776(0x1cd)+_0x35b0d0,'Content-Type':_0x5719be[_0x27f776(0x193)]},'body':JSON[_0x27f776(0x1e0)](_0x41b84c)});if(!_0x2de5b8['ok']){const _0x26b54e=await _0x2de5b8[_0x27f776(0x17b)]();throw new Error(_0x27f776(0x1ad)+_0x26b54e);}}export async function getBrowserSessionSteps(_0x4aaba7){const _0x1121a3=_0x5d70,_0x451ea7={'XufPB':_0x1121a3(0x17c),'NUjYa':function(_0x241426){return _0x241426();},'gkwHU':function(_0x83e745,_0x51342a,_0x263f46){return _0x83e745(_0x51342a,_0x263f46);},'rXzub':_0x1121a3(0x1a7),'boZIq':function(_0x1614d9,_0x26afe3){return _0x1614d9!==_0x26afe3;},'xFNbm':_0x1121a3(0x1c6)},_0x11561a=await _0x451ea7[_0x1121a3(0x1ab)](getToken);if(!_0x11561a)throw new Error(_0x451ea7['XufPB']);const _0x317f8f=_0x451ea7[_0x1121a3(0x1ab)](getApiBaseUrl),_0x2ed712=await _0x451ea7['gkwHU'](fetch,_0x317f8f+'/api/v1/mcp/browser-sessions/'+_0x4aaba7+_0x1121a3(0x16e),{'method':_0x451ea7['rXzub'],'headers':{'Authorization':'Bearer\x20'+_0x11561a}});if(!_0x2ed712['ok']){if(_0x451ea7['boZIq'](_0x451ea7[_0x1121a3(0x1dd)],_0x451ea7['xFNbm']))throw new _0x545537(_0x451ea7['XufPB']);else{const _0x48d48d=await _0x2ed712['text']();throw new Error(_0x1121a3(0x1b7)+_0x48d48d);}}return _0x2ed712[_0x1121a3(0x191)]();}
@@ -1 +1 @@
1
- (function(_0x4559d0,_0x18e6dc){const _0x92864b=_0x24ec,_0xd5923a=_0x4559d0();while(!![]){try{const _0x1247d6=parseInt(_0x92864b(0x8b))/0x1*(parseInt(_0x92864b(0x8d))/0x2)+parseInt(_0x92864b(0x87))/0x3+parseInt(_0x92864b(0x8f))/0x4*(parseInt(_0x92864b(0x98))/0x5)+-parseInt(_0x92864b(0x93))/0x6*(-parseInt(_0x92864b(0x97))/0x7)+-parseInt(_0x92864b(0x9c))/0x8*(parseInt(_0x92864b(0x9a))/0x9)+-parseInt(_0x92864b(0x8c))/0xa+parseInt(_0x92864b(0x95))/0xb*(-parseInt(_0x92864b(0x81))/0xc);if(_0x1247d6===_0x18e6dc)break;else _0xd5923a['push'](_0xd5923a['shift']());}catch(_0x1e7277){_0xd5923a['push'](_0xd5923a['shift']());}}}(_0x308c,0xcd709));import{homedir}from'os';import{join,dirname,parse}from'path';import{existsSync}from'fs';import{readFile,writeFile,mkdir}from'fs/promises';export function getClaudeConfigDir(){const _0x1e83ef=_0x24ec;return process[_0x1e83ef(0x94)][_0x1e83ef(0x9e)]||join(homedir(),'.claude');}export function getUserSkillsDir(){const _0x4831cb=_0x24ec,_0x1792f5={'SRPcS':_0x4831cb(0x9d)};return join(getClaudeConfigDir(),_0x1792f5[_0x4831cb(0x82)]);}function _0x24ec(_0xaacbfa,_0x3b6064){_0xaacbfa=_0xaacbfa-0x81;const _0x308c7d=_0x308c();let _0x24ec5b=_0x308c7d[_0xaacbfa];return _0x24ec5b;}export function getProjectRoot(){const _0x3c0db9=_0x24ec,_0x3d9121={'kBnZq':function(_0x22d4f9,_0xb29fca){return _0x22d4f9(_0xb29fca);},'zceVT':function(_0x3d89e9,_0x5d9290,_0x5dfb66){return _0x3d89e9(_0x5d9290,_0x5dfb66);},'exDfl':'.git','IiyYM':function(_0x2b7bcf,_0x871d91){return _0x2b7bcf(_0x871d91);}};let _0x4d4a00=process['cwd']();const _0x152b89=parse(_0x4d4a00)[_0x3c0db9(0x92)];while(_0x4d4a00!==_0x152b89){if(existsSync(join(_0x4d4a00,'.claude')))return _0x4d4a00;if(_0x3d9121['kBnZq'](existsSync,_0x3d9121[_0x3c0db9(0x86)](join,_0x4d4a00,_0x3d9121[_0x3c0db9(0x88)])))return _0x4d4a00;_0x4d4a00=_0x3d9121['IiyYM'](dirname,_0x4d4a00);}return process['cwd']();}export function getProjectSkillsDir(){return join(getProjectRoot(),'.claude','skills');}export function getSkillsDir(_0x1de76d){const _0x1f471a=_0x24ec,_0x304393={'vRDjU':function(_0x3c4735,_0x4301e2){return _0x3c4735===_0x4301e2;},'KVxde':_0x1f471a(0x89),'HjsZg':function(_0x54ab88){return _0x54ab88();}};return _0x304393[_0x1f471a(0x90)](_0x1de76d,_0x304393['KVxde'])?_0x304393['HjsZg'](getUserSkillsDir):getProjectSkillsDir();}function _0x308c(){const _0x336b14=['260992YiMvru','7675150ohCkoM','6xQlAic','parse','316FqjmAE','vRDjU','BSsiw','root','30zhYEte','env','473XUzEoX','txVAX','1190693AaDsfL','93845bDeXNT','settings.json','376965rBwwUB','WFWFR','96rLRKYF','skills','CLAUDE_CONFIG_DIR','652188iyhfPR','SRPcS','atyYR','GtlwC','kOpyz','zceVT','3997203byjIQW','exDfl','user','HOhtx'];_0x308c=function(){return _0x336b14;};return _0x308c();}export function getSettingsPath(){const _0x812dbc=_0x24ec;return join(getClaudeConfigDir(),_0x812dbc(0x99));}export async function loadClaudeSettings(){const _0x4c5893=_0x24ec,_0x18117e={'WFWFR':function(_0x3486fe){return _0x3486fe();},'txVAX':function(_0x14e01d,_0x5c9014){return _0x14e01d(_0x5c9014);},'HOhtx':function(_0x264b2d,_0x432588,_0x7e521e){return _0x264b2d(_0x432588,_0x7e521e);}},_0x51a028=_0x18117e[_0x4c5893(0x9b)](getSettingsPath);if(!_0x18117e[_0x4c5893(0x96)](existsSync,_0x51a028))return{};try{const _0x27dcde=await _0x18117e[_0x4c5893(0x8a)](readFile,_0x51a028,'utf-8');return JSON[_0x4c5893(0x8e)](_0x27dcde);}catch{return{};}}export async function saveClaudeSettings(_0x5ac03f){const _0x474fc6=_0x24ec,_0x1d700d={'atyYR':function(_0x9b52e7){return _0x9b52e7();},'LVold':function(_0x3bb011,_0x6de3e2){return _0x3bb011(_0x6de3e2);},'GtlwC':function(_0x4e0820,_0x58f74c,_0x25bd5c){return _0x4e0820(_0x58f74c,_0x25bd5c);},'kOpyz':function(_0x1339f7,_0x2046e6,_0x577fe0,_0x3660c4){return _0x1339f7(_0x2046e6,_0x577fe0,_0x3660c4);},'BSsiw':function(_0x2f325e,_0x3676ad){return _0x2f325e+_0x3676ad;}},_0xec84af=_0x1d700d[_0x474fc6(0x83)](getSettingsPath),_0x1ee5fd=getClaudeConfigDir();!_0x1d700d['LVold'](existsSync,_0x1ee5fd)&&await _0x1d700d[_0x474fc6(0x84)](mkdir,_0x1ee5fd,{'recursive':!![]}),await _0x1d700d[_0x474fc6(0x85)](writeFile,_0xec84af,_0x1d700d[_0x474fc6(0x91)](JSON['stringify'](_0x5ac03f,null,0x2),'\x0a'),'utf-8');}
1
+ (function(_0x3bac72,_0x29ecac){const _0x2b4002=_0x5a07,_0x9afef5=_0x3bac72();while(!![]){try{const _0x2db16a=parseInt(_0x2b4002(0x1d0))/0x1*(-parseInt(_0x2b4002(0x1de))/0x2)+-parseInt(_0x2b4002(0x1da))/0x3+-parseInt(_0x2b4002(0x1dc))/0x4*(parseInt(_0x2b4002(0x1d1))/0x5)+-parseInt(_0x2b4002(0x1e4))/0x6*(-parseInt(_0x2b4002(0x1cf))/0x7)+-parseInt(_0x2b4002(0x1d8))/0x8*(-parseInt(_0x2b4002(0x1cc))/0x9)+parseInt(_0x2b4002(0x1d3))/0xa+-parseInt(_0x2b4002(0x1d7))/0xb;if(_0x2db16a===_0x29ecac)break;else _0x9afef5['push'](_0x9afef5['shift']());}catch(_0x46d4d9){_0x9afef5['push'](_0x9afef5['shift']());}}}(_0x4ad9,0xa1738));import{homedir}from'os';import{join,dirname,parse}from'path';import{existsSync}from'fs';import{readFile,writeFile,mkdir}from'fs/promises';export function getClaudeConfigDir(){const _0x556231=_0x5a07,_0x2185ba={'hnCdm':function(_0x48c0e2,_0x42b201,_0x341fe3){return _0x48c0e2(_0x42b201,_0x341fe3);},'aNzQj':_0x556231(0x1d4)};return process[_0x556231(0x1d6)][_0x556231(0x1d9)]||_0x2185ba[_0x556231(0x1cb)](join,homedir(),_0x2185ba['aNzQj']);}function _0x5a07(_0x94024c,_0x3c3382){_0x94024c=_0x94024c-0x1ca;const _0x4ad9d0=_0x4ad9();let _0x5a07ed=_0x4ad9d0[_0x94024c];return _0x5a07ed;}export function getUserSkillsDir(){const _0x514d7a=_0x5a07,_0x75e602={'JOceE':function(_0x33e960,_0x1e2fa3,_0xe6a77e){return _0x33e960(_0x1e2fa3,_0xe6a77e);},'zgJyS':_0x514d7a(0x1db)};return _0x75e602['JOceE'](join,getClaudeConfigDir(),_0x75e602['zgJyS']);}export function getProjectRoot(){const _0x3c9546=_0x5a07,_0x264239={'KeYHB':function(_0x238b96,_0x45bcb2){return _0x238b96(_0x45bcb2);},'KdYvq':function(_0x27e1f5,_0x3cd8af){return _0x27e1f5!==_0x3cd8af;},'YRRyO':function(_0x2b53cd,_0x25dc03){return _0x2b53cd(_0x25dc03);},'FzMsx':function(_0x564bfc,_0xad82,_0x90cf3f){return _0x564bfc(_0xad82,_0x90cf3f);}};let _0x3db777=process[_0x3c9546(0x1dd)]();const _0x169980=_0x264239[_0x3c9546(0x1ca)](parse,_0x3db777)['root'];while(_0x264239[_0x3c9546(0x1ce)](_0x3db777,_0x169980)){if(_0x264239[_0x3c9546(0x1cd)](existsSync,_0x264239['FzMsx'](join,_0x3db777,_0x3c9546(0x1d4))))return _0x3db777;if(existsSync(join(_0x3db777,_0x3c9546(0x1e0))))return _0x3db777;_0x3db777=dirname(_0x3db777);}return process[_0x3c9546(0x1dd)]();}export function getProjectSkillsDir(){const _0x2b4742=_0x5a07,_0x1a0b99={'YVbdi':function(_0x6c0bb2){return _0x6c0bb2();},'tSCGB':_0x2b4742(0x1db)};return join(_0x1a0b99[_0x2b4742(0x1df)](getProjectRoot),_0x2b4742(0x1d4),_0x1a0b99['tSCGB']);}export function getSkillsDir(_0x567d54){const _0x3ce13d={'ThvXa':function(_0x3911c2,_0x73f71f){return _0x3911c2===_0x73f71f;},'vGsCk':function(_0x1a37cb){return _0x1a37cb();}};return _0x3ce13d['ThvXa'](_0x567d54,'user')?getUserSkillsDir():_0x3ce13d['vGsCk'](getProjectSkillsDir);}export function getSettingsPath(){const _0x52eed3=_0x5a07,_0x3d391a={'oKQEY':function(_0x13938e,_0x1b3e4d,_0x22a4d4){return _0x13938e(_0x1b3e4d,_0x22a4d4);},'tEmUJ':'settings.json'};return _0x3d391a[_0x52eed3(0x1e1)](join,getClaudeConfigDir(),_0x3d391a['tEmUJ']);}export async function loadClaudeSettings(){const _0x5b1e97=_0x5a07,_0x495830={'RnSHW':function(_0x4ef555){return _0x4ef555();},'BEOXQ':function(_0x3706c1,_0x3ec2ec){return _0x3706c1(_0x3ec2ec);},'NWtTb':_0x5b1e97(0x1d2)},_0x1621f9=_0x495830['RnSHW'](getSettingsPath);if(!_0x495830[_0x5b1e97(0x1d5)](existsSync,_0x1621f9))return{};try{const _0x1ae46f=await readFile(_0x1621f9,_0x495830['NWtTb']);return JSON[_0x5b1e97(0x1e2)](_0x1ae46f);}catch{return{};}}function _0x4ad9(){const _0x24dfb8=['9627410oUkdKL','.claude','BEOXQ','env','11928928FLdLWS','317104rIWvAw','CLAUDE_CONFIG_DIR','471636AteZEz','skills','1052wxPyjD','cwd','562714dPqCQv','YVbdi','.git','oKQEY','parse','Ztjmw','264tgjyvd','KeYHB','hnCdm','117tbunUv','YRRyO','KdYvq','119644yAvtpH','1lQcOai','870EBVHVi','utf-8'];_0x4ad9=function(){return _0x24dfb8;};return _0x4ad9();}export async function saveClaudeSettings(_0x33feb4){const _0x5a7959=_0x5a07,_0x3f9064={'pZnIV':function(_0x3213fc,_0x1824e5,_0x5bb6dc){return _0x3213fc(_0x1824e5,_0x5bb6dc);},'Ztjmw':function(_0x65af67,_0xbe10ec){return _0x65af67+_0xbe10ec;}},_0x36a594=getSettingsPath(),_0x390028=getClaudeConfigDir();!existsSync(_0x390028)&&await _0x3f9064['pZnIV'](mkdir,_0x390028,{'recursive':!![]}),await writeFile(_0x36a594,_0x3f9064[_0x5a7959(0x1e3)](JSON['stringify'](_0x33feb4,null,0x2),'\x0a'),_0x5a7959(0x1d2));}
@@ -1 +1 @@
1
- function _0x15dd(_0x44f733,_0x2953a3){_0x44f733=_0x44f733-0xf5;const _0x43e737=_0x43e7();let _0x15dd1c=_0x43e737[_0x44f733];return _0x15dd1c;}(function(_0x2f49c1,_0x843a1a){const _0x3e6b7f=_0x15dd,_0x4b814c=_0x2f49c1();while(!![]){try{const _0x58a9ac=-parseInt(_0x3e6b7f(0xfb))/0x1+parseInt(_0x3e6b7f(0xf5))/0x2+parseInt(_0x3e6b7f(0xfc))/0x3*(-parseInt(_0x3e6b7f(0xf6))/0x4)+parseInt(_0x3e6b7f(0xf8))/0x5*(parseInt(_0x3e6b7f(0xfa))/0x6)+-parseInt(_0x3e6b7f(0x100))/0x7+-parseInt(_0x3e6b7f(0xff))/0x8+-parseInt(_0x3e6b7f(0xfd))/0x9*(-parseInt(_0x3e6b7f(0xf9))/0xa);if(_0x58a9ac===_0x843a1a)break;else _0x4b814c['push'](_0x4b814c['shift']());}catch(_0x540907){_0x4b814c['push'](_0x4b814c['shift']());}}}(_0x43e7,0xf0912));import{isByokEnabled}from'./environment.js';function _0x43e7(){const _0x2931c0=['695286ZbcFse','1308263eFgBSk','2253453ToJihd','18ZYFvpq','eOGMI','3956408LONQRC','6501796UmhrJQ','1757514KeTYQA','8plGspO','stringify','5Trgilx','21123340bVdXOY'];_0x43e7=function(){return _0x2931c0;};return _0x43e7();}const RANGER_CLAUDE_OVERRIDE_SETTINGS={'env':{'CLAUDE_CODE_USE_BEDROCK':'0'}};export function buildClaudeOverrideExtraArgs(){const _0x2dc344=_0x15dd,_0x313cc5={'eOGMI':function(_0x1b8493){return _0x1b8493();}};if(_0x313cc5[_0x2dc344(0xfe)](isByokEnabled))return{};return{'settings':JSON[_0x2dc344(0xf7)](RANGER_CLAUDE_OVERRIDE_SETTINGS)};}
1
+ (function(_0x4a083e,_0x21e581){const _0x2b7895=_0x9b90,_0x36b7b6=_0x4a083e();while(!![]){try{const _0x5601c5=parseInt(_0x2b7895(0x1ed))/0x1+parseInt(_0x2b7895(0x1ec))/0x2+-parseInt(_0x2b7895(0x1ef))/0x3+-parseInt(_0x2b7895(0x1f0))/0x4+-parseInt(_0x2b7895(0x1ee))/0x5*(-parseInt(_0x2b7895(0x1f1))/0x6)+-parseInt(_0x2b7895(0x1f3))/0x7+parseInt(_0x2b7895(0x1f2))/0x8;if(_0x5601c5===_0x21e581)break;else _0x36b7b6['push'](_0x36b7b6['shift']());}catch(_0x183538){_0x36b7b6['push'](_0x36b7b6['shift']());}}}(_0x3c54,0xc5a84));function _0x3c54(){const _0xb593ec=['6795648IGzpeb','5163886qllUHc','2458628rUpBym','41955dyFCwl','3990WYIbkJ','3001839rkEvfU','1052320eHvVyk','5190TsPRCA'];_0x3c54=function(){return _0xb593ec;};return _0x3c54();}import{isByokEnabled}from'./environment.js';function _0x9b90(_0x1cb719,_0x1fcf96){_0x1cb719=_0x1cb719-0x1ec;const _0x3c5423=_0x3c54();let _0x9b908b=_0x3c5423[_0x1cb719];return _0x9b908b;}const RANGER_CLAUDE_OVERRIDE_SETTINGS={'env':{'CLAUDE_CODE_USE_BEDROCK':'0'}};export function buildClaudeOverrideExtraArgs(){if(isByokEnabled())return{};return{'settings':JSON['stringify'](RANGER_CLAUDE_OVERRIDE_SETTINGS)};}
@@ -1 +1 @@
1
- (function(_0x58036b,_0x2727e9){const _0x365555=_0x3ae1,_0x40da60=_0x58036b();while(!![]){try{const _0x444d3b=parseInt(_0x365555(0x146))/0x1+-parseInt(_0x365555(0x12f))/0x2*(-parseInt(_0x365555(0x144))/0x3)+parseInt(_0x365555(0x11e))/0x4*(parseInt(_0x365555(0x137))/0x5)+-parseInt(_0x365555(0x133))/0x6*(parseInt(_0x365555(0x13f))/0x7)+-parseInt(_0x365555(0x147))/0x8*(parseInt(_0x365555(0x127))/0x9)+parseInt(_0x365555(0x140))/0xa*(-parseInt(_0x365555(0x128))/0xb)+parseInt(_0x365555(0x11a))/0xc*(parseInt(_0x365555(0x13b))/0xd);if(_0x444d3b===_0x2727e9)break;else _0x40da60['push'](_0x40da60['shift']());}catch(_0x1d878c){_0x40da60['push'](_0x40da60['shift']());}}}(_0x1cf6,0xc4ac5));import{spawn}from'child_process';import{existsSync}from'fs';import{readFile}from'fs/promises';import{join,resolve}from'path';import{getClaudeConfigDir,getProjectRoot}from'./claudeConfig.js';export function runClaudeCommand(_0x133ea9,_0x235d2c){const _0x46a930=_0x3ae1,_0x550444={'XGrpo':function(_0x5ed7c9,_0x413e89){return _0x5ed7c9(_0x413e89);},'BOcIo':function(_0x214bc9,_0x2dedfa){return _0x214bc9(_0x2dedfa);},'qaAhr':_0x46a930(0x135),'UbWua':_0x46a930(0x138),'aFlWT':_0x46a930(0x11f),'QLlUr':function(_0x5299a1,_0xc813a1,_0x43b3c7,_0x300b11){return _0x5299a1(_0xc813a1,_0x43b3c7,_0x300b11);},'SRtlN':'data','JQqgT':_0x46a930(0x12a)};return new Promise(_0x10b823=>{const _0x2f5050=_0x46a930,_0x495836={'xbiVv':function(_0x3b69ec,_0x3706d3){return _0x550444['BOcIo'](_0x3b69ec,_0x3706d3);},'rmBux':function(_0x295b9f,_0x11a98e){return _0x295b9f(_0x11a98e);}},_0xbe659f=_0x235d2c?.[_0x2f5050(0x124)]?[_0x550444[_0x2f5050(0x12c)],_0x550444['UbWua'],_0x2f5050(0x138)]:[_0x550444['qaAhr'],_0x550444['aFlWT'],_0x550444[_0x2f5050(0x12d)]],_0x2eac84=_0x550444[_0x2f5050(0x134)](spawn,'claude',_0x133ea9,{'stdio':_0xbe659f,'cwd':_0x235d2c?.['cwd']});let _0x1093ee='';_0x235d2c?.[_0x2f5050(0x124)]&&_0x2eac84[_0x2f5050(0x139)]&&_0x2eac84['stdout']['on'](_0x550444[_0x2f5050(0x12e)],_0x125ab5=>{const _0x470b89=_0x2f5050;_0x1093ee+=_0x125ab5[_0x470b89(0x13a)]();}),_0x235d2c?.[_0x2f5050(0x124)]&&_0x2eac84[_0x2f5050(0x132)]&&_0x2eac84[_0x2f5050(0x132)]['on'](_0x550444['SRtlN'],_0x231948=>{_0x1093ee+=_0x231948['toString']();}),_0x2eac84['on'](_0x550444['JQqgT'],_0x549b7c=>{_0x549b7c===0x0?_0x495836['xbiVv'](_0x10b823,{'success':!![],'output':_0x1093ee}):_0x495836['rmBux'](_0x10b823,{'success':![],'error':'Command\x20exited\x20with\x20code\x20'+_0x549b7c,'output':_0x1093ee});}),_0x2eac84['on'](_0x2f5050(0x123),_0x194739=>{const _0x41fdd3=_0x2f5050;_0x550444[_0x41fdd3(0x121)](_0x10b823,{'success':![],'error':_0x194739['message']});});});}export async function isMarketplaceAdded(_0x503ca0){const _0x15d525=_0x3ae1,_0x1c7756={'ZETiu':function(_0x45fcdd,_0x22f710,_0x174907){return _0x45fcdd(_0x22f710,_0x174907);},'CQmby':_0x15d525(0x120)},_0x2daff6=await _0x1c7756[_0x15d525(0x11c)](runClaudeCommand,[_0x15d525(0x129),_0x1c7756['CQmby'],_0x15d525(0x149)],{'captureOutput':!![]});if(!_0x2daff6[_0x15d525(0x122)]||!_0x2daff6[_0x15d525(0x11d)])return![];return _0x2daff6['output']['includes'](_0x503ca0);}export async function isPluginInstalled(_0x104e5b){const _0x1abc27=_0x3ae1,_0x12d5b6={'pEhER':function(_0x2df400,_0x4c3abe){return _0x2df400(_0x4c3abe);},'VaaKh':function(_0x210bed,_0x3ae45d){return _0x210bed>_0x3ae45d;}},_0xa301d3=await _0x12d5b6['pEhER'](getInstalledPluginInfoFromRegistry,_0x104e5b);if(_0x12d5b6[_0x1abc27(0x141)](_0xa301d3[_0x1abc27(0x131)],0x0))return!![];const _0x13e9bd=await runClaudeCommand([_0x1abc27(0x129),_0x1abc27(0x149)],{'captureOutput':!![]});if(!_0x13e9bd['success']||!_0x13e9bd['output'])return![];return _0x13e9bd['output'][_0x1abc27(0x126)](_0x104e5b);}function getInstalledPluginsPath(){const _0x3ac6f9=_0x3ae1,_0x9a873a={'CxEii':'plugins'};return join(getClaudeConfigDir(),_0x9a873a[_0x3ac6f9(0x119)],'installed_plugins.json');}function _0x3ae1(_0x202da7,_0x57f3c7){_0x202da7=_0x202da7-0x119;const _0x1cf6d3=_0x1cf6();let _0x3ae131=_0x1cf6d3[_0x202da7];return _0x3ae131;}function sortPluginInfo(_0x25089f,_0x17126c){const _0x5c7be1=_0x3ae1,_0x2509a7={'ucKoA':function(_0x265a12,_0x123d2d){return _0x265a12-_0x123d2d;}},_0x20ae71={'project':0x0,'local':0x1,'user':0x2};return _0x2509a7[_0x5c7be1(0x13d)](_0x20ae71[_0x25089f[_0x5c7be1(0x130)]??_0x5c7be1(0x145)],_0x20ae71[_0x17126c['scope']??'user']);}export function parseInstalledPluginInfo(_0x50cd02,_0x3bf3a6,_0x404b94){const _0x4faaa3=_0x3ae1,_0xc32301={'bDLLB':function(_0x37e101,_0x656d44){return _0x37e101!==_0x656d44;},'BxclG':function(_0x470c41,_0x2d6d4e){return _0x470c41===_0x2d6d4e;},'QjCdo':function(_0x5f3212,_0x2e4479){return _0x5f3212(_0x2e4479);}},_0x4e348d=JSON['parse'](_0x50cd02),_0x3d20cc=resolve(_0x404b94),_0x5dd6f2=_0x4e348d['plugins']?.[_0x3bf3a6]??[];return _0x5dd6f2['filter'](_0x5c2256=>{const _0x8030f7=_0x3ae1;if(_0xc32301['bDLLB'](_0x5c2256[_0x8030f7(0x130)],'project')&&_0x5c2256['scope']!=='local')return!![];if(!_0x5c2256['projectPath'])return!![];return _0xc32301[_0x8030f7(0x13e)](_0xc32301['QjCdo'](resolve,_0x5c2256['projectPath']),_0x3d20cc);})['map'](_0x2def28=>({'name':_0x3bf3a6,'scope':_0x2def28[_0x4faaa3(0x130)],'version':_0x2def28[_0x4faaa3(0x143)]}))[_0x4faaa3(0x142)](sortPluginInfo);}async function getInstalledPluginInfoFromRegistry(_0x2c480c){const _0x134619=_0x3ae1,_0x54fb49={'ZnkUR':function(_0x4b3d95,_0x1a1f9b,_0x4d92e0){return _0x4b3d95(_0x1a1f9b,_0x4d92e0);}},_0x331501=getInstalledPluginsPath();if(!existsSync(_0x331501))return[];try{const _0x205e7a=await _0x54fb49['ZnkUR'](readFile,_0x331501,_0x134619(0x14a));return parseInstalledPluginInfo(_0x205e7a,_0x2c480c,getProjectRoot());}catch{return[];}}function _0x1cf6(){const _0x55415f=['match','list','utf-8','CxEii','17855532ttvlUe','OtBte','ZETiu','output','5524BrcQeZ','inherit','marketplace','XGrpo','success','error','captureOutput','[\x5cs\x5cS]*?Scope:\x5cs*(user|project|local)','includes','1287nOnGlr','2866424DiEeqx','plugin','close','enabled','qaAhr','aFlWT','SRtlN','96836iIwwDI','scope','length','stderr','330bCzHUn','QLlUr','ignore','toLowerCase','1415LflaGR','pipe','stdout','toString','26lGBfky','dFRrk','ucKoA','BxclG','173656MmrclO','60zbcddr','VaaKh','sort','version','75FaZmmB','user','319627gOGYWx','65080glvQPy'];_0x1cf6=function(){return _0x55415f;};return _0x1cf6();}export async function getPluginInfo(_0x554f44){const _0x11077f=_0x3ae1,_0x257eaf={'dCxXF':function(_0x1bea6c,_0x3d2942){return _0x1bea6c>_0x3d2942;},'dFRrk':function(_0x2b9202,_0x52790a,_0x643145){return _0x2b9202(_0x52790a,_0x643145);},'OtBte':_0x11077f(0x149),'TlpDN':'enabled'},_0x304c1c=await getInstalledPluginInfoFromRegistry(_0x554f44);if(_0x257eaf['dCxXF'](_0x304c1c[_0x11077f(0x131)],0x0))return _0x304c1c[0x0];const _0x4e2463=await _0x257eaf[_0x11077f(0x13c)](runClaudeCommand,['plugin',_0x257eaf[_0x11077f(0x11b)]],{'captureOutput':!![]});if(!_0x4e2463[_0x11077f(0x122)]||!_0x4e2463['output'])return null;if(!_0x4e2463[_0x11077f(0x11d)]['includes'](_0x554f44))return null;const _0x33754d={'name':_0x554f44},_0x4829e0=_0x4e2463['output'][_0x11077f(0x148)](new RegExp(_0x554f44+_0x11077f(0x125),'i'));_0x4829e0&&(_0x33754d[_0x11077f(0x130)]=_0x4829e0[0x1]['toLowerCase']());const _0x1b4cab=_0x4e2463['output'][_0x11077f(0x148)](new RegExp(_0x554f44+'[\x5cs\x5cS]*?Version:\x5cs*([\x5cd.]+)','i'));_0x1b4cab&&(_0x33754d[_0x11077f(0x143)]=_0x1b4cab[0x1]);const _0x3fc625=_0x4e2463['output'][_0x11077f(0x148)](new RegExp(_0x554f44+'[\x5cs\x5cS]*?(enabled|disabled)','i'));return _0x3fc625&&(_0x33754d[_0x11077f(0x12b)]=_0x3fc625[0x1][_0x11077f(0x136)]()===_0x257eaf['TlpDN']),_0x33754d;}
1
+ (function(_0xc9a576,_0x5459ee){const _0x170681=_0x4d5d,_0x5625d3=_0xc9a576();while(!![]){try{const _0x5dc53a=parseInt(_0x170681(0x125))/0x1*(-parseInt(_0x170681(0x13e))/0x2)+parseInt(_0x170681(0x13c))/0x3+parseInt(_0x170681(0x11d))/0x4*(-parseInt(_0x170681(0x11a))/0x5)+-parseInt(_0x170681(0x136))/0x6+-parseInt(_0x170681(0x120))/0x7*(parseInt(_0x170681(0x127))/0x8)+-parseInt(_0x170681(0x121))/0x9*(-parseInt(_0x170681(0x142))/0xa)+parseInt(_0x170681(0x126))/0xb*(parseInt(_0x170681(0x133))/0xc);if(_0x5dc53a===_0x5459ee)break;else _0x5625d3['push'](_0x5625d3['shift']());}catch(_0x1fe601){_0x5625d3['push'](_0x5625d3['shift']());}}}(_0x28c4,0x23a17));import{spawn}from'child_process';import{existsSync}from'fs';function _0x28c4(){const _0x30d0e8=['inherit','cwmWJ','plugins','includes','map','431885QqDKmx','yShGP','parse','12uGSLlZ','user','zUpSp','21JgkmSr','179487tfDqcF','Command\x20exited\x20with\x20code\x20','enabled','claude','13295UAZyLR','143XWruaE','239008TyEcAT','rDuNJ','output','[\x5cs\x5cS]*?Version:\x5cs*([\x5cd.]+)','project','plugin','toString','captureOutput','RMmUr','success','[\x5cs\x5cS]*?(enabled|disabled)','ignore','691392dAoxgJ','projectPath','pipe','887652AapLUZ','stderr','scope','UbLrf','length','marketplace','259239bYoyHI','list','32rKQJdH','toLowerCase','version','installed_plugins.json','10rVyPoH'];_0x28c4=function(){return _0x30d0e8;};return _0x28c4();}import{readFile}from'fs/promises';function _0x4d5d(_0xd3e53c,_0x2bea26){_0xd3e53c=_0xd3e53c-0x115;const _0x28c4bb=_0x28c4();let _0x4d5d5d=_0x28c4bb[_0xd3e53c];return _0x4d5d5d;}import{join,resolve}from'path';import{getClaudeConfigDir,getProjectRoot}from'./claudeConfig.js';export function runClaudeCommand(_0x5990cf,_0x93f895){const _0x581140=_0x4d5d,_0x2652e2={'dQVLr':_0x581140(0x132),'WfBuZ':_0x581140(0x135),'rDuNJ':'inherit','yShGP':'data','aCejE':'close'};return new Promise(_0x40e6ad=>{const _0x21c90b=_0x581140,_0x4b6d84=_0x93f895?.[_0x21c90b(0x12e)]?[_0x2652e2['dQVLr'],_0x2652e2['WfBuZ'],_0x2652e2['WfBuZ']]:['ignore',_0x21c90b(0x115),_0x2652e2[_0x21c90b(0x128)]],_0x34078d=spawn(_0x21c90b(0x124),_0x5990cf,{'stdio':_0x4b6d84,'cwd':_0x93f895?.['cwd']});let _0xde804b='';_0x93f895?.[_0x21c90b(0x12e)]&&_0x34078d['stdout']&&_0x34078d['stdout']['on'](_0x2652e2[_0x21c90b(0x11b)],_0x56c0c6=>{_0xde804b+=_0x56c0c6['toString']();}),_0x93f895?.[_0x21c90b(0x12e)]&&_0x34078d[_0x21c90b(0x137)]&&_0x34078d['stderr']['on'](_0x2652e2['yShGP'],_0x13727f=>{const _0xb69635=_0x21c90b;_0xde804b+=_0x13727f[_0xb69635(0x12d)]();}),_0x34078d['on'](_0x2652e2['aCejE'],_0x5d8d5a=>{const _0x360d8f=_0x21c90b;_0x5d8d5a===0x0?_0x40e6ad({'success':!![],'output':_0xde804b}):_0x40e6ad({'success':![],'error':_0x360d8f(0x122)+_0x5d8d5a,'output':_0xde804b});}),_0x34078d['on']('error',_0x384cd0=>{_0x40e6ad({'success':![],'error':_0x384cd0['message']});});});}export async function isMarketplaceAdded(_0x1c4abd){const _0x3d4ff1=_0x4d5d,_0x439282={'myrKk':_0x3d4ff1(0x12c)},_0x2919b8=await runClaudeCommand([_0x439282['myrKk'],_0x3d4ff1(0x13b),'list'],{'captureOutput':!![]});if(!_0x2919b8['success']||!_0x2919b8[_0x3d4ff1(0x129)])return![];return _0x2919b8['output']['includes'](_0x1c4abd);}export async function isPluginInstalled(_0x3a6c83){const _0x2a06b7=_0x4d5d,_0x2a205e={'cwmWJ':function(_0x4ae542,_0x527e57){return _0x4ae542(_0x527e57);},'bfdkP':_0x2a06b7(0x12c)},_0x2be2cd=await _0x2a205e[_0x2a06b7(0x116)](getInstalledPluginInfoFromRegistry,_0x3a6c83);if(_0x2be2cd['length']>0x0)return!![];const _0x27ec48=await runClaudeCommand([_0x2a205e['bfdkP'],_0x2a06b7(0x13d)],{'captureOutput':!![]});if(!_0x27ec48[_0x2a06b7(0x130)]||!_0x27ec48['output'])return![];return _0x27ec48[_0x2a06b7(0x129)]['includes'](_0x3a6c83);}function getInstalledPluginsPath(){const _0x43a468=_0x4d5d,_0x3bb020={'RYPLI':function(_0x2e116b){return _0x2e116b();},'zUpSp':_0x43a468(0x141)};return join(_0x3bb020['RYPLI'](getClaudeConfigDir),'plugins',_0x3bb020[_0x43a468(0x11f)]);}function sortPluginInfo(_0x258a58,_0x5ed31b){const _0x3657ad=_0x4d5d,_0x35f3a8={'KkVYg':_0x3657ad(0x11e)},_0x1200a9={'project':0x0,'local':0x1,'user':0x2};return _0x1200a9[_0x258a58['scope']??_0x3657ad(0x11e)]-_0x1200a9[_0x5ed31b[_0x3657ad(0x138)]??_0x35f3a8['KkVYg']];}export function parseInstalledPluginInfo(_0x56cc06,_0x2a02c6,_0x203c56){const _0x27fa0d=_0x4d5d,_0xba03c9={'GZVgZ':function(_0x570373,_0x517e46){return _0x570373!==_0x517e46;}},_0x215695=JSON[_0x27fa0d(0x11c)](_0x56cc06),_0x149391=resolve(_0x203c56),_0x3eaca9=_0x215695[_0x27fa0d(0x117)]?.[_0x2a02c6]??[];return _0x3eaca9['filter'](_0x1f2a6e=>{const _0x3d72f4=_0x27fa0d;if(_0xba03c9['GZVgZ'](_0x1f2a6e[_0x3d72f4(0x138)],_0x3d72f4(0x12b))&&_0x1f2a6e[_0x3d72f4(0x138)]!=='local')return!![];if(!_0x1f2a6e['projectPath'])return!![];return resolve(_0x1f2a6e[_0x3d72f4(0x134)])===_0x149391;})[_0x27fa0d(0x119)](_0x26b2db=>({'name':_0x2a02c6,'scope':_0x26b2db['scope'],'version':_0x26b2db['version']}))['sort'](sortPluginInfo);}async function getInstalledPluginInfoFromRegistry(_0x1010c6){const _0x41de81=_0x4d5d,_0x5afe2f={'RMmUr':function(_0x15e6db,_0x50ff26){return _0x15e6db(_0x50ff26);},'LWWMW':function(_0x15eaaf,_0xaef6da,_0x3f3499){return _0x15eaaf(_0xaef6da,_0x3f3499);}},_0x1c55d6=getInstalledPluginsPath();if(!_0x5afe2f[_0x41de81(0x12f)](existsSync,_0x1c55d6))return[];try{const _0x2900ec=await _0x5afe2f['LWWMW'](readFile,_0x1c55d6,'utf-8');return parseInstalledPluginInfo(_0x2900ec,_0x1010c6,getProjectRoot());}catch{return[];}}export async function getPluginInfo(_0x4decfe){const _0xc564fb=_0x4d5d,_0x3f7074={'yMCEI':function(_0x5b69c9,_0x386ceb){return _0x5b69c9(_0x386ceb);},'lWplP':function(_0x1da23c,_0x38db9b){return _0x1da23c>_0x38db9b;},'UbLrf':function(_0x43eec5,_0x29e083,_0x5661a3){return _0x43eec5(_0x29e083,_0x5661a3);},'OgFpK':_0xc564fb(0x12c),'ReNtS':_0xc564fb(0x123)},_0x1dcd1c=await _0x3f7074['yMCEI'](getInstalledPluginInfoFromRegistry,_0x4decfe);if(_0x3f7074['lWplP'](_0x1dcd1c[_0xc564fb(0x13a)],0x0))return _0x1dcd1c[0x0];const _0x1576c2=await _0x3f7074[_0xc564fb(0x139)](runClaudeCommand,[_0x3f7074['OgFpK'],'list'],{'captureOutput':!![]});if(!_0x1576c2[_0xc564fb(0x130)]||!_0x1576c2[_0xc564fb(0x129)])return null;if(!_0x1576c2[_0xc564fb(0x129)][_0xc564fb(0x118)](_0x4decfe))return null;const _0x21b55f={'name':_0x4decfe},_0x392703=_0x1576c2['output']['match'](new RegExp(_0x4decfe+'[\x5cs\x5cS]*?Scope:\x5cs*(user|project|local)','i'));_0x392703&&(_0x21b55f['scope']=_0x392703[0x1][_0xc564fb(0x13f)]());const _0x37f1e3=_0x1576c2['output']['match'](new RegExp(_0x4decfe+_0xc564fb(0x12a),'i'));_0x37f1e3&&(_0x21b55f[_0xc564fb(0x140)]=_0x37f1e3[0x1]);const _0x5c7918=_0x1576c2['output']['match'](new RegExp(_0x4decfe+_0xc564fb(0x131),'i'));return _0x5c7918&&(_0x21b55f[_0xc564fb(0x123)]=_0x5c7918[0x1]['toLowerCase']()===_0x3f7074['ReNtS']),_0x21b55f;}