@ranger-testing/ranger-cli 3.1.5-alpha.aebd071-49 → 3.1.5

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 (86) 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/scenarioOriginCheck.js +1 -1
  71. package/build/commands/utils/sessionCache.js +1 -1
  72. package/build/commands/utils/settings.js +1 -1
  73. package/build/commands/utils/skillContent.js +1 -1
  74. package/build/commands/utils/skills.js +1 -1
  75. package/build/commands/utils/stitchWebmFiles.js +1 -1
  76. package/build/commands/utils/telemetry.js +1 -1
  77. package/build/commands/utils/tokenRefresh.js +1 -1
  78. package/build/commands/utils/traceSnapshotMapper.js +1 -1
  79. package/build/commands/utils/tunnelClient.js +1 -1
  80. package/build/commands/utils/userApi.js +1 -1
  81. package/build/commands/utils/version.js +1 -1
  82. package/build/commands/verifyFeature.js +1 -1
  83. package/build/commands/verifyFeatureCli.js +1 -1
  84. package/build/commands/verifyFeatureNovaCli.js +1 -1
  85. package/build/commands/verifyFeatureRangerwrightCli.js +1 -1
  86. package/package.json +2 -2
@@ -1 +1 @@
1
- const _0x174c51=_0x15e4;(function(_0x4d23d4,_0x2f8487){const _0x3999ba=_0x15e4,_0x1c2f87=_0x4d23d4();while(!![]){try{const _0x1cd47f=parseInt(_0x3999ba(0x1ee))/0x1*(-parseInt(_0x3999ba(0x211))/0x2)+parseInt(_0x3999ba(0x1f0))/0x3+parseInt(_0x3999ba(0x1e1))/0x4*(-parseInt(_0x3999ba(0x1db))/0x5)+-parseInt(_0x3999ba(0x1d6))/0x6+-parseInt(_0x3999ba(0x1c5))/0x7*(parseInt(_0x3999ba(0x204))/0x8)+parseInt(_0x3999ba(0x20d))/0x9*(-parseInt(_0x3999ba(0x1b9))/0xa)+parseInt(_0x3999ba(0x1b8))/0xb*(parseInt(_0x3999ba(0x212))/0xc);if(_0x1cd47f===_0x2f8487)break;else _0x1c2f87['push'](_0x1c2f87['shift']());}catch(_0x3326a5){_0x1c2f87['push'](_0x1c2f87['shift']());}}}(_0x1aa8,0x9125f));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';function _0x1aa8(){const _0x21619d=['Rjdez','HmiOm','alpha','claude','17428kriwRk','stdio','isFinite','plugin','close','...','\x0aNo\x20ranger-managed\x20skills\x20found\x20to\x20reinstall.','trim','UObLq','vxOMd','GJiaF','fKtvj','zhjli','27yRvxTf','platform','96915NaQFnp','wSlLd','\x20channel.','active-profile.txt','WsAzg','\x0aYou\x20are\x20already\x20on\x20the\x20latest\x20version.','npm\x20i\x20-g\x20','YIcKd','RayRk','\x0a✅\x20Update\x20complete!','...\x0a','usKFh','dlmoQ','trailhead','ignore','BRZCw','splice','error','.gitignore','\x20—\x20reinstalling\x20@','40DiilZX','opencode','split','\x20\x20Failed\x20to\x20reinstall\x20','LwQxS','ranger@trailhead','VRVWD','\x0aInstalling\x20','PkiWj','3467070wRrJPc','--scope','test','project','64882NnNsWL','12LREUtD','EvvoE','wORas','win32','PoJbV','SVSLj','35977425sQYFQr','20tPGrTV',')\x20is\x20newer\x20than\x20the\x20published\x20version\x20(','dyKcD','GlIiC','uUsYE','\x0aSuccessfully\x20installed\x20latest\x20version.','Claude\x20plugin\x20update\x20failed\x20for\x20','\x0aSuccessfully\x20updated\x20to\x20version\x20','bBMGH','log','lLXEi','BSEpZ','459067NZiIkV',').\x20Staying\x20on\x20','unref','version','Update\x20failed\x20for\x20@','UpLUC','active-feature.txt','GFDsT','Update\x20failed:\x20','HbLBn','some','update','marketplace','inherit','user','twOda','\x0aClaude\x20plugin\x20updated\x20(project\x20scope).','1764744PecAQo','Attempting\x20install\x20anyway...','xAKqE','cwd','EMHJH','505HTKSEd','beta'];_0x1aa8=function(){return _0x21619d;};return _0x1aa8();}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';const CLAUDE_COMMAND_TIMEOUT_MS=0x1d4c0;async function runCommand(_0x3dd4a1,_0x2b1090,_0x3f1613){const _0x4e9fc6=_0x15e4,_0x423193={'BSEpZ':function(_0x2dba24,_0x2f4941){return _0x2dba24(_0x2f4941);},'dlmoQ':function(_0x5e953c,_0x52a781){return _0x5e953c(_0x52a781);},'SVSLj':function(_0x2f57d7,_0x530335){return _0x2f57d7===_0x530335;},'wPRbg':function(_0x4437ca,_0x4ebccc,_0x3c2856,_0x441352){return _0x4437ca(_0x4ebccc,_0x3c2856,_0x441352);},'wOnzI':_0x4e9fc6(0x1fe),'WsAzg':_0x4e9fc6(0x215),'tEDLV':function(_0x4481a2,_0x3fa55c,_0x53a45f){return _0x4481a2(_0x3fa55c,_0x53a45f);}};return new Promise(_0x5f1295=>{const _0x6a9803=_0x4e9fc6,_0x4dab37={'BRZCw':function(_0x5f25ab,_0x410dea){const _0x234afe=_0x15e4;return _0x423193[_0x234afe(0x1c4)](_0x5f25ab,_0x410dea);},'ZymOr':function(_0x46470a,_0x3690e6){const _0x51cb38=_0x15e4;return _0x423193[_0x51cb38(0x1fc)](_0x46470a,_0x3690e6);},'fKtvj':function(_0x256fae,_0x2a74ac){const _0x306903=_0x15e4;return _0x423193[_0x306903(0x1b7)](_0x256fae,_0x2a74ac);}};let _0xbbf539=![],_0x1badf2;const _0x34a0a0=_0x30b97b=>{const _0x89508e=_0x15e4;if(_0xbbf539)return;_0xbbf539=!![],_0x1badf2&&_0x4dab37[_0x89508e(0x1ff)](clearTimeout,_0x1badf2),_0x4dab37[_0x89508e(0x1ff)](_0x5f1295,_0x30b97b);},_0x387d72=_0x423193['wPRbg'](spawn,_0x3dd4a1,_0x2b1090,{'stdio':[_0x423193['wOnzI'],_0x3f1613?.[_0x6a9803(0x1e2)]??'inherit',_0x3f1613?.[_0x6a9803(0x1e2)]??_0x6a9803(0x1d2)],'cwd':_0x3f1613?.[_0x6a9803(0x1d9)],'shell':_0x423193[_0x6a9803(0x1b7)](process[_0x6a9803(0x1ef)],_0x423193[_0x6a9803(0x1f4)])});_0x1badf2=_0x3f1613?.['timeoutMs']?_0x423193['tEDLV'](setTimeout,()=>{const _0x8e9b89=_0x6a9803;_0x387d72['kill'](),_0x387d72[_0x8e9b89(0x1c7)](),_0x34a0a0(![]);},_0x3f1613['timeoutMs']):undefined,_0x387d72['on'](_0x6a9803(0x1e5),_0x31c355=>{const _0x41fc32=_0x6a9803;_0x4dab37['ZymOr'](_0x34a0a0,_0x4dab37[_0x41fc32(0x1ec)](_0x31c355,0x0));}),_0x387d72['on']('error',()=>{_0x34a0a0(![]);});});}export function resolveDistTag(_0x44ff92){const _0x8defc9=_0x15e4,_0xd1feae={'ZkAat':_0x8defc9(0x1dc),'LwQxS':'latest'};if(/-alpha\./i['test'](_0x44ff92))return _0x8defc9(0x1df);if(/-beta\./i[_0x8defc9(0x20f)](_0x44ff92))return _0xd1feae['ZkAat'];if(/-rc\./i[_0x8defc9(0x20f)](_0x44ff92))return'rc';return _0xd1feae[_0x8defc9(0x208)];}export function resolveInstallTarget(_0x20ac82){const _0x246778=_0x15e4,_0x4e1213={'GlIiC':function(_0x156f38,_0x4e53ff){return _0x156f38(_0x4e53ff);},'FDQTM':'latest'},_0x1cd14a=_0x4e1213[_0x246778(0x1bc)](resolveDistTag,_0x20ac82);if(_0x1cd14a!==_0x4e1213['FDQTM'])return _0x1cd14a;const _0x42f6f2=_0x20ac82[_0x246778(0x206)]('.')[0x0],_0x109fc5=parseInt(_0x42f6f2,0xa);if(!Number[_0x246778(0x1e3)](_0x109fc5))return'latest';return'^'+_0x109fc5+'.0.0';}async function runInstall(_0x5b0d61){const _0x32a790=_0x15e4,_0x5c49ca={'RayRk':function(_0x3a5d54,_0x31797b){return _0x3a5d54===_0x31797b;},'UObLq':'install','gJUMZ':'ignore','uUsYE':'inherit','VRVWD':_0x32a790(0x1e5),'YIcKd':'error'},_0x17da9c=resolveInstallTarget(_0x5b0d61);return new Promise(_0x814387=>{const _0x1fe51b=_0x32a790,_0x5242fe={'zhjli':function(_0xd34f8b,_0xd70aa3){return _0xd34f8b(_0xd70aa3);}};console[_0x1fe51b(0x1c2)](_0x1fe51b(0x20b)+PACKAGE_NAME+'@'+_0x17da9c+_0x1fe51b(0x1fa));const _0x5ea786=spawn('npm',[_0x5c49ca[_0x1fe51b(0x1e9)],'-g',PACKAGE_NAME+'@'+_0x17da9c],{'stdio':[_0x5c49ca['gJUMZ'],_0x5c49ca[_0x1fe51b(0x1bd)],_0x5c49ca['uUsYE']],'shell':process['platform']===_0x1fe51b(0x215)});_0x5ea786['on'](_0x5c49ca[_0x1fe51b(0x20a)],_0x33bf8a=>{const _0x45abbd=_0x1fe51b;_0x814387(_0x5c49ca[_0x45abbd(0x1f8)](_0x33bf8a,0x0));}),_0x5ea786['on'](_0x5c49ca[_0x1fe51b(0x1f7)],()=>{const _0x9e29b2=_0x1fe51b;_0x5242fe[_0x9e29b2(0x1ed)](_0x814387,![]);});});}async function updateClaudeMarketplace(){const _0x255054=_0x15e4,_0x5d43c5={'DqNaj':_0x255054(0x1e0),'PhTGJ':'Claude\x20marketplace\x20update\x20command\x20failed\x20(timed\x20out,\x20failed\x20to\x20start,\x20or\x20exited\x20with\x20a\x20non-zero\x20status).'},_0x503ca8=await runCommand(_0x5d43c5['DqNaj'],['plugin',_0x255054(0x1d1),_0x255054(0x1d0),_0x255054(0x1fd)],{'timeoutMs':CLAUDE_COMMAND_TIMEOUT_MS});if(!_0x503ca8)throw new Error(_0x5d43c5['PhTGJ']);}async function updateClaudePlugin(_0x1949ad=_0x174c51(0x1d3)){const _0x3ffad5=_0x174c51,_0x38b799={'nWThJ':'user','wSlLd':function(_0x3b3f12,_0x519170,_0x3e4fd9,_0x2c484e){return _0x3b3f12(_0x519170,_0x3e4fd9,_0x2c484e);},'usKFh':function(_0xe6a011,_0x449b86){return _0xe6a011===_0x449b86;},'PkiWj':'project','UpLUC':function(_0x3657cd){return _0x3657cd();}},_0x1d6efc=[_0x3ffad5(0x1e4),'update','ranger@trailhead'];_0x1949ad!==_0x38b799['nWThJ']&&_0x1d6efc['push'](_0x3ffad5(0x20e),_0x1949ad);const _0x1a8342=await _0x38b799[_0x3ffad5(0x1f1)](runCommand,'claude',_0x1d6efc,{'timeoutMs':CLAUDE_COMMAND_TIMEOUT_MS,'cwd':_0x38b799[_0x3ffad5(0x1fb)](_0x1949ad,_0x38b799[_0x3ffad5(0x20c)])||_0x38b799[_0x3ffad5(0x1fb)](_0x1949ad,'local')?_0x38b799[_0x3ffad5(0x1ca)](getProjectRoot):undefined});if(!_0x1a8342)throw new Error(_0x3ffad5(0x1bf)+_0x1949ad+'\x20scope\x20(timed\x20out,\x20failed\x20to\x20start,\x20or\x20exited\x20with\x20a\x20non-zero\x20status).');}function isSkillInstalled(_0x5e99aa,_0x19fe48,_0x2e0cd9){const _0x26b854=_0x174c51,_0x5ebb69={'lLXEi':'opencode'},_0x203a65=_0x2e0cd9===_0x5ebb69[_0x26b854(0x1c3)]?getOpencodeSkillsDir(_0x19fe48):getSkillsDir(_0x19fe48),_0x52b457=join(_0x203a65,_0x5e99aa);return existsSync(_0x52b457);}function _0x15e4(_0x2ccd5b,_0x5e3e44){_0x2ccd5b=_0x2ccd5b-0x1b6;const _0x1aa80f=_0x1aa8();let _0x15e423=_0x1aa80f[_0x2ccd5b];return _0x15e423;}async function reinstallSkills(_0x22e243){const _0x1c0bf3=_0x174c51,_0x2c385c={'dYUax':_0x1c0bf3(0x210),'vdNFi':function(_0x19c4b3,_0x734f79,_0x4f0a53,_0xfb09a6){return _0x19c4b3(_0x734f79,_0x4f0a53,_0xfb09a6);},'osMRo':'claude','hOhtl':_0x1c0bf3(0x205),'uVmDF':function(_0x1e99d7,_0x2b01a5,_0x49c44d){return _0x1e99d7(_0x2b01a5,_0x49c44d);}},_0x392593=[_0x2c385c['dYUax'],_0x1c0bf3(0x1d3)],_0x53177b=[];for(const _0x43c675 of _0x392593){for(const _0x250f6a of RANGER_MANAGED_SKILLS){_0x2c385c['vdNFi'](isSkillInstalled,_0x250f6a,_0x43c675,'claude')&&_0x53177b['push']({'skillName':_0x250f6a,'level':_0x43c675,'platform':_0x2c385c['osMRo']}),isSkillInstalled(_0x250f6a,_0x43c675,_0x1c0bf3(0x205))&&_0x53177b['push']({'skillName':_0x250f6a,'level':_0x43c675,'platform':_0x2c385c['hOhtl']});}}for(const _0x20134a of _0x392593){for(const _0x2f5927 of DEPRECATED_SKILLS){await removeSkill(_0x2f5927,_0x20134a);}}if(_0x53177b['length']===0x0){console['log'](_0x1c0bf3(0x1e7));return;}console['log']('\x0aReinstalling\x20'+_0x53177b['length']+'\x20ranger-managed\x20skill(s)...');for(const {skillName:_0x2d356a,level:_0x488602,platform:_0x165f7a}of _0x53177b){try{await _0x2c385c['uVmDF'](installSkill,_0x2d356a,{'level':_0x488602,'cliVersion':_0x22e243,'platform':_0x165f7a});}catch(_0x3832d1){console['warn'](_0x1c0bf3(0x207)+_0x165f7a+'\x20'+_0x488602+'\x20skill\x20'+_0x2d356a+':',_0x3832d1);}}}async function ensureActiveProfileGitignored(){const _0x207e57=_0x174c51,_0x1a9e54={'xAKqE':function(_0xd8f62b){return _0xd8f62b();},'vxOMd':_0x207e57(0x202),'GJiaF':function(_0x4700ca,_0xddaa48,_0x4b0636){return _0x4700ca(_0xddaa48,_0x4b0636);},'wORas':'utf-8','Rjdez':_0x207e57(0x1f3),'HmiOm':function(_0x1c681d,_0x113312,_0x810520,_0x1d5294){return _0x1c681d(_0x113312,_0x810520,_0x1d5294);}},_0x2f3f35=join(_0x1a9e54[_0x207e57(0x1d8)](getRangerDir),_0x1a9e54[_0x207e57(0x1ea)]);if(!existsSync(_0x2f3f35))return![];let _0x1fbe25='';try{_0x1fbe25=await _0x1a9e54[_0x207e57(0x1eb)](readFile,_0x2f3f35,_0x1a9e54[_0x207e57(0x214)]);}catch{return![];}const _0x5a7607=_0x1fbe25['split'](/\r?\n/);if(_0x5a7607[_0x207e57(0x1cf)](_0x1a0109=>_0x1a0109[_0x207e57(0x1e8)]()==='active-profile.txt'))return![];let _0x121c50=_0x5a7607['findIndex'](_0x59a0a8=>_0x59a0a8['trim']()===_0x207e57(0x1cb));_0x121c50===-0x1&&(_0x121c50=_0x5a7607['length']);_0x5a7607[_0x207e57(0x200)](_0x121c50,0x0,_0x1a9e54[_0x207e57(0x1dd)]);let _0x366cb0=_0x5a7607['join']('\x0a');!_0x366cb0['endsWith']('\x0a')&&(_0x366cb0+='\x0a');try{await _0x1a9e54[_0x207e57(0x1de)](writeFile,_0x2f3f35,_0x366cb0,_0x1a9e54[_0x207e57(0x214)]);}catch{return![];}return!![];}export async function update(){const _0x2a6079=_0x174c51,_0x905ec1={'NRDbS':function(_0x4af960,_0x4b6a2b){return _0x4af960(_0x4b6a2b);},'PoJbV':function(_0x4893b6,_0x468d9f){return _0x4893b6(_0x468d9f);},'sUzZa':function(_0x177886){return _0x177886();},'EvvoE':function(_0x110f1f,_0x417501){return _0x110f1f+_0x417501;},'dyKcD':_0x2a6079(0x1d7),'OFywM':function(_0x34fbc7){return _0x34fbc7();},'bBMGH':function(_0x44f158,_0x5c369f){return _0x44f158<_0x5c369f;},'twOda':_0x2a6079(0x1fd),'IUpce':'\x0aClaude\x20marketplace\x20updated\x20(trailhead).','HbLBn':function(_0x4ea696,_0x756fae){return _0x4ea696===_0x756fae;},'EMHJH':'local','GFDsT':'\x0aClaude\x20plugin\x20updated\x20(user\x20scope).'},_0x99d7ea=getCurrentVersion();console['log']('\x0aCurrent\x20version:\x20'+_0x99d7ea);const _0x2c0579=_0x905ec1['NRDbS'](resolveDistTag,_0x99d7ea);if(_0x2c0579!=='latest'){console['log']('Prerelease\x20channel\x20detected\x20(@'+_0x2c0579+_0x2a6079(0x1c6)+_0x2c0579+_0x2a6079(0x203)+_0x2c0579+_0x2a6079(0x1e6));const _0x5b4491=await _0x905ec1[_0x2a6079(0x1b6)](runInstall,_0x99d7ea);if(!_0x5b4491)throw new Error(_0x2a6079(0x1c9)+_0x2c0579+_0x2a6079(0x1f2));const _0x128338=_0x905ec1['sUzZa'](getCurrentVersion);console[_0x2a6079(0x1c2)]('\x0aSuccessfully\x20installed\x20'+PACKAGE_NAME+'@'+_0x2c0579+'.'),await reinstallSkills(_0x128338),await ensureActiveProfileGitignored(),console[_0x2a6079(0x1c2)](_0x2a6079(0x1f9));return;}console[_0x2a6079(0x1c2)]('Checking\x20for\x20updates...');const _0x5ae921=parseInt(_0x99d7ea['split']('.')[0x0],0xa);if(!Number[_0x2a6079(0x1e3)](_0x5ae921))throw new Error(_0x905ec1[_0x2a6079(0x213)]('Could\x20not\x20determine\x20the\x20current\x20major\x20version\x20from\x20\x22'+_0x99d7ea+'\x22.\x20','Aborting\x20to\x20avoid\x20a\x20cross-major\x20upgrade.\x20Reinstall\x20explicitly\x20with:\x20')+(_0x2a6079(0x1f6)+PACKAGE_NAME+'@latest'));const _0x1c84a3=_0x905ec1['PoJbV'](getLatestVersion,_0x5ae921);let _0x48d629=_0x99d7ea;if(!_0x1c84a3[_0x2a6079(0x1c8)]){console['warn']('\x0aCould\x20not\x20check\x20latest\x20version:\x20'+_0x1c84a3[_0x2a6079(0x201)]),console[_0x2a6079(0x1c2)](_0x905ec1[_0x2a6079(0x1bb)]);const _0x244d3c=await runInstall(_0x99d7ea);if(_0x244d3c)console[_0x2a6079(0x1c2)](_0x2a6079(0x1be)),_0x48d629=_0x905ec1['OFywM'](getCurrentVersion);else throw new Error(_0x2a6079(0x1cd)+_0x1c84a3['error']);}else{const _0xf2da7=_0x1c84a3['version'];console['log']('Latest\x20version:\x20\x20'+_0xf2da7);const _0x1da75e=compareVersions(_0x99d7ea,_0xf2da7);if(_0x1da75e===0x0)console['log'](_0x2a6079(0x1f5));else{if(_0x905ec1[_0x2a6079(0x1c1)](_0x1da75e,0x0))console['log']('\x0aYour\x20version\x20('+_0x99d7ea+_0x2a6079(0x1ba)+_0xf2da7+').');else{const _0x385463=await runInstall(_0x99d7ea);if(_0x385463)console[_0x2a6079(0x1c2)](_0x2a6079(0x1c0)+_0xf2da7),_0x48d629=_0xf2da7;else throw new Error('Update\x20failed.');}}}await reinstallSkills(_0x48d629);const _0x32cc37=await isMarketplaceAdded(_0x905ec1[_0x2a6079(0x1d4)]),_0x300ae0=await isPluginInstalled('ranger@trailhead');_0x32cc37&&(await updateClaudeMarketplace(),console[_0x2a6079(0x1c2)](_0x905ec1['IUpce']));if(_0x300ae0){const _0xe698f=await getPluginInfo(_0x2a6079(0x209)),_0x107a33=_0xe698f?.['scope']??'user';await updateClaudePlugin(_0x107a33);if(_0x905ec1[_0x2a6079(0x1ce)](_0x107a33,'project'))console[_0x2a6079(0x1c2)](_0x2a6079(0x1d5));else _0x905ec1[_0x2a6079(0x1ce)](_0x107a33,_0x905ec1[_0x2a6079(0x1da)])?console['log']('\x0aClaude\x20plugin\x20updated\x20(local\x20scope).'):console[_0x2a6079(0x1c2)](_0x905ec1[_0x2a6079(0x1cc)]);}const _0x4a6b49=await ensureActiveProfileGitignored();console['log'](_0x2a6079(0x1f9));}
1
+ const _0x363c4f=_0x4c6f;(function(_0x3483fd,_0x24c90c){const _0x4ad6ef=_0x4c6f,_0x3eead3=_0x3483fd();while(!![]){try{const _0x402556=parseInt(_0x4ad6ef(0x1c7))/0x1*(parseInt(_0x4ad6ef(0x1ba))/0x2)+-parseInt(_0x4ad6ef(0x1d9))/0x3*(-parseInt(_0x4ad6ef(0x1ea))/0x4)+parseInt(_0x4ad6ef(0x20e))/0x5+-parseInt(_0x4ad6ef(0x1df))/0x6+-parseInt(_0x4ad6ef(0x1d1))/0x7+parseInt(_0x4ad6ef(0x1d8))/0x8*(-parseInt(_0x4ad6ef(0x1d3))/0x9)+parseInt(_0x4ad6ef(0x1ff))/0xa;if(_0x402556===_0x24c90c)break;else _0x3eead3['push'](_0x3eead3['shift']());}catch(_0x33de49){_0x3eead3['push'](_0x3eead3['shift']());}}}(_0x4086,0x53b4a));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';const CLAUDE_COMMAND_TIMEOUT_MS=0x1d4c0;function _0x4086(){const _0x37a443=['GiejT','ZDyIh','sSZpX','ranger@trailhead','982464TxEREH',')\x20is\x20newer\x20than\x20the\x20published\x20version\x20(','2529vWSdwC','unref','trailhead','\x20channel.','FwDSe','9304mHmDOH','4965kdybht','stdio','close','plugin','version','LGVed','1721868ouguUq','test','inherit','OpqAh','WOYFa','uxoUe','Could\x20not\x20determine\x20the\x20current\x20major\x20version\x20from\x20\x22','log','OPUDk','\x0aYou\x20are\x20already\x20on\x20the\x20latest\x20version.','scope','556etmEnB','join','\x0aCould\x20not\x20check\x20latest\x20version:\x20','cwd','ignore','HAtLA','\x0aSuccessfully\x20installed\x20','install','Attempting\x20install\x20anyway...','push','marketplace','endsWith','length','platform','bsVAf','\x0aSuccessfully\x20updated\x20to\x20version\x20','xFIEx','update','LsAGC','weoBe','SfxYo','841140dAMRHk','DORVW','aZokJ',').\x20Staying\x20on\x20','beta','Update\x20failed:\x20','TOLQV','active-profile.txt','\x0aReinstalling\x20','IESGe','error','QCgLq','\x0aInstalling\x20','@latest','RNISv','2757690yIHWkR','pRvwn','VPRBD','kRKwJ','QGGBA','\x0aClaude\x20marketplace\x20updated\x20(trailhead).','user','462588ZHHkMK','findIndex','claude','DvJbP','Aborting\x20to\x20avoid\x20a\x20cross-major\x20upgrade.\x20Reinstall\x20explicitly\x20with:\x20','latest','\x0aClaude\x20plugin\x20updated\x20(local\x20scope).','\x0a✅\x20Update\x20complete!','JqsBl','GPbrR','win32','project','some','1xzfosx','active-feature.txt','npm','trim','isFinite','local'];_0x4086=function(){return _0x37a443;};return _0x4086();}function _0x4c6f(_0x5c6ff2,_0x394487){_0x5c6ff2=_0x5c6ff2-0x1b6;const _0x408696=_0x4086();let _0x4c6f50=_0x408696[_0x5c6ff2];return _0x4c6f50;}async function runCommand(_0x4959eb,_0x358301,_0x5ccf47){const _0x41a53e=_0x4c6f,_0x4c946c={'ZDyIh':function(_0x27c476,_0x239be1){return _0x27c476(_0x239be1);},'aZokJ':function(_0x58497e,_0xf49d22,_0x44542e,_0x3b17eb){return _0x58497e(_0xf49d22,_0x44542e,_0x3b17eb);},'LGVed':_0x41a53e(0x1ee),'pRvwn':_0x41a53e(0x1e1),'cFvLU':function(_0x1b843c,_0x104a28){return _0x1b843c===_0x104a28;},'jHIYb':'win32','LsAGC':function(_0x507d3c,_0x4febc8,_0x31b723){return _0x507d3c(_0x4febc8,_0x31b723);}};return new Promise(_0x3523ff=>{const _0x88f16f=_0x41a53e,_0x1ee63b={'uyZIh':function(_0x9f7eaf,_0x4027cd){return _0x9f7eaf(_0x4027cd);},'kRKwJ':function(_0x425be8,_0x313abc){return _0x425be8(_0x313abc);}};let _0x5ab280=![],_0x4ae497;const _0x1284ff=_0x4bc9f8=>{const _0x42ce13=_0x4c6f;if(_0x5ab280)return;_0x5ab280=!![],_0x4ae497&&clearTimeout(_0x4ae497),_0x4c946c[_0x42ce13(0x1ce)](_0x3523ff,_0x4bc9f8);},_0x39dccd=_0x4c946c[_0x88f16f(0x201)](spawn,_0x4959eb,_0x358301,{'stdio':[_0x4c946c[_0x88f16f(0x1de)],_0x5ccf47?.[_0x88f16f(0x1da)]??_0x4c946c[_0x88f16f(0x20f)],_0x5ccf47?.[_0x88f16f(0x1da)]??_0x88f16f(0x1e1)],'cwd':_0x5ccf47?.[_0x88f16f(0x1ed)],'shell':_0x4c946c['cFvLU'](process[_0x88f16f(0x1f7)],_0x4c946c['jHIYb'])});_0x4ae497=_0x5ccf47?.['timeoutMs']?_0x4c946c[_0x88f16f(0x1fc)](setTimeout,()=>{const _0x41df85=_0x88f16f;_0x39dccd['kill'](),_0x39dccd[_0x41df85(0x1d4)](),_0x1ee63b['uyZIh'](_0x1284ff,![]);},_0x5ccf47['timeoutMs']):undefined,_0x39dccd['on']('close',_0x224365=>{const _0x479ea0=_0x88f16f;_0x1ee63b[_0x479ea0(0x1b6)](_0x1284ff,_0x224365===0x0);}),_0x39dccd['on'](_0x88f16f(0x209),()=>{_0x1284ff(![]);});});}export function resolveDistTag(_0x17fb4){const _0x4a6e40=_0x4c6f,_0x15756f={'QCgLq':_0x4a6e40(0x1bf)};if(/-alpha\./i[_0x4a6e40(0x1e0)](_0x17fb4))return'alpha';if(/-beta\./i[_0x4a6e40(0x1e0)](_0x17fb4))return _0x4a6e40(0x203);if(/-rc\./i['test'](_0x17fb4))return'rc';return _0x15756f[_0x4a6e40(0x20a)];}export function resolveInstallTarget(_0x4b52be){const _0xa20c8f=_0x4c6f,_0x3e97fd={'spTVB':function(_0x1d8c05,_0x55dff6){return _0x1d8c05(_0x55dff6);}},_0x5874d5=_0x3e97fd['spTVB'](resolveDistTag,_0x4b52be);if(_0x5874d5!=='latest')return _0x5874d5;const _0x3a0999=_0x4b52be['split']('.')[0x0],_0x15b515=parseInt(_0x3a0999,0xa);if(!Number['isFinite'](_0x15b515))return _0xa20c8f(0x1bf);return'^'+_0x15b515+'.0.0';}async function runInstall(_0x1cd154){const _0x298b9d=_0x4c6f,_0x1b0e4b={'xFIEx':function(_0x3f773e,_0x427a73,_0x4d890d,_0x52dc60){return _0x3f773e(_0x427a73,_0x4d890d,_0x52dc60);},'SfxYo':_0x298b9d(0x1f1),'DKroP':_0x298b9d(0x1ee),'UmoRk':_0x298b9d(0x1e1),'OpqAh':_0x298b9d(0x209)},_0x477238=resolveInstallTarget(_0x1cd154);return new Promise(_0x3b27ad=>{const _0x4f881e=_0x298b9d;console[_0x4f881e(0x1e6)](_0x4f881e(0x20b)+PACKAGE_NAME+'@'+_0x477238+'...\x0a');const _0x2fc37c=_0x1b0e4b[_0x4f881e(0x1fa)](spawn,_0x4f881e(0x1c9),[_0x1b0e4b[_0x4f881e(0x1fe)],'-g',PACKAGE_NAME+'@'+_0x477238],{'stdio':[_0x1b0e4b['DKroP'],'inherit',_0x1b0e4b['UmoRk']],'shell':process[_0x4f881e(0x1f7)]===_0x4f881e(0x1c4)});_0x2fc37c['on'](_0x4f881e(0x1db),_0x255e11=>{_0x3b27ad(_0x255e11===0x0);}),_0x2fc37c['on'](_0x1b0e4b[_0x4f881e(0x1e2)],()=>{_0x3b27ad(![]);});});}async function updateClaudeMarketplace(){const _0xd82509=_0x4c6f,_0x2bce59={'bsVAf':'claude','mBuKr':'plugin','QBXLq':_0xd82509(0x1f4),'QGGBA':'update','JqsBl':'trailhead'},_0x5798b7=await runCommand(_0x2bce59[_0xd82509(0x1f8)],[_0x2bce59['mBuKr'],_0x2bce59['QBXLq'],_0x2bce59[_0xd82509(0x1b7)],_0x2bce59[_0xd82509(0x1c2)]],{'timeoutMs':CLAUDE_COMMAND_TIMEOUT_MS});if(!_0x5798b7)throw new Error('Claude\x20marketplace\x20update\x20command\x20failed\x20(timed\x20out,\x20failed\x20to\x20start,\x20or\x20exited\x20with\x20a\x20non-zero\x20status).');}async function updateClaudePlugin(_0x1e6daa=_0x363c4f(0x1b9)){const _0x203220=_0x363c4f,_0x1564c3={'GiejT':_0x203220(0x1dc),'xTuwf':_0x203220(0x1fb),'WOYFa':'ranger@trailhead','WOfXF':function(_0x380b71,_0x1ba7db){return _0x380b71!==_0x1ba7db;},'uxoUe':function(_0x162ba7,_0x409c4f,_0x1863b0,_0x4e5dc3){return _0x162ba7(_0x409c4f,_0x1863b0,_0x4e5dc3);},'DORVW':'claude','sSZpX':function(_0x284f05,_0x8c1732){return _0x284f05===_0x8c1732;}},_0x31d412=[_0x1564c3[_0x203220(0x1cd)],_0x1564c3['xTuwf'],_0x1564c3[_0x203220(0x1e3)]];_0x1564c3['WOfXF'](_0x1e6daa,_0x203220(0x1b9))&&_0x31d412['push']('--scope',_0x1e6daa);const _0x1c4f86=await _0x1564c3[_0x203220(0x1e4)](runCommand,_0x1564c3[_0x203220(0x200)],_0x31d412,{'timeoutMs':CLAUDE_COMMAND_TIMEOUT_MS,'cwd':_0x1564c3['sSZpX'](_0x1e6daa,'project')||_0x1564c3[_0x203220(0x1cf)](_0x1e6daa,_0x203220(0x1cc))?getProjectRoot():undefined});if(!_0x1c4f86)throw new Error('Claude\x20plugin\x20update\x20failed\x20for\x20'+_0x1e6daa+'\x20scope\x20(timed\x20out,\x20failed\x20to\x20start,\x20or\x20exited\x20with\x20a\x20non-zero\x20status).');}function isSkillInstalled(_0x115748,_0x5dd593,_0x3333d9){const _0x30cad2=_0x363c4f,_0x2c3636={'zGqXh':function(_0x115630,_0x3e70c1){return _0x115630===_0x3e70c1;},'DvJbP':function(_0x5e43ae,_0xa60032){return _0x5e43ae(_0xa60032);}},_0xa13fcd=_0x2c3636['zGqXh'](_0x3333d9,'opencode')?_0x2c3636[_0x30cad2(0x1bd)](getOpencodeSkillsDir,_0x5dd593):getSkillsDir(_0x5dd593),_0x382f90=join(_0xa13fcd,_0x115748);return existsSync(_0x382f90);}async function reinstallSkills(_0x47f29d){const _0x20c1ac=_0x363c4f,_0xae3941={'PIolW':function(_0x5e2c07,_0x474a16,_0x4fc800,_0x537dfd){return _0x5e2c07(_0x474a16,_0x4fc800,_0x537dfd);},'TOLQV':'opencode','jGUPp':function(_0x2d742d,_0x1dad5b,_0x25c549){return _0x2d742d(_0x1dad5b,_0x25c549);},'xOMqg':'\x0aNo\x20ranger-managed\x20skills\x20found\x20to\x20reinstall.'},_0x1ac589=[_0x20c1ac(0x1c5),'user'],_0x1c5153=[];for(const _0x2c4870 of _0x1ac589){for(const _0x49b92f of RANGER_MANAGED_SKILLS){_0xae3941['PIolW'](isSkillInstalled,_0x49b92f,_0x2c4870,_0x20c1ac(0x1bc))&&_0x1c5153[_0x20c1ac(0x1f3)]({'skillName':_0x49b92f,'level':_0x2c4870,'platform':'claude'}),isSkillInstalled(_0x49b92f,_0x2c4870,_0xae3941['TOLQV'])&&_0x1c5153['push']({'skillName':_0x49b92f,'level':_0x2c4870,'platform':_0xae3941[_0x20c1ac(0x205)]});}}for(const _0x531b2a of _0x1ac589){for(const _0x29eed2 of DEPRECATED_SKILLS){await _0xae3941['jGUPp'](removeSkill,_0x29eed2,_0x531b2a);}}if(_0x1c5153['length']===0x0){console['log'](_0xae3941['xOMqg']);return;}console['log'](_0x20c1ac(0x207)+_0x1c5153[_0x20c1ac(0x1f6)]+'\x20ranger-managed\x20skill(s)...');for(const {skillName:_0x1fa617,level:_0x52fdaf,platform:_0x3920da}of _0x1c5153){try{await installSkill(_0x1fa617,{'level':_0x52fdaf,'cliVersion':_0x47f29d,'platform':_0x3920da});}catch(_0x123a23){console['warn']('\x20\x20Failed\x20to\x20reinstall\x20'+_0x3920da+'\x20'+_0x52fdaf+'\x20skill\x20'+_0x1fa617+':',_0x123a23);}}}async function ensureActiveProfileGitignored(){const _0x28f9f0=_0x363c4f,_0x49c221={'GPbrR':function(_0x377e90){return _0x377e90();},'FeCuN':'.gitignore','RNISv':function(_0x115d4b,_0x3ac117){return _0x115d4b(_0x3ac117);},'tXupJ':function(_0x46e9f7,_0x51abdf,_0xf144dd,_0x140501){return _0x46e9f7(_0x51abdf,_0xf144dd,_0x140501);},'OPUDk':'utf-8'},_0x1c5a1c=join(_0x49c221[_0x28f9f0(0x1c3)](getRangerDir),_0x49c221['FeCuN']);if(!_0x49c221[_0x28f9f0(0x20d)](existsSync,_0x1c5a1c))return![];let _0x42d993='';try{_0x42d993=await readFile(_0x1c5a1c,'utf-8');}catch{return![];}const _0x36541e=_0x42d993['split'](/\r?\n/);if(_0x36541e[_0x28f9f0(0x1c6)](_0x5295f1=>_0x5295f1[_0x28f9f0(0x1ca)]()===_0x28f9f0(0x206)))return![];let _0x901e68=_0x36541e[_0x28f9f0(0x1bb)](_0x4aa67e=>_0x4aa67e[_0x28f9f0(0x1ca)]()===_0x28f9f0(0x1c8));_0x901e68===-0x1&&(_0x901e68=_0x36541e['length']);_0x36541e['splice'](_0x901e68,0x0,_0x28f9f0(0x206));let _0x2384ab=_0x36541e[_0x28f9f0(0x1eb)]('\x0a');!_0x2384ab[_0x28f9f0(0x1f5)]('\x0a')&&(_0x2384ab+='\x0a');try{await _0x49c221['tXupJ'](writeFile,_0x1c5a1c,_0x2384ab,_0x49c221[_0x28f9f0(0x1e7)]);}catch{return![];}return!![];}export async function update(){const _0x5994a4=_0x363c4f,_0x249bd7={'TrTLj':function(_0x26a6bb){return _0x26a6bb();},'VPRBD':function(_0x171dc1,_0x26ce33){return _0x171dc1(_0x26ce33);},'HAtLA':function(_0x4d0222,_0x3efa41){return _0x4d0222(_0x3efa41);},'QZalj':_0x5994a4(0x1c1),'hxlfy':function(_0x261f80,_0x21b268){return _0x261f80+_0x21b268;},'IESGe':'\x0aSuccessfully\x20installed\x20latest\x20version.','tkMJP':_0x5994a4(0x1e8),'zkHry':function(_0x41f848,_0x221a36){return _0x41f848<_0x221a36;},'FwDSe':_0x5994a4(0x1d0),'AwpQm':_0x5994a4(0x1b8),'YVenZ':_0x5994a4(0x1c5),'weoBe':function(_0x1f0ec8,_0x52cb9c){return _0x1f0ec8===_0x52cb9c;}},_0x29b4ef=_0x249bd7['TrTLj'](getCurrentVersion);console['log']('\x0aCurrent\x20version:\x20'+_0x29b4ef);const _0x2949da=_0x249bd7['VPRBD'](resolveDistTag,_0x29b4ef);if(_0x2949da!==_0x5994a4(0x1bf)){console[_0x5994a4(0x1e6)]('Prerelease\x20channel\x20detected\x20(@'+_0x2949da+_0x5994a4(0x202)+_0x2949da+'\x20—\x20reinstalling\x20@'+_0x2949da+'...');const _0x10ff75=await runInstall(_0x29b4ef);if(!_0x10ff75)throw new Error('Update\x20failed\x20for\x20@'+_0x2949da+_0x5994a4(0x1d6));const _0x171a25=_0x249bd7['TrTLj'](getCurrentVersion);console[_0x5994a4(0x1e6)](_0x5994a4(0x1f0)+PACKAGE_NAME+'@'+_0x2949da+'.'),await _0x249bd7[_0x5994a4(0x1ef)](reinstallSkills,_0x171a25),await ensureActiveProfileGitignored(),console['log'](_0x249bd7['QZalj']);return;}console['log']('Checking\x20for\x20updates...');const _0x81759a=parseInt(_0x29b4ef['split']('.')[0x0],0xa);if(!Number[_0x5994a4(0x1cb)](_0x81759a))throw new Error(_0x249bd7['hxlfy'](_0x5994a4(0x1e5)+_0x29b4ef+'\x22.\x20'+_0x5994a4(0x1be),'npm\x20i\x20-g\x20'+PACKAGE_NAME+_0x5994a4(0x20c)));const _0xa98a4b=getLatestVersion(_0x81759a);let _0x21c585=_0x29b4ef;if(!_0xa98a4b[_0x5994a4(0x1dd)]){console['warn'](_0x5994a4(0x1ec)+_0xa98a4b[_0x5994a4(0x209)]),console[_0x5994a4(0x1e6)](_0x5994a4(0x1f2));const _0x3c2c80=await _0x249bd7['HAtLA'](runInstall,_0x29b4ef);if(_0x3c2c80)console['log'](_0x249bd7[_0x5994a4(0x208)]),_0x21c585=getCurrentVersion();else throw new Error(_0x5994a4(0x204)+_0xa98a4b['error']);}else{const _0x27b415=_0xa98a4b['version'];console['log']('Latest\x20version:\x20\x20'+_0x27b415);const _0x496ed6=compareVersions(_0x29b4ef,_0x27b415);if(_0x496ed6===0x0)console['log'](_0x249bd7['tkMJP']);else{if(_0x249bd7['zkHry'](_0x496ed6,0x0))console[_0x5994a4(0x1e6)]('\x0aYour\x20version\x20('+_0x29b4ef+_0x5994a4(0x1d2)+_0x27b415+').');else{const _0x43e8c6=await _0x249bd7['HAtLA'](runInstall,_0x29b4ef);if(_0x43e8c6)console[_0x5994a4(0x1e6)](_0x5994a4(0x1f9)+_0x27b415),_0x21c585=_0x27b415;else throw new Error('Update\x20failed.');}}}await reinstallSkills(_0x21c585);const _0x5dcace=await _0x249bd7[_0x5994a4(0x210)](isMarketplaceAdded,_0x5994a4(0x1d5)),_0x56d875=await isPluginInstalled(_0x249bd7['FwDSe']);_0x5dcace&&(await updateClaudeMarketplace(),console['log'](_0x249bd7['AwpQm']));if(_0x56d875){const _0x301891=await _0x249bd7[_0x5994a4(0x1ef)](getPluginInfo,_0x249bd7[_0x5994a4(0x1d7)]),_0x5b878a=_0x301891?.[_0x5994a4(0x1e9)]??'user';await updateClaudePlugin(_0x5b878a);if(_0x5b878a===_0x249bd7['YVenZ'])console['log']('\x0aClaude\x20plugin\x20updated\x20(project\x20scope).');else _0x249bd7[_0x5994a4(0x1fd)](_0x5b878a,'local')?console[_0x5994a4(0x1e6)](_0x5994a4(0x1c0)):console['log']('\x0aClaude\x20plugin\x20updated\x20(user\x20scope).');}const _0x4875d3=await _0x249bd7['TrTLj'](ensureActiveProfileGitignored);console['log']('\x0a✅\x20Update\x20complete!');}
@@ -1 +1 @@
1
- function _0x2261(_0x34dd64,_0x43492d){_0x34dd64=_0x34dd64-0xb6;const _0x2e1fa0=_0x2e1f();let _0x22611e=_0x2e1fa0[_0x34dd64];return _0x22611e;}(function(_0x30ee38,_0x447453){const _0x11c029=_0x2261,_0x1353f7=_0x30ee38();while(!![]){try{const _0x548a80=-parseInt(_0x11c029(0xd1))/0x1+parseInt(_0x11c029(0xe0))/0x2+-parseInt(_0x11c029(0xcb))/0x3*(parseInt(_0x11c029(0xd9))/0x4)+-parseInt(_0x11c029(0xd8))/0x5+-parseInt(_0x11c029(0xc8))/0x6+-parseInt(_0x11c029(0xd7))/0x7*(-parseInt(_0x11c029(0xc7))/0x8)+parseInt(_0x11c029(0xdc))/0x9;if(_0x548a80===_0x447453)break;else _0x1353f7['push'](_0x1353f7['shift']());}catch(_0x409964){_0x1353f7['push'](_0x1353f7['shift']());}}}(_0x2e1f,0xed973));function _0x2e1f(){const _0x197312=['gZdvM','manual','648588rWDejl','environmentKey','CyxrM','`\x20from\x20a\x20local\x20terminal,\x20or\x20set\x20up\x20automated\x20login\x20for\x20your\x20team\x20(contact\x20eng@ranger.net).','\x20\x20ranger\x20profile\x20add\x20','\x20\x20Falling\x20back\x20to\x20headed\x20browser...','665910bXurKw','\x22\x20has\x20no\x20URL\x20on\x20file\x20to\x20refresh\x20against.\x0a','baseUrl','Profile\x20\x22','qPFxx','Migrate\x20it\x20to\x20a\x20cloud\x20profile\x20by\x20running:\x0a','892689WDIzRI','621885VtdHoQ','8HtSxCN','not_configured','UFcwU','24390675byxaub','UCNTE','✓\x20Session\x20refreshed\x20for\x20\x22','Re-create\x20it\x20with:\x0a','121570pwCxHe','XHkkr','cwd','rvLmy','\x22\x20found.\x0a','\x0a\x20\x20Server-side\x20login\x20failed.\x20Test\x20output:','message','settings','setupHeaders','status','test_output','Can\x27t\x20refresh\x20\x22','tKiBs','sbWYA','\x20--url\x20<your-app-url>\x0a','\x22\x20non-interactively\x20—\x20this\x20profile\x20needs\x20a\x20headed\x20browser\x20to\x20capture\x20a\x20session.\x0a','domains','catch','exit','log','No\x20profile\x20named\x20\x22','Capturing\x20a\x20fresh\x20session\x20for\x20\x22','AqWne','32OtBpVP','6510708KjZwLD'];_0x2e1f=function(){return _0x197312;};return _0x2e1f();}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(_0x42ca0d,_0x21855d,_0x2844d6){const _0x4328b1=_0x2261,_0x4ed1ac={'UCNTE':function(_0x32edfe,_0x38913f){return _0x32edfe(_0x38913f);},'xMcYn':function(_0x35773e){return _0x35773e();},'oGUAJ':function(_0x5cce1e,_0x7abdf8){return _0x5cce1e===_0x7abdf8;},'QjVqz':'local','aJJhp':function(_0x12471f,_0x2bb0ce){return _0x12471f+_0x2bb0ce;},'CyxrM':function(_0x161ab2,_0x822f68){return _0x161ab2+_0x822f68;},'UFcwU':function(_0xefd088,_0x59ed8a,_0x5353c6){return _0xefd088(_0x59ed8a,_0x5353c6);},'CZtso':function(_0x27e0fe,_0x4c6e8b){return _0x27e0fe===_0x4c6e8b;},'DjHPY':function(_0x25b36e,_0x472317){return _0x25b36e===_0x472317;},'qPFxx':_0x4328b1(0xda),'XHkkr':'\x20\x20Server-side\x20login\x20not\x20configured\x20for\x20this\x20org.\x20Falling\x20back\x20to\x20headed\x20browser...','rvLmy':'\x20\x20Falling\x20back\x20to\x20headed\x20browser...','gZdvM':function(_0x217b63,_0x100a07){return _0x217b63 instanceof _0x100a07;},'tKiBs':function(_0x51de5b,_0x287742,_0x13204a){return _0x51de5b(_0x287742,_0x13204a);},'JeRnF':function(_0x33c680,_0x27fc6b){return _0x33c680+_0x27fc6b;},'AqWne':function(_0x8f8e0c){return _0x8f8e0c();},'sbWYA':function(_0x214195,_0xa83069){return _0x214195+_0xa83069;},'FLWzL':function(_0x51e243,_0x5cdeda,_0x26ca84){return _0x51e243(_0x5cdeda,_0x26ca84);}},_0x3f2549=await _0x4ed1ac[_0x4328b1(0xdd)](fetchCloudProfile,_0x42ca0d);if(!_0x3f2549){const {envTypes:_0x393d6d}=await _0x4ed1ac['xMcYn'](getEnvNames),_0x513c35=_0x393d6d[_0x42ca0d];(_0x4ed1ac['oGUAJ'](_0x513c35,'legacy')||_0x513c35===_0x4ed1ac['QjVqz']||_0x513c35==='ci')&&(console['error'](_0x4ed1ac['aJJhp'](_0x4ed1ac['aJJhp'](_0x4328b1(0xd4)+_0x42ca0d+'\x22\x20is\x20a\x20legacy\x20on-disk\x20profile\x20and\x20can\x20no\x20longer\x20be\x20refreshed\x20in\x20place.\x0a',_0x4328b1(0xd6)),'\x0a')+(_0x4328b1(0xcf)+_0x42ca0d+'\x0a')),process[_0x4328b1(0xc2)](0x1));}!_0x3f2549&&(console['error'](_0x4ed1ac['CyxrM'](_0x4ed1ac['aJJhp'](_0x4328b1(0xc4)+_0x42ca0d+_0x4328b1(0xe4),'Create\x20it\x20with:\x0a'),'\x0a')+(_0x4328b1(0xcf)+_0x42ca0d+'\x0a')),process['exit'](0x1));const _0x5bc66c=await fetchAuthConfig()[_0x4328b1(0xc1)](()=>null),_0x362fc0=_0x3f2549['environmentKey']&&_0x5bc66c?_0x4ed1ac[_0x4328b1(0xdb)](resolveAuthEnvironmentLocally,_0x5bc66c,_0x3f2549['environmentKey']):null;if(_0x3f2549['environmentKey']&&_0x362fc0&&!_0x2844d6?.[_0x4328b1(0xca)]){console[_0x4328b1(0xc3)]('Refreshing\x20session\x20for\x20\x22'+_0x42ca0d+'\x22\x20via\x20server-side\x20login...');try{const _0x43589f=await serverSideLogin(_0x42ca0d,{'force':!![]});if(_0x4ed1ac['CZtso'](_0x43589f[_0x4328b1(0xb9)],'success')){console['log'](_0x4328b1(0xde)+_0x42ca0d+'\x22.');return;}_0x4ed1ac['DjHPY'](_0x43589f['status'],_0x4ed1ac[_0x4328b1(0xd5)])?console['log'](_0x4ed1ac[_0x4328b1(0xe1)]):(_0x43589f[_0x4328b1(0xba)]&&(console[_0x4328b1(0xc3)](_0x4328b1(0xe5)),console['log'](_0x43589f['test_output'])),console[_0x4328b1(0xc3)](_0x4ed1ac[_0x4328b1(0xe3)]));}catch(_0x2e2c9f){console[_0x4328b1(0xc3)]('\x20\x20Server-side\x20login\x20error:\x20'+(_0x4ed1ac[_0x4328b1(0xc9)](_0x2e2c9f,Error)?_0x2e2c9f[_0x4328b1(0xb6)]:String(_0x2e2c9f))),console[_0x4328b1(0xc3)](_0x4328b1(0xd0));}}const _0x5c72b4=_0x4ed1ac[_0x4328b1(0xbc)](readProfileOverrides,process[_0x4328b1(0xe2)](),_0x42ca0d),_0xf5913e=mergeCloudProfileSettings(_0x3f2549[_0x4328b1(0xb7)]??{},_0x5c72b4??undefined),_0x559874=_0xf5913e[_0x4328b1(0xb8)],_0x1a2f52=_0xf5913e[_0x4328b1(0xd3)],_0x657362=_0x362fc0?{..._0x362fc0,'domains':_0x1a2f52?[_0x1a2f52,..._0x362fc0[_0x4328b1(0xc0)]]:_0x362fc0['domains'],'setupHeaders':_0x559874??_0x362fc0['setupHeaders']}:_0x1a2f52?{'key':_0x3f2549[_0x4328b1(0xcc)]??'','domains':[_0x1a2f52],'setupHeaders':_0x559874}:null;!_0x657362&&(console['error'](_0x4ed1ac[_0x4328b1(0xcd)](_0x4ed1ac['JeRnF'](_0x4328b1(0xd4)+_0x42ca0d+_0x4328b1(0xd2)+_0x4328b1(0xdf),'\x0a'),_0x4328b1(0xcf)+_0x42ca0d+_0x4328b1(0xbe))),process['exit'](0x1)),!_0x4ed1ac[_0x4328b1(0xc6)](isInteractive)&&(console['error'](_0x4ed1ac[_0x4328b1(0xbd)](_0x4328b1(0xbb)+_0x42ca0d+_0x4328b1(0xbf),'Run\x20`ranger\x20profile\x20update\x20'+_0x42ca0d+_0x4328b1(0xce))),process['exit'](0x1)),console['log'](_0x4328b1(0xc5)+_0x42ca0d+'\x22\x20via\x20headed\x20browser...'),await _0x4ed1ac['FLWzL'](manualBrowserLogin,_0x3f2549,_0x657362),console[_0x4328b1(0xc3)]('✓\x20Session\x20refreshed\x20for\x20\x22'+_0x42ca0d+'\x22.');}
1
+ function _0x56e4(_0x5a7788,_0x511427){_0x5a7788=_0x5a7788-0xe6;const _0x2b175f=_0x2b17();let _0x56e4ce=_0x2b175f[_0x5a7788];return _0x56e4ce;}(function(_0x245823,_0x42a7ca){const _0x53166d=_0x56e4,_0x2bfbc4=_0x245823();while(!![]){try{const _0x2aa784=parseInt(_0x53166d(0x102))/0x1*(parseInt(_0x53166d(0xe7))/0x2)+-parseInt(_0x53166d(0xf6))/0x3*(parseInt(_0x53166d(0xf3))/0x4)+parseInt(_0x53166d(0x100))/0x5+-parseInt(_0x53166d(0x105))/0x6*(parseInt(_0x53166d(0xfc))/0x7)+-parseInt(_0x53166d(0x10e))/0x8*(-parseInt(_0x53166d(0x108))/0x9)+-parseInt(_0x53166d(0xe8))/0xa+-parseInt(_0x53166d(0x103))/0xb*(-parseInt(_0x53166d(0xfa))/0xc);if(_0x2aa784===_0x42a7ca)break;else _0x2bfbc4['push'](_0x2bfbc4['shift']());}catch(_0x37f1d9){_0x2bfbc4['push'](_0x2bfbc4['shift']());}}}(_0x2b17,0xaf7f1));import{fetchAuthConfig,fetchCloudProfile,manualBrowserLogin,serverSideLogin}from'./utils/cloudProfile.js';import{isInteractive,resolveAuthEnvironmentLocally}from'./utils/cloudProfileSession.js';function _0x2b17(){const _0x451a5f=['2134BtcoGm','12608700tVFwzZ','\x20--url\x20<your-app-url>\x0a','error','\x0a\x20\x20Server-side\x20login\x20failed.\x20Test\x20output:','✓\x20Session\x20refreshed\x20for\x20\x22','status','Re-create\x20it\x20with:\x0a','\x20\x20ranger\x20profile\x20add\x20','log','jlCbU','environmentKey','275348cwxUwj','dHqtA','legacy','21xgqaCG','ZRFyl','\x20\x20Server-side\x20login\x20not\x20configured\x20for\x20this\x20org.\x20Falling\x20back\x20to\x20headed\x20browser...','FhxDD','3683868PEfYut','exit','7UgGmDH','Profile\x20\x22','UQYUF','BBrvT','6268430MOFlHK','TzaLj','1013RxsfMc','22VgCvDn','`\x20from\x20a\x20local\x20terminal,\x20or\x20set\x20up\x20automated\x20login\x20for\x20your\x20team\x20(contact\x20eng@ranger.net).','4170594XNSFBG','domains','yphYB','9caLcwg','Migrate\x20it\x20to\x20a\x20cloud\x20profile\x20by\x20running:\x0a','\x22\x20found.\x0a','not_configured','catch','test_output','1665008hqcOZP','dxeyz'];_0x2b17=function(){return _0x451a5f;};return _0x2b17();}import{mergeCloudProfileSettings,readProfileOverrides}from'./utils/projectsConfig.js';import{getEnvNames}from'./env.js';export async function updateEnv(_0x2356f5,_0x48698f,_0x55d0ca){const _0x2f8e28=_0x56e4,_0x29509d={'jlCbU':function(_0x1767f1,_0x27ba06){return _0x1767f1(_0x27ba06);},'dxeyz':function(_0x54d52d,_0x14e773){return _0x54d52d===_0x14e773;},'CbeGx':_0x2f8e28(0xf5),'hIjhX':'local','BBrvT':function(_0x25b7b6,_0x449f2a){return _0x25b7b6+_0x449f2a;},'dHqtA':function(_0x1d3cba,_0x1a9aeb){return _0x1d3cba+_0x1a9aeb;},'UQYUF':function(_0x2215aa){return _0x2215aa();},'TzaLj':function(_0x3fec32,_0x5244c2,_0x55c4b1){return _0x3fec32(_0x5244c2,_0x55c4b1);},'FBOKW':function(_0x573e40,_0x3024eb,_0x147c99){return _0x573e40(_0x3024eb,_0x147c99);},'FhxDD':'success','GvvdM':_0x2f8e28(0xeb),'ZRFyl':function(_0x75325a,_0x59575f){return _0x75325a(_0x59575f);},'yphYB':function(_0x158ef7,_0x43c966){return _0x158ef7??_0x43c966;},'kESKg':function(_0x1d3df5,_0xc1fc3e){return _0x1d3df5+_0xc1fc3e;}},_0x4703cf=await _0x29509d[_0x2f8e28(0xf1)](fetchCloudProfile,_0x2356f5);if(!_0x4703cf){const {envTypes:_0x53b3d7}=await getEnvNames(),_0x1b97af=_0x53b3d7[_0x2356f5];(_0x29509d[_0x2f8e28(0xe6)](_0x1b97af,_0x29509d['CbeGx'])||_0x1b97af===_0x29509d['hIjhX']||_0x1b97af==='ci')&&(console['error'](_0x29509d[_0x2f8e28(0xff)](_0x29509d[_0x2f8e28(0xf4)]('Profile\x20\x22'+_0x2356f5+'\x22\x20is\x20a\x20legacy\x20on-disk\x20profile\x20and\x20can\x20no\x20longer\x20be\x20refreshed\x20in\x20place.\x0a'+_0x2f8e28(0x109),'\x0a'),_0x2f8e28(0xef)+_0x2356f5+'\x0a')),process['exit'](0x1));}!_0x4703cf&&(console[_0x2f8e28(0xea)](_0x29509d['dHqtA']('No\x20profile\x20named\x20\x22'+_0x2356f5+_0x2f8e28(0x10a),'Create\x20it\x20with:\x0a')+'\x0a'+('\x20\x20ranger\x20profile\x20add\x20'+_0x2356f5+'\x0a')),process['exit'](0x1));const _0x5119ca=await _0x29509d[_0x2f8e28(0xfe)](fetchAuthConfig)[_0x2f8e28(0x10c)](()=>null),_0x393a23=_0x4703cf[_0x2f8e28(0xf2)]&&_0x5119ca?_0x29509d[_0x2f8e28(0x101)](resolveAuthEnvironmentLocally,_0x5119ca,_0x4703cf['environmentKey']):null;if(_0x4703cf['environmentKey']&&_0x393a23&&!_0x55d0ca?.['manual']){console[_0x2f8e28(0xf0)]('Refreshing\x20session\x20for\x20\x22'+_0x2356f5+'\x22\x20via\x20server-side\x20login...');try{const _0x17def0=await _0x29509d['FBOKW'](serverSideLogin,_0x2356f5,{'force':!![]});if(_0x17def0['status']===_0x29509d[_0x2f8e28(0xf9)]){console['log'](_0x2f8e28(0xec)+_0x2356f5+'\x22.');return;}_0x29509d['dxeyz'](_0x17def0[_0x2f8e28(0xed)],_0x2f8e28(0x10b))?console['log'](_0x2f8e28(0xf8)):(_0x17def0['test_output']&&(console[_0x2f8e28(0xf0)](_0x29509d['GvvdM']),console[_0x2f8e28(0xf0)](_0x17def0[_0x2f8e28(0x10d)])),console['log']('\x20\x20Falling\x20back\x20to\x20headed\x20browser...'));}catch(_0x3be837){console['log']('\x20\x20Server-side\x20login\x20error:\x20'+(_0x3be837 instanceof Error?_0x3be837['message']:_0x29509d[_0x2f8e28(0xf7)](String,_0x3be837))),console[_0x2f8e28(0xf0)]('\x20\x20Falling\x20back\x20to\x20headed\x20browser...');}}const _0x1bcf21=readProfileOverrides(process['cwd'](),_0x2356f5),_0x161926=mergeCloudProfileSettings(_0x4703cf['settings']??{},_0x29509d[_0x2f8e28(0x107)](_0x1bcf21,undefined)),_0x96f215=_0x161926['setupHeaders'],_0x5c16a3=_0x161926['baseUrl'],_0x348fee=_0x393a23?{..._0x393a23,'domains':_0x5c16a3?[_0x5c16a3,..._0x393a23[_0x2f8e28(0x106)]]:_0x393a23[_0x2f8e28(0x106)],'setupHeaders':_0x96f215??_0x393a23['setupHeaders']}:_0x5c16a3?{'key':_0x4703cf['environmentKey']??'','domains':[_0x5c16a3],'setupHeaders':_0x96f215}:null;!_0x348fee&&(console['error'](_0x29509d['kESKg'](_0x2f8e28(0xfd)+_0x2356f5+'\x22\x20has\x20no\x20URL\x20on\x20file\x20to\x20refresh\x20against.\x0a'+_0x2f8e28(0xee)+'\x0a','\x20\x20ranger\x20profile\x20add\x20'+_0x2356f5+_0x2f8e28(0xe9))),process['exit'](0x1)),!isInteractive()&&(console['error'](_0x29509d['BBrvT']('Can\x27t\x20refresh\x20\x22'+_0x2356f5+'\x22\x20non-interactively\x20—\x20this\x20profile\x20needs\x20a\x20headed\x20browser\x20to\x20capture\x20a\x20session.\x0a','Run\x20`ranger\x20profile\x20update\x20'+_0x2356f5+_0x2f8e28(0x104))),process[_0x2f8e28(0xfb)](0x1)),console[_0x2f8e28(0xf0)]('Capturing\x20a\x20fresh\x20session\x20for\x20\x22'+_0x2356f5+'\x22\x20via\x20headed\x20browser...'),await manualBrowserLogin(_0x4703cf,_0x348fee),console[_0x2f8e28(0xf0)]('✓\x20Session\x20refreshed\x20for\x20\x22'+_0x2356f5+'\x22.');}
@@ -1 +1 @@
1
- (function(_0x2a948c,_0x173cc7){const _0x33a690=_0x4e70,_0x2ec8aa=_0x2a948c();while(!![]){try{const _0x3c767f=-parseInt(_0x33a690(0xfc))/0x1+parseInt(_0x33a690(0xf9))/0x2*(parseInt(_0x33a690(0xfd))/0x3)+-parseInt(_0x33a690(0xed))/0x4*(parseInt(_0x33a690(0xf2))/0x5)+parseInt(_0x33a690(0xfa))/0x6*(-parseInt(_0x33a690(0xff))/0x7)+parseInt(_0x33a690(0xfe))/0x8+-parseInt(_0x33a690(0xeb))/0x9*(-parseInt(_0x33a690(0xf0))/0xa)+parseInt(_0x33a690(0xf5))/0xb;if(_0x3c767f===_0x173cc7)break;else _0x2ec8aa['push'](_0x2ec8aa['shift']());}catch(_0x48c380){_0x2ec8aa['push'](_0x2ec8aa['shift']());}}}(_0x325b,0xc1abc));function _0x325b(){const _0x4e86d1=['3370ZDrHGt','rVAbK','6485275MvgoTl','\x0a✓\x20Now\x20using\x20profile\x20\x22','TpyFF','25249950jrOEtb','\x22\x20not\x20found\x20locally\x20or\x20in\x20the\x20cloud.\x20','Run\x20`ranger\x20profile\x20ls`\x20to\x20see\x20available\x20profiles,\x20or\x20','HqCGM','559298kPBnVR','30OZQhFP','settings.json','611131hRMkGf','15NvkpsC','2397440xuhlgh','1905869rCZqLD','`\x20to\x20create\x20one.','TIHSe','1854GCBpgl','status','4OFjZcE','log','TTbTz'];_0x325b=function(){return _0x4e86d1;};return _0x325b();}function _0x4e70(_0x54c489,_0x490fca){_0x54c489=_0x54c489-0xea;const _0x325bcc=_0x325b();let _0x4e70c1=_0x325bcc[_0x54c489];return _0x4e70c1;}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(_0x2e3456){const _0x4843fa=_0x4e70,_0x30ab05={'HqCGM':function(_0x4cff0a,_0x17960a){return _0x4cff0a(_0x17960a);},'TTbTz':function(_0x1916fc,_0x127db0){return _0x1916fc(_0x127db0);},'TpyFF':function(_0x29ccb9,_0x3c8b41){return _0x29ccb9 instanceof _0x3c8b41;},'TIHSe':function(_0x1e5baa,_0x572631){return _0x1e5baa+_0x572631;},'rVAbK':function(_0xf3ead0,_0x522924){return _0xf3ead0(_0x522924);}},_0x199ef5=getEnvDir(_0x2e3456),_0x2d86fe=join(_0x199ef5,_0x4843fa(0xfb)),_0x2f1177=_0x30ab05[_0x4843fa(0xf8)](existsSync,_0x199ef5)&&_0x30ab05[_0x4843fa(0xef)](existsSync,_0x2d86fe);if(_0x2f1177){await writeActiveProfileName(_0x2e3456),console[_0x4843fa(0xee)]('\x0a✓\x20Now\x20using\x20profile\x20\x22'+_0x2e3456+'\x22');return;}let _0x4a781b=null,_0x4f613d=![];try{_0x4a781b=await _0x30ab05['TTbTz'](fetchCloudProfile,_0x2e3456);if(!_0x4a781b)_0x4f613d=!![];}catch(_0x540c72){_0x30ab05[_0x4843fa(0xf4)](_0x540c72,ApiError)&&_0x540c72[_0x4843fa(0xec)]===0x194&&(_0x4f613d=!![]);}if(_0x4f613d)throw new Error(_0x30ab05[_0x4843fa(0xea)]('Profile\x20\x22'+_0x2e3456+_0x4843fa(0xf6)+_0x4843fa(0xf7),'`ranger\x20profile\x20add\x20'+_0x2e3456+_0x4843fa(0x100)));await _0x30ab05[_0x4843fa(0xf1)](writeActiveProfileName,_0x2e3456),console[_0x4843fa(0xee)](_0x4843fa(0xf3)+_0x2e3456+'\x22');}
1
+ function _0xa5c9(_0x2fe57e,_0x16afb1){_0x2fe57e=_0x2fe57e-0x1ee;const _0x40b8dd=_0x40b8();let _0xa5c9cb=_0x40b8dd[_0x2fe57e];return _0xa5c9cb;}(function(_0x4679c3,_0x6da604){const _0x10d342=_0xa5c9,_0x3e59b6=_0x4679c3();while(!![]){try{const _0x585fff=-parseInt(_0x10d342(0x1fc))/0x1*(parseInt(_0x10d342(0x1fb))/0x2)+-parseInt(_0x10d342(0x1f9))/0x3+-parseInt(_0x10d342(0x1f5))/0x4+-parseInt(_0x10d342(0x1f1))/0x5*(-parseInt(_0x10d342(0x1f0))/0x6)+parseInt(_0x10d342(0x1f3))/0x7+-parseInt(_0x10d342(0x1f8))/0x8*(parseInt(_0x10d342(0x1fe))/0x9)+-parseInt(_0x10d342(0x1f7))/0xa*(-parseInt(_0x10d342(0x1fd))/0xb);if(_0x585fff===_0x6da604)break;else _0x3e59b6['push'](_0x3e59b6['shift']());}catch(_0x5f0264){_0x3e59b6['push'](_0x3e59b6['shift']());}}}(_0x40b8,0x59bd4));import{join}from'path';function _0x40b8(){const _0x43c852=['11qKOvFD','963855UUqwdf','`ranger\x20profile\x20add\x20','status','812832xLAFFR','5BZaHpM','settings.json','1605457kDxLuq','log','2166632SKtTSq','\x0a✓\x20Now\x20using\x20profile\x20\x22','14972060amNxTk','8oWjqRS','1514991ASXANH','hXRQT','227138JCCbXN','3IeITHR'];_0x40b8=function(){return _0x43c852;};return _0x40b8();}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(_0x55be66){const _0xb0db9=_0xa5c9,_0x556c0e={'hXRQT':function(_0x25cfca,_0x183ff1,_0x2eb746){return _0x25cfca(_0x183ff1,_0x2eb746);},'ONIhp':function(_0x1f28b0,_0x58f978){return _0x1f28b0(_0x58f978);},'wwEvC':function(_0x159216,_0x12a52f){return _0x159216 instanceof _0x12a52f;}},_0x406f1=getEnvDir(_0x55be66),_0x456306=_0x556c0e[_0xb0db9(0x1fa)](join,_0x406f1,_0xb0db9(0x1f2)),_0x3d28c9=existsSync(_0x406f1)&&existsSync(_0x456306);if(_0x3d28c9){await _0x556c0e['ONIhp'](writeActiveProfileName,_0x55be66),console[_0xb0db9(0x1f4)](_0xb0db9(0x1f6)+_0x55be66+'\x22');return;}let _0xe86e49=null,_0x1c81dc=![];try{_0xe86e49=await fetchCloudProfile(_0x55be66);if(!_0xe86e49)_0x1c81dc=!![];}catch(_0x232b5a){_0x556c0e['wwEvC'](_0x232b5a,ApiError)&&_0x232b5a[_0xb0db9(0x1ef)]===0x194&&(_0x1c81dc=!![]);}if(_0x1c81dc)throw new Error('Profile\x20\x22'+_0x55be66+'\x22\x20not\x20found\x20locally\x20or\x20in\x20the\x20cloud.\x20'+'Run\x20`ranger\x20profile\x20ls`\x20to\x20see\x20available\x20profiles,\x20or\x20'+(_0xb0db9(0x1ee)+_0x55be66+'`\x20to\x20create\x20one.'));await writeActiveProfileName(_0x55be66),console[_0xb0db9(0x1f4)](_0xb0db9(0x1f6)+_0x55be66+'\x22');}
@@ -1 +1 @@
1
- const _0x352149=_0x5cca;(function(_0x13223d,_0x1f834a){const _0x12601b=_0x5cca,_0x2e5ae5=_0x13223d();while(!![]){try{const _0x6a7346=-parseInt(_0x12601b(0x174))/0x1*(parseInt(_0x12601b(0x17d))/0x2)+-parseInt(_0x12601b(0x17b))/0x3*(parseInt(_0x12601b(0x178))/0x4)+-parseInt(_0x12601b(0x170))/0x5+-parseInt(_0x12601b(0x172))/0x6*(parseInt(_0x12601b(0x177))/0x7)+parseInt(_0x12601b(0x175))/0x8+parseInt(_0x12601b(0x17c))/0x9+parseInt(_0x12601b(0x179))/0xa;if(_0x6a7346===_0x1f834a)break;else _0x2e5ae5['push'](_0x2e5ae5['shift']());}catch(_0x2e6cf6){_0x2e5ae5['push'](_0x2e5ae5['shift']());}}}(_0x288e,0xa8067));import{existsSync}from'fs';import{readFile}from'fs/promises';function _0x288e(){const _0x520b6b=['trim','690466rThvMo','4OXMpCr','33207970owKrKQ','active-profile.txt','1193334YiDSnF','2280465RJaMBt','1741492tPXmjN','WTNWo','6492055izNWDf','nFfwL','72qwFcPY','ApvoD','1vgByPA','6917120wZHmEM'];_0x288e=function(){return _0x520b6b;};return _0x288e();}import{join}from'path';import{getRangerDir,getRangerHomeDir}from'./rangerRoot.js';import{readLastProfile,writeLastProfile}from'./projectsConfig.js';const LEGACY_ACTIVE_PROFILE_FILE=_0x352149(0x17a),LEGACY_ACTIVE_ENV_FILE='active-env.txt';function _0x5cca(_0x596a72,_0x211fdf){_0x596a72=_0x596a72-0x170;const _0x288eb6=_0x288e();let _0x5ccab5=_0x288eb6[_0x596a72];return _0x5ccab5;}function readLegacyActiveProfileFile(){const _0x5a1fea=_0x352149,_0x3bfdd4={'Zgnbv':function(_0x20f2bf,_0x50552f,_0x30a9f6){return _0x20f2bf(_0x50552f,_0x30a9f6);},'nFfwL':function(_0x3ecd9a,_0x20282d,_0x440f04){return _0x3ecd9a(_0x20282d,_0x440f04);},'ApvoD':function(_0x5af30a){return _0x5af30a();}},_0x184e80=[join(getRangerDir(),LEGACY_ACTIVE_PROFILE_FILE),_0x3bfdd4['Zgnbv'](join,getRangerHomeDir(),LEGACY_ACTIVE_PROFILE_FILE),_0x3bfdd4[_0x5a1fea(0x171)](join,_0x3bfdd4[_0x5a1fea(0x173)](getRangerDir),LEGACY_ACTIVE_ENV_FILE),join(_0x3bfdd4[_0x5a1fea(0x173)](getRangerHomeDir),LEGACY_ACTIVE_ENV_FILE)];for(const _0x3885bc of _0x184e80){if(existsSync(_0x3885bc))return _0x3885bc;}return null;}export async function readActiveProfileName(){const _0x2dab73=_0x352149,_0x2f5ae6={'dloDw':function(_0x4ddf0e){return _0x4ddf0e();},'aCpoA':'utf-8'},_0x5c711d=readLastProfile(process['cwd']());if(_0x5c711d)return _0x5c711d;const _0x48737e=_0x2f5ae6['dloDw'](readLegacyActiveProfileFile);if(!_0x48737e)return null;try{return(await readFile(_0x48737e,_0x2f5ae6['aCpoA']))[_0x2dab73(0x176)]()||null;}catch{return null;}}export async function writeActiveProfileName(_0x43e28a){const _0x47121f=_0x352149,_0x47bd88={'WTNWo':function(_0x5cf7cf,_0xc65f23,_0x42fa70){return _0x5cf7cf(_0xc65f23,_0x42fa70);}};_0x47bd88[_0x47121f(0x17e)](writeLastProfile,process['cwd'](),_0x43e28a);}
1
+ function _0x5b56(){const _0x573cd2=['292608FFaXRD','440090HbUEWb','204ViPlbl','Plakz','cwd','12JoBEcF','839724ZUesbJ','16099369powkQl','9KjEEds','2700957xvQptn','2283866HWtcnK','150555ejKUKV','20HwgQuB','8ftsiiE','active-env.txt'];_0x5b56=function(){return _0x573cd2;};return _0x5b56();}const _0x1494bd=_0x2555;(function(_0xd1201e,_0x3f78cd){const _0x2250d0=_0x2555,_0x1215da=_0xd1201e();while(!![]){try{const _0x39c8d4=-parseInt(_0x2250d0(0x199))/0x1+parseInt(_0x2250d0(0x19d))/0x2+parseInt(_0x2250d0(0x193))/0x3*(-parseInt(_0x2250d0(0x190))/0x4)+-parseInt(_0x2250d0(0x18f))/0x5*(parseInt(_0x2250d0(0x195))/0x6)+-parseInt(_0x2250d0(0x19c))/0x7*(-parseInt(_0x2250d0(0x191))/0x8)+parseInt(_0x2250d0(0x19b))/0x9*(parseInt(_0x2250d0(0x194))/0xa)+-parseInt(_0x2250d0(0x19a))/0xb*(-parseInt(_0x2250d0(0x198))/0xc);if(_0x39c8d4===_0x3f78cd)break;else _0x1215da['push'](_0x1215da['shift']());}catch(_0x2e2b13){_0x1215da['push'](_0x1215da['shift']());}}}(_0x5b56,0xa70a2));function _0x2555(_0x56c993,_0x496f96){_0x56c993=_0x56c993-0x18f;const _0x5b566b=_0x5b56();let _0x255539=_0x5b566b[_0x56c993];return _0x255539;}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='active-profile.txt',LEGACY_ACTIVE_ENV_FILE=_0x1494bd(0x192);function readLegacyActiveProfileFile(){const _0x2fba72=[join(getRangerDir(),LEGACY_ACTIVE_PROFILE_FILE),join(getRangerHomeDir(),LEGACY_ACTIVE_PROFILE_FILE),join(getRangerDir(),LEGACY_ACTIVE_ENV_FILE),join(getRangerHomeDir(),LEGACY_ACTIVE_ENV_FILE)];for(const _0x37ba8c of _0x2fba72){if(existsSync(_0x37ba8c))return _0x37ba8c;}return null;}export async function readActiveProfileName(){const _0x103935=_0x1494bd,_0x429b22={'Plakz':function(_0xe67ea5,_0x435bd4){return _0xe67ea5(_0x435bd4);},'ugZOd':function(_0x577976){return _0x577976();},'AhyRV':'utf-8'},_0x5df339=_0x429b22[_0x103935(0x196)](readLastProfile,process[_0x103935(0x197)]());if(_0x5df339)return _0x5df339;const _0x51fda7=_0x429b22['ugZOd'](readLegacyActiveProfileFile);if(!_0x51fda7)return null;try{return(await readFile(_0x51fda7,_0x429b22['AhyRV']))['trim']()||null;}catch{return null;}}export async function writeActiveProfileName(_0x3f1b81){const _0x5e2616=_0x1494bd;writeLastProfile(process[_0x5e2616(0x197)](),_0x3f1b81);}
@@ -1 +1 @@
1
- function _0x4344(){const _0x360515=['ZcCji','x-ranger-','XDG_CONFIG_HOME','GesjO','npm_config_userconfig','27xPAGKK','%PATH%','AWS_SESSION_TOKEN','PATH','UKXbJ','815080cwqFby','2628165vBclNW','filter','DEBUG','4096620soSnBT','CHROME_BIN','2094160feQHRs','length','2259936WhvEeD','EZMsk','AWS_ROLE_SESSION_NAME','AWS_SDK_LOAD_CONFIG','1200076VRrEzM','RANGERWRIGHT_CLICK_TIMEOUT_MS','push','AWS_WEB_IDENTITY_TOKEN_FILE','AWS_PROFILE','NPM_CONFIG_PREFIX','platform','NPM_CONFIG_USERCONFIG','entries','map','8gtMhad','AWS_CONFIG_FILE','npm_config_registry','TEMP','slice','has','metadata','NODE_ENV','PATH\x20is\x20missing\x20core\x20system\x20directories\x20like\x20`/usr/bin`\x20and\x20`/bin`.','bYQin','TMPDIR','split','TMP','includes','RANGER_TRANSPORT','Hwdze','Session\x20token\x20is\x20required\x20when\x20RANGER_BYOK=false','2zubwjq','NPM_CONFIG_REGISTRY','toLowerCase','trim','AWS_ACCESS_KEY_ID','sessionToken','RANGERWRIGHT_FORCE_CLICK_TIMEOUT_MS','RANGERWRIGHT_DAEMON_START_TIMEOUT_MS','ranger-claude-tmp','env','2445039dgyFKz','HOME','from','PATH\x20contains\x20an\x20unexpanded\x20placeholder\x20like\x20`${PATH}`\x20instead\x20of\x20the\x20expanded\x20current\x20PATH.'];_0x4344=function(){return _0x360515;};return _0x4344();}const _0x5f4a6d=_0x47a4;(function(_0x5d238d,_0x1ff65d){const _0x4f791f=_0x47a4,_0x2770c9=_0x5d238d();while(!![]){try{const _0x192b53=parseInt(_0x4f791f(0xac))/0x1+-parseInt(_0x4f791f(0x88))/0x2*(parseInt(_0x4f791f(0x92))/0x3)+-parseInt(_0x4f791f(0xb6))/0x4*(parseInt(_0x4f791f(0xa1))/0x5)+parseInt(_0x4f791f(0xa4))/0x6+parseInt(_0x4f791f(0xa0))/0x7+-parseInt(_0x4f791f(0xa8))/0x8*(-parseInt(_0x4f791f(0x9b))/0x9)+-parseInt(_0x4f791f(0xa6))/0xa;if(_0x192b53===_0x1ff65d)break;else _0x2770c9['push'](_0x2770c9['shift']());}catch(_0x7a1c2c){_0x2770c9['push'](_0x2770c9['shift']());}}}(_0x4344,0xbc3fb));import{delimiter,join}from'path';import{tmpdir}from'os';import{mkdirSync}from'fs';import{getAiProxyUrl}from'./environment.js';function _0x47a4(_0x466c6d,_0x13475a){_0x466c6d=_0x466c6d-0x7e;const _0x434427=_0x4344();let _0x47a455=_0x434427[_0x466c6d];return _0x47a455;}const AI_PROXY_METADATA_HEADERS_ENV_VAR='ANTHROPIC_CUSTOM_HEADERS',AGENT_ENV_PASSTHROUGH_KEYS=[_0x5f4a6d(0x9e),_0x5f4a6d(0x93),_0x5f4a6d(0x81),_0x5f4a6d(0x83),_0x5f4a6d(0xb9),'USERPROFILE','APPDATA','LOCALAPPDATA','XDG_CACHE_HOME',_0x5f4a6d(0x98),'PLAYWRIGHT_BROWSERS_PATH','PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD',_0x5f4a6d(0xa5),'CHROMIUM_BIN','npm_config_cache','NPM_CONFIG_CACHE',_0x5f4a6d(0x9a),_0x5f4a6d(0xb3),'npm_config_prefix',_0x5f4a6d(0xb1),_0x5f4a6d(0xb8),_0x5f4a6d(0x89),_0x5f4a6d(0xa3),_0x5f4a6d(0x7e),'RANGER_TEST_SKIP_BROWSER_WAIT',_0x5f4a6d(0x85),_0x5f4a6d(0x8f),_0x5f4a6d(0xad),_0x5f4a6d(0x8e),'NOVA_ACT_API_KEY',_0x5f4a6d(0xb0),'AWS_REGION','AWS_DEFAULT_REGION',_0x5f4a6d(0xb7),'AWS_SHARED_CREDENTIALS_FILE',_0x5f4a6d(0x8c),'AWS_SECRET_ACCESS_KEY',_0x5f4a6d(0x9d),_0x5f4a6d(0xab),_0x5f4a6d(0xaf),'AWS_ROLE_ARN',_0x5f4a6d(0xaa),AI_PROXY_METADATA_HEADERS_ENV_VAR],UNEXPANDED_PATH_TOKEN_PATTERNS=['${PATH}','$PATH',_0x5f4a6d(0x9c)];function parseCustomHeaders(_0x48f3c1){const _0x317924=_0x5f4a6d,_0x2d357f={'GesjO':function(_0x497e9f,_0x19f465){return _0x497e9f===_0x19f465;}};if(!_0x48f3c1)return[];return _0x48f3c1[_0x317924(0x82)](/\r?\n/)['map'](_0x4d86c9=>_0x4d86c9[_0x317924(0x8b)]())['filter'](Boolean)[_0x317924(0xb5)](_0x54211d=>{const _0x364371=_0x317924,_0x226a1a=_0x54211d['indexOf'](':');if(_0x2d357f[_0x364371(0x99)](_0x226a1a,-0x1))return null;const _0x195998=_0x54211d[_0x364371(0xba)](0x0,_0x226a1a)['trim'](),_0x2fd729=_0x54211d['slice'](_0x226a1a+0x1)[_0x364371(0x8b)]();if(!_0x195998)return null;return[_0x195998,_0x2fd729];})[_0x317924(0xa2)](_0x3ae24d=>_0x3ae24d!==null);}export function getAgentPathHealthWarning(_0x3c0e84,_0x286fd3=process[_0x5f4a6d(0xb2)]){const _0x2ce26b=_0x5f4a6d,_0x1bc7f6={'inXvg':function(_0x4eea3e,_0x5e1bd6){return _0x4eea3e===_0x5e1bd6;},'EZMsk':'win32','ZNnMh':'/usr/bin','ZPcDW':_0x2ce26b(0x7f),'PUMwF':function(_0x3ec4f1,_0x2f9758){return _0x3ec4f1===_0x2f9758;}},_0x514190=[],_0x355b2b=(_0x3c0e84||'')[_0x2ce26b(0x82)](delimiter)['filter'](Boolean);_0x1bc7f6['inXvg'](_0x355b2b['length'],0x0)&&_0x514190[_0x2ce26b(0xae)]('PATH\x20is\x20empty,\x20so\x20npm\x20and\x20core\x20system\x20tools\x20may\x20be\x20unavailable.');UNEXPANDED_PATH_TOKEN_PATTERNS['some'](_0x279698=>(_0x3c0e84||'')[_0x2ce26b(0x84)](_0x279698))&&_0x514190['push'](_0x2ce26b(0x95));if(_0x286fd3!==_0x1bc7f6[_0x2ce26b(0xa9)]){const _0x3b3a22=_0x355b2b['includes'](_0x1bc7f6['ZNnMh']),_0x14bc9b=_0x355b2b['includes']('/bin');!_0x3b3a22&&!_0x14bc9b&&_0x514190[_0x2ce26b(0xae)](_0x1bc7f6['ZPcDW']);}if(_0x1bc7f6['PUMwF'](_0x514190[_0x2ce26b(0xa7)],0x0))return null;return{'summary':'Your\x20PATH\x20looks\x20incomplete\x20for\x20browser\x20automation.\x20Ranger\x20will\x20keep\x20going,\x20but\x20browser\x20setup\x20may\x20fail.','issues':_0x514190};}export function buildAgentEnv(_0x56e6ff){const _0x539abe=_0x5f4a6d,_0x17c5f7={'UKXbJ':'TMPDIR','nbGpA':_0x539abe(0x83),'Hwdze':_0x539abe(0xb9),'bYQin':_0x539abe(0x90),'ZcCji':function(_0x227c4a,_0x5a6390){return _0x227c4a==_0x5a6390;}};if(_0x56e6ff['byokEnabled'])return Object['fromEntries'](Object[_0x539abe(0xb4)](process[_0x539abe(0x91)])[_0x539abe(0xa2)](_0x366efb=>typeof _0x366efb[0x1]==='string'));if(!_0x56e6ff[_0x539abe(0x8d)])throw new Error(_0x539abe(0x87));const _0x13d7fb={'ANTHROPIC_API_KEY':_0x56e6ff['sessionToken'],'ANTHROPIC_BASE_URL':getAiProxyUrl(),'DISABLE_TELEMETRY':'true'};for(const _0x11346 of AGENT_ENV_PASSTHROUGH_KEYS){const _0x3e845d=process[_0x539abe(0x91)][_0x11346];_0x3e845d&&![_0x17c5f7['UKXbJ'],_0x17c5f7['nbGpA'],_0x17c5f7[_0x539abe(0x86)]][_0x539abe(0x84)](_0x11346)&&(_0x13d7fb[_0x11346]=_0x3e845d);}const _0x300a91=join(tmpdir(),_0x17c5f7[_0x539abe(0x80)]);try{mkdirSync(_0x300a91,{'recursive':!![]});}catch{}_0x13d7fb[_0x17c5f7[_0x539abe(0x9f)]]=_0x300a91,_0x13d7fb[_0x539abe(0x83)]=_0x300a91,_0x13d7fb[_0x539abe(0xb9)]=_0x300a91;const _0x3dbd18=parseCustomHeaders(process['env'][AI_PROXY_METADATA_HEADERS_ENV_VAR]),_0x214019=new Map(_0x3dbd18),_0x4951ad=new Set(_0x3dbd18['map'](([_0x241b86])=>_0x241b86['toLowerCase']()));if(_0x56e6ff[_0x539abe(0xbc)])for(const [_0x23276e,_0x576790]of Object['entries'](_0x56e6ff['metadata'])){if(_0x17c5f7[_0x539abe(0x96)](_0x576790,null)||_0x576790==='')continue;const _0xe0698e=_0x539abe(0x97)+_0x23276e;!_0x4951ad[_0x539abe(0xbb)](_0xe0698e['toLowerCase']())&&(_0x214019['set'](_0xe0698e,_0x576790),_0x4951ad['add'](_0xe0698e[_0x539abe(0x8a)]()));}const _0x54204f=Array[_0x539abe(0x94)](_0x214019['entries']())['map'](([_0x499109,_0x4da09b])=>_0x499109+':\x20'+_0x4da09b)['join']('\x0a');return _0x54204f&&(_0x13d7fb[AI_PROXY_METADATA_HEADERS_ENV_VAR]=_0x54204f),_0x13d7fb;}
1
+ function _0x2c49(_0x2cbbdf,_0x1b3e91){_0x2cbbdf=_0x2cbbdf-0x1ae;const _0x471bc3=_0x471b();let _0x2c49df=_0x471bc3[_0x2cbbdf];return _0x2c49df;}const _0x5d7c1f=_0x2c49;(function(_0xd5c095,_0x22c45e){const _0x6950e3=_0x2c49,_0x28fcb7=_0xd5c095();while(!![]){try{const _0x208d01=parseInt(_0x6950e3(0x1cb))/0x1+-parseInt(_0x6950e3(0x1e8))/0x2+-parseInt(_0x6950e3(0x1c3))/0x3*(parseInt(_0x6950e3(0x1c0))/0x4)+parseInt(_0x6950e3(0x1bb))/0x5+parseInt(_0x6950e3(0x1ce))/0x6+parseInt(_0x6950e3(0x1e7))/0x7+parseInt(_0x6950e3(0x1b2))/0x8*(-parseInt(_0x6950e3(0x1cc))/0x9);if(_0x208d01===_0x22c45e)break;else _0x28fcb7['push'](_0x28fcb7['shift']());}catch(_0x4602d4){_0x28fcb7['push'](_0x28fcb7['shift']());}}}(_0x471b,0x6baf9));import{delimiter,join}from'path';import{tmpdir}from'os';import{mkdirSync}from'fs';import{getAiProxyUrl}from'./environment.js';function _0x471b(){const _0x55dfcd=['NPM_CONFIG_REGISTRY','string','ANTHROPIC_CUSTOM_HEADERS','AWS_ACCESS_KEY_ID','npm_config_prefix','LOCALAPPDATA','includes','join','agkqV','env','Mqwmb','toLowerCase','ZlZPl','NOVA_ACT_API_KEY','true','qcPAj','okbDu','PATH\x20contains\x20an\x20unexpanded\x20placeholder\x20like\x20`${PATH}`\x20instead\x20of\x20the\x20expanded\x20current\x20PATH.','AWS_ROLE_SESSION_NAME','RANGERWRIGHT_CLICK_TIMEOUT_MS','Session\x20token\x20is\x20required\x20when\x20RANGER_BYOK=false','length','6016031BNYRWh','311882tfyAoL','raEgl','map','NPM_CONFIG_USERCONFIG','AWS_SHARED_CREDENTIALS_FILE','AWS_WEB_IDENTITY_TOKEN_FILE','push','2403512mrlcdy','NPM_CONFIG_CACHE','USERPROFILE','split','PATH\x20is\x20missing\x20core\x20system\x20directories\x20like\x20`/usr/bin`\x20and\x20`/bin`.','RANGER_TRANSPORT','has','AWS_ROLE_ARN','fromEntries','2432120JaHDdt','APPDATA','from','/bin','some','7108chWrlO','CHROMIUM_BIN','%PATH%','1053vocxyD','PATH\x20is\x20empty,\x20so\x20npm\x20and\x20core\x20system\x20tools\x20may\x20be\x20unavailable.','PLAYWRIGHT_BROWSERS_PATH','PATH','RANGERWRIGHT_DAEMON_START_TIMEOUT_MS','TMPDIR','RANGERWRIGHT_FORCE_CLICK_TIMEOUT_MS','npm_config_registry','440050fQXqGb','27ZayXmD','entries','2016954NlCikl','slice','byokEnabled'];_0x471b=function(){return _0x55dfcd;};return _0x471b();}const AI_PROXY_METADATA_HEADERS_ENV_VAR=_0x5d7c1f(0x1d3),AGENT_ENV_PASSTHROUGH_KEYS=[_0x5d7c1f(0x1c6),'HOME',_0x5d7c1f(0x1c8),'TMP','TEMP',_0x5d7c1f(0x1b4),_0x5d7c1f(0x1bc),_0x5d7c1f(0x1d6),'XDG_CACHE_HOME','XDG_CONFIG_HOME',_0x5d7c1f(0x1c5),'PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD','CHROME_BIN',_0x5d7c1f(0x1c1),'npm_config_cache',_0x5d7c1f(0x1b3),'npm_config_userconfig',_0x5d7c1f(0x1ae),_0x5d7c1f(0x1d5),'NPM_CONFIG_PREFIX',_0x5d7c1f(0x1ca),_0x5d7c1f(0x1d1),'DEBUG','NODE_ENV','RANGER_TEST_SKIP_BROWSER_WAIT',_0x5d7c1f(0x1b7),_0x5d7c1f(0x1c7),_0x5d7c1f(0x1e4),_0x5d7c1f(0x1c9),_0x5d7c1f(0x1de),'AWS_PROFILE','AWS_REGION','AWS_DEFAULT_REGION','AWS_CONFIG_FILE',_0x5d7c1f(0x1af),_0x5d7c1f(0x1d4),'AWS_SECRET_ACCESS_KEY','AWS_SESSION_TOKEN','AWS_SDK_LOAD_CONFIG',_0x5d7c1f(0x1b0),_0x5d7c1f(0x1b9),_0x5d7c1f(0x1e3),AI_PROXY_METADATA_HEADERS_ENV_VAR],UNEXPANDED_PATH_TOKEN_PATTERNS=['${PATH}','$PATH',_0x5d7c1f(0x1c2)];function parseCustomHeaders(_0x5e2e8d){const _0x55ab24=_0x5d7c1f,_0x2a4ccc={'nAcUW':function(_0x5e8795,_0x4cfb82){return _0x5e8795+_0x4cfb82;}};if(!_0x5e2e8d)return[];return _0x5e2e8d[_0x55ab24(0x1b5)](/\r?\n/)['map'](_0x5b3564=>_0x5b3564['trim']())['filter'](Boolean)[_0x55ab24(0x1ea)](_0x198d41=>{const _0x3a8955=_0x55ab24,_0x4123c3=_0x198d41['indexOf'](':');if(_0x4123c3===-0x1)return null;const _0x4f88be=_0x198d41[_0x3a8955(0x1cf)](0x0,_0x4123c3)['trim'](),_0x31cf35=_0x198d41[_0x3a8955(0x1cf)](_0x2a4ccc['nAcUW'](_0x4123c3,0x1))['trim']();if(!_0x4f88be)return null;return[_0x4f88be,_0x31cf35];})['filter'](_0x128b57=>_0x128b57!==null);}export function getAgentPathHealthWarning(_0x193fac,_0x34b0f8=process['platform']){const _0x36ce1d=_0x5d7c1f,_0x3856bb={'Mqwmb':function(_0x293db0,_0x57560e){return _0x293db0===_0x57560e;},'ROWKi':_0x36ce1d(0x1c4),'okbDu':'/usr/bin','BETfn':_0x36ce1d(0x1b6)},_0x1841ac=[],_0x29984c=(_0x193fac||'')['split'](delimiter)['filter'](Boolean);_0x3856bb[_0x36ce1d(0x1db)](_0x29984c[_0x36ce1d(0x1e6)],0x0)&&_0x1841ac['push'](_0x3856bb['ROWKi']);UNEXPANDED_PATH_TOKEN_PATTERNS[_0x36ce1d(0x1bf)](_0x23af9e=>(_0x193fac||'')['includes'](_0x23af9e))&&_0x1841ac['push'](_0x36ce1d(0x1e2));if(_0x34b0f8!=='win32'){const _0x484c4b=_0x29984c[_0x36ce1d(0x1d7)](_0x3856bb[_0x36ce1d(0x1e1)]),_0x2c469a=_0x29984c[_0x36ce1d(0x1d7)](_0x36ce1d(0x1be));!_0x484c4b&&!_0x2c469a&&_0x1841ac[_0x36ce1d(0x1b1)](_0x3856bb['BETfn']);}if(_0x3856bb['Mqwmb'](_0x1841ac['length'],0x0))return null;return{'summary':'Your\x20PATH\x20looks\x20incomplete\x20for\x20browser\x20automation.\x20Ranger\x20will\x20keep\x20going,\x20but\x20browser\x20setup\x20may\x20fail.','issues':_0x1841ac};}export function buildAgentEnv(_0x277092){const _0x33505c=_0x5d7c1f,_0x5af88d={'gUuUs':function(_0x7b75d7){return _0x7b75d7();},'agkqV':_0x33505c(0x1df),'qcPAj':'TMP','raEgl':'ranger-claude-tmp','ZlZPl':function(_0x597263,_0x52e909,_0x44b10e){return _0x597263(_0x52e909,_0x44b10e);},'cfvEr':function(_0x4b70f9,_0x933c4b){return _0x4b70f9(_0x933c4b);},'ATVCh':function(_0x3476a2,_0x3cda7b){return _0x3476a2==_0x3cda7b;}};if(_0x277092[_0x33505c(0x1d0)])return Object[_0x33505c(0x1ba)](Object[_0x33505c(0x1cd)](process['env'])['filter'](_0x2c09e8=>typeof _0x2c09e8[0x1]===_0x33505c(0x1d2)));if(!_0x277092['sessionToken'])throw new Error(_0x33505c(0x1e5));const _0x2a1e2f={'ANTHROPIC_API_KEY':_0x277092['sessionToken'],'ANTHROPIC_BASE_URL':_0x5af88d['gUuUs'](getAiProxyUrl),'DISABLE_TELEMETRY':_0x5af88d[_0x33505c(0x1d9)]};for(const _0x2822fd of AGENT_ENV_PASSTHROUGH_KEYS){const _0x2b2a27=process[_0x33505c(0x1da)][_0x2822fd];_0x2b2a27&&!['TMPDIR',_0x5af88d[_0x33505c(0x1e0)],'TEMP']['includes'](_0x2822fd)&&(_0x2a1e2f[_0x2822fd]=_0x2b2a27);}const _0x375f0f=join(tmpdir(),_0x5af88d[_0x33505c(0x1e9)]);try{_0x5af88d[_0x33505c(0x1dd)](mkdirSync,_0x375f0f,{'recursive':!![]});}catch{}_0x2a1e2f['TMPDIR']=_0x375f0f,_0x2a1e2f[_0x5af88d['qcPAj']]=_0x375f0f,_0x2a1e2f['TEMP']=_0x375f0f;const _0x3b9c29=_0x5af88d['cfvEr'](parseCustomHeaders,process['env'][AI_PROXY_METADATA_HEADERS_ENV_VAR]),_0x49ba68=new Map(_0x3b9c29),_0x2f07e4=new Set(_0x3b9c29[_0x33505c(0x1ea)](([_0xc1ec89])=>_0xc1ec89[_0x33505c(0x1dc)]()));if(_0x277092['metadata'])for(const [_0x84d17a,_0x57013f]of Object[_0x33505c(0x1cd)](_0x277092['metadata'])){if(_0x5af88d['ATVCh'](_0x57013f,null)||_0x57013f==='')continue;const _0x4abf52='x-ranger-'+_0x84d17a;!_0x2f07e4[_0x33505c(0x1b8)](_0x4abf52[_0x33505c(0x1dc)]())&&(_0x49ba68['set'](_0x4abf52,_0x57013f),_0x2f07e4['add'](_0x4abf52[_0x33505c(0x1dc)]()));}const _0x293d8e=Array[_0x33505c(0x1bd)](_0x49ba68['entries']())[_0x33505c(0x1ea)](([_0x360c1a,_0x271a68])=>_0x360c1a+':\x20'+_0x271a68)[_0x33505c(0x1d8)]('\x0a');return _0x293d8e&&(_0x2a1e2f[AI_PROXY_METADATA_HEADERS_ENV_VAR]=_0x293d8e),_0x2a1e2f;}
@@ -1 +1 @@
1
- (function(_0x418972,_0x2254ba){const _0xf8aa0f=_0x14e3,_0x16281e=_0x418972();while(!![]){try{const _0x175d99=parseInt(_0xf8aa0f(0x1aa))/0x1+-parseInt(_0xf8aa0f(0x222))/0x2*(-parseInt(_0xf8aa0f(0x1d7))/0x3)+-parseInt(_0xf8aa0f(0x1e4))/0x4+parseInt(_0xf8aa0f(0x1da))/0x5*(parseInt(_0xf8aa0f(0x19e))/0x6)+parseInt(_0xf8aa0f(0x1d1))/0x7*(parseInt(_0xf8aa0f(0x1c9))/0x8)+parseInt(_0xf8aa0f(0x212))/0x9*(parseInt(_0xf8aa0f(0x1d8))/0xa)+-parseInt(_0xf8aa0f(0x203))/0xb*(parseInt(_0xf8aa0f(0x1d2))/0xc);if(_0x175d99===_0x2254ba)break;else _0x16281e['push'](_0x16281e['shift']());}catch(_0xd3c4ae){_0x16281e['push'](_0x16281e['shift']());}}}(_0x3191,0xaf551));const _0x6b33b4=(function(){const _0x1ddf75=_0x14e3,_0x2fe5f7={'xnDrW':function(_0x3698e8,_0x2bca5c){return _0x3698e8===_0x2bca5c;},'Hoaco':_0x1ddf75(0x1af)};let _0x34eda9=!![];return function(_0x5674fe,_0x55ae3d){const _0x77a0f2=_0x1ddf75,_0x3287aa={'wulCp':function(_0x3ffb78,_0x471383){return _0x3ffb78!==_0x471383;}};if(_0x2fe5f7[_0x77a0f2(0x21a)](_0x2fe5f7['Hoaco'],_0x2fe5f7['Hoaco'])){const _0x5c9e3a=_0x34eda9?function(){const _0x55619b=_0x77a0f2;if(_0x3287aa[_0x55619b(0x1bf)]('rhaYY',_0x55619b(0x1d0))){if(_0x55ae3d){const _0x314a67=_0x55ae3d[_0x55619b(0x210)](_0x5674fe,arguments);return _0x55ae3d=null,_0x314a67;}}else throw new _0x4197ff('No\x20API\x20token\x20configured.\x20Run:\x20ranger\x20setup\x20[token]');}:function(){};return _0x34eda9=![],_0x5c9e3a;}else{if(_0x5ca51e){const _0x2cc778=_0x2d6026[_0x77a0f2(0x210)](_0x35d7ad,arguments);return _0x31ae8a=null,_0x2cc778;}}};}()),_0x19f311=_0x6b33b4(this,function(){const _0x43164f=_0x14e3,_0x4755f3={'zrAGe':_0x43164f(0x1c4)};return _0x19f311[_0x43164f(0x1e1)]()[_0x43164f(0x1a0)]('(((.+)+)+)+$')['toString']()['constructor'](_0x19f311)[_0x43164f(0x1a0)](_0x4755f3[_0x43164f(0x205)]);});_0x19f311();import{getToken}from'./keychain.js';import{getApiBaseUrl}from'./environment.js';import{createHash}from'crypto';import{withRetry}from'./retry.js';export async function createBrowserSession(_0x512866){const _0x1b1513=_0x14e3,_0x54ea99={'qRgxP':'(((.+)+)+)+$','DRvRZ':function(_0x272fa2,_0x323750){return _0x272fa2===_0x323750;},'TOcrj':_0x1b1513(0x1b6),'FdQiQ':_0x1b1513(0x1c1),'SPywc':_0x1b1513(0x1fb),'sjFmU':function(_0x2b8055){return _0x2b8055();},'kTsHK':'POST','tyDIM':'application/json'},_0x25e07a=await getToken();if(!_0x25e07a){if(_0x54ea99[_0x1b1513(0x1e2)](_0x54ea99[_0x1b1513(0x1ec)],_0x54ea99[_0x1b1513(0x1b7)]))return _0x3e0b07[_0x1b1513(0x1e1)]()['search'](hcxDnM[_0x1b1513(0x1ac)])['toString']()[_0x1b1513(0x1f1)](_0x1f7224)[_0x1b1513(0x1a0)](hcxDnM['qRgxP']);else throw new Error(_0x54ea99['SPywc']);}const _0x216b42=_0x54ea99[_0x1b1513(0x1df)](getApiBaseUrl),_0x5674c0=await fetch(_0x216b42+'/api/v1/mcp/browser-sessions',{'method':_0x54ea99[_0x1b1513(0x208)],'headers':{'Authorization':_0x1b1513(0x1f7)+_0x25e07a,'Content-Type':_0x54ea99[_0x1b1513(0x216)]},'body':JSON[_0x1b1513(0x1c3)]({'environmentName':_0x512866?.[_0x1b1513(0x1ae)],'settings':_0x512866?.[_0x1b1513(0x1e8)],'task':_0x512866?.['task'],'url':_0x512866?.[_0x1b1513(0x21e)],'featureId':_0x512866?.[_0x1b1513(0x207)],'checklistItemId':_0x512866?.['checklistItemId']})});if(!_0x5674c0['ok']){const _0x1bc268=await _0x5674c0['text']();throw new Error(_0x1b1513(0x214)+_0x1bc268);}return _0x5674c0[_0x1b1513(0x217)]();}export async function updateBrowserSession(_0x519362,_0x2bcda4){const _0x5253e3=_0x14e3,_0x28452f={'sXFpk':'No\x20API\x20token\x20configured.\x20Run:\x20ranger\x20setup\x20[token]','mMUVT':function(_0x1fac4d,_0x1d998c){return _0x1fac4d!==_0x1d998c;},'vFiZx':_0x5253e3(0x1fd),'UUTYC':function(_0x2586a7){return _0x2586a7();},'ieBKr':'PATCH','uEwCZ':_0x5253e3(0x1ba),'XFTne':function(_0x798043,_0x1ccd2d){return _0x798043===_0x1ccd2d;},'cqOQR':'OkxYd'};return withRetry(async()=>{const _0x4ef7e8=_0x5253e3,_0x1df446={'zoycQ':_0x28452f['sXFpk']},_0x10a00c=await getToken();if(!_0x10a00c){if(_0x28452f['mMUVT'](_0x28452f[_0x4ef7e8(0x213)],_0x28452f['vFiZx']))throw new _0x23c88f(_0x1df446[_0x4ef7e8(0x21d)]);else throw new Error(_0x28452f['sXFpk']);}const _0x5c40b8=_0x28452f['UUTYC'](getApiBaseUrl),_0x2f84da=await fetch(_0x5c40b8+_0x4ef7e8(0x1ea)+_0x519362,{'method':_0x28452f[_0x4ef7e8(0x1a3)],'headers':{'Authorization':_0x4ef7e8(0x1f7)+_0x10a00c,'Content-Type':_0x28452f[_0x4ef7e8(0x1cc)]},'body':JSON[_0x4ef7e8(0x1c3)](_0x2bcda4)});if(!_0x2f84da['ok']){if(_0x28452f['XFTne'](_0x28452f[_0x4ef7e8(0x1f3)],_0x4ef7e8(0x1f9)))throw new _0x34e168(_0x4ef7e8(0x1fb));else{const _0x124dc9=await _0x2f84da[_0x4ef7e8(0x1f0)]();throw new Error(_0x4ef7e8(0x20d)+_0x124dc9);}}return _0x2f84da['json']();},{'label':_0x5253e3(0x1a2)});}export async function getBrowserSession(_0x3e9f32){const _0x52047a=_0x14e3,_0x3b563d={'EKLGq':function(_0x590886){return _0x590886();},'DlEjN':_0x52047a(0x1fb),'YdaRQ':function(_0x52034f){return _0x52034f();},'BgXCd':function(_0x2a9df9,_0x3e7176,_0x57e72f){return _0x2a9df9(_0x3e7176,_0x57e72f);},'yhjbd':_0x52047a(0x1cd)},_0x20e4c7=await _0x3b563d['EKLGq'](getToken);if(!_0x20e4c7)throw new Error(_0x3b563d[_0x52047a(0x20b)]);const _0x429355=_0x3b563d[_0x52047a(0x21b)](getApiBaseUrl),_0x12cc40=await _0x3b563d[_0x52047a(0x1b3)](fetch,_0x429355+_0x52047a(0x1ea)+_0x3e9f32,{'method':_0x3b563d[_0x52047a(0x1e0)],'headers':{'Authorization':'Bearer\x20'+_0x20e4c7}});if(!_0x12cc40['ok']){const _0x53f4eb=await _0x12cc40[_0x52047a(0x1f0)]();throw new Error('Failed\x20to\x20get\x20browser\x20session:\x20'+_0x53f4eb);}return _0x12cc40[_0x52047a(0x217)]();}export async function getUploadUrls(_0x15f790,_0x973b7a,_0x390077,_0x19bdeb){const _0x3aedc2=_0x14e3,_0x5323ec={'yOISr':function(_0x4de6ec){return _0x4de6ec();},'PIfJA':function(_0x59a886){return _0x59a886();},'YpZvl':function(_0x329374,_0x1010ea,_0x944e6){return _0x329374(_0x1010ea,_0x944e6);},'cUpne':_0x3aedc2(0x1f6),'tMPvJ':_0x3aedc2(0x1ba),'npZLH':function(_0x4d5b88,_0x611bae){return _0x4d5b88!==_0x611bae;},'LASSd':function(_0xe9081b,_0x118101){return _0xe9081b!==_0x118101;},'VmHtB':function(_0x7cce0b,_0x5018af){return _0x7cce0b!==_0x5018af;}},_0x2b429d=await _0x5323ec[_0x3aedc2(0x1ca)](getToken);if(!_0x2b429d)throw new Error(_0x3aedc2(0x1fb));const _0x24d567=_0x5323ec[_0x3aedc2(0x1e3)](getApiBaseUrl),_0x1e2da7=await _0x5323ec[_0x3aedc2(0x1b0)](fetch,_0x24d567+'/api/v1/mcp/browser-sessions/'+_0x15f790+_0x3aedc2(0x1b1),{'method':_0x5323ec[_0x3aedc2(0x21c)],'headers':{'Authorization':_0x3aedc2(0x1f7)+_0x2b429d,'Content-Type':_0x5323ec[_0x3aedc2(0x1d5)]},'body':JSON['stringify']({'filename':_0x973b7a,'filetype':_0x390077,..._0x5323ec[_0x3aedc2(0x1b5)](_0x19bdeb?.['size'],undefined)&&{'size':_0x19bdeb[_0x3aedc2(0x206)]},..._0x5323ec[_0x3aedc2(0x20e)](_0x19bdeb?.[_0x3aedc2(0x1c2)],undefined)&&{'checksum':_0x19bdeb[_0x3aedc2(0x1c2)]},..._0x5323ec[_0x3aedc2(0x1fc)](_0x19bdeb?.[_0x3aedc2(0x1e9)],undefined)&&{'metadata':_0x19bdeb[_0x3aedc2(0x1e9)]}})});if(!_0x1e2da7['ok']){const _0x2cb987=await _0x1e2da7[_0x3aedc2(0x1f0)]();throw new Error('Failed\x20to\x20get\x20upload\x20URLs:\x20'+_0x2cb987);}return _0x1e2da7[_0x3aedc2(0x217)]();}export async function uploadFile(_0x4e7fe6,_0x49bc64,_0x41cb89){const _0x3e7c6f=_0x14e3,_0x128814={'uDhfz':function(_0x3b0a43,_0x690a99,_0x239a9b){return _0x3b0a43(_0x690a99,_0x239a9b);},'IaYuB':_0x3e7c6f(0x21f)},_0x55afbb=await _0x128814[_0x3e7c6f(0x1f4)](fetch,_0x4e7fe6,{'method':_0x128814[_0x3e7c6f(0x204)],'headers':{'Content-Type':_0x41cb89,'Content-Length':_0x49bc64[_0x3e7c6f(0x1dd)][_0x3e7c6f(0x1e1)]()},'body':_0x49bc64});if(!_0x55afbb['ok']){const _0x217235=await _0x55afbb[_0x3e7c6f(0x1f0)]();throw new Error('Failed\x20to\x20upload\x20file:\x20'+_0x217235);}}export async function uploadTrace(_0x40c9be,_0x305a7f){const _0x4ab853=_0x14e3,_0x5cf61c={'KADZZ':function(_0x201231,_0x383eae,_0x499e64,_0x480e6c){return _0x201231(_0x383eae,_0x499e64,_0x480e6c);},'qRysY':_0x4ab853(0x202)};return _0x5cf61c['KADZZ'](uploadFile,_0x40c9be,_0x305a7f,_0x5cf61c['qRysY']);}export async function uploadConversation(_0x3deba4,_0x1a18aa){const _0x2c4d5f=_0x14e3,_0x2ecae5={'frHwv':function(_0x584d92,_0xc27a61,_0xf7bc38,_0x11cae3){return _0x584d92(_0xc27a61,_0xf7bc38,_0x11cae3);},'iHsre':'application/jsonl'};return _0x2ecae5[_0x2c4d5f(0x1f5)](uploadFile,_0x3deba4,_0x1a18aa,_0x2ecae5[_0x2c4d5f(0x1d9)]);}export async function uploadScreenshot(_0x4186c7,_0x2709b1){const _0x57417c=_0x14e3,_0xca96c9={'fTWOD':'image/png'};return uploadFile(_0x4186c7,_0x2709b1,_0xca96c9[_0x57417c(0x201)]);}function _0x14e3(_0x5f3320,_0x3d9296){_0x5f3320=_0x5f3320-0x19e;const _0x10fa01=_0x3191();let _0x19f311=_0x10fa01[_0x5f3320];if(_0x14e3['mYdgrB']===undefined){var _0x6b33b4=function(_0x58baa0){const _0x20235a='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';let _0x4b2e6c='',_0x54a08d='',_0x13976c=_0x4b2e6c+_0x6b33b4;for(let _0x47af57=0x0,_0x4d7e8e,_0x54a20f,_0x4a0e26=0x0;_0x54a20f=_0x58baa0['charAt'](_0x4a0e26++);~_0x54a20f&&(_0x4d7e8e=_0x47af57%0x4?_0x4d7e8e*0x40+_0x54a20f:_0x54a20f,_0x47af57++%0x4)?_0x4b2e6c+=_0x13976c['charCodeAt'](_0x4a0e26+0xa)-0xa!==0x0?String['fromCharCode'](0xff&_0x4d7e8e>>(-0x2*_0x47af57&0x6)):_0x47af57:0x0){_0x54a20f=_0x20235a['indexOf'](_0x54a20f);}for(let _0x3a88b5=0x0,_0x1481aa=_0x4b2e6c['length'];_0x3a88b5<_0x1481aa;_0x3a88b5++){_0x54a08d+='%'+('00'+_0x4b2e6c['charCodeAt'](_0x3a88b5)['toString'](0x10))['slice'](-0x2);}return decodeURIComponent(_0x54a08d);};_0x14e3['TRdNbU']=_0x6b33b4,_0x14e3['lVcVbk']={},_0x14e3['mYdgrB']=!![];}const _0x3191fb=_0x10fa01[0x0],_0x14e3b3=_0x5f3320+_0x3191fb,_0x4d5a79=_0x14e3['lVcVbk'][_0x14e3b3];if(!_0x4d5a79){const _0x17609b=function(_0x3bf3db){this['UHMTcu']=_0x3bf3db,this['iGBKek']=[0x1,0x0,0x0],this['LrCOQB']=function(){return'newState';},this['OWVeiY']='\x5cw+\x20*\x5c(\x5c)\x20*{\x5cw+\x20*',this['SKyVNh']='[\x27|\x22].+[\x27|\x22];?\x20*}';};_0x17609b['prototype']['NFABnz']=function(){const _0x18d5fb=new RegExp(this['OWVeiY']+this['SKyVNh']),_0x32da4e=_0x18d5fb['test'](this['LrCOQB']['toString']())?--this['iGBKek'][0x1]:--this['iGBKek'][0x0];return this['URmYYC'](_0x32da4e);},_0x17609b['prototype']['URmYYC']=function(_0x3d0cd0){if(!Boolean(~_0x3d0cd0))return _0x3d0cd0;return this['BtbUnY'](this['UHMTcu']);},_0x17609b['prototype']['BtbUnY']=function(_0x120b2e){for(let _0x37b51f=0x0,_0x546458=this['iGBKek']['length'];_0x37b51f<_0x546458;_0x37b51f++){this['iGBKek']['push'](Math['round'](Math['random']())),_0x546458=this['iGBKek']['length'];}return _0x120b2e(this['iGBKek'][0x0]);},new _0x17609b(_0x14e3)['NFABnz'](),_0x19f311=_0x14e3['TRdNbU'](_0x19f311),_0x14e3['lVcVbk'][_0x14e3b3]=_0x19f311;}else _0x19f311=_0x4d5a79;return _0x19f311;}export async function uploadVideo(_0x169886,_0x3616ac){const _0x5f4592=_0x14e3,_0x26ba42={'Gtbth':function(_0x16c60b,_0x1ee155,_0x597b08,_0x475b33){return _0x16c60b(_0x1ee155,_0x597b08,_0x475b33);},'BZErH':_0x5f4592(0x1b9)};return _0x26ba42[_0x5f4592(0x1cf)](uploadFile,_0x169886,_0x3616ac,_0x26ba42[_0x5f4592(0x1b8)]);}export function buildTraceViewerUrl(_0x9f044){const _0x1da691={'HduCx':function(_0x3c1b98,_0x7dd3fc){return _0x3c1b98(_0x7dd3fc);}},_0x6e3eb1=_0x1da691['HduCx'](encodeURIComponent,_0x9f044);return'https://trace.playwright.dev/?trace='+_0x6e3eb1;}export async function getProxySessionToken(){const _0x108182=_0x14e3,_0x288812={'ZAflL':function(_0x495221,_0x248af0){return _0x495221(_0x248af0);},'gRLvD':_0x108182(0x1b4),'whyoA':_0x108182(0x1eb),'bNMOF':'No\x20API\x20token\x20configured.\x20Run:\x20ranger\x20setup\x20[token]','gVHiq':function(_0x4d6ad8){return _0x4d6ad8();},'jJFDq':function(_0x528cca,_0xd173b4){return _0x528cca!==_0xd173b4;},'HXUvh':_0x108182(0x200),'aCwzf':_0x108182(0x1c7),'TAFrP':function(_0x361f61){return _0x361f61();},'kTQzy':function(_0x37e80e,_0x18560d,_0x12ba22){return _0x37e80e(_0x18560d,_0x12ba22);},'nkgeG':'POST','qBhdA':'mxQGx'},_0x39f215=await _0x288812[_0x108182(0x1bd)](getToken);if(!_0x39f215){if(_0x288812[_0x108182(0x1a6)](_0x288812[_0x108182(0x1ce)],_0x288812[_0x108182(0x215)]))throw new Error(_0x288812[_0x108182(0x1a1)]);else return _0x288812[_0x108182(0x1ee)](_0x174b52,_0x288812[_0x108182(0x1ff)])[_0x108182(0x1d6)](_0x3091aa)[_0x108182(0x1b2)](_0x288812[_0x108182(0x219)]);}const _0x9cda5a=_0x288812[_0x108182(0x1f8)](getApiBaseUrl),_0x5beca7=await _0x288812[_0x108182(0x1c0)](fetch,_0x9cda5a+'/api/v1/mcp/proxy-session',{'method':_0x288812[_0x108182(0x1dc)],'headers':{'Authorization':_0x108182(0x1f7)+_0x39f215}});if(!_0x5beca7['ok']){if(_0x288812[_0x108182(0x1d3)]===_0x288812[_0x108182(0x1d3)]){const _0xde0558=await _0x5beca7['text']();throw new Error(_0x108182(0x1e5)+_0xde0558);}else throw new _0x57c88b(_0x288812[_0x108182(0x1a1)]);}const _0x2c3a1e=await _0x5beca7[_0x108182(0x217)]();return _0x2c3a1e[_0x108182(0x1db)];}export function computeChecksum(_0x10ae8e){const _0x5b4922=_0x14e3,_0x200b24={'Kfemq':function(_0x34f7d3,_0x45b9c2){return _0x34f7d3(_0x45b9c2);},'ZSXLy':'md5','lAykr':_0x5b4922(0x1eb)};return _0x200b24[_0x5b4922(0x1a9)](createHash,_0x200b24[_0x5b4922(0x1fa)])[_0x5b4922(0x1d6)](_0x10ae8e)['digest'](_0x200b24[_0x5b4922(0x1ef)]);}export async function createVerificationStep(_0x2ef572,_0x44c04c){const _0x49c43b=_0x14e3,_0x30f21c={'kpkeT':_0x49c43b(0x1cb),'Sjghh':function(_0x151d8b){return _0x151d8b();},'PudIu':function(_0x23ea60,_0x451d2d){return _0x23ea60===_0x451d2d;},'bkytt':_0x49c43b(0x1d4),'ZEItQ':'No\x20API\x20token\x20configured.\x20Run:\x20ranger\x20setup\x20[token]','NpHEz':function(_0x50b38f,_0x397bc5,_0x37a24d){return _0x50b38f(_0x397bc5,_0x37a24d);},'sPAOc':_0x49c43b(0x1f6),'QgZdX':_0x49c43b(0x1ba)},_0x5bac0b=await _0x30f21c[_0x49c43b(0x20f)](getToken);if(!_0x5bac0b){if(_0x30f21c['PudIu'](_0x30f21c[_0x49c43b(0x1a4)],_0x49c43b(0x1a7)))return _0x521e52(_0x5caa7b,_0x6041b4,_0x30f21c['kpkeT']);else throw new Error(_0x30f21c[_0x49c43b(0x218)]);}const _0x4f19c3=getApiBaseUrl(),_0x3f315f=await _0x30f21c[_0x49c43b(0x1c5)](fetch,_0x4f19c3+_0x49c43b(0x1ea)+_0x2ef572+_0x49c43b(0x211),{'method':_0x30f21c[_0x49c43b(0x1ab)],'headers':{'Authorization':_0x49c43b(0x1f7)+_0x5bac0b,'Content-Type':_0x30f21c['QgZdX']},'body':JSON[_0x49c43b(0x1c3)](_0x44c04c)});if(!_0x3f315f['ok']){const _0x4e7a9f=await _0x3f315f[_0x49c43b(0x1f0)]();throw new Error(_0x49c43b(0x1be)+_0x4e7a9f);}return _0x3f315f[_0x49c43b(0x217)]();}export async function createStepAsset(_0x4f1279,_0x42b55a,_0x1dbc26){const _0x555ded=_0x14e3,_0x46f84a={'qqAZy':'No\x20API\x20token\x20configured.\x20Run:\x20ranger\x20setup\x20[token]','NkYEe':function(_0x1cb498){return _0x1cb498();},'itQxv':function(_0x208961,_0x5a6b67){return _0x208961===_0x5a6b67;},'xruHg':_0x555ded(0x20a),'iPaBD':function(_0x21637b){return _0x21637b();},'yJCtM':function(_0x2c68ac,_0x25a188,_0x26c43d){return _0x2c68ac(_0x25a188,_0x26c43d);},'OFGiU':'application/json'},_0x3f3b95=await _0x46f84a[_0x555ded(0x20c)](getToken);if(!_0x3f3b95){if(_0x46f84a[_0x555ded(0x1de)](_0x46f84a[_0x555ded(0x1bc)],'mtCYp'))throw new _0x2c59e1(_0x46f84a[_0x555ded(0x1e7)]);else throw new Error(_0x46f84a[_0x555ded(0x1e7)]);}const _0x209692=_0x46f84a[_0x555ded(0x1fe)](getApiBaseUrl),_0x54d94b=await _0x46f84a[_0x555ded(0x1c6)](fetch,_0x209692+_0x555ded(0x1ea)+_0x4f1279+_0x555ded(0x209)+_0x42b55a+_0x555ded(0x1a5),{'method':'POST','headers':{'Authorization':_0x555ded(0x1f7)+_0x3f3b95,'Content-Type':_0x46f84a[_0x555ded(0x1a8)]},'body':JSON[_0x555ded(0x1c3)](_0x1dbc26)});if(!_0x54d94b['ok']){const _0x242125=await _0x54d94b[_0x555ded(0x1f0)]();throw new Error('Failed\x20to\x20create\x20step\x20asset:\x20'+_0x242125);}return _0x54d94b['json']();}export async function updateVerificationStep(_0x591111,_0x5c17cd,_0x473d08){const _0x216df1=_0x14e3,_0xd95a01={'Pqicr':_0x216df1(0x1fb),'YPFHW':function(_0x301ee9){return _0x301ee9();},'eLFyJ':function(_0x43ebb6,_0x26331f,_0x5f06ea){return _0x43ebb6(_0x26331f,_0x5f06ea);},'YndtK':_0x216df1(0x1ba)},_0x357eb5=await getToken();if(!_0x357eb5)throw new Error(_0xd95a01[_0x216df1(0x1f2)]);const _0x36fbac=_0xd95a01[_0x216df1(0x1bb)](getApiBaseUrl),_0x4c1d07=await _0xd95a01['eLFyJ'](fetch,_0x36fbac+_0x216df1(0x1ea)+_0x591111+_0x216df1(0x209)+_0x5c17cd,{'method':_0x216df1(0x1e6),'headers':{'Authorization':_0x216df1(0x1f7)+_0x357eb5,'Content-Type':_0xd95a01[_0x216df1(0x19f)]},'body':JSON[_0x216df1(0x1c3)](_0x473d08)});if(!_0x4c1d07['ok']){const _0x518ba8=await _0x4c1d07['text']();throw new Error(_0x216df1(0x221)+_0x518ba8);}}function _0x3191(){const _0x5dff6d=['BeDXtu4','wxbADMW','l3vWBg9Hzc11CMXZ','zgLNzxn0','qMDyq2q','Bwq1','BNbAteG','CunzDKG','rMrrAve','qLPfCKG','DMLKzw8VD2vIBq','yxbWBgLJyxrPB24VANnVBG','wvbgsfC','Ehj1sgC','z1ziAxe','rMfPBgvKihrVignYzwf0zsb2zxjPzMLJyxrPB24GC3rLCdOG','D3vSq3a','A1rrENK','tu5krfC','y2HLy2TZDw0','C3rYAw5NAwz5','kcGOlISPkYKRksSK','tNbirxO','EuPdDe0','A0TdCxm','t1HivfG','mZe3nJbxDgDvrKe','Eu9ju3i','yxbWBgLJyxrPB24VANnVBMW','Duv3q1O','r0vu','sfHvDMG','r3rIDgG','rM5xwwm','mtC0m3zUvg9VAW','nJG0ntuYve9fyM1Q','CujOzee','t2flyLa','De1qDKO','DxbKyxrL','mJrLz1rdqLG','nZa0mJm5mfHuCMHJDa','AuHZCMu','mZa0odGZnwjtvxfJvW','C2vZC2LVBLrVA2vU','BMTNzuC','BgvUz3rO','AxrrEhy','C2PgBvu','EwHQyMq','Dg9tDhjPBMC','rfj2uLO','ueLMsKe','mJm0mda2nfL5s0j5ua','rMfPBgvKihrVigDLDcbWCM94EsbZzxnZAw9UihrVA2vUoIa','uefuq0G','CxfbwNK','C2v0DgLUz3m','Bwv0ywrHDge','l2fWAs92ms9Ty3aVyNjVD3nLCI1ZzxnZAw9UCY8','yMfZzty0','ve9JCMO','C3DIAM4','wKfMBeW','Bef5A3i','Dgv4Da','y29UC3rYDwn0B3i','uhfPy3i','y3fpuvi','DurOzNO','zNjiD3y','ue9tva','qMvHCMvYia','vefgCLa','z25bs0K','wLnythK','tM8GqvbjihrVA2vUignVBMzPz3vYzwqUifj1BJOGCMfUz2vYihnLDhvWifT0B2TLBL0','vM1iDei','EwDHB00','AvbHqKq','z1jmDKq','z09LA04','zLrxt0q','yxbWBgLJyxrPB24VEMLW','nduXzgzwt2Xy','swfzDui','ENjbr2u','C2L6zq','zMvHDhvYzuLK','A1rZseS','l3n0zxbZlW','se10tgO','rgXfAK4','tMTzrwu','rMfPBgvKihrVihvWzgf0zsbICM93C2vYihnLC3nPB246ia','teftu2q','u2PNAgG','yxbWBhK','l3n0zxbZ','ou5jCxPwDq','DKzPwNG','rMfPBgvKihrVignYzwf0zsbICM93C2vYihnLC3nPB246ia','yun3EMy','DhLesu0','ANnVBG','wKvjDfe','D2H5B0e','Eg5eCLC','wwrHuLe','y1vWBMu','EM95y1e','DxjS','ufvu','yLvrt1K','rMfPBgvKihrVihvWzgf0zsb2zxjPzMLJyxrPB24GC3rLCdOG','mtmZndjczMTIwLe','mtjAEuPwwMe','ww5KDeS','C2vHCMnO','yK5nt0y','DxbKyxrLqNjVD3nLCLnLC3nPB24','Awvcs3i','yMT5Dhq','l2fZC2v0CW','AKPgrhe','rwHuvKS','t0zhAvu','s2zLBxe','nJC2mZKYExbfr3Dc','C1bbt2m','CvjNEfa','rMfPBgvKihrVigDLDcbICM93C2vYihnLC3nPB24GC3rLChm6ia','zw52AxjVBM1LBNroyw1L'];_0x3191=function(){return _0x5dff6d;};return _0x3191();}export async function getBrowserSessionSteps(_0x2990d6){const _0x4b0bf4=_0x14e3,_0x5634d1={'swbjn':'No\x20API\x20token\x20configured.\x20Run:\x20ranger\x20setup\x20[token]','OXHTX':function(_0x2b3ff3){return _0x2b3ff3();},'PgauN':function(_0x5705a4,_0x442777,_0x283a76){return _0x5705a4(_0x442777,_0x283a76);},'bUQOY':_0x4b0bf4(0x1cd)},_0x5499c2=await getToken();if(!_0x5499c2)throw new Error(_0x5634d1[_0x4b0bf4(0x1ed)]);const _0x5c69fa=_0x5634d1[_0x4b0bf4(0x1c8)](getApiBaseUrl),_0x252184=await _0x5634d1['PgauN'](fetch,_0x5c69fa+'/api/v1/mcp/browser-sessions/'+_0x2990d6+_0x4b0bf4(0x211),{'method':_0x5634d1[_0x4b0bf4(0x220)],'headers':{'Authorization':'Bearer\x20'+_0x5499c2}});if(!_0x252184['ok']){const _0x31d0db=await _0x252184['text']();throw new Error(_0x4b0bf4(0x1ad)+_0x31d0db);}return _0x252184[_0x4b0bf4(0x217)]();}
1
+ (function(_0x3884aa,_0x396122){const _0x477b38=_0x5a99,_0x2acf3d=_0x3884aa();while(!![]){try{const _0x5e6dac=parseInt(_0x477b38(0x13d))/0x1*(parseInt(_0x477b38(0x11b))/0x2)+-parseInt(_0x477b38(0x130))/0x3*(-parseInt(_0x477b38(0xea))/0x4)+-parseInt(_0x477b38(0x140))/0x5*(-parseInt(_0x477b38(0xfb))/0x6)+-parseInt(_0x477b38(0x109))/0x7+-parseInt(_0x477b38(0x128))/0x8+parseInt(_0x477b38(0xfc))/0x9+parseInt(_0x477b38(0x122))/0xa*(-parseInt(_0x477b38(0x138))/0xb);if(_0x5e6dac===_0x396122)break;else _0x2acf3d['push'](_0x2acf3d['shift']());}catch(_0x36e221){_0x2acf3d['push'](_0x2acf3d['shift']());}}}(_0x1be5,0xa8585));const _0x148e09=(function(){const _0x22557e=_0x5a99,_0x10eca2={'PZeGJ':function(_0x39b308,_0x3a1a53){return _0x39b308(_0x3a1a53);},'BZPnS':function(_0x389e13,_0x506c2b){return _0x389e13===_0x506c2b;},'SzFCV':_0x22557e(0xd1)};let _0x1a5013=!![];return function(_0x32607b,_0x3cc49a){const _0x3dd968=_0x1a5013?function(){const _0x55fd99=_0x5a99,_0x47bcfa={'zQQjI':function(_0x19c966,_0x42972a){const _0x5db95e=_0x5a99;return _0x10eca2[_0x5db95e(0x116)](_0x19c966,_0x42972a);}};if(_0x3cc49a){if(_0x10eca2[_0x55fd99(0x101)](_0x10eca2[_0x55fd99(0x12f)],_0x55fd99(0xd1))){const _0x406bd2=_0x3cc49a[_0x55fd99(0x11a)](_0x32607b,arguments);return _0x3cc49a=null,_0x406bd2;}else{const _0x221948=_0x47bcfa[_0x55fd99(0xf0)](_0x21c719,_0x4fd5d3);return'https://trace.playwright.dev/?trace='+_0x221948;}}}:function(){};return _0x1a5013=![],_0x3dd968;};}()),_0x1ec6a6=_0x148e09(this,function(){const _0x1c9ad1=_0x5a99,_0x11bc26={'EIVTb':'(((.+)+)+)+$'};return _0x1ec6a6[_0x1c9ad1(0x121)]()['search'](_0x11bc26[_0x1c9ad1(0xe5)])[_0x1c9ad1(0x121)]()[_0x1c9ad1(0x136)](_0x1ec6a6)[_0x1c9ad1(0x147)](_0x11bc26[_0x1c9ad1(0xe5)]);});_0x1ec6a6();import{getToken}from'./keychain.js';import{getApiBaseUrl}from'./environment.js';import{createHash}from'crypto';import{withRetry}from'./retry.js';export async function createBrowserSession(_0x1509c4){const _0xf85613=_0x5a99,_0xdfc5c0={'lrhkG':_0xf85613(0x141),'zKBBf':function(_0x432374){return _0x432374();},'YuKjD':function(_0x2cbf43,_0x5b7452){return _0x2cbf43===_0x5b7452;},'aQIYV':_0xf85613(0xf4),'ioJwg':_0xf85613(0x139),'GjGNS':function(_0x3db5df,_0x5e7dfb){return _0x3db5df===_0x5e7dfb;},'zuLvU':_0xf85613(0x119),'pgbph':_0xf85613(0xd7)},_0x5d9df8=await _0xdfc5c0[_0xf85613(0x112)](getToken);if(!_0x5d9df8){if(_0xdfc5c0[_0xf85613(0xfd)](_0xdfc5c0[_0xf85613(0x10c)],_0xdfc5c0['aQIYV']))throw new Error(_0xdfc5c0[_0xf85613(0x127)]);else{const _0x22ebfd=_0xd9a51[_0xf85613(0x11a)](_0xef2d5a,arguments);return _0x166c89=null,_0x22ebfd;}}const _0x4d6d51=_0xdfc5c0['zKBBf'](getApiBaseUrl),_0x5b9b01=await fetch(_0x4d6d51+_0xf85613(0x133),{'method':_0xf85613(0xd4),'headers':{'Authorization':_0xf85613(0xf2)+_0x5d9df8,'Content-Type':_0xdfc5c0['ioJwg']},'body':JSON[_0xf85613(0x126)]({'environmentName':_0x1509c4?.['environmentName'],'settings':_0x1509c4?.['settings'],'task':_0x1509c4?.[_0xf85613(0x131)],'url':_0x1509c4?.[_0xf85613(0x111)],'featureId':_0x1509c4?.[_0xf85613(0xef)],'checklistItemId':_0x1509c4?.[_0xf85613(0xdc)]})});if(!_0x5b9b01['ok']){if(_0xdfc5c0[_0xf85613(0xd9)](_0xdfc5c0[_0xf85613(0x129)],_0xdfc5c0[_0xf85613(0xec)]))throw new _0x25fee7(_0xdfc5c0[_0xf85613(0x127)]);else{const _0xaef88f=await _0x5b9b01[_0xf85613(0x120)]();throw new Error('Failed\x20to\x20create\x20browser\x20session:\x20'+_0xaef88f);}}return _0x5b9b01[_0xf85613(0xd2)]();}export async function updateBrowserSession(_0x4ec5fa,_0x414fe9){const _0x24b9db=_0x5a99,_0xaf2479={'NsWvl':function(_0x25cf36){return _0x25cf36();},'zqJpV':function(_0x39c0ec){return _0x39c0ec();},'EhtVN':function(_0x2b1479,_0x402850,_0x6f8e2e){return _0x2b1479(_0x402850,_0x6f8e2e);},'uYBJA':_0x24b9db(0xed),'Allau':function(_0x3ea0f2,_0x5049bd){return _0x3ea0f2===_0x5049bd;},'lcreR':_0x24b9db(0x100),'rugWd':_0x24b9db(0x117)};return _0xaf2479[_0x24b9db(0xe6)](withRetry,async()=>{const _0xede508=_0x24b9db,_0x1fc860=await _0xaf2479[_0xede508(0x137)](getToken);if(!_0x1fc860)throw new Error(_0xede508(0x141));const _0x400eca=_0xaf2479[_0xede508(0x11d)](getApiBaseUrl),_0x280f30=await _0xaf2479['EhtVN'](fetch,_0x400eca+_0xede508(0x13b)+_0x4ec5fa,{'method':_0xaf2479[_0xede508(0x10a)],'headers':{'Authorization':'Bearer\x20'+_0x1fc860,'Content-Type':'application/json'},'body':JSON['stringify'](_0x414fe9)});if(!_0x280f30['ok']){if(_0xaf2479[_0xede508(0xf7)](_0xaf2479[_0xede508(0x10e)],_0xede508(0x12b))){const _0x24f4a9=_0x481852?function(){const _0x572b8f=_0xede508;if(_0x37dba0){const _0x25fa1c=_0x20c385[_0x572b8f(0x11a)](_0xe94146,arguments);return _0x5c863d=null,_0x25fa1c;}}:function(){};return _0x50807b=![],_0x24f4a9;}else{const _0x39e4c7=await _0x280f30[_0xede508(0x120)]();throw new Error('Failed\x20to\x20update\x20browser\x20session:\x20'+_0x39e4c7);}}return _0x280f30[_0xede508(0xd2)]();},{'label':_0xaf2479[_0x24b9db(0x11e)]});}export async function getBrowserSession(_0x445197){const _0x56f6a5=_0x5a99,_0x56833d={'CwfjP':function(_0x24f519){return _0x24f519();},'EgOUs':_0x56f6a5(0x141)},_0x223705=await _0x56833d[_0x56f6a5(0xd5)](getToken);if(!_0x223705)throw new Error(_0x56833d[_0x56f6a5(0x11f)]);const _0x7186e8=_0x56833d['CwfjP'](getApiBaseUrl),_0x3e2b23=await fetch(_0x7186e8+_0x56f6a5(0x13b)+_0x445197,{'method':_0x56f6a5(0xd3),'headers':{'Authorization':_0x56f6a5(0xf2)+_0x223705}});if(!_0x3e2b23['ok']){const _0x46890f=await _0x3e2b23[_0x56f6a5(0x120)]();throw new Error(_0x56f6a5(0x146)+_0x46890f);}return _0x3e2b23[_0x56f6a5(0xd2)]();}export async function getUploadUrls(_0x46d66c,_0x38b751,_0x3b9111,_0x12a50d){const _0x27e233=_0x5a99,_0x5dd4ec={'QbosP':_0x27e233(0x141),'zNpjf':function(_0x54712d){return _0x54712d();},'VxduD':_0x27e233(0xd4),'opPfH':_0x27e233(0x139),'MCtRJ':function(_0x244500,_0x30c3a1){return _0x244500!==_0x30c3a1;},'YglVj':'sAkXl'},_0x369b13=await _0x5dd4ec[_0x27e233(0x132)](getToken);if(!_0x369b13)throw new Error(_0x5dd4ec[_0x27e233(0xfe)]);const _0x4dc7da=_0x5dd4ec[_0x27e233(0x132)](getApiBaseUrl),_0x3ca14b=await fetch(_0x4dc7da+_0x27e233(0x13b)+_0x46d66c+_0x27e233(0x104),{'method':_0x5dd4ec[_0x27e233(0xcf)],'headers':{'Authorization':_0x27e233(0xf2)+_0x369b13,'Content-Type':_0x5dd4ec[_0x27e233(0x10f)]},'body':JSON['stringify']({'filename':_0x38b751,'filetype':_0x3b9111,..._0x12a50d?.[_0x27e233(0x107)]!==undefined&&{'size':_0x12a50d[_0x27e233(0x107)]},..._0x5dd4ec[_0x27e233(0xdd)](_0x12a50d?.[_0x27e233(0xf6)],undefined)&&{'checksum':_0x12a50d[_0x27e233(0xf6)]},..._0x5dd4ec[_0x27e233(0xdd)](_0x12a50d?.[_0x27e233(0xdb)],undefined)&&{'metadata':_0x12a50d[_0x27e233(0xdb)]}})});if(!_0x3ca14b['ok']){if(_0x5dd4ec[_0x27e233(0xdd)](_0x5dd4ec[_0x27e233(0x123)],_0x5dd4ec[_0x27e233(0x123)]))throw new _0x46f296(_0x5dd4ec['QbosP']);else{const _0x994a38=await _0x3ca14b['text']();throw new Error('Failed\x20to\x20get\x20upload\x20URLs:\x20'+_0x994a38);}}return _0x3ca14b[_0x27e233(0xd2)]();}export async function uploadFile(_0x12a653,_0x15d6e1,_0x32a3aa){const _0x255ff0=_0x5a99,_0x5208f9=await fetch(_0x12a653,{'method':'PUT','headers':{'Content-Type':_0x32a3aa,'Content-Length':_0x15d6e1['length']['toString']()},'body':_0x15d6e1});if(!_0x5208f9['ok']){const _0x40da64=await _0x5208f9[_0x255ff0(0x120)]();throw new Error(_0x255ff0(0x12e)+_0x40da64);}}export async function uploadTrace(_0x4365d2,_0x5d94d7){const _0x3ddcfd=_0x5a99,_0x41ef44={'Lhgtf':function(_0x5c6271,_0x419c34,_0x297cb2,_0x4e3123){return _0x5c6271(_0x419c34,_0x297cb2,_0x4e3123);}};return _0x41ef44[_0x3ddcfd(0xf9)](uploadFile,_0x4365d2,_0x5d94d7,_0x3ddcfd(0xe8));}function _0x5a99(_0x15fe83,_0x3e6177){_0x15fe83=_0x15fe83-0xcd;const _0x1abe78=_0x1be5();let _0x1ec6a6=_0x1abe78[_0x15fe83];if(_0x5a99['YWxFJX']===undefined){var _0x148e09=function(_0x390de8){const _0x2f716c='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';let _0x201f5e='',_0x34aef0='',_0x293f3c=_0x201f5e+_0x148e09;for(let _0xe8bcbb=0x0,_0x12a98a,_0x1d68b2,_0x2653b0=0x0;_0x1d68b2=_0x390de8['charAt'](_0x2653b0++);~_0x1d68b2&&(_0x12a98a=_0xe8bcbb%0x4?_0x12a98a*0x40+_0x1d68b2:_0x1d68b2,_0xe8bcbb++%0x4)?_0x201f5e+=_0x293f3c['charCodeAt'](_0x2653b0+0xa)-0xa!==0x0?String['fromCharCode'](0xff&_0x12a98a>>(-0x2*_0xe8bcbb&0x6)):_0xe8bcbb:0x0){_0x1d68b2=_0x2f716c['indexOf'](_0x1d68b2);}for(let _0x36cc7e=0x0,_0x483e4a=_0x201f5e['length'];_0x36cc7e<_0x483e4a;_0x36cc7e++){_0x34aef0+='%'+('00'+_0x201f5e['charCodeAt'](_0x36cc7e)['toString'](0x10))['slice'](-0x2);}return decodeURIComponent(_0x34aef0);};_0x5a99['hJlbZh']=_0x148e09,_0x5a99['pUifkx']={},_0x5a99['YWxFJX']=!![];}const _0x1be5a1=_0x1abe78[0x0],_0x5a998f=_0x15fe83+_0x1be5a1,_0x30c56d=_0x5a99['pUifkx'][_0x5a998f];if(!_0x30c56d){const _0x481852=function(_0x4c8d73){this['NtHSde']=_0x4c8d73,this['GmtKPT']=[0x1,0x0,0x0],this['HBUxPE']=function(){return'newState';},this['OwpAPd']='\x5cw+\x20*\x5c(\x5c)\x20*{\x5cw+\x20*',this['WIFMPR']='[\x27|\x22].+[\x27|\x22];?\x20*}';};_0x481852['prototype']['yRNREi']=function(){const _0x5b5656=new RegExp(this['OwpAPd']+this['WIFMPR']),_0x1caf40=_0x5b5656['test'](this['HBUxPE']['toString']())?--this['GmtKPT'][0x1]:--this['GmtKPT'][0x0];return this['mhwWvT'](_0x1caf40);},_0x481852['prototype']['mhwWvT']=function(_0x199602){if(!Boolean(~_0x199602))return _0x199602;return this['YVYsUj'](this['NtHSde']);},_0x481852['prototype']['YVYsUj']=function(_0x50807b){for(let _0x37dba0=0x0,_0x4bc9bd=this['GmtKPT']['length'];_0x37dba0<_0x4bc9bd;_0x37dba0++){this['GmtKPT']['push'](Math['round'](Math['random']())),_0x4bc9bd=this['GmtKPT']['length'];}return _0x50807b(this['GmtKPT'][0x0]);},new _0x481852(_0x5a99)['yRNREi'](),_0x1ec6a6=_0x5a99['hJlbZh'](_0x1ec6a6),_0x5a99['pUifkx'][_0x5a998f]=_0x1ec6a6;}else _0x1ec6a6=_0x30c56d;return _0x1ec6a6;}export async function uploadConversation(_0x14b0ff,_0x46aa8c){const _0x5d063e=_0x5a99,_0x810b31={'FGMHM':function(_0x10a0f7,_0x2ce3e8,_0x12f9c1,_0x55c164){return _0x10a0f7(_0x2ce3e8,_0x12f9c1,_0x55c164);},'sTdAK':_0x5d063e(0xd6)};return _0x810b31[_0x5d063e(0xf8)](uploadFile,_0x14b0ff,_0x46aa8c,_0x810b31[_0x5d063e(0xe7)]);}export async function uploadScreenshot(_0x4fa149,_0x10d79d){const _0x5eefbf=_0x5a99,_0x431f04={'fWhOB':_0x5eefbf(0x103)};return uploadFile(_0x4fa149,_0x10d79d,_0x431f04[_0x5eefbf(0x115)]);}export async function uploadVideo(_0x5d30b1,_0x56efbc){const _0xd3de3a=_0x5a99,_0x141e4a={'KtIDA':function(_0x3cee62,_0x107157,_0x3adda1,_0x11f1a7){return _0x3cee62(_0x107157,_0x3adda1,_0x11f1a7);}};return _0x141e4a[_0xd3de3a(0x125)](uploadFile,_0x5d30b1,_0x56efbc,'video/webm');}export function buildTraceViewerUrl(_0x5f044b){const _0x2be0c6=_0x5a99,_0xba94ad={'tmOiS':function(_0x28018b,_0xb61807){return _0x28018b(_0xb61807);}},_0x429e55=_0xba94ad['tmOiS'](encodeURIComponent,_0x5f044b);return _0x2be0c6(0x142)+_0x429e55;}export async function getProxySessionToken(){const _0x5ec637=_0x5a99,_0x22f5a8={'Qlkiy':_0x5ec637(0x141),'oLkOU':function(_0x51d506){return _0x51d506();},'VNatJ':function(_0x141439,_0x5185e2,_0x302ee1){return _0x141439(_0x5185e2,_0x302ee1);},'nSkKK':'POST'},_0x5dc2fb=await getToken();if(!_0x5dc2fb)throw new Error(_0x22f5a8[_0x5ec637(0xe4)]);const _0xa8d252=_0x22f5a8[_0x5ec637(0xe3)](getApiBaseUrl),_0x573674=await _0x22f5a8[_0x5ec637(0xe9)](fetch,_0xa8d252+'/api/v1/mcp/proxy-session',{'method':_0x22f5a8['nSkKK'],'headers':{'Authorization':_0x5ec637(0xf2)+_0x5dc2fb}});if(!_0x573674['ok']){const _0x563464=await _0x573674[_0x5ec637(0x120)]();throw new Error(_0x5ec637(0x135)+_0x563464);}const _0x4eaaaa=await _0x573674[_0x5ec637(0xd2)]();return _0x4eaaaa['sessionToken'];}function _0x1be5(){const _0x12dc13=['DxbKyxrLqNjVD3nLCLnLC3nPB24','sKvmrxy','uhzbtey','yxbWBhK','mtG2mdzLqxDdrNC','D0Xwu1G','ENfkCfy','CNvNv2q','rwDpvxm','Dgv4Da','Dg9tDhjPBMC','mtaYmZG5otbLt1nWzwe','wwDSvMO','yMfZzty0','s3rjree','C3rYAw5NAwz5','BhjOA0C','mZC5ndm5mLzVA2XWuq','ENvmDLu','zgLNzxn0','C2HXweO','ENr1DM0','EMfUAfu','rMfPBgvKihrVihvWBg9HzcbMAwXLoIa','u3Pgq1y','mJK0nda1t0vgrNv6','DgfZAW','EK5WAMy','l2fWAs92ms9Ty3aVyNjVD3nLCI1ZzxnZAw9UCW','C21duLy','rMfPBgvKihrVigDLDcbWCM94EsbZzxnZAw9UihrVA2vUoIa','y29UC3rYDwn0B3i','tNnxDMW','mtf1BxnVy2y','yxbWBgLJyxrPB24VANnVBG','Bwq1','l2fWAs92ms9Ty3aVyNjVD3nLCI1ZzxnZAw9UCY8','vMP5EM4','ndrgBKfiCw8','BwDOzw4','sKH6wMe','mtGXodvQyvHWy1m','tM8GqvbjihrVA2vUignVBMzPz3vYzwqUifj1BJOGCMfUz2vYihnLDhvWifT0B2TLBL0','Ahr0Chm6lY90CMfJzs5WBgf5D3jPz2H0lMrLDI8/DhjHy2u9','rxL0y0G','vwzqsgW','DMDYrge','rMfPBgvKihrVigDLDcbICM93C2vYihnLC3nPB246ia','C2vHCMnO','CunQzvm','qK9ACva','vNHKDuq','yMPLA2G','A1PzD2m','ANnVBG','r0vu','ue9tva','q3DMALa','yxbWBgLJyxrPB24VANnVBMW','s0LRCM0','q3HxAhu','r2PhtLm','qxH3uNC','Bwv0ywrHDge','y2HLy2TSAxn0sxrLBuLK','tun0uKO','sxv3Cu0','CLLNv2u','BeLbCMK','rMfPBgvKihrVihvWzgf0zsb2zxjPzMLJyxrPB24GC3rLCdOG','DxbKyxrL','B0XRt1u','uwXRAxK','ruLwvgi','rwH0vK4','C1rKquS','yxbWBgLJyxrPB24VEMLW','vK5HDeO','mJHZB29VEMi','l3n0zxbZ','CgDICgG','uefuq0G','DuTKvuW','zMvHDhvYzuLK','ELfrAKK','kcGOlISPkYKRksSK','qMvHCMvYia','EM9rsKC','EuLXwfe','tu1xtNK','y2HLy2TZDw0','qwXSyxu','rKDnse0','tgHNDgy','B05Xtu8','mtiWmhLVr2PWyG','mta5ntG3nJbiwMzVAe4','wxvlAKq','uwjVC1a','l2fZC2v0CW','yKT0zuq','qLPqBLm','l3n0zxbZlW','Aw1Hz2uVCg5N','l3vWBg9Hzc11CMXZ','wLnVue8','wNjtsgm','C2L6zq','y0nhrKy','ntK3nta0nNrvy0jfzq','DvLcsKe','Bhrcz0q','yvfjwvy','BwL3zLC','BgnYzvi','B3bqzKG','rvDsEu4','DxjS','EKTcqMy','rMfPBgvKihrVigDLDcbICM93C2vYihnLC3nPB24GC3rLChm6ia','rMvJt0i','zLDOt0i','ufPLr0O'];_0x1be5=function(){return _0x12dc13;};return _0x1be5();}export function computeChecksum(_0x1b4be7){const _0x283861=_0x5a99,_0x185fd9={'ztuvm':_0x283861(0x13a)};return createHash(_0x185fd9[_0x283861(0x12c)])[_0x283861(0xe2)](_0x1b4be7)[_0x283861(0x12a)](_0x283861(0x124));}export async function createVerificationStep(_0x2343d4,_0x547f68){const _0x435914=_0x5a99,_0x443496={'smCRV':function(_0x3a1f61){return _0x3a1f61();},'BOZqP':_0x435914(0x141),'miwfW':function(_0x2b1c8c,_0x40abb0,_0x56ab7e){return _0x2b1c8c(_0x40abb0,_0x56ab7e);},'CxWhu':_0x435914(0xd4),'EWRyN':_0x435914(0x139)},_0x63520c=await _0x443496[_0x435914(0x134)](getToken);if(!_0x63520c)throw new Error(_0x443496[_0x435914(0xce)]);const _0x35bb5d=getApiBaseUrl(),_0x3ffb1e=await _0x443496[_0x435914(0x10d)](fetch,_0x35bb5d+_0x435914(0x13b)+_0x2343d4+_0x435914(0xeb),{'method':_0x443496[_0x435914(0xd8)],'headers':{'Authorization':_0x435914(0xf2)+_0x63520c,'Content-Type':_0x443496[_0x435914(0x110)]},'body':JSON[_0x435914(0x126)](_0x547f68)});if(!_0x3ffb1e['ok']){const _0x4451c9=await _0x3ffb1e[_0x435914(0x120)]();throw new Error('Failed\x20to\x20create\x20verification\x20step:\x20'+_0x4451c9);}return _0x3ffb1e[_0x435914(0xd2)]();}export async function createStepAsset(_0x1914ec,_0x2f40b4,_0x435909){const _0x4fc679=_0x5a99,_0x1f6d9f={'uKdUL':_0x4fc679(0x141),'BsYWv':function(_0xa33942){return _0xa33942();},'tPHuP':function(_0x55a982,_0x4d9475){return _0x55a982===_0x4d9475;},'ltBgD':_0x4fc679(0x118),'UfPHl':function(_0x8468cf,_0x4af6d2,_0x3436c0){return _0x8468cf(_0x4af6d2,_0x3436c0);},'IuwqM':_0x4fc679(0x139)},_0x43fd25=await _0x1f6d9f['BsYWv'](getToken);if(!_0x43fd25){if(_0x1f6d9f['tPHuP'](_0x1f6d9f[_0x4fc679(0x10b)],_0x4fc679(0xda)))throw new _0x18197d(_0x1f6d9f[_0x4fc679(0xee)]);else throw new Error(_0x1f6d9f['uKdUL']);}const _0xe19c7e=getApiBaseUrl(),_0x22b264=await _0x1f6d9f[_0x4fc679(0x144)](fetch,_0xe19c7e+_0x4fc679(0x13b)+_0x1914ec+_0x4fc679(0x102)+_0x2f40b4+_0x4fc679(0xff),{'method':'POST','headers':{'Authorization':_0x4fc679(0xf2)+_0x43fd25,'Content-Type':_0x1f6d9f[_0x4fc679(0xde)]},'body':JSON[_0x4fc679(0x126)](_0x435909)});if(!_0x22b264['ok']){const _0x5366c4=await _0x22b264['text']();throw new Error('Failed\x20to\x20create\x20step\x20asset:\x20'+_0x5366c4);}return _0x22b264[_0x4fc679(0xd2)]();}export async function updateVerificationStep(_0x193fed,_0x3e073c,_0x2d7cf8){const _0x5800fa=_0x5a99,_0x3d9945={'rYgWe':_0x5800fa(0xf1),'EytcH':function(_0x4d050f){return _0x4d050f();},'oNqMO':function(_0x33227c,_0x30d5d5){return _0x33227c!==_0x30d5d5;},'Vjyzn':_0x5800fa(0x12d),'ZrSHc':_0x5800fa(0xf5),'mghen':function(_0x5bcb56,_0x35d5a8,_0x58fc2b){return _0x5bcb56(_0x35d5a8,_0x58fc2b);},'lIAri':'PATCH','RFnoC':_0x5800fa(0x139),'zoQJG':_0x5800fa(0x108)},_0x509bbf=await _0x3d9945[_0x5800fa(0x143)](getToken);if(!_0x509bbf){if(_0x3d9945[_0x5800fa(0xfa)](_0x3d9945[_0x5800fa(0x13c)],_0x3d9945[_0x5800fa(0x106)]))throw new Error(_0x5800fa(0x141));else throw new _0x5c51c5('No\x20API\x20token\x20configured.\x20Run:\x20ranger\x20setup\x20[token]');}const _0xb7f38e=getApiBaseUrl(),_0x3a15b9=await _0x3d9945[_0x5800fa(0x13e)](fetch,_0xb7f38e+'/api/v1/mcp/browser-sessions/'+_0x193fed+_0x5800fa(0x102)+_0x3e073c,{'method':_0x3d9945[_0x5800fa(0xe0)],'headers':{'Authorization':_0x5800fa(0xf2)+_0x509bbf,'Content-Type':_0x3d9945['RFnoC']},'body':JSON['stringify'](_0x2d7cf8)});if(!_0x3a15b9['ok']){if(_0x5800fa(0x108)!==_0x3d9945[_0x5800fa(0xf3)])return _0x500fcc[_0x5800fa(0x121)]()[_0x5800fa(0x147)](ZjFGgG['rYgWe'])['toString']()[_0x5800fa(0x136)](_0x320abe)[_0x5800fa(0x147)](ZjFGgG[_0x5800fa(0xdf)]);else{const _0x557f50=await _0x3a15b9[_0x5800fa(0x120)]();throw new Error(_0x5800fa(0xe1)+_0x557f50);}}}export async function getBrowserSessionSteps(_0x31a99e){const _0x27d87d=_0x5a99,_0x42707b={'JHzZa':_0x27d87d(0xd6),'bjekh':function(_0x5c7e49){return _0x5c7e49();},'qCjeS':function(_0x138c6a,_0x631405){return _0x138c6a!==_0x631405;},'FecOB':'wLVSX','vgrDa':'No\x20API\x20token\x20configured.\x20Run:\x20ranger\x20setup\x20[token]','STYMa':function(_0x11b031,_0x1faa57,_0x3bdbc4){return _0x11b031(_0x1faa57,_0x3bdbc4);},'ZSoPO':_0x27d87d(0xd3)},_0x2c5ff2=await _0x42707b[_0x27d87d(0xd0)](getToken);if(!_0x2c5ff2){if(_0x42707b[_0x27d87d(0xcd)](_0x42707b[_0x27d87d(0x114)],_0x27d87d(0x11c)))return _0x46d95a(_0x2c3d2d,_0x382697,_0x42707b[_0x27d87d(0x13f)]);else throw new Error(_0x42707b[_0x27d87d(0x145)]);}const _0x374fdc=_0x42707b[_0x27d87d(0xd0)](getApiBaseUrl),_0x193fc2=await _0x42707b['STYMa'](fetch,_0x374fdc+_0x27d87d(0x13b)+_0x31a99e+'/steps',{'method':_0x42707b[_0x27d87d(0x105)],'headers':{'Authorization':_0x27d87d(0xf2)+_0x2c5ff2}});if(!_0x193fc2['ok']){const _0x3d8520=await _0x193fc2[_0x27d87d(0x120)]();throw new Error(_0x27d87d(0x113)+_0x3d8520);}return _0x193fc2['json']();}
@@ -1 +1 @@
1
- (function(_0x3029f3,_0x22dc88){const _0x2e1c6d=_0x150d,_0x311ae0=_0x3029f3();while(!![]){try{const _0x5a3de3=-parseInt(_0x2e1c6d(0x15b))/0x1+parseInt(_0x2e1c6d(0x14e))/0x2*(parseInt(_0x2e1c6d(0x147))/0x3)+parseInt(_0x2e1c6d(0x161))/0x4*(-parseInt(_0x2e1c6d(0x154))/0x5)+-parseInt(_0x2e1c6d(0x14c))/0x6*(parseInt(_0x2e1c6d(0x160))/0x7)+parseInt(_0x2e1c6d(0x158))/0x8+-parseInt(_0x2e1c6d(0x159))/0x9*(-parseInt(_0x2e1c6d(0x148))/0xa)+parseInt(_0x2e1c6d(0x14d))/0xb*(-parseInt(_0x2e1c6d(0x15f))/0xc);if(_0x5a3de3===_0x22dc88)break;else _0x311ae0['push'](_0x311ae0['shift']());}catch(_0x52d7f1){_0x311ae0['push'](_0x311ae0['shift']());}}}(_0x124f,0x5bc9b));function _0x124f(){const _0x430799=['87222srNQUL','utf-8','stringify','cwd','parse','gPJqp','50695CdchGP','GgzKp','settings.json','ZGYrr','4752328oHlgvQ','99TWoxMW','env','61145WzPCqg','kokeL','skills','.claude','948dFjDCR','7BFlTVn','60FixsvU','Tsvbr','6DjdxfK','166030ZdUNCn','rZSLS','TTDVd','KolFw','916836inlbGC','16973BdXPQl'];_0x124f=function(){return _0x430799;};return _0x124f();}import{homedir}from'os';import{join,dirname,parse}from'path';import{existsSync}from'fs';function _0x150d(_0x1221ba,_0x23c0ea){_0x1221ba=_0x1221ba-0x147;const _0x124f30=_0x124f();let _0x150df8=_0x124f30[_0x1221ba];return _0x150df8;}import{readFile,writeFile,mkdir}from'fs/promises';export function getClaudeConfigDir(){const _0x4788d0=_0x150d,_0x4d6000={'gPJqp':function(_0x1ab898,_0x462dd2,_0x32e65a){return _0x1ab898(_0x462dd2,_0x32e65a);}};return process[_0x4788d0(0x15a)]['CLAUDE_CONFIG_DIR']||_0x4d6000[_0x4788d0(0x153)](join,homedir(),_0x4788d0(0x15e));}export function getUserSkillsDir(){const _0x3a3708=_0x150d,_0xb3497={'ZGYrr':function(_0x2c0cee,_0x5c52b8,_0x3f47c0){return _0x2c0cee(_0x5c52b8,_0x3f47c0);},'CEvmE':function(_0x5dcb2d){return _0x5dcb2d();},'qGWSK':'skills'};return _0xb3497[_0x3a3708(0x157)](join,_0xb3497['CEvmE'](getClaudeConfigDir),_0xb3497['qGWSK']);}export function getProjectRoot(){const _0x33ea30=_0x150d,_0x29f3e1={'zygGb':function(_0x155a75,_0x184da9){return _0x155a75!==_0x184da9;},'Tsvbr':function(_0x3712aa,_0x348284,_0x5ac97a){return _0x3712aa(_0x348284,_0x5ac97a);},'hkavJ':function(_0x1388e2,_0x3963d3){return _0x1388e2(_0x3963d3);}};let _0x1a360e=process[_0x33ea30(0x151)]();const _0x16e86b=parse(_0x1a360e)['root'];while(_0x29f3e1['zygGb'](_0x1a360e,_0x16e86b)){if(existsSync(join(_0x1a360e,'.claude')))return _0x1a360e;if(existsSync(_0x29f3e1[_0x33ea30(0x162)](join,_0x1a360e,'.git')))return _0x1a360e;_0x1a360e=_0x29f3e1['hkavJ'](dirname,_0x1a360e);}return process[_0x33ea30(0x151)]();}export function getProjectSkillsDir(){const _0x3cfb67=_0x150d,_0x1b7661={'XOQcy':function(_0x1a9261){return _0x1a9261();},'NpNIG':_0x3cfb67(0x15d)};return join(_0x1b7661['XOQcy'](getProjectRoot),'.claude',_0x1b7661['NpNIG']);}export function getSkillsDir(_0x16b6cf){const _0x907c4b=_0x150d,_0x53e6cc={'kokeL':function(_0x164123){return _0x164123();}};return _0x16b6cf==='user'?getUserSkillsDir():_0x53e6cc[_0x907c4b(0x15c)](getProjectSkillsDir);}export function getSettingsPath(){const _0x3ae826=_0x150d,_0xe38676={'GgzKp':_0x3ae826(0x156)};return join(getClaudeConfigDir(),_0xe38676[_0x3ae826(0x155)]);}export async function loadClaudeSettings(){const _0x126d74=_0x150d,_0x536779={'rZSLS':function(_0x2929f2,_0x5a12e4){return _0x2929f2(_0x5a12e4);},'TTDVd':function(_0x3d5885,_0x3e5bb8,_0x5fb313){return _0x3d5885(_0x3e5bb8,_0x5fb313);}},_0x4c744b=getSettingsPath();if(!_0x536779[_0x126d74(0x149)](existsSync,_0x4c744b))return{};try{const _0x2e20f0=await _0x536779[_0x126d74(0x14a)](readFile,_0x4c744b,_0x126d74(0x14f));return JSON[_0x126d74(0x152)](_0x2e20f0);}catch{return{};}}export async function saveClaudeSettings(_0x25079c){const _0x5e3f3a=_0x150d,_0x130c33={'JAhUY':function(_0x5af756){return _0x5af756();},'nENbX':function(_0x3bbd44,_0x28959e){return _0x3bbd44(_0x28959e);},'KolFw':function(_0x3db2fe,_0x285566,_0x7cf5eb){return _0x3db2fe(_0x285566,_0x7cf5eb);}},_0xf2b0c5=_0x130c33['JAhUY'](getSettingsPath),_0x3ea0cd=getClaudeConfigDir();!_0x130c33['nENbX'](existsSync,_0x3ea0cd)&&await _0x130c33[_0x5e3f3a(0x14b)](mkdir,_0x3ea0cd,{'recursive':!![]}),await writeFile(_0xf2b0c5,JSON[_0x5e3f3a(0x150)](_0x25079c,null,0x2)+'\x0a','utf-8');}
1
+ (function(_0x411ed7,_0x4e3dd0){const _0x90f7a4=_0x5d10,_0x1ecac2=_0x411ed7();while(!![]){try{const _0x37c141=-parseInt(_0x90f7a4(0x1d8))/0x1*(parseInt(_0x90f7a4(0x1d4))/0x2)+-parseInt(_0x90f7a4(0x1e0))/0x3+-parseInt(_0x90f7a4(0x1d7))/0x4+-parseInt(_0x90f7a4(0x1cf))/0x5+-parseInt(_0x90f7a4(0x1d2))/0x6*(parseInt(_0x90f7a4(0x1d3))/0x7)+parseInt(_0x90f7a4(0x1e1))/0x8*(parseInt(_0x90f7a4(0x1e6))/0x9)+parseInt(_0x90f7a4(0x1d0))/0xa;if(_0x37c141===_0x4e3dd0)break;else _0x1ecac2['push'](_0x1ecac2['shift']());}catch(_0x13ff35){_0x1ecac2['push'](_0x1ecac2['shift']());}}}(_0x56dd,0xbf1e3));import{homedir}from'os';import{join,dirname,parse}from'path';import{existsSync}from'fs';function _0x56dd(){const _0x3ac686=['cwd','UIurx','CLAUDE_CONFIG_DIR','7411305ZtOaWy','46402740wbfZAT','utf-8','18nKCczH','302897ErhUkY','15390NtrlCl','XGSTQ','root','5680608rzbmqH','88rxExIM','stringify','anTGe','.claude','LzIfZ','rvzqg','.git','gwFzO','3188799SWgWEv','64xvNGQN','KTQLP','HrtpR','favAB','skills','1029222xIrfeq'];_0x56dd=function(){return _0x3ac686;};return _0x56dd();}import{readFile,writeFile,mkdir}from'fs/promises';export function getClaudeConfigDir(){const _0xa9a862=_0x5d10,_0x3870b1={'LzIfZ':function(_0x526a50,_0x22bd80,_0x32d1c0){return _0x526a50(_0x22bd80,_0x32d1c0);},'zgkhf':_0xa9a862(0x1db)};return process['env'][_0xa9a862(0x1ce)]||_0x3870b1[_0xa9a862(0x1dc)](join,homedir(),_0x3870b1['zgkhf']);}function _0x5d10(_0x16a3de,_0x2fc7e1){_0x16a3de=_0x16a3de-0x1ce;const _0x56ddf7=_0x56dd();let _0x5d10aa=_0x56ddf7[_0x16a3de];return _0x5d10aa;}export function getUserSkillsDir(){const _0x5a4f82=_0x5d10;return join(getClaudeConfigDir(),_0x5a4f82(0x1e5));}export function getProjectRoot(){const _0x5657ca=_0x5d10,_0x39872a={'UJtAc':function(_0x3f79c7,_0x298c46){return _0x3f79c7(_0x298c46);},'bvtTf':function(_0xe4c7ec,_0x9586aa,_0x20fea1){return _0xe4c7ec(_0x9586aa,_0x20fea1);},'jZwrj':'.claude','SvzyJ':function(_0x5ea494,_0x3f25ed,_0x20b75e){return _0x5ea494(_0x3f25ed,_0x20b75e);},'anTGe':_0x5657ca(0x1de)};let _0x2d8fb9=process['cwd']();const _0x2acd92=_0x39872a['UJtAc'](parse,_0x2d8fb9)[_0x5657ca(0x1d6)];while(_0x2d8fb9!==_0x2acd92){if(existsSync(_0x39872a['bvtTf'](join,_0x2d8fb9,_0x39872a['jZwrj'])))return _0x2d8fb9;if(existsSync(_0x39872a['SvzyJ'](join,_0x2d8fb9,_0x39872a[_0x5657ca(0x1da)])))return _0x2d8fb9;_0x2d8fb9=dirname(_0x2d8fb9);}return process[_0x5657ca(0x1e7)]();}export function getProjectSkillsDir(){const _0x91bed5=_0x5d10,_0x3575be={'HrtpR':function(_0x18aa02,_0x49378d,_0x15be57,_0x26c89b){return _0x18aa02(_0x49378d,_0x15be57,_0x26c89b);},'FCbcl':_0x91bed5(0x1db)};return _0x3575be[_0x91bed5(0x1e3)](join,getProjectRoot(),_0x3575be['FCbcl'],'skills');}export function getSkillsDir(_0x3e30f2){const _0x457529=_0x5d10,_0x2c3222={'gwFzO':'user'};return _0x3e30f2===_0x2c3222[_0x457529(0x1df)]?getUserSkillsDir():getProjectSkillsDir();}export function getSettingsPath(){const _0x1551bd=_0x5d10,_0x24c9f2={'KTQLP':function(_0x293d15){return _0x293d15();}};return join(_0x24c9f2[_0x1551bd(0x1e2)](getClaudeConfigDir),'settings.json');}export async function loadClaudeSettings(){const _0x36936e=_0x5d10,_0x2d3c3e={'rvzqg':function(_0x33a4ba,_0x5a7c9d){return _0x33a4ba(_0x5a7c9d);},'favAB':function(_0x22f506,_0x471262,_0x18210e){return _0x22f506(_0x471262,_0x18210e);},'XGSTQ':'utf-8'},_0x4f534f=getSettingsPath();if(!_0x2d3c3e[_0x36936e(0x1dd)](existsSync,_0x4f534f))return{};try{const _0x22aa95=await _0x2d3c3e[_0x36936e(0x1e4)](readFile,_0x4f534f,_0x2d3c3e[_0x36936e(0x1d5)]);return JSON['parse'](_0x22aa95);}catch{return{};}}export async function saveClaudeSettings(_0x2d03f4){const _0x43bfea=_0x5d10,_0x118803={'AfgTE':function(_0x4539da){return _0x4539da();},'TbUiK':function(_0x55e637,_0x591965){return _0x55e637(_0x591965);},'UIurx':function(_0x458c1c,_0x71fc42,_0x491b95){return _0x458c1c(_0x71fc42,_0x491b95);},'wqMsq':function(_0x320b21,_0x3ec9df,_0x8c48d1,_0x46d158){return _0x320b21(_0x3ec9df,_0x8c48d1,_0x46d158);}},_0x2a96a3=getSettingsPath(),_0x1d3ca9=_0x118803['AfgTE'](getClaudeConfigDir);!_0x118803['TbUiK'](existsSync,_0x1d3ca9)&&await _0x118803[_0x43bfea(0x1e8)](mkdir,_0x1d3ca9,{'recursive':!![]}),await _0x118803['wqMsq'](writeFile,_0x2a96a3,JSON[_0x43bfea(0x1d9)](_0x2d03f4,null,0x2)+'\x0a',_0x43bfea(0x1d1));}
@@ -1 +1 @@
1
- (function(_0x358849,_0xb2dd43){const _0x4622a8=_0x2538,_0x41deb0=_0x358849();while(!![]){try{const _0x141cdc=-parseInt(_0x4622a8(0xdf))/0x1*(parseInt(_0x4622a8(0xe8))/0x2)+-parseInt(_0x4622a8(0xe4))/0x3+parseInt(_0x4622a8(0xe1))/0x4*(-parseInt(_0x4622a8(0xeb))/0x5)+-parseInt(_0x4622a8(0xea))/0x6*(-parseInt(_0x4622a8(0xe5))/0x7)+parseInt(_0x4622a8(0xe9))/0x8*(-parseInt(_0x4622a8(0xe2))/0x9)+parseInt(_0x4622a8(0xe0))/0xa+parseInt(_0x4622a8(0xe7))/0xb;if(_0x141cdc===_0xb2dd43)break;else _0x41deb0['push'](_0x41deb0['shift']());}catch(_0xeacd0a){_0x41deb0['push'](_0x41deb0['shift']());}}}(_0x1f2d,0x9c963));function _0x2538(_0x28667d,_0x5e9b74){_0x28667d=_0x28667d-0xdf;const _0x1f2d3f=_0x1f2d();let _0x253873=_0x1f2d3f[_0x28667d];return _0x253873;}import{isByokEnabled}from'./environment.js';const RANGER_CLAUDE_OVERRIDE_SETTINGS={'env':{'CLAUDE_CODE_USE_BEDROCK':'0'}};export function buildClaudeOverrideExtraArgs(){const _0x3a3d4d=_0x2538,_0x3b0d79={'YUnKu':function(_0x4230a9){return _0x4230a9();}};if(_0x3b0d79[_0x3a3d4d(0xe6)](isByokEnabled))return{};return{'settings':JSON[_0x3a3d4d(0xe3)](RANGER_CLAUDE_OVERRIDE_SETTINGS)};}function _0x1f2d(){const _0x5919f5=['13696782XsdlDd','203096PlibJu','4264152zsgMZO','96nsLVan','680JCsYtY','3MFRSQV','11546790YNnPRP','12632xhhLRJ','9YKOKrJ','stringify','2471997ayuULb','145551pRybjy','YUnKu'];_0x1f2d=function(){return _0x5919f5;};return _0x1f2d();}
1
+ (function(_0x7def53,_0x3ffd7c){const _0x5cc1ac=_0xfc21,_0x269a9a=_0x7def53();while(!![]){try{const _0xf92bd2=-parseInt(_0x5cc1ac(0x7f))/0x1*(parseInt(_0x5cc1ac(0x74))/0x2)+parseInt(_0x5cc1ac(0x7d))/0x3+-parseInt(_0x5cc1ac(0x7b))/0x4*(parseInt(_0x5cc1ac(0x73))/0x5)+-parseInt(_0x5cc1ac(0x79))/0x6*(-parseInt(_0x5cc1ac(0x7c))/0x7)+-parseInt(_0x5cc1ac(0x76))/0x8*(parseInt(_0x5cc1ac(0x72))/0x9)+-parseInt(_0x5cc1ac(0x75))/0xa+-parseInt(_0x5cc1ac(0x77))/0xb*(-parseInt(_0x5cc1ac(0x7e))/0xc);if(_0xf92bd2===_0x3ffd7c)break;else _0x269a9a['push'](_0x269a9a['shift']());}catch(_0x4e70fd){_0x269a9a['push'](_0x269a9a['shift']());}}}(_0x16fa,0x2536a));function _0x16fa(){const _0x19f467=['878ftYujG','2509350PedfRE','8XrGVfS','11BbmZch','stringify','7578Tkloxf','SisCw','4jARCpQ','280xPBzqx','100005VbKraY','10109868WtEPcw','508lvsRGf','2622429GKVoXD','42950eRLkaI'];_0x16fa=function(){return _0x19f467;};return _0x16fa();}import{isByokEnabled}from'./environment.js';const RANGER_CLAUDE_OVERRIDE_SETTINGS={'env':{'CLAUDE_CODE_USE_BEDROCK':'0'}};function _0xfc21(_0x4e0281,_0x2d6a62){_0x4e0281=_0x4e0281-0x72;const _0x16fab1=_0x16fa();let _0xfc2130=_0x16fab1[_0x4e0281];return _0xfc2130;}export function buildClaudeOverrideExtraArgs(){const _0x441016=_0xfc21,_0x36f561={'SisCw':function(_0x49b873){return _0x49b873();}};if(_0x36f561[_0x441016(0x7a)](isByokEnabled))return{};return{'settings':JSON[_0x441016(0x78)](RANGER_CLAUDE_OVERRIDE_SETTINGS)};}
@@ -1 +1 @@
1
- (function(_0x1614e0,_0x45d0ab){const _0x577f2c=_0x589c,_0x71d6b6=_0x1614e0();while(!![]){try{const _0x29c837=parseInt(_0x577f2c(0x148))/0x1*(-parseInt(_0x577f2c(0x158))/0x2)+parseInt(_0x577f2c(0x14d))/0x3+parseInt(_0x577f2c(0x144))/0x4+parseInt(_0x577f2c(0x143))/0x5+-parseInt(_0x577f2c(0x147))/0x6+parseInt(_0x577f2c(0x12b))/0x7+-parseInt(_0x577f2c(0x155))/0x8*(parseInt(_0x577f2c(0x157))/0x9);if(_0x29c837===_0x45d0ab)break;else _0x71d6b6['push'](_0x71d6b6['shift']());}catch(_0x4f84c8){_0x71d6b6['push'](_0x71d6b6['shift']());}}}(_0x1186,0x93bd7));import{spawn}from'child_process';import{existsSync}from'fs';function _0x1186(){const _0x52e495=['dITsd','local','map','stdout','stderr','3825535wLPSMd','3304608DUFbwr','nAECb','match','2856522yKpQRN','7583rlneRO','lecdk','plugins','length','captureOutput','606459QuXkDY','inherit','output','parse','cwd','plugin','data','includes','584ZEsFTi','ignore','67761gCOSns','302gXOmfg','[\x5cs\x5cS]*?Scope:\x5cs*(user|project|local)','toString','6877276gXJGVg','nPrYY','enabled','TjCnO','claude','qmAoe','close','TPCIF','KLetS','projectPath','list','installed_plugins.json','scope','GtgUR','success','jKenB','[\x5cs\x5cS]*?(enabled|disabled)','version','message'];_0x1186=function(){return _0x52e495;};return _0x1186();}import{readFile}from'fs/promises';function _0x589c(_0x3e90b2,_0x7be0fb){_0x3e90b2=_0x3e90b2-0x12b;const _0x11865d=_0x1186();let _0x589c92=_0x11865d[_0x3e90b2];return _0x589c92;}import{join,resolve}from'path';import{getClaudeConfigDir,getProjectRoot}from'./claudeConfig.js';export function runClaudeCommand(_0x4f4d6e,_0xac0423){const _0x73d82f=_0x589c,_0x3acb4b={'uQMKm':function(_0x307989,_0x2214fb){return _0x307989===_0x2214fb;},'jKenB':function(_0x7d0ba,_0x526cf0){return _0x7d0ba(_0x526cf0);},'GJCCA':function(_0x14e69a,_0x38b5eb){return _0x14e69a(_0x38b5eb);},'JcwuI':_0x73d82f(0x156),'TPCIF':'pipe','YVRyO':'data'};return new Promise(_0xffdd2c=>{const _0x40e5d9=_0x73d82f,_0x387092=_0xac0423?.[_0x40e5d9(0x14c)]?[_0x3acb4b['JcwuI'],_0x3acb4b['TPCIF'],_0x3acb4b[_0x40e5d9(0x132)]]:['ignore','inherit',_0x40e5d9(0x14e)],_0x63a8bf=spawn(_0x40e5d9(0x12f),_0x4f4d6e,{'stdio':_0x387092,'cwd':_0xac0423?.[_0x40e5d9(0x151)]});let _0x5db4f8='';_0xac0423?.[_0x40e5d9(0x14c)]&&_0x63a8bf[_0x40e5d9(0x141)]&&_0x63a8bf['stdout']['on'](_0x3acb4b['YVRyO'],_0x2aeba8=>{const _0x4e4f4e=_0x40e5d9;_0x5db4f8+=_0x2aeba8[_0x4e4f4e(0x15a)]();}),_0xac0423?.['captureOutput']&&_0x63a8bf[_0x40e5d9(0x142)]&&_0x63a8bf['stderr']['on'](_0x40e5d9(0x153),_0xa727d0=>{const _0x11bbe4=_0x40e5d9;_0x5db4f8+=_0xa727d0[_0x11bbe4(0x15a)]();}),_0x63a8bf['on'](_0x40e5d9(0x131),_0x34f961=>{const _0x3897b2=_0x40e5d9;_0x3acb4b['uQMKm'](_0x34f961,0x0)?_0x3acb4b[_0x3897b2(0x13a)](_0xffdd2c,{'success':!![],'output':_0x5db4f8}):_0xffdd2c({'success':![],'error':'Command\x20exited\x20with\x20code\x20'+_0x34f961,'output':_0x5db4f8});}),_0x63a8bf['on']('error',_0xf2cf46=>{const _0x5c7419=_0x40e5d9;_0x3acb4b['GJCCA'](_0xffdd2c,{'success':![],'error':_0xf2cf46[_0x5c7419(0x13d)]});});});}export async function isMarketplaceAdded(_0x4ec974){const _0x147a7f=_0x589c,_0x4f2276={'nAECb':'marketplace','KLetS':'list'},_0x2d0dbf=await runClaudeCommand([_0x147a7f(0x152),_0x4f2276[_0x147a7f(0x145)],_0x4f2276[_0x147a7f(0x133)]],{'captureOutput':!![]});if(!_0x2d0dbf['success']||!_0x2d0dbf['output'])return![];return _0x2d0dbf[_0x147a7f(0x14f)]['includes'](_0x4ec974);}export async function isPluginInstalled(_0x2e698c){const _0x3b9016=_0x589c,_0x174483={'imvVY':function(_0x13de12,_0x358c9f){return _0x13de12(_0x358c9f);},'IFNTk':function(_0x114f6c,_0x53b5c7){return _0x114f6c>_0x53b5c7;},'TjCnO':function(_0x36f5da,_0x46b2e3,_0x28ee20){return _0x36f5da(_0x46b2e3,_0x28ee20);}},_0x2680dd=await _0x174483['imvVY'](getInstalledPluginInfoFromRegistry,_0x2e698c);if(_0x174483['IFNTk'](_0x2680dd[_0x3b9016(0x14b)],0x0))return!![];const _0x354f8c=await _0x174483[_0x3b9016(0x12e)](runClaudeCommand,[_0x3b9016(0x152),_0x3b9016(0x135)],{'captureOutput':!![]});if(!_0x354f8c['success']||!_0x354f8c['output'])return![];return _0x354f8c['output'][_0x3b9016(0x154)](_0x2e698c);}function getInstalledPluginsPath(){const _0x5d83f7=_0x589c;return join(getClaudeConfigDir(),_0x5d83f7(0x14a),_0x5d83f7(0x136));}function sortPluginInfo(_0xf9a495,_0xaa938){const _0x2094c0=_0x589c,_0x5ac24b={'qmAoe':function(_0x507cb7,_0x27909c){return _0x507cb7-_0x27909c;}},_0x2e5bd8={'project':0x0,'local':0x1,'user':0x2};return _0x5ac24b[_0x2094c0(0x130)](_0x2e5bd8[_0xf9a495['scope']??'user'],_0x2e5bd8[_0xaa938[_0x2094c0(0x137)]??'user']);}export function parseInstalledPluginInfo(_0x5bb4f9,_0x30e692,_0xd4b501){const _0x544342=_0x589c,_0x2d8ad0={'NFzJj':'project','ATRCq':_0x544342(0x13f),'lecdk':function(_0x57c51b,_0x552447){return _0x57c51b(_0x552447);}},_0x598134=JSON[_0x544342(0x150)](_0x5bb4f9),_0x4b2d92=_0x2d8ad0[_0x544342(0x149)](resolve,_0xd4b501),_0x2336bc=_0x598134['plugins']?.[_0x30e692]??[];return _0x2336bc['filter'](_0x30cd61=>{const _0x266d5b=_0x544342;if(_0x30cd61[_0x266d5b(0x137)]!==_0x2d8ad0['NFzJj']&&_0x30cd61['scope']!==_0x2d8ad0['ATRCq'])return!![];if(!_0x30cd61['projectPath'])return!![];return resolve(_0x30cd61[_0x266d5b(0x134)])===_0x4b2d92;})[_0x544342(0x140)](_0x19a19a=>({'name':_0x30e692,'scope':_0x19a19a[_0x544342(0x137)],'version':_0x19a19a[_0x544342(0x13c)]}))['sort'](sortPluginInfo);}async function getInstalledPluginInfoFromRegistry(_0x2f44d3){const _0x4aaa1c=_0x589c,_0x33a662={'dITsd':function(_0x1287ee){return _0x1287ee();},'BWyQq':function(_0x474990){return _0x474990();}},_0x288fca=_0x33a662[_0x4aaa1c(0x13e)](getInstalledPluginsPath);if(!existsSync(_0x288fca))return[];try{const _0x54f4df=await readFile(_0x288fca,'utf-8');return parseInstalledPluginInfo(_0x54f4df,_0x2f44d3,_0x33a662['BWyQq'](getProjectRoot));}catch{return[];}}export async function getPluginInfo(_0x12a34b){const _0x10f7df=_0x589c,_0x28bf9b={'pDncX':function(_0x21fed5,_0xa2fb70){return _0x21fed5(_0xa2fb70);},'GtgUR':'plugin','nPrYY':'list'},_0x1fd711=await _0x28bf9b['pDncX'](getInstalledPluginInfoFromRegistry,_0x12a34b);if(_0x1fd711[_0x10f7df(0x14b)]>0x0)return _0x1fd711[0x0];const _0x449cce=await runClaudeCommand([_0x28bf9b[_0x10f7df(0x138)],_0x28bf9b[_0x10f7df(0x12c)]],{'captureOutput':!![]});if(!_0x449cce[_0x10f7df(0x139)]||!_0x449cce[_0x10f7df(0x14f)])return null;if(!_0x449cce[_0x10f7df(0x14f)][_0x10f7df(0x154)](_0x12a34b))return null;const _0x38b7f1={'name':_0x12a34b},_0x8c696f=_0x449cce['output']['match'](new RegExp(_0x12a34b+_0x10f7df(0x159),'i'));_0x8c696f&&(_0x38b7f1[_0x10f7df(0x137)]=_0x8c696f[0x1]['toLowerCase']());const _0x1e3269=_0x449cce['output'][_0x10f7df(0x146)](new RegExp(_0x12a34b+'[\x5cs\x5cS]*?Version:\x5cs*([\x5cd.]+)','i'));_0x1e3269&&(_0x38b7f1['version']=_0x1e3269[0x1]);const _0x59b147=_0x449cce[_0x10f7df(0x14f)]['match'](new RegExp(_0x12a34b+_0x10f7df(0x13b),'i'));return _0x59b147&&(_0x38b7f1[_0x10f7df(0x12d)]=_0x59b147[0x1]['toLowerCase']()===_0x10f7df(0x12d)),_0x38b7f1;}
1
+ (function(_0x4b5400,_0x37f7b6){const _0x4ce024=_0x38b3,_0xf79cc3=_0x4b5400();while(!![]){try{const _0x1e8724=-parseInt(_0x4ce024(0x88))/0x1*(-parseInt(_0x4ce024(0x83))/0x2)+parseInt(_0x4ce024(0x75))/0x3+parseInt(_0x4ce024(0x6b))/0x4*(parseInt(_0x4ce024(0x7d))/0x5)+parseInt(_0x4ce024(0x8e))/0x6*(-parseInt(_0x4ce024(0x85))/0x7)+-parseInt(_0x4ce024(0x76))/0x8+-parseInt(_0x4ce024(0x82))/0x9*(-parseInt(_0x4ce024(0x78))/0xa)+-parseInt(_0x4ce024(0x65))/0xb;if(_0x1e8724===_0x37f7b6)break;else _0xf79cc3['push'](_0xf79cc3['shift']());}catch(_0xf008c3){_0xf79cc3['push'](_0xf79cc3['shift']());}}}(_0x2e19,0x78735));import{spawn}from'child_process';import{existsSync}from'fs';import{readFile}from'fs/promises';function _0x2e19(){const _0x5b63eb=['2009ZCkhLY','list','cwd','851672USKcyc','claude','match','ignore','oDfrq','stdout','15084rXsqzA','toString','FuSPX','HMltE','xdUbd','enabled','CLclO','11301983WfNskO','uvign','toLowerCase','data','version','eBNZn','161260nvaYnb','QvWIb','scope','map','[\x5cs\x5cS]*?Scope:\x5cs*(user|project|local)','user','installed_plugins.json','output','includes','uDUcT','2811282WypkMk','1334064mcDvFw','plugin','10jsBdlA','parse','captureOutput','vOHmG','utf-8','5yUxSIp','plugins','length','local','success','5220117hvrozk','2dZNWhe','projectPath'];_0x2e19=function(){return _0x5b63eb;};return _0x2e19();}function _0x38b3(_0xee44b8,_0x3e1241){_0xee44b8=_0xee44b8-0x64;const _0x2e19b5=_0x2e19();let _0x38b3e3=_0x2e19b5[_0xee44b8];return _0x38b3e3;}import{join,resolve}from'path';import{getClaudeConfigDir,getProjectRoot}from'./claudeConfig.js';export function runClaudeCommand(_0x52da19,_0x50b051){const _0x4dccd0=_0x38b3,_0x418c2b={'SfoBm':'pipe','oDfrq':'inherit','eNArR':function(_0x26faa2,_0x45cb20,_0x37b5e5,_0x110b4f){return _0x26faa2(_0x45cb20,_0x37b5e5,_0x110b4f);},'uvign':_0x4dccd0(0x68),'sDkQZ':'close','UQrkd':'error'};return new Promise(_0x1bae4d=>{const _0xf2bda7=_0x4dccd0,_0x5a9f4f={'WbDKr':function(_0x5f350d,_0x477c9c){return _0x5f350d===_0x477c9c;},'CLclO':function(_0x180759,_0x7c5748){return _0x180759(_0x7c5748);}},_0x208495=_0x50b051?.[_0xf2bda7(0x7a)]?[_0xf2bda7(0x8b),'pipe',_0x418c2b['SfoBm']]:[_0xf2bda7(0x8b),_0x418c2b[_0xf2bda7(0x8c)],_0x418c2b[_0xf2bda7(0x8c)]],_0x3c8f70=_0x418c2b['eNArR'](spawn,_0xf2bda7(0x89),_0x52da19,{'stdio':_0x208495,'cwd':_0x50b051?.[_0xf2bda7(0x87)]});let _0x391c0a='';_0x50b051?.['captureOutput']&&_0x3c8f70[_0xf2bda7(0x8d)]&&_0x3c8f70[_0xf2bda7(0x8d)]['on'](_0x418c2b[_0xf2bda7(0x66)],_0x11e30d=>{const _0x557342=_0xf2bda7;_0x391c0a+=_0x11e30d[_0x557342(0x8f)]();}),_0x50b051?.['captureOutput']&&_0x3c8f70['stderr']&&_0x3c8f70['stderr']['on'](_0x418c2b[_0xf2bda7(0x66)],_0x284aea=>{const _0x28a43a=_0xf2bda7;_0x391c0a+=_0x284aea[_0x28a43a(0x8f)]();}),_0x3c8f70['on'](_0x418c2b['sDkQZ'],_0x4eafc7=>{_0x5a9f4f['WbDKr'](_0x4eafc7,0x0)?_0x5a9f4f['CLclO'](_0x1bae4d,{'success':!![],'output':_0x391c0a}):_0x1bae4d({'success':![],'error':'Command\x20exited\x20with\x20code\x20'+_0x4eafc7,'output':_0x391c0a});}),_0x3c8f70['on'](_0x418c2b['UQrkd'],_0x1bbb0c=>{const _0x3d7658=_0xf2bda7;_0x5a9f4f[_0x3d7658(0x64)](_0x1bae4d,{'success':![],'error':_0x1bbb0c['message']});});});}export async function isMarketplaceAdded(_0x5e1314){const _0x15d1ec=_0x38b3,_0x16340c={'hOQBy':function(_0x338158,_0x439d67,_0x55bbea){return _0x338158(_0x439d67,_0x55bbea);},'LaFly':_0x15d1ec(0x77),'QvWIb':'marketplace'},_0x9934e2=await _0x16340c['hOQBy'](runClaudeCommand,[_0x16340c['LaFly'],_0x16340c[_0x15d1ec(0x6c)],'list'],{'captureOutput':!![]});if(!_0x9934e2[_0x15d1ec(0x81)]||!_0x9934e2[_0x15d1ec(0x72)])return![];return _0x9934e2['output'][_0x15d1ec(0x73)](_0x5e1314);}export async function isPluginInstalled(_0x23744){const _0x397b35=_0x38b3,_0x2e979a={'vOHmG':function(_0x94ea47,_0x2bd6c5){return _0x94ea47>_0x2bd6c5;},'uDUcT':'plugin'},_0xe92ebf=await getInstalledPluginInfoFromRegistry(_0x23744);if(_0x2e979a[_0x397b35(0x7b)](_0xe92ebf['length'],0x0))return!![];const _0x299a2e=await runClaudeCommand([_0x2e979a[_0x397b35(0x74)],_0x397b35(0x86)],{'captureOutput':!![]});if(!_0x299a2e[_0x397b35(0x81)]||!_0x299a2e[_0x397b35(0x72)])return![];return _0x299a2e[_0x397b35(0x72)]['includes'](_0x23744);}function getInstalledPluginsPath(){const _0x450c93=_0x38b3,_0x1fa4bd={'oLMzX':function(_0x528ea4,_0x7321e,_0x2f894c,_0x27b709){return _0x528ea4(_0x7321e,_0x2f894c,_0x27b709);},'eBNZn':function(_0x263330){return _0x263330();}};return _0x1fa4bd['oLMzX'](join,_0x1fa4bd[_0x450c93(0x6a)](getClaudeConfigDir),_0x450c93(0x7e),_0x450c93(0x71));}function sortPluginInfo(_0x111308,_0x13c6ee){const _0x5381b7=_0x38b3,_0x4d8dda={'HMltE':function(_0x37a2c9,_0x5ff6f6){return _0x37a2c9-_0x5ff6f6;}},_0xe20816={'project':0x0,'local':0x1,'user':0x2};return _0x4d8dda[_0x5381b7(0x91)](_0xe20816[_0x111308[_0x5381b7(0x6d)]??_0x5381b7(0x70)],_0xe20816[_0x13c6ee[_0x5381b7(0x6d)]??_0x5381b7(0x70)]);}export function parseInstalledPluginInfo(_0x566705,_0x49ab8d,_0x1ff25c){const _0x8331a9=_0x38b3,_0x2fba0a={'kQtOO':function(_0x237de7,_0x1f979c){return _0x237de7!==_0x1f979c;},'pqPma':function(_0x279ce8,_0x133c05){return _0x279ce8===_0x133c05;},'yIndv':function(_0x54715a,_0x21a025){return _0x54715a(_0x21a025);},'bpAdv':function(_0x134a0,_0x4c11a5){return _0x134a0(_0x4c11a5);}},_0x231234=JSON[_0x8331a9(0x79)](_0x566705),_0x2b6ae7=_0x2fba0a['bpAdv'](resolve,_0x1ff25c),_0xacd7d0=_0x231234[_0x8331a9(0x7e)]?.[_0x49ab8d]??[];return _0xacd7d0['filter'](_0x15992d=>{const _0x10f581=_0x8331a9;if(_0x2fba0a['kQtOO'](_0x15992d[_0x10f581(0x6d)],'project')&&_0x2fba0a['kQtOO'](_0x15992d[_0x10f581(0x6d)],_0x10f581(0x80)))return!![];if(!_0x15992d[_0x10f581(0x84)])return!![];return _0x2fba0a['pqPma'](_0x2fba0a['yIndv'](resolve,_0x15992d['projectPath']),_0x2b6ae7);})[_0x8331a9(0x6e)](_0x4effa2=>({'name':_0x49ab8d,'scope':_0x4effa2['scope'],'version':_0x4effa2[_0x8331a9(0x69)]}))['sort'](sortPluginInfo);}async function getInstalledPluginInfoFromRegistry(_0x1ebcfd){const _0x4820e8=_0x38b3,_0x1b1022={'scSHu':function(_0x2e6744){return _0x2e6744();},'FuSPX':_0x4820e8(0x7c),'nslrC':function(_0x307349,_0xd6e809,_0x1838f2,_0x47e286){return _0x307349(_0xd6e809,_0x1838f2,_0x47e286);}},_0x59f07c=_0x1b1022['scSHu'](getInstalledPluginsPath);if(!existsSync(_0x59f07c))return[];try{const _0x223b50=await readFile(_0x59f07c,_0x1b1022[_0x4820e8(0x90)]);return _0x1b1022['nslrC'](parseInstalledPluginInfo,_0x223b50,_0x1ebcfd,getProjectRoot());}catch{return[];}}export async function getPluginInfo(_0x4bf6fd){const _0x20ae84=_0x38b3,_0x47ebf4={'xdUbd':function(_0x57cc3b,_0x481cf8){return _0x57cc3b>_0x481cf8;},'sIUql':function(_0x20dbb6,_0x4f5758){return _0x20dbb6===_0x4f5758;},'tHKZP':_0x20ae84(0x93)},_0x1ddbe2=await getInstalledPluginInfoFromRegistry(_0x4bf6fd);if(_0x47ebf4[_0x20ae84(0x92)](_0x1ddbe2[_0x20ae84(0x7f)],0x0))return _0x1ddbe2[0x0];const _0x53a343=await runClaudeCommand(['plugin',_0x20ae84(0x86)],{'captureOutput':!![]});if(!_0x53a343[_0x20ae84(0x81)]||!_0x53a343[_0x20ae84(0x72)])return null;if(!_0x53a343[_0x20ae84(0x72)]['includes'](_0x4bf6fd))return null;const _0x5aca79={'name':_0x4bf6fd},_0x585f8c=_0x53a343['output'][_0x20ae84(0x8a)](new RegExp(_0x4bf6fd+_0x20ae84(0x6f),'i'));_0x585f8c&&(_0x5aca79[_0x20ae84(0x6d)]=_0x585f8c[0x1][_0x20ae84(0x67)]());const _0x3efded=_0x53a343['output']['match'](new RegExp(_0x4bf6fd+'[\x5cs\x5cS]*?Version:\x5cs*([\x5cd.]+)','i'));_0x3efded&&(_0x5aca79[_0x20ae84(0x69)]=_0x3efded[0x1]);const _0x192af9=_0x53a343['output']['match'](new RegExp(_0x4bf6fd+'[\x5cs\x5cS]*?(enabled|disabled)','i'));return _0x192af9&&(_0x5aca79['enabled']=_0x47ebf4['sIUql'](_0x192af9[0x1]['toLowerCase'](),_0x47ebf4['tHKZP'])),_0x5aca79;}