@ranger-testing/ranger-cli 3.1.6-alpha.aca5f9c-53 → 3.1.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/cli.js +1 -1
- package/build/commands/addEnv.js +1 -1
- package/build/commands/authEncrypt.js +1 -1
- package/build/commands/clean.js +1 -1
- package/build/commands/config.js +1 -1
- package/build/commands/deleteProfile.js +1 -1
- package/build/commands/env.js +1 -1
- package/build/commands/feature.js +1 -1
- package/build/commands/hook.js +1 -1
- package/build/commands/hooks/autoPrompt.js +1 -1
- package/build/commands/hooks/disable.js +1 -1
- package/build/commands/hooks/enable.js +1 -1
- package/build/commands/hooks/exitPlanMode.js +1 -1
- package/build/commands/hooks/index.js +1 -1
- package/build/commands/hooks/output.js +1 -1
- package/build/commands/hooks/planReminder.js +1 -1
- package/build/commands/hooks/planStart.js +1 -1
- package/build/commands/hooks/postEdit.js +1 -1
- package/build/commands/hooks/preCompact.js +1 -1
- package/build/commands/hooks/sessionEnd.js +1 -1
- package/build/commands/hooks/sessionStart.js +1 -1
- package/build/commands/hooks/stopHook.js +1 -1
- package/build/commands/index.js +1 -1
- package/build/commands/login.js +1 -1
- package/build/commands/mcpBootstrap.js +1 -1
- package/build/commands/migrateProfile.js +1 -1
- package/build/commands/setup/claude.js +1 -1
- package/build/commands/setup/opencode.js +1 -1
- package/build/commands/setupCi.js +1 -1
- package/build/commands/skillup.js +1 -1
- package/build/commands/start.js +1 -1
- package/build/commands/status.js +1 -1
- package/build/commands/update.js +1 -1
- package/build/commands/updateEnv.js +1 -1
- package/build/commands/useEnv.js +1 -1
- package/build/commands/utils/activeProfile.js +1 -1
- package/build/commands/utils/agentEnv.js +1 -1
- package/build/commands/utils/browserSessionsApi.js +1 -1
- package/build/commands/utils/claudeConfig.js +1 -1
- package/build/commands/utils/claudeOverrideSettings.js +1 -1
- package/build/commands/utils/claudePlugin.js +1 -1
- package/build/commands/utils/cloudProfile.js +1 -1
- package/build/commands/utils/cloudProfileSession.js +1 -1
- package/build/commands/utils/crypto.js +1 -1
- package/build/commands/utils/desirePathLog.js +1 -1
- package/build/commands/utils/deviceAuth.js +1 -1
- package/build/commands/utils/environment.js +1 -1
- package/build/commands/utils/featureApi.js +1 -1
- package/build/commands/utils/fixWebmDuration.js +1 -1
- package/build/commands/utils/gitTracked.js +1 -1
- package/build/commands/utils/keychain.js +1 -1
- package/build/commands/utils/legacyWarning.js +1 -1
- package/build/commands/utils/localAgentInstallationsApi.js +1 -1
- package/build/commands/utils/matchAuthEnvironment.js +1 -1
- package/build/commands/utils/mcpImageBase64.js +1 -1
- package/build/commands/utils/model.js +1 -1
- package/build/commands/utils/novaActCli.js +1 -1
- package/build/commands/utils/opencodeConfig.js +1 -1
- package/build/commands/utils/organizationEnvApi.js +1 -1
- package/build/commands/utils/playwrightCli.js +1 -1
- package/build/commands/utils/profileMessages.js +1 -1
- package/build/commands/utils/profileSetupBanner.js +1 -1
- package/build/commands/utils/projectsConfig.js +1 -1
- package/build/commands/utils/rangerConfig.js +1 -1
- package/build/commands/utils/rangerRoot.js +1 -1
- package/build/commands/utils/rangerwrightCli.js +1 -1
- package/build/commands/utils/resolveProfileContext.js +1 -1
- package/build/commands/utils/resolveProfileUrl.js +1 -1
- package/build/commands/utils/retry.js +1 -1
- package/build/commands/utils/scenarioOriginCheck.js +1 -1
- package/build/commands/utils/sessionCache.js +1 -1
- package/build/commands/utils/settings.js +1 -1
- package/build/commands/utils/skillContent.js +1 -1
- package/build/commands/utils/skills.js +1 -1
- package/build/commands/utils/stitchWebmFiles.js +1 -1
- package/build/commands/utils/telemetry.js +1 -1
- package/build/commands/utils/tokenRefresh.js +1 -1
- package/build/commands/utils/traceSnapshotMapper.js +1 -1
- package/build/commands/utils/tunnelClient.js +1 -1
- package/build/commands/utils/userApi.js +1 -1
- package/build/commands/utils/version.js +1 -1
- package/build/commands/verifyFeature.js +1 -1
- package/build/commands/verifyFeatureCli.js +1 -1
- package/build/commands/verifyFeatureNovaCli.js +1 -1
- package/build/commands/verifyFeatureRangerwrightCli.js +1 -1
- package/package.json +1 -1
package/build/commands/update.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const _0x2d1217=_0x247b;(function(_0x4f67b9,_0x33a074){const _0x22a288=_0x247b,_0x307ae4=_0x4f67b9();while(!![]){try{const _0xf446fa=parseInt(_0x22a288(0x1f3))/0x1+-parseInt(_0x22a288(0x1af))/0x2*(parseInt(_0x22a288(0x1ad))/0x3)+-parseInt(_0x22a288(0x1d3))/0x4*(parseInt(_0x22a288(0x1b8))/0x5)+parseInt(_0x22a288(0x1c0))/0x6+-parseInt(_0x22a288(0x1db))/0x7*(-parseInt(_0x22a288(0x1bb))/0x8)+parseInt(_0x22a288(0x202))/0x9+parseInt(_0x22a288(0x1a7))/0xa*(-parseInt(_0x22a288(0x1c7))/0xb);if(_0xf446fa===_0x33a074)break;else _0x307ae4['push'](_0x307ae4['shift']());}catch(_0x1bc064){_0x307ae4['push'](_0x307ae4['shift']());}}}(_0x232b,0x8e607));import{spawn,execSync}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;async function runCommand(_0x8c71a2,_0x2c8f5f,_0x598239){const _0x522ef3=_0x247b,_0x5a7935={'LSlbc':function(_0x3ffc69,_0x1490fc){return _0x3ffc69(_0x1490fc);},'RdXep':function(_0x1ef030,_0x242ecf){return _0x1ef030===_0x242ecf;},'ImjQg':function(_0x4111bd,_0x2c6fd7,_0x50216d,_0x3e2052){return _0x4111bd(_0x2c6fd7,_0x50216d,_0x3e2052);},'TEckk':_0x522ef3(0x1fd),'BkTJK':_0x522ef3(0x1f4),'yxrQB':_0x522ef3(0x1d1)};return new Promise(_0x5547df=>{const _0x490561=_0x522ef3;let _0x6a1cc4=![],_0x2ed1e4;const _0x415e28=_0x5042c0=>{if(_0x6a1cc4)return;_0x6a1cc4=!![],_0x2ed1e4&&clearTimeout(_0x2ed1e4),_0x5a7935['LSlbc'](_0x5547df,_0x5042c0);},_0x4ab3f5=_0x5a7935['ImjQg'](spawn,_0x8c71a2,_0x2c8f5f,{'stdio':[_0x490561(0x1e6),_0x598239?.[_0x490561(0x200)]??'inherit',_0x598239?.[_0x490561(0x200)]??_0x5a7935['TEckk']],'cwd':_0x598239?.['cwd'],'shell':process[_0x490561(0x1b0)]===_0x5a7935['BkTJK']});_0x2ed1e4=_0x598239?.['timeoutMs']?setTimeout(()=>{_0x4ab3f5['kill'](),_0x4ab3f5['unref'](),_0x5a7935['LSlbc'](_0x415e28,![]);},_0x598239['timeoutMs']):undefined,_0x4ab3f5['on'](_0x5a7935[_0x490561(0x1e1)],_0x2d6bc4=>{_0x415e28(_0x5a7935['RdXep'](_0x2d6bc4,0x0));}),_0x4ab3f5['on']('error',()=>{_0x415e28(![]);});});}export function resolveDistTag(_0x4f0ad0){const _0x743869=_0x247b,_0x306f39={'oAIUZ':'latest'};if(/-alpha\./i[_0x743869(0x1cc)](_0x4f0ad0))return _0x743869(0x1e9);if(/-beta\./i[_0x743869(0x1cc)](_0x4f0ad0))return'beta';if(/-rc\./i[_0x743869(0x1cc)](_0x4f0ad0))return'rc';return _0x306f39['oAIUZ'];}export function resolveInstallTarget(_0x59029d){const _0x555062=_0x247b,_0x1f194d={'uXHTC':function(_0x21bc9f,_0x2f83de){return _0x21bc9f(_0x2f83de);},'AnvRf':function(_0x454e5f,_0x182a2a,_0x3ed9e1){return _0x454e5f(_0x182a2a,_0x3ed9e1);}},_0x482937=_0x1f194d[_0x555062(0x1aa)](resolveDistTag,_0x59029d);if(_0x482937!=='latest')return _0x482937;const _0x485568=_0x59029d[_0x555062(0x1d5)]('.')[0x0],_0x2ea4f5=_0x1f194d['AnvRf'](parseInt,_0x485568,0xa);if(!Number[_0x555062(0x1f0)](_0x2ea4f5))return _0x555062(0x1ec);return'^'+_0x2ea4f5+_0x555062(0x1ca);}async function runInstall(_0x11bdbf){const _0xe98c2e=_0x247b,_0x567c78={'BllXB':function(_0x1349ba,_0x66320f){return _0x1349ba(_0x66320f);},'pBihh':function(_0x27ba2c,_0x23bc5d,_0x325033,_0x19b45d){return _0x27ba2c(_0x23bc5d,_0x325033,_0x19b45d);},'MUxpq':_0xe98c2e(0x1f9),'sbPVG':'ignore','OqFHn':_0xe98c2e(0x1fd),'ZRqKq':function(_0x2c6cfd,_0x5523f0){return _0x2c6cfd===_0x5523f0;},'CVpee':_0xe98c2e(0x1f4),'TKNRl':'error'},_0x38f7a2=resolveInstallTarget(_0x11bdbf);return new Promise(_0x5448dd=>{const _0x4f26de=_0xe98c2e,_0x2d6c4f={'rwMQA':function(_0x7f3226,_0x420e61){return _0x7f3226(_0x420e61);},'ojpmD':function(_0x307d7c,_0x528048){return _0x307d7c===_0x528048;}};console[_0x4f26de(0x1b4)]('\x0aInstalling\x20'+PACKAGE_NAME+'@'+_0x38f7a2+_0x4f26de(0x1ba));const _0x2a12b2=_0x567c78['pBihh'](spawn,_0x4f26de(0x1dc),[_0x567c78[_0x4f26de(0x207)],'-g',PACKAGE_NAME+'@'+_0x38f7a2],{'stdio':[_0x567c78['sbPVG'],_0x567c78[_0x4f26de(0x1dd)],_0x567c78['OqFHn']],'shell':_0x567c78['ZRqKq'](process['platform'],_0x567c78['CVpee'])});_0x2a12b2['on']('close',_0x4692bf=>{const _0x222758=_0x4f26de;_0x2d6c4f['rwMQA'](_0x5448dd,_0x2d6c4f[_0x222758(0x1b6)](_0x4692bf,0x0));}),_0x2a12b2['on'](_0x567c78['TKNRl'],()=>{const _0x11e49f=_0x4f26de;_0x567c78[_0x11e49f(0x201)](_0x5448dd,![]);});});}function resolveInstalledCliPath(){const _0x1a79a6=_0x247b,_0x3ec8f8={'ShfOL':_0x1a79a6(0x1b1),'nzQnI':function(_0x928f67,_0x25bc10,_0x2bb259,_0x3e5439,_0x12b80a){return _0x928f67(_0x25bc10,_0x2bb259,_0x3e5439,_0x12b80a);},'VoQVI':_0x1a79a6(0x1c1),'ySlrd':'cli.js'};try{const _0x27cdf2=execSync(_0x1a79a6(0x1ee),{'encoding':_0x3ec8f8[_0x1a79a6(0x20b)]})[_0x1a79a6(0x209)](),_0x140e01=_0x3ec8f8[_0x1a79a6(0x1ea)](join,_0x27cdf2,PACKAGE_NAME,_0x3ec8f8[_0x1a79a6(0x205)],_0x3ec8f8['ySlrd']);return existsSync(_0x140e01)?_0x140e01:null;}catch{return null;}}async function installMatchingChromium(){const _0x5610f1=_0x247b,_0x469fd5={'ccPiD':function(_0x21073b){return _0x21073b();},'YGrkX':function(_0x5afce5,_0x4495c4,_0x57fc09,_0x37dd1c){return _0x5afce5(_0x4495c4,_0x57fc09,_0x37dd1c);},'YgvUA':'setup','lspaV':'inherit','MsAal':'close','xVEOL':_0x5610f1(0x1d0)},_0x161126=resolveInstalledCliPath(),_0x4a4eeb=_0x5610f1(0x1e3);if(!_0x161126){console['log'](_0x4a4eeb);return;}await new Promise(_0x5404e4=>{const _0x1a2b58=_0x5610f1,_0x45fda3=_0x469fd5[_0x1a2b58(0x1eb)](spawn,process[_0x1a2b58(0x1e8)],[_0x161126,_0x469fd5[_0x1a2b58(0x203)],_0x1a2b58(0x1c9)],{'stdio':_0x469fd5['lspaV']});_0x45fda3['on'](_0x469fd5[_0x1a2b58(0x1fc)],()=>_0x5404e4()),_0x45fda3['on'](_0x469fd5['xVEOL'],()=>{const _0x42f44f=_0x1a2b58;console['log'](_0x4a4eeb),_0x469fd5[_0x42f44f(0x1be)](_0x5404e4);});});}function _0x247b(_0x1cfd3a,_0x58fad7){_0x1cfd3a=_0x1cfd3a-0x1a3;const _0x232b47=_0x232b();let _0x247b7c=_0x232b47[_0x1cfd3a];return _0x247b7c;}async function updateClaudeMarketplace(){const _0x56cee2=_0x247b,_0x343e84={'Qqgur':'marketplace','WPpuE':_0x56cee2(0x1e0)},_0x3cf1f=await runCommand('claude',[_0x56cee2(0x1c4),_0x343e84['Qqgur'],'update',_0x343e84[_0x56cee2(0x208)]],{'timeoutMs':CLAUDE_COMMAND_TIMEOUT_MS});if(!_0x3cf1f)throw new Error('Claude\x20marketplace\x20update\x20command\x20failed\x20(timed\x20out,\x20failed\x20to\x20start,\x20or\x20exited\x20with\x20a\x20non-zero\x20status).');}async function updateClaudePlugin(_0x29e15d=_0x2d1217(0x1b2)){const _0x1f3a35=_0x2d1217,_0xe0e7d0={'bUxyG':_0x1f3a35(0x1c4),'OvyDi':_0x1f3a35(0x1d8),'DETaY':_0x1f3a35(0x1e5),'dxGKc':'--scope','JYROa':function(_0x1cc8ce,_0x371343,_0x35a489,_0x2eec42){return _0x1cc8ce(_0x371343,_0x35a489,_0x2eec42);},'AOltK':function(_0x2e7ee0,_0x2276c3){return _0x2e7ee0===_0x2276c3;},'ZebLs':'project','imZal':_0x1f3a35(0x1d6),'ItLnI':function(_0x1b7caf){return _0x1b7caf();}},_0x3d87e0=[_0xe0e7d0[_0x1f3a35(0x1a6)],_0xe0e7d0[_0x1f3a35(0x1b7)],_0xe0e7d0[_0x1f3a35(0x1ab)]];_0x29e15d!==_0x1f3a35(0x1b2)&&_0x3d87e0[_0x1f3a35(0x1c3)](_0xe0e7d0[_0x1f3a35(0x1ef)],_0x29e15d);const _0x16204c=await _0xe0e7d0['JYROa'](runCommand,_0x1f3a35(0x1e7),_0x3d87e0,{'timeoutMs':CLAUDE_COMMAND_TIMEOUT_MS,'cwd':_0xe0e7d0['AOltK'](_0x29e15d,_0xe0e7d0[_0x1f3a35(0x1ff)])||_0x29e15d===_0xe0e7d0[_0x1f3a35(0x1fa)]?_0xe0e7d0[_0x1f3a35(0x1cb)](getProjectRoot):undefined});if(!_0x16204c)throw new Error(_0x1f3a35(0x1fe)+_0x29e15d+_0x1f3a35(0x1f6));}function isSkillInstalled(_0x57b750,_0x2e6d85,_0x23c4df){const _0x55d686=_0x2d1217,_0x2b01eb={'wsqFG':_0x55d686(0x1c5),'Tirok':function(_0x2622ac,_0x56f864){return _0x2622ac(_0x56f864);}},_0x252909=_0x23c4df===_0x2b01eb[_0x55d686(0x204)]?_0x2b01eb[_0x55d686(0x1a5)](getOpencodeSkillsDir,_0x2e6d85):getSkillsDir(_0x2e6d85),_0x355960=join(_0x252909,_0x57b750);return existsSync(_0x355960);}async function reinstallSkills(_0x566e34){const _0x7c8d10=_0x2d1217,_0x46eb36={'fXUeW':_0x7c8d10(0x1de),'ldcha':function(_0x2473d1,_0xdc1035,_0xa79b38,_0x33565d){return _0x2473d1(_0xdc1035,_0xa79b38,_0x33565d);},'djiNW':_0x7c8d10(0x1e7),'DzDOK':_0x7c8d10(0x1c5),'OCqqD':function(_0x1d4f98,_0x3dac16,_0x4ad0af){return _0x1d4f98(_0x3dac16,_0x4ad0af);},'byqdi':function(_0x4235ac,_0x456e58){return _0x4235ac===_0x456e58;},'vdwXl':_0x7c8d10(0x1f1)},_0x405563=[_0x46eb36['fXUeW'],'user'],_0xb2c91b=[];for(const _0x1d303e of _0x405563){for(const _0x34a04e of RANGER_MANAGED_SKILLS){_0x46eb36['ldcha'](isSkillInstalled,_0x34a04e,_0x1d303e,_0x7c8d10(0x1e7))&&_0xb2c91b['push']({'skillName':_0x34a04e,'level':_0x1d303e,'platform':_0x46eb36[_0x7c8d10(0x1fb)]}),isSkillInstalled(_0x34a04e,_0x1d303e,_0x46eb36[_0x7c8d10(0x1a3)])&&_0xb2c91b['push']({'skillName':_0x34a04e,'level':_0x1d303e,'platform':_0x7c8d10(0x1c5)});}}for(const _0x56e3bd of _0x405563){for(const _0xbbc6a of DEPRECATED_SKILLS){await _0x46eb36['OCqqD'](removeSkill,_0xbbc6a,_0x56e3bd);}}if(_0x46eb36[_0x7c8d10(0x1d4)](_0xb2c91b[_0x7c8d10(0x1f2)],0x0)){console[_0x7c8d10(0x1b4)](_0x46eb36['vdwXl']);return;}console['log'](_0x7c8d10(0x1df)+_0xb2c91b[_0x7c8d10(0x1f2)]+_0x7c8d10(0x1cd));for(const {skillName:_0x2abf00,level:_0xa1509c,platform:_0x16c6a2}of _0xb2c91b){try{await _0x46eb36[_0x7c8d10(0x1f5)](installSkill,_0x2abf00,{'level':_0xa1509c,'cliVersion':_0x566e34,'platform':_0x16c6a2});}catch(_0x56fe7){console['warn']('\x20\x20Failed\x20to\x20reinstall\x20'+_0x16c6a2+'\x20'+_0xa1509c+'\x20skill\x20'+_0x2abf00+':',_0x56fe7);}}}function _0x232b(){const _0x1d3212=['DZPku','\x0aClaude\x20plugin\x20updated\x20(user\x20scope).','error','close','\x0aClaude\x20plugin\x20updated\x20(local\x20scope).','12wcJSUV','byqdi','split','local','\x0a✅\x20Update\x20complete!','update','tNrGH','\x0aSuccessfully\x20installed\x20latest\x20version.','7nqHNoR','npm','OqFHn','project','\x0aReinstalling\x20','trailhead','yxrQB','LEdjl','\x0a\x20\x20Could\x20not\x20auto-install\x20the\x20matching\x20Chromium\x20—\x20run\x20`ranger\x20setup\x20deps`\x20to\x20install\x20it.','\x0aSuccessfully\x20updated\x20to\x20version\x20','ranger@trailhead','ignore','claude','execPath','alpha','nzQnI','YGrkX','latest','\x20channel.','npm\x20root\x20-g','dxGKc','isFinite','\x0aNo\x20ranger-managed\x20skills\x20found\x20to\x20reinstall.','length','662986yZeXSt','win32','OCqqD','\x20scope\x20(timed\x20out,\x20failed\x20to\x20start,\x20or\x20exited\x20with\x20a\x20non-zero\x20status).','utf-8','vZzmn','install','imZal','djiNW','MsAal','inherit','Claude\x20plugin\x20update\x20failed\x20for\x20','ZebLs','stdio','BllXB','5755401kRCznt','YgvUA','wsqFG','VoQVI','Update\x20failed.','MUxpq','WPpuE','trim','QftrF','ShfOL','pxzHg','DzDOK','Update\x20failed\x20for\x20@','Tirok','bUxyG','13724020NWyrrQ','CGCOG','active-profile.txt','uXHTC','DETaY','BOaCC','3Axkezn','dhYFR','12434BFXDoV','platform','utf8','user','Could\x20not\x20determine\x20the\x20current\x20major\x20version\x20from\x20\x22','log','warn','ojpmD','OvyDi','988090GJLlNv','@latest','...\x0a','2498584iKzUoZ','Attempting\x20install\x20anyway...','\x0aCould\x20not\x20check\x20latest\x20version:\x20','ccPiD','version','5639100URzuwa','build',')\x20is\x20newer\x20than\x20the\x20published\x20version\x20(','push','plugin','opencode','\x20—\x20reinstalling\x20@','11oGGaTt','mlvgF','deps','.0.0','ItLnI','test','\x20ranger-managed\x20skill(s)...'];_0x232b=function(){return _0x1d3212;};return _0x232b();}async function ensureActiveProfileGitignored(){const _0x684f85=_0x2d1217,_0x301879={'dhYFR':function(_0x59f7db,_0x392d34,_0x11543b){return _0x59f7db(_0x392d34,_0x11543b);},'tNrGH':function(_0x442631){return _0x442631();},'QftrF':function(_0x5e972d,_0x11d6f8){return _0x5e972d(_0x11d6f8);},'ljOAd':_0x684f85(0x1f7),'vZzmn':function(_0x25676b,_0x3bcdc0){return _0x25676b===_0x3bcdc0;},'Vkqbr':'active-profile.txt'},_0x119945=_0x301879[_0x684f85(0x1ae)](join,_0x301879[_0x684f85(0x1d9)](getRangerDir),'.gitignore');if(!_0x301879[_0x684f85(0x20a)](existsSync,_0x119945))return![];let _0x5f0d77='';try{_0x5f0d77=await readFile(_0x119945,_0x301879['ljOAd']);}catch{return![];}const _0x13848b=_0x5f0d77[_0x684f85(0x1d5)](/\r?\n/);if(_0x13848b['some'](_0x143066=>_0x143066['trim']()===_0x684f85(0x1a9)))return![];let _0x1c21fb=_0x13848b['findIndex'](_0x1f8cce=>_0x1f8cce['trim']()==='active-feature.txt');_0x301879[_0x684f85(0x1f8)](_0x1c21fb,-0x1)&&(_0x1c21fb=_0x13848b['length']);_0x13848b['splice'](_0x1c21fb,0x0,_0x301879['Vkqbr']);let _0xb1c28e=_0x13848b['join']('\x0a');!_0xb1c28e['endsWith']('\x0a')&&(_0xb1c28e+='\x0a');try{await writeFile(_0x119945,_0xb1c28e,_0x684f85(0x1f7));}catch{return![];}return!![];}export async function update(){const _0x379579=_0x2d1217,_0x1a3bca={'LEdjl':function(_0x355dfc){return _0x355dfc();},'FEvfm':function(_0x23dd5e,_0x1d2b48){return _0x23dd5e(_0x1d2b48);},'inRSe':_0x379579(0x1ec),'cXbFQ':function(_0x2f8ba8){return _0x2f8ba8();},'LgErh':'Checking\x20for\x20updates...','WzUqQ':function(_0x431f82,_0x43eada){return _0x431f82+_0x43eada;},'mlvgF':_0x379579(0x1bc),'Yyiuc':function(_0x406970){return _0x406970();},'aFHgB':function(_0x37b230,_0x8eb6d8){return _0x37b230<_0x8eb6d8;},'CGCOG':function(_0x453cbe,_0x592db6){return _0x453cbe(_0x592db6);},'pxzHg':function(_0x2bf4cc){return _0x2bf4cc();},'QDVCg':_0x379579(0x206),'yQXsK':_0x379579(0x1e0),'DZPku':function(_0xfa8d12,_0x325fdc){return _0xfa8d12(_0x325fdc);},'filCZ':function(_0x180ce7,_0x1ebc06){return _0x180ce7===_0x1ebc06;},'SVkVf':'\x0aClaude\x20plugin\x20updated\x20(project\x20scope).','BOaCC':'local'},_0x27c7a7=_0x1a3bca['LEdjl'](getCurrentVersion);console[_0x379579(0x1b4)]('\x0aCurrent\x20version:\x20'+_0x27c7a7);const _0x341d66=_0x1a3bca['FEvfm'](resolveDistTag,_0x27c7a7);if(_0x341d66!==_0x1a3bca['inRSe']){console['log']('Prerelease\x20channel\x20detected\x20(@'+_0x341d66+').\x20Staying\x20on\x20'+_0x341d66+_0x379579(0x1c6)+_0x341d66+'...');const _0x303d32=await runInstall(_0x27c7a7);if(!_0x303d32)throw new Error(_0x379579(0x1a4)+_0x341d66+_0x379579(0x1ed));const _0x1ad017=_0x1a3bca['cXbFQ'](getCurrentVersion);console[_0x379579(0x1b4)]('\x0aSuccessfully\x20installed\x20'+PACKAGE_NAME+'@'+_0x341d66+'.'),await reinstallSkills(_0x1ad017),await _0x1a3bca['LEdjl'](installMatchingChromium),await ensureActiveProfileGitignored(),console['log'](_0x379579(0x1d7));return;}console['log'](_0x1a3bca['LgErh']);const _0x47f56a=parseInt(_0x27c7a7['split']('.')[0x0],0xa);if(!Number[_0x379579(0x1f0)](_0x47f56a))throw new Error(_0x1a3bca['WzUqQ'](_0x379579(0x1b3)+_0x27c7a7+'\x22.\x20','Aborting\x20to\x20avoid\x20a\x20cross-major\x20upgrade.\x20Reinstall\x20explicitly\x20with:\x20')+('npm\x20i\x20-g\x20'+PACKAGE_NAME+_0x379579(0x1b9)));const _0x5785c6=getLatestVersion(_0x47f56a);let _0x5b3ce1=_0x27c7a7;if(!_0x5785c6['version']){console[_0x379579(0x1b5)](_0x379579(0x1bd)+_0x5785c6[_0x379579(0x1d0)]),console[_0x379579(0x1b4)](_0x1a3bca[_0x379579(0x1c8)]);const _0x2cfc0d=await runInstall(_0x27c7a7);if(_0x2cfc0d)console[_0x379579(0x1b4)](_0x379579(0x1da)),_0x5b3ce1=_0x1a3bca[_0x379579(0x1e2)](getCurrentVersion),await _0x1a3bca['Yyiuc'](installMatchingChromium);else throw new Error('Update\x20failed:\x20'+_0x5785c6['error']);}else{const _0x174fc3=_0x5785c6[_0x379579(0x1bf)];console['log']('Latest\x20version:\x20\x20'+_0x174fc3);const _0x123797=compareVersions(_0x27c7a7,_0x174fc3);if(_0x123797===0x0)console['log']('\x0aYou\x20are\x20already\x20on\x20the\x20latest\x20version.');else{if(_0x1a3bca['aFHgB'](_0x123797,0x0))console['log']('\x0aYour\x20version\x20('+_0x27c7a7+_0x379579(0x1c2)+_0x174fc3+').');else{const _0x1602da=await _0x1a3bca[_0x379579(0x1a8)](runInstall,_0x27c7a7);if(_0x1602da)console[_0x379579(0x1b4)](_0x379579(0x1e4)+_0x174fc3),_0x5b3ce1=_0x174fc3,await _0x1a3bca[_0x379579(0x20c)](installMatchingChromium);else throw new Error(_0x1a3bca['QDVCg']);}}}await _0x1a3bca[_0x379579(0x1a8)](reinstallSkills,_0x5b3ce1);const _0x3cba7c=await _0x1a3bca[_0x379579(0x1a8)](isMarketplaceAdded,_0x1a3bca['yQXsK']),_0x170912=await isPluginInstalled(_0x379579(0x1e5));_0x3cba7c&&(await updateClaudeMarketplace(),console['log']('\x0aClaude\x20marketplace\x20updated\x20(trailhead).'));if(_0x170912){const _0x2c66b8=await _0x1a3bca[_0x379579(0x1ce)](getPluginInfo,'ranger@trailhead'),_0x521330=_0x2c66b8?.['scope']??_0x379579(0x1b2);await _0x1a3bca[_0x379579(0x1ce)](updateClaudePlugin,_0x521330);if(_0x1a3bca['filCZ'](_0x521330,'project'))console['log'](_0x1a3bca['SVkVf']);else _0x521330===_0x1a3bca[_0x379579(0x1ac)]?console['log'](_0x379579(0x1d2)):console['log'](_0x379579(0x1cf));}const _0x5c800f=await _0x1a3bca['pxzHg'](ensureActiveProfileGitignored);console['log'](_0x379579(0x1d7));}
|
|
1
|
+
const _0x3fccee=_0x240d;(function(_0x2d2867,_0x14195d){const _0x30a338=_0x240d,_0x374f65=_0x2d2867();while(!![]){try{const _0x176b62=-parseInt(_0x30a338(0x205))/0x1*(parseInt(_0x30a338(0x1cd))/0x2)+-parseInt(_0x30a338(0x1c8))/0x3+parseInt(_0x30a338(0x1ea))/0x4*(parseInt(_0x30a338(0x204))/0x5)+-parseInt(_0x30a338(0x1d5))/0x6*(-parseInt(_0x30a338(0x1a6))/0x7)+-parseInt(_0x30a338(0x1d2))/0x8*(-parseInt(_0x30a338(0x1d4))/0x9)+-parseInt(_0x30a338(0x1da))/0xa*(-parseInt(_0x30a338(0x20b))/0xb)+parseInt(_0x30a338(0x1f1))/0xc*(-parseInt(_0x30a338(0x1e5))/0xd);if(_0x176b62===_0x14195d)break;else _0x374f65['push'](_0x374f65['shift']());}catch(_0x2dee2e){_0x374f65['push'](_0x374f65['shift']());}}}(_0x444c,0xd8eac));import{spawn,execSync}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;async function runCommand(_0x4693d2,_0x14979c,_0x334694){const _0x526ee0=_0x240d,_0x380db4={'qwrEw':function(_0x7aaed5,_0x21b03e){return _0x7aaed5(_0x21b03e);},'axqAu':function(_0xd25d1c,_0x25d5bd){return _0xd25d1c(_0x25d5bd);},'gIQrP':function(_0x41b9df,_0x16ffe5){return _0x41b9df===_0x16ffe5;},'oEkdL':_0x526ee0(0x1e2),'wKSos':_0x526ee0(0x1b1),'ohtDD':_0x526ee0(0x1ba)};return new Promise(_0x45c75e=>{const _0x52ab87=_0x526ee0,_0x5e05c2={'efWAo':function(_0x231f74,_0x5af875){return _0x231f74(_0x5af875);},'lZusA':function(_0x563673,_0x202f46){const _0x5a5983=_0x240d;return _0x380db4[_0x5a5983(0x1b5)](_0x563673,_0x202f46);}};let _0xd69d67=![],_0x5d5b88;const _0x1a6e08=_0x481ed2=>{if(_0xd69d67)return;_0xd69d67=!![],_0x5d5b88&&clearTimeout(_0x5d5b88),_0x45c75e(_0x481ed2);},_0x3368a4=spawn(_0x4693d2,_0x14979c,{'stdio':[_0x380db4[_0x52ab87(0x1fc)],_0x334694?.['stdio']??_0x380db4['wKSos'],_0x334694?.[_0x52ab87(0x1cc)]??_0x380db4[_0x52ab87(0x201)]],'cwd':_0x334694?.[_0x52ab87(0x1c4)],'shell':process['platform']==='win32'});_0x5d5b88=_0x334694?.[_0x52ab87(0x1a3)]?setTimeout(()=>{const _0x4cbca0=_0x52ab87;_0x3368a4[_0x4cbca0(0x1df)](),_0x3368a4[_0x4cbca0(0x1b2)](),_0x380db4['qwrEw'](_0x1a6e08,![]);},_0x334694[_0x52ab87(0x1a3)]):undefined,_0x3368a4['on']('close',_0x33d086=>{const _0x2f05f3=_0x52ab87;_0x5e05c2[_0x2f05f3(0x1fa)](_0x1a6e08,_0x5e05c2['lZusA'](_0x33d086,0x0));}),_0x3368a4['on'](_0x380db4['ohtDD'],()=>{_0x380db4['axqAu'](_0x1a6e08,![]);});});}export function resolveDistTag(_0x4dbbd7){const _0x452619=_0x240d,_0x568d0d={'MnycC':_0x452619(0x1e6)};if(/-alpha\./i[_0x452619(0x1f0)](_0x4dbbd7))return _0x452619(0x21b);if(/-beta\./i[_0x452619(0x1f0)](_0x4dbbd7))return _0x452619(0x217);if(/-rc\./i[_0x452619(0x1f0)](_0x4dbbd7))return'rc';return _0x568d0d['MnycC'];}function _0x444c(){const _0x4cd8ac=['KxYoI','\x0aClaude\x20plugin\x20updated\x20(user\x20scope).','\x0a✅\x20Update\x20complete!','yAAoO','project','--scope','wTgcH','NktGH','efWAo','trim','oEkdL',').\x20Staying\x20on\x20','lSuos','build','active-feature.txt','wKSos','kOuCk','warn','3907430MfSCcC','53Dsqrhw','opencode','PtEKX','oDvTX','utf8','join','50699mhMzay','QvUpj','claude','CpsLT','npm','Update\x20failed\x20for\x20@','tOWbz','execPath','tqklr','Claude\x20plugin\x20update\x20failed\x20for\x20','CAMTw','push','beta','update','comyL','Prerelease\x20channel\x20detected\x20(@','alpha','timeoutMs','vwSRv','\x0aYou\x20are\x20already\x20on\x20the\x20latest\x20version.','7ZXEcXI','\x0aSuccessfully\x20installed\x20latest\x20version.','length','UkMtb','ranger@trailhead','JafBK','iqikF','platform','version','deps','unTWu','inherit','unref','TAFKl','Claude\x20marketplace\x20update\x20command\x20failed\x20(timed\x20out,\x20failed\x20to\x20start,\x20or\x20exited\x20with\x20a\x20non-zero\x20status).','gIQrP','FaSjv','\x20channel.','\x0a\x20\x20Could\x20not\x20auto-install\x20the\x20matching\x20Chromium\x20—\x20run\x20`ranger\x20setup\x20deps`\x20to\x20install\x20it.','zVeTp','error','marketplace','...',')\x20is\x20newer\x20than\x20the\x20published\x20version\x20(','user','TugMQ','OxFWg','KDwGi','\x20scope\x20(timed\x20out,\x20failed\x20to\x20start,\x20or\x20exited\x20with\x20a\x20non-zero\x20status).','.gitignore','cwd','oCaCF','\x20skill\x20','HbfHy','3807807xOzAGd','isFinite','ocyFA','Ysews','stdio','9566UyEdrc','local','SRQad','pfpGY','Attempting\x20install\x20anyway...','6626672HxfzRE','log','18MVaxVV','10007676RVBqDK','trailhead','\x0aClaude\x20marketplace\x20updated\x20(trailhead).','zqLzD','iUzuf','3550frvMlI','gqImO','splice','plugin','setup','kill','ChAws','scope','ignore','CQZXP','\x0aNo\x20ranger-managed\x20skills\x20found\x20to\x20reinstall.','2886897MXzylv','latest','XElSK','Latest\x20version:\x20\x20','rHAOd','4ZPUsiw','NQcAc','NkLNv','split','utf-8','\x0aSuccessfully\x20updated\x20to\x20version\x20','test','180jwqAtw'];_0x444c=function(){return _0x4cd8ac;};return _0x444c();}export function resolveInstallTarget(_0x43e130){const _0x3e0adf=_0x240d,_0x147d28={'Lmyvk':function(_0x4c28b3,_0x19e631){return _0x4c28b3!==_0x19e631;},'CQZXP':'latest','NkLNv':function(_0x4d5349,_0x5e6fb6,_0x561028){return _0x4d5349(_0x5e6fb6,_0x561028);}},_0xa9e0fb=resolveDistTag(_0x43e130);if(_0x147d28['Lmyvk'](_0xa9e0fb,_0x147d28['CQZXP']))return _0xa9e0fb;const _0x410a48=_0x43e130['split']('.')[0x0],_0x5e1f31=_0x147d28[_0x3e0adf(0x1ec)](parseInt,_0x410a48,0xa);if(!Number['isFinite'](_0x5e1f31))return _0x147d28[_0x3e0adf(0x1e3)];return'^'+_0x5e1f31+'.0.0';}async function runInstall(_0x59a199){const _0x457877=_0x240d,_0x125f5f={'YlbGD':function(_0x3b26c0,_0x51893b,_0x3de575,_0x595084){return _0x3b26c0(_0x51893b,_0x3de575,_0x595084);},'qFNEe':'ignore','JYzai':_0x457877(0x1b1),'stwWP':function(_0x3c0f8a,_0x395ac1){return _0x3c0f8a===_0x395ac1;},'CpsLT':'win32','zXtjN':'close','wqtgS':'error','efMXF':function(_0x303221,_0x1967c3){return _0x303221(_0x1967c3);}},_0x5eb06e=_0x125f5f['efMXF'](resolveInstallTarget,_0x59a199);return new Promise(_0x5f0a60=>{const _0x14efd3=_0x457877;console[_0x14efd3(0x1d3)]('\x0aInstalling\x20'+PACKAGE_NAME+'@'+_0x5eb06e+'...\x0a');const _0x2c297d=_0x125f5f['YlbGD'](spawn,_0x14efd3(0x20f),['install','-g',PACKAGE_NAME+'@'+_0x5eb06e],{'stdio':[_0x125f5f['qFNEe'],_0x125f5f['JYzai'],_0x14efd3(0x1b1)],'shell':_0x125f5f['stwWP'](process[_0x14efd3(0x1ad)],_0x125f5f[_0x14efd3(0x20e)])});_0x2c297d['on'](_0x125f5f['zXtjN'],_0x40be2d=>{_0x5f0a60(_0x40be2d===0x0);}),_0x2c297d['on'](_0x125f5f['wqtgS'],()=>{_0x5f0a60(![]);});});}function resolveInstalledCliPath(){const _0x55c886=_0x240d,_0x44702f={'SDuwW':function(_0x54e687,_0x22abf4,_0x46c4b0){return _0x54e687(_0x22abf4,_0x46c4b0);},'NktGH':_0x55c886(0x209),'mYKqg':function(_0x550deb,_0x40d404,_0x304054,_0x5bbd4c,_0x2f2c01){return _0x550deb(_0x40d404,_0x304054,_0x5bbd4c,_0x2f2c01);},'HWUgI':_0x55c886(0x1ff)};try{const _0x335b48=_0x44702f['SDuwW'](execSync,'npm\x20root\x20-g',{'encoding':_0x44702f[_0x55c886(0x1f9)]})[_0x55c886(0x1fb)](),_0x85b514=_0x44702f['mYKqg'](join,_0x335b48,PACKAGE_NAME,_0x44702f['HWUgI'],'cli.js');return existsSync(_0x85b514)?_0x85b514:null;}catch{return null;}}async function installMatchingChromium(){const _0x29d4cd=_0x240d,_0x32722c={'oCaCF':function(_0x21f9cf){return _0x21f9cf();},'iUzuf':function(_0x1916c1,_0x2c6d96,_0x333ee2,_0x359318){return _0x1916c1(_0x2c6d96,_0x333ee2,_0x359318);},'vwSRv':_0x29d4cd(0x1af),'BsHXA':'error','yAAoO':_0x29d4cd(0x1b8)},_0x27da37=resolveInstalledCliPath(),_0x3a93bf=_0x32722c[_0x29d4cd(0x1f5)];if(!_0x27da37){console['log'](_0x3a93bf);return;}await new Promise(_0x52fcc4=>{const _0x233fa2=_0x29d4cd,_0x18e8ce=_0x32722c[_0x233fa2(0x1d9)](spawn,process[_0x233fa2(0x212)],[_0x27da37,_0x233fa2(0x1de),_0x32722c[_0x233fa2(0x1a4)]],{'stdio':_0x233fa2(0x1b1)});_0x18e8ce['on']('close',()=>_0x52fcc4()),_0x18e8ce['on'](_0x32722c['BsHXA'],()=>{const _0x3cc8c8=_0x233fa2;console[_0x3cc8c8(0x1d3)](_0x3a93bf),_0x32722c[_0x3cc8c8(0x1c5)](_0x52fcc4);});});}async function updateClaudeMarketplace(){const _0x121dc8=_0x240d,_0x3ef539={'QvUpj':function(_0xa21e53,_0x514744,_0xff666c,_0x18b9c0){return _0xa21e53(_0x514744,_0xff666c,_0x18b9c0);},'Ysews':'claude','OQkaR':_0x121dc8(0x1dd),'lSuos':_0x121dc8(0x1bb),'comyL':_0x121dc8(0x218),'pybKl':_0x121dc8(0x1d6),'KxYoI':_0x121dc8(0x1b4)},_0x109573=await _0x3ef539[_0x121dc8(0x20c)](runCommand,_0x3ef539[_0x121dc8(0x1cb)],[_0x3ef539['OQkaR'],_0x3ef539[_0x121dc8(0x1fe)],_0x3ef539[_0x121dc8(0x219)],_0x3ef539['pybKl']],{'timeoutMs':CLAUDE_COMMAND_TIMEOUT_MS});if(!_0x109573)throw new Error(_0x3ef539[_0x121dc8(0x1f2)]);}async function updateClaudePlugin(_0x233005=_0x3fccee(0x1be)){const _0x4db026=_0x3fccee,_0x2ba322={'ymnmW':_0x4db026(0x1dd),'PtEKX':'update','unTWu':_0x4db026(0x1be),'Nthag':_0x4db026(0x1f7),'wTgcH':function(_0x1bbb8b,_0x14e9df,_0x406a0f,_0x3db893){return _0x1bbb8b(_0x14e9df,_0x406a0f,_0x3db893);},'jHZJk':'claude','FaSjv':'project','PMCgv':function(_0x4fb8ed,_0x1be29f){return _0x4fb8ed===_0x1be29f;},'wRqTx':'local','TAFKl':function(_0x5d9f84){return _0x5d9f84();}},_0x257f13=[_0x2ba322['ymnmW'],_0x2ba322[_0x4db026(0x207)],_0x4db026(0x1aa)];_0x233005!==_0x2ba322[_0x4db026(0x1b0)]&&_0x257f13['push'](_0x2ba322['Nthag'],_0x233005);const _0xaa032e=await _0x2ba322[_0x4db026(0x1f8)](runCommand,_0x2ba322['jHZJk'],_0x257f13,{'timeoutMs':CLAUDE_COMMAND_TIMEOUT_MS,'cwd':_0x233005===_0x2ba322[_0x4db026(0x1b6)]||_0x2ba322['PMCgv'](_0x233005,_0x2ba322['wRqTx'])?_0x2ba322[_0x4db026(0x1b3)](getProjectRoot):undefined});if(!_0xaa032e)throw new Error(_0x4db026(0x214)+_0x233005+_0x4db026(0x1c2));}function isSkillInstalled(_0x43be85,_0x18baed,_0x332f44){const _0x27e465=_0x3fccee,_0x520d08={'tOWbz':_0x27e465(0x206),'tqklr':function(_0x1f7963,_0x6a9650){return _0x1f7963(_0x6a9650);}},_0x207fb7=_0x332f44===_0x520d08[_0x27e465(0x211)]?getOpencodeSkillsDir(_0x18baed):getSkillsDir(_0x18baed),_0x3e22e4=join(_0x207fb7,_0x43be85);return _0x520d08[_0x27e465(0x213)](existsSync,_0x3e22e4);}async function reinstallSkills(_0x4de8d6){const _0x5a38a2=_0x3fccee,_0x28b647={'JafBK':_0x5a38a2(0x1f6),'zVeTp':'user','kOuCk':function(_0x38b2f1,_0x37ca07,_0x516d39,_0x5daa9b){return _0x38b2f1(_0x37ca07,_0x516d39,_0x5daa9b);},'HbfHy':_0x5a38a2(0x20d),'CHVWx':function(_0x58bea5,_0x2c7065,_0x566fce,_0x3d2b29){return _0x58bea5(_0x2c7065,_0x566fce,_0x3d2b29);},'oDvTX':function(_0x1d57b5,_0x2b5e7c,_0x1b607e){return _0x1d57b5(_0x2b5e7c,_0x1b607e);},'QarBe':_0x5a38a2(0x1e4),'BKSCo':function(_0x41d34f,_0x2aa867,_0x45846b){return _0x41d34f(_0x2aa867,_0x45846b);}},_0x53b96c=[_0x28b647[_0x5a38a2(0x1ab)],_0x28b647[_0x5a38a2(0x1b9)]],_0x4108da=[];for(const _0x13f9d0 of _0x53b96c){for(const _0xc48b36 of RANGER_MANAGED_SKILLS){_0x28b647[_0x5a38a2(0x202)](isSkillInstalled,_0xc48b36,_0x13f9d0,_0x28b647[_0x5a38a2(0x1c7)])&&_0x4108da[_0x5a38a2(0x216)]({'skillName':_0xc48b36,'level':_0x13f9d0,'platform':_0x5a38a2(0x20d)}),_0x28b647['CHVWx'](isSkillInstalled,_0xc48b36,_0x13f9d0,_0x5a38a2(0x206))&&_0x4108da['push']({'skillName':_0xc48b36,'level':_0x13f9d0,'platform':'opencode'});}}for(const _0x542154 of _0x53b96c){for(const _0x137fa8 of DEPRECATED_SKILLS){await _0x28b647[_0x5a38a2(0x208)](removeSkill,_0x137fa8,_0x542154);}}if(_0x4108da[_0x5a38a2(0x1a8)]===0x0){console[_0x5a38a2(0x1d3)](_0x28b647['QarBe']);return;}console[_0x5a38a2(0x1d3)]('\x0aReinstalling\x20'+_0x4108da['length']+'\x20ranger-managed\x20skill(s)...');for(const {skillName:_0x26b15f,level:_0x515b4c,platform:_0x519f51}of _0x4108da){try{await _0x28b647['BKSCo'](installSkill,_0x26b15f,{'level':_0x515b4c,'cliVersion':_0x4de8d6,'platform':_0x519f51});}catch(_0x5aeca5){console[_0x5a38a2(0x203)]('\x20\x20Failed\x20to\x20reinstall\x20'+_0x519f51+'\x20'+_0x515b4c+_0x5a38a2(0x1c6)+_0x26b15f+':',_0x5aeca5);}}}async function ensureActiveProfileGitignored(){const _0x3b0a0b=_0x3fccee,_0x86942={'XElSK':function(_0x27f09c,_0x163c68,_0x43320d){return _0x27f09c(_0x163c68,_0x43320d);},'EnhxE':function(_0x512f71){return _0x512f71();},'OxFWg':function(_0x29172d,_0x3e9c9f,_0x38317d){return _0x29172d(_0x3e9c9f,_0x38317d);},'TugMQ':_0x3b0a0b(0x1ee),'SRQad':'active-profile.txt','ocyFA':function(_0x33206f,_0xef5bfa,_0x4d0b77,_0x121c38){return _0x33206f(_0xef5bfa,_0x4d0b77,_0x121c38);}},_0x1b8a05=_0x86942[_0x3b0a0b(0x1e7)](join,_0x86942['EnhxE'](getRangerDir),_0x3b0a0b(0x1c3));if(!existsSync(_0x1b8a05))return![];let _0x449df7='';try{_0x449df7=await _0x86942[_0x3b0a0b(0x1c0)](readFile,_0x1b8a05,_0x86942['TugMQ']);}catch{return![];}const _0x934ef5=_0x449df7[_0x3b0a0b(0x1ed)](/\r?\n/);if(_0x934ef5['some'](_0x139117=>_0x139117[_0x3b0a0b(0x1fb)]()==='active-profile.txt'))return![];let _0x4575cb=_0x934ef5['findIndex'](_0x484a9f=>_0x484a9f['trim']()===_0x3b0a0b(0x200));_0x4575cb===-0x1&&(_0x4575cb=_0x934ef5[_0x3b0a0b(0x1a8)]);_0x934ef5[_0x3b0a0b(0x1dc)](_0x4575cb,0x0,_0x86942[_0x3b0a0b(0x1cf)]);let _0x4f8246=_0x934ef5[_0x3b0a0b(0x20a)]('\x0a');!_0x4f8246['endsWith']('\x0a')&&(_0x4f8246+='\x0a');try{await _0x86942[_0x3b0a0b(0x1ca)](writeFile,_0x1b8a05,_0x4f8246,_0x86942[_0x3b0a0b(0x1bf)]);}catch{return![];}return!![];}function _0x240d(_0x42f51a,_0x582b53){_0x42f51a=_0x42f51a-0x1a3;const _0x444c13=_0x444c();let _0x240db3=_0x444c13[_0x42f51a];return _0x240db3;}export async function update(){const _0x3fb34c=_0x3fccee,_0x42a882={'NQcAc':function(_0x5d61d1){return _0x5d61d1();},'UIlAB':function(_0x126783,_0x508e6d){return _0x126783(_0x508e6d);},'zqLzD':function(_0x4ac479,_0x4872b7){return _0x4ac479!==_0x4872b7;},'ChAws':function(_0x6f5517,_0xa0d674){return _0x6f5517(_0xa0d674);},'KDwGi':function(_0xdaceb4){return _0xdaceb4();},'Fomrv':function(_0x3469bc,_0x42ee8e){return _0x3469bc+_0x42ee8e;},'iqikF':function(_0x1f962b,_0x5879f2){return _0x1f962b(_0x5879f2);},'uEcqV':_0x3fb34c(0x1a7),'ZnnAX':function(_0x4d2e25,_0x20cba4,_0x4d0700){return _0x4d2e25(_0x20cba4,_0x4d0700);},'CAMTw':_0x3fb34c(0x1a5),'cZQwE':function(_0x103aae,_0x111149){return _0x103aae<_0x111149;},'rHAOd':_0x3fb34c(0x1d6),'UkMtb':function(_0x3d51a2,_0x1aafe7){return _0x3d51a2(_0x1aafe7);},'gqImO':'ranger@trailhead','pfpGY':function(_0x288790,_0x2347d9){return _0x288790===_0x2347d9;},'SzjVG':'\x0aClaude\x20plugin\x20updated\x20(project\x20scope).','bzPgb':_0x3fb34c(0x1f3)},_0x31ee11=_0x42a882['NQcAc'](getCurrentVersion);console['log']('\x0aCurrent\x20version:\x20'+_0x31ee11);const _0x87f5a1=_0x42a882['UIlAB'](resolveDistTag,_0x31ee11);if(_0x42a882[_0x3fb34c(0x1d8)](_0x87f5a1,_0x3fb34c(0x1e6))){console[_0x3fb34c(0x1d3)](_0x3fb34c(0x21a)+_0x87f5a1+_0x3fb34c(0x1fd)+_0x87f5a1+'\x20—\x20reinstalling\x20@'+_0x87f5a1+_0x3fb34c(0x1bc));const _0x8af12c=await _0x42a882[_0x3fb34c(0x1e0)](runInstall,_0x31ee11);if(!_0x8af12c)throw new Error(_0x3fb34c(0x210)+_0x87f5a1+_0x3fb34c(0x1b7));const _0x4cfc4b=_0x42a882['KDwGi'](getCurrentVersion);console['log']('\x0aSuccessfully\x20installed\x20'+PACKAGE_NAME+'@'+_0x87f5a1+'.'),await reinstallSkills(_0x4cfc4b),await _0x42a882['NQcAc'](installMatchingChromium),await ensureActiveProfileGitignored(),console[_0x3fb34c(0x1d3)](_0x3fb34c(0x1f4));return;}console['log']('Checking\x20for\x20updates...');const _0x2fdc28=parseInt(_0x31ee11['split']('.')[0x0],0xa);if(!Number[_0x3fb34c(0x1c9)](_0x2fdc28))throw new Error(_0x42a882['Fomrv']('Could\x20not\x20determine\x20the\x20current\x20major\x20version\x20from\x20\x22'+_0x31ee11+'\x22.\x20','Aborting\x20to\x20avoid\x20a\x20cross-major\x20upgrade.\x20Reinstall\x20explicitly\x20with:\x20')+('npm\x20i\x20-g\x20'+PACKAGE_NAME+'@latest'));const _0xa036f9=_0x42a882[_0x3fb34c(0x1ac)](getLatestVersion,_0x2fdc28);let _0x3c916c=_0x31ee11;if(!_0xa036f9[_0x3fb34c(0x1ae)]){console[_0x3fb34c(0x203)]('\x0aCould\x20not\x20check\x20latest\x20version:\x20'+_0xa036f9[_0x3fb34c(0x1ba)]),console[_0x3fb34c(0x1d3)](_0x3fb34c(0x1d1));const _0x376f7c=await runInstall(_0x31ee11);if(_0x376f7c)console[_0x3fb34c(0x1d3)](_0x42a882['uEcqV']),_0x3c916c=_0x42a882[_0x3fb34c(0x1eb)](getCurrentVersion),await installMatchingChromium();else throw new Error('Update\x20failed:\x20'+_0xa036f9['error']);}else{const _0x723534=_0xa036f9[_0x3fb34c(0x1ae)];console[_0x3fb34c(0x1d3)](_0x3fb34c(0x1e8)+_0x723534);const _0x419423=_0x42a882['ZnnAX'](compareVersions,_0x31ee11,_0x723534);if(_0x419423===0x0)console[_0x3fb34c(0x1d3)](_0x42a882[_0x3fb34c(0x215)]);else{if(_0x42a882['cZQwE'](_0x419423,0x0))console['log']('\x0aYour\x20version\x20('+_0x31ee11+_0x3fb34c(0x1bd)+_0x723534+').');else{const _0x45fae5=await runInstall(_0x31ee11);if(_0x45fae5)console[_0x3fb34c(0x1d3)](_0x3fb34c(0x1ef)+_0x723534),_0x3c916c=_0x723534,await _0x42a882[_0x3fb34c(0x1c1)](installMatchingChromium);else throw new Error('Update\x20failed.');}}}await reinstallSkills(_0x3c916c);const _0x263914=await isMarketplaceAdded(_0x42a882[_0x3fb34c(0x1e9)]),_0x38f352=await _0x42a882[_0x3fb34c(0x1a9)](isPluginInstalled,_0x42a882[_0x3fb34c(0x1db)]);_0x263914&&(await _0x42a882['NQcAc'](updateClaudeMarketplace),console[_0x3fb34c(0x1d3)](_0x3fb34c(0x1d7)));if(_0x38f352){const _0x35c3dd=await getPluginInfo(_0x42a882['gqImO']),_0x463e0f=_0x35c3dd?.[_0x3fb34c(0x1e1)]??_0x3fb34c(0x1be);await updateClaudePlugin(_0x463e0f);if(_0x42a882[_0x3fb34c(0x1d0)](_0x463e0f,_0x3fb34c(0x1f6)))console[_0x3fb34c(0x1d3)](_0x42a882['SzjVG']);else _0x463e0f===_0x3fb34c(0x1ce)?console[_0x3fb34c(0x1d3)]('\x0aClaude\x20plugin\x20updated\x20(local\x20scope).'):console['log'](_0x42a882['bzPgb']);}const _0x5ebc00=await ensureActiveProfileGitignored();console['log']('\x0a✅\x20Update\x20complete!');}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x2dd805,_0x308a1d){const _0x3ebc72=_0x48e9,_0x58085d=_0x2dd805();while(!![]){try{const _0x48c121=-parseInt(_0x3ebc72(0x1be))/0x1*(-parseInt(_0x3ebc72(0x1bd))/0x2)+parseInt(_0x3ebc72(0x1b7))/0x3*(parseInt(_0x3ebc72(0x1c3))/0x4)+-parseInt(_0x3ebc72(0x1bc))/0x5*(parseInt(_0x3ebc72(0x1b8))/0x6)+-parseInt(_0x3ebc72(0x1b5))/0x7*(-parseInt(_0x3ebc72(0x1c5))/0x8)+parseInt(_0x3ebc72(0x1c0))/0x9*(-parseInt(_0x3ebc72(0x1ce))/0xa)+-parseInt(_0x3ebc72(0x1b1))/0xb*(parseInt(_0x3ebc72(0x1cf))/0xc)+-parseInt(_0x3ebc72(0x1b3))/0xd*(-parseInt(_0x3ebc72(0x1bf))/0xe);if(_0x48c121===_0x308a1d)break;else _0x58085d['push'](_0x58085d['shift']());}catch(_0x355eda){_0x58085d['push'](_0x58085d['shift']());}}}(_0x3ad3,0x9c2d1));function _0x48e9(_0x22dd56,_0x332762){_0x22dd56=_0x22dd56-0x1b1;const _0x3ad36b=_0x3ad3();let _0x48e991=_0x3ad36b[_0x22dd56];return _0x48e991;}function _0x3ad3(){const _0x44c5c6=['1451170mSbriW','156QrElFh','suWZe','bbEBb','test_output','955768uoaVos','\x20\x20ranger\x20profile\x20add\x20','310791GSxeKC','\x22\x20non-interactively\x20—\x20this\x20profile\x20needs\x20a\x20headed\x20browser\x20to\x20capture\x20a\x20session.\x0a','7XWjeGD','ZIQee','9eFFzqo','311274NMeBCO','setupHeaders','JWCVZ','exit','55JDvKLo','2FOidGx','607570JSlDqN','658shsoGI','45ZmmtXj','YsdYr','status','207708hMWVkE','message','9428120GynpfN','`\x20from\x20a\x20local\x20terminal,\x20or\x20set\x20up\x20automated\x20login\x20for\x20your\x20team\x20(contact\x20eng@ranger.net).','Migrate\x20it\x20to\x20a\x20cloud\x20profile\x20by\x20running:\x0a','log','✓\x20Session\x20refreshed\x20for\x20\x22','error','domains','cwd','environmentKey'];_0x3ad3=function(){return _0x44c5c6;};return _0x3ad3();}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(_0x45c880,_0x1e1ed6,_0xce3d1d){const _0x3b28fb=_0x48e9,_0x492986={'MfIgA':'local','KhGqQ':function(_0x3c6e4a,_0x278dca){return _0x3c6e4a===_0x278dca;},'bbEBb':function(_0x162d7e,_0x1300b1){return _0x162d7e+_0x1300b1;},'suWZe':function(_0x1323a1,_0x5af152){return _0x1323a1+_0x5af152;},'YsdYr':function(_0x582be,_0x175619){return _0x582be+_0x175619;},'BECaD':function(_0x554850,_0x244ba0,_0x59fd7a){return _0x554850(_0x244ba0,_0x59fd7a);},'ZIQee':'success','hjEWb':'\x20\x20Server-side\x20login\x20not\x20configured\x20for\x20this\x20org.\x20Falling\x20back\x20to\x20headed\x20browser...','JWCVZ':'\x20\x20Falling\x20back\x20to\x20headed\x20browser...','wcuRi':function(_0x42e73f,_0x5273f4){return _0x42e73f instanceof _0x5273f4;},'jbhJO':function(_0x5444d1,_0x694b8a){return _0x5444d1(_0x694b8a);},'WVUsD':function(_0x4f9b33,_0x4215a4){return _0x4f9b33+_0x4215a4;},'LRMoS':function(_0x1a4d7d){return _0x1a4d7d();}},_0x57a89f=await fetchCloudProfile(_0x45c880);if(!_0x57a89f){const {envTypes:_0x575ea7}=await getEnvNames(),_0x814dda=_0x575ea7[_0x45c880];(_0x814dda==='legacy'||_0x814dda===_0x492986['MfIgA']||_0x492986['KhGqQ'](_0x814dda,'ci'))&&(console[_0x3b28fb(0x1ca)](_0x492986[_0x3b28fb(0x1d1)](_0x492986[_0x3b28fb(0x1d0)]('Profile\x20\x22'+_0x45c880+'\x22\x20is\x20a\x20legacy\x20on-disk\x20profile\x20and\x20can\x20no\x20longer\x20be\x20refreshed\x20in\x20place.\x0a',_0x3b28fb(0x1c7)),'\x0a')+('\x20\x20ranger\x20profile\x20add\x20'+_0x45c880+'\x0a')),process['exit'](0x1));}!_0x57a89f&&(console[_0x3b28fb(0x1ca)](_0x492986[_0x3b28fb(0x1c1)]('No\x20profile\x20named\x20\x22'+_0x45c880+'\x22\x20found.\x0a'+'Create\x20it\x20with:\x0a','\x0a')+('\x20\x20ranger\x20profile\x20add\x20'+_0x45c880+'\x0a')),process['exit'](0x1));const _0x144342=await fetchAuthConfig()['catch'](()=>null),_0x47c6b0=_0x57a89f['environmentKey']&&_0x144342?resolveAuthEnvironmentLocally(_0x144342,_0x57a89f[_0x3b28fb(0x1cd)]):null;if(_0x57a89f[_0x3b28fb(0x1cd)]&&_0x47c6b0&&!_0xce3d1d?.['manual']){console[_0x3b28fb(0x1c8)]('Refreshing\x20session\x20for\x20\x22'+_0x45c880+'\x22\x20via\x20server-side\x20login...');try{const _0x27835c=await _0x492986['BECaD'](serverSideLogin,_0x45c880,{'force':!![]});if(_0x492986['KhGqQ'](_0x27835c[_0x3b28fb(0x1c2)],_0x492986[_0x3b28fb(0x1b6)])){console['log']('✓\x20Session\x20refreshed\x20for\x20\x22'+_0x45c880+'\x22.');return;}_0x492986['KhGqQ'](_0x27835c[_0x3b28fb(0x1c2)],'not_configured')?console['log'](_0x492986['hjEWb']):(_0x27835c[_0x3b28fb(0x1d2)]&&(console['log']('\x0a\x20\x20Server-side\x20login\x20failed.\x20Test\x20output:'),console[_0x3b28fb(0x1c8)](_0x27835c[_0x3b28fb(0x1d2)])),console['log'](_0x492986[_0x3b28fb(0x1ba)]));}catch(_0x1d473f){console['log']('\x20\x20Server-side\x20login\x20error:\x20'+(_0x492986['wcuRi'](_0x1d473f,Error)?_0x1d473f[_0x3b28fb(0x1c4)]:_0x492986['jbhJO'](String,_0x1d473f))),console[_0x3b28fb(0x1c8)](_0x492986[_0x3b28fb(0x1ba)]);}}const _0x5a58ae=readProfileOverrides(process[_0x3b28fb(0x1cc)](),_0x45c880),_0x1ea00c=_0x492986['BECaD'](mergeCloudProfileSettings,_0x57a89f['settings']??{},_0x5a58ae??undefined),_0x448a6d=_0x1ea00c[_0x3b28fb(0x1b9)],_0xd603c6=_0x1ea00c['baseUrl'],_0x3441e6=_0x47c6b0?{..._0x47c6b0,'domains':_0xd603c6?[_0xd603c6,..._0x47c6b0[_0x3b28fb(0x1cb)]]:_0x47c6b0[_0x3b28fb(0x1cb)],'setupHeaders':_0x448a6d??_0x47c6b0[_0x3b28fb(0x1b9)]}:_0xd603c6?{'key':_0x57a89f[_0x3b28fb(0x1cd)]??'','domains':[_0xd603c6],'setupHeaders':_0x448a6d}:null;!_0x3441e6&&(console[_0x3b28fb(0x1ca)](_0x492986['WVUsD']('Profile\x20\x22'+_0x45c880+'\x22\x20has\x20no\x20URL\x20on\x20file\x20to\x20refresh\x20against.\x0a'+'Re-create\x20it\x20with:\x0a'+'\x0a',_0x3b28fb(0x1b2)+_0x45c880+'\x20--url\x20<your-app-url>\x0a')),process[_0x3b28fb(0x1bb)](0x1)),!_0x492986['LRMoS'](isInteractive)&&(console['error']('Can\x27t\x20refresh\x20\x22'+_0x45c880+_0x3b28fb(0x1b4)+('Run\x20`ranger\x20profile\x20update\x20'+_0x45c880+_0x3b28fb(0x1c6))),process[_0x3b28fb(0x1bb)](0x1)),console[_0x3b28fb(0x1c8)]('Capturing\x20a\x20fresh\x20session\x20for\x20\x22'+_0x45c880+'\x22\x20via\x20headed\x20browser...'),await manualBrowserLogin(_0x57a89f,_0x3441e6),console[_0x3b28fb(0x1c8)](_0x3b28fb(0x1c9)+_0x45c880+'\x22.');}
|
package/build/commands/useEnv.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function _0x16db(){const _0x2798d0=['224FOUNWI','`ranger\x20profile\x20add\x20','9557315dXWnzM','2104000gmiQzI','1032197ulQBLr','\x0a✓\x20Now\x20using\x20profile\x20\x22','NYKhV','9826332cMjDjg','status','28164MTNtWM','`\x20to\x20create\x20one.','17167576QqNsQO','11889535JpfOri','log','Run\x20`ranger\x20profile\x20ls`\x20to\x20see\x20available\x20profiles,\x20or\x20','YwyxH'];_0x16db=function(){return _0x2798d0;};return _0x16db();}(function(_0x25f1c1,_0x487cfc){const _0xe81538=_0x2ab3,_0x4c7a15=_0x25f1c1();while(!![]){try{const _0x1d3917=-parseInt(_0xe81538(0x13a))/0x1+-parseInt(_0xe81538(0x136))/0x2*(parseInt(_0xe81538(0x12f))/0x3)+-parseInt(_0xe81538(0x139))/0x4+-parseInt(_0xe81538(0x138))/0x5+parseInt(_0xe81538(0x13d))/0x6+parseInt(_0xe81538(0x132))/0x7+parseInt(_0xe81538(0x131))/0x8;if(_0x1d3917===_0x487cfc)break;else _0x4c7a15['push'](_0x4c7a15['shift']());}catch(_0x3de6e9){_0x4c7a15['push'](_0x4c7a15['shift']());}}}(_0x16db,0xeaa22));import{join}from'path';import{existsSync}from'fs';import{getEnvDir}from'./utils/settings.js';function _0x2ab3(_0x386cee,_0xb16751){_0x386cee=_0x386cee-0x12e;const _0x16dbaa=_0x16db();let _0x2ab398=_0x16dbaa[_0x386cee];return _0x2ab398;}import{writeActiveProfileName}from'./utils/activeProfile.js';import{ApiError,fetchCloudProfile}from'./utils/cloudProfile.js';export async function useEnv(_0x1790c7){const _0xea4e31=_0x2ab3,_0x99a50b={'FMHVw':'settings.json','YwyxH':function(_0x16356b,_0x5ccdfb){return _0x16356b+_0x5ccdfb;},'NYKhV':function(_0x47e770,_0x481c79){return _0x47e770(_0x481c79);}},_0xe417a=getEnvDir(_0x1790c7),_0x1d2e3=join(_0xe417a,_0x99a50b['FMHVw']),_0x5ba718=existsSync(_0xe417a)&&existsSync(_0x1d2e3);if(_0x5ba718){await writeActiveProfileName(_0x1790c7),console['log'](_0xea4e31(0x13b)+_0x1790c7+'\x22');return;}let _0x1164aa=null,_0xef5238=![];try{_0x1164aa=await fetchCloudProfile(_0x1790c7);if(!_0x1164aa)_0xef5238=!![];}catch(_0x5d9b1a){_0x5d9b1a instanceof ApiError&&_0x5d9b1a[_0xea4e31(0x12e)]===0x194&&(_0xef5238=!![]);}if(_0xef5238)throw new Error(_0x99a50b[_0xea4e31(0x135)]('Profile\x20\x22'+_0x1790c7+'\x22\x20not\x20found\x20locally\x20or\x20in\x20the\x20cloud.\x20'+_0xea4e31(0x134),_0xea4e31(0x137)+_0x1790c7+_0xea4e31(0x130)));await _0x99a50b[_0xea4e31(0x13c)](writeActiveProfileName,_0x1790c7),console[_0xea4e31(0x133)](_0xea4e31(0x13b)+_0x1790c7+'\x22');}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const _0x41d0f4=_0x4d3d;function _0x122f(){const _0x3775c7=['1052GTynrK','11rARPaK','active-profile.txt','3385iyTCDD','12nmeQoE','11099540rBgSbi','4968VsBpGa','cwd','18rCzYMc','Ywqkl','2852055jIpGyn','511jNeKNL','8oJdilI','82398hsnTma','sBWef','33660159oJLIit','1038159qPJXtK','shosv','trim'];_0x122f=function(){return _0x3775c7;};return _0x122f();}(function(_0x4a5936,_0x4ab7ae){const _0xc910a8=_0x4d3d,_0xf3cf55=_0x4a5936();while(!![]){try{const _0x3060f9=-parseInt(_0xc910a8(0x153))/0x1*(-parseInt(_0xc910a8(0x151))/0x2)+-parseInt(_0xc910a8(0x148))/0x3+parseInt(_0xc910a8(0x14b))/0x4*(parseInt(_0xc910a8(0x14e))/0x5)+-parseInt(_0xc910a8(0x145))/0x6*(parseInt(_0xc910a8(0x143))/0x7)+-parseInt(_0xc910a8(0x144))/0x8*(-parseInt(_0xc910a8(0x142))/0x9)+-parseInt(_0xc910a8(0x150))/0xa*(parseInt(_0xc910a8(0x14c))/0xb)+-parseInt(_0xc910a8(0x14f))/0xc*(-parseInt(_0xc910a8(0x147))/0xd);if(_0x3060f9===_0x4ab7ae)break;else _0xf3cf55['push'](_0xf3cf55['shift']());}catch(_0x391373){_0xf3cf55['push'](_0xf3cf55['shift']());}}}(_0x122f,0xa3ab1));import{existsSync}from'fs';import{readFile}from'fs/promises';import{join}from'path';import{getRangerDir,getRangerHomeDir}from'./rangerRoot.js';function _0x4d3d(_0x404d04,_0x850a3a){_0x404d04=_0x404d04-0x141;const _0x122fe4=_0x122f();let _0x4d3d74=_0x122fe4[_0x404d04];return _0x4d3d74;}import{readLastProfile,writeLastProfile}from'./projectsConfig.js';const LEGACY_ACTIVE_PROFILE_FILE=_0x41d0f4(0x14d),LEGACY_ACTIVE_ENV_FILE='active-env.txt';function readLegacyActiveProfileFile(){const _0x3bdffe=_0x41d0f4,_0x1ae711={'shosv':function(_0x328c7f){return _0x328c7f();},'qtlmI':function(_0x5e1b56){return _0x5e1b56();},'Ywqkl':function(_0x26abe8,_0x44f875,_0x369cc3){return _0x26abe8(_0x44f875,_0x369cc3);}},_0x5d9174=[join(_0x1ae711[_0x3bdffe(0x149)](getRangerDir),LEGACY_ACTIVE_PROFILE_FILE),join(_0x1ae711['qtlmI'](getRangerHomeDir),LEGACY_ACTIVE_PROFILE_FILE),_0x1ae711[_0x3bdffe(0x141)](join,getRangerDir(),LEGACY_ACTIVE_ENV_FILE),join(getRangerHomeDir(),LEGACY_ACTIVE_ENV_FILE)];for(const _0x217e1c of _0x5d9174){if(existsSync(_0x217e1c))return _0x217e1c;}return null;}export async function readActiveProfileName(){const _0x2ad330=_0x41d0f4,_0x3f199f={'sBWef':function(_0x11a967,_0x2b6986,_0x3a9bca){return _0x11a967(_0x2b6986,_0x3a9bca);}},_0x23c401=readLastProfile(process[_0x2ad330(0x152)]());if(_0x23c401)return _0x23c401;const _0x28aeaf=readLegacyActiveProfileFile();if(!_0x28aeaf)return null;try{return(await _0x3f199f[_0x2ad330(0x146)](readFile,_0x28aeaf,'utf-8'))[_0x2ad330(0x14a)]()||null;}catch{return null;}}export async function writeActiveProfileName(_0x5a9c85){const _0x140442=_0x41d0f4,_0xd2efc9={'zMQJZ':function(_0x2ad5a4,_0x535151,_0x2e74d6){return _0x2ad5a4(_0x535151,_0x2e74d6);}};_0xd2efc9['zMQJZ'](writeLastProfile,process[_0x140442(0x152)](),_0x5a9c85);}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
function _0x142a(){const _0x5018d8=['86446OliKyu','push','TEMP','AWS_ACCESS_KEY_ID','392hhqPMN','PATH\x20is\x20empty,\x20so\x20npm\x20and\x20core\x20system\x20tools\x20may\x20be\x20unavailable.','AWS_DEFAULT_REGION','8WTBvoJ','includes','entries','WDvMa','split','map','has','NPM_CONFIG_PREFIX','npm_config_registry','string','PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD','length','kiNBB','%PATH%','RANGER_TEST_SKIP_BROWSER_WAIT','2844YGvFbU','platform','XDG_CACHE_HOME','11249NjugON','AWS_ROLE_SESSION_NAME','xLuOl','656547EUblFc','3845750zqZDcP','true','env','npm_config_userconfig','ranger-claude-tmp','RrBkQ','sessionToken','5636943SQboNL','APPDATA','byokEnabled','win32','metadata','filter','USERPROFILE','HWbPS','npm_config_prefix','AWS_PROFILE','npm_config_cache','AWS_SESSION_TOKEN','indexOf','CHROME_BIN','TMPDIR','PATH','TTmeh','/usr/bin','1199728FfmoHE','toLowerCase','OGFWF','AWS_CONFIG_FILE','Your\x20PATH\x20looks\x20incomplete\x20for\x20browser\x20automation.\x20Ranger\x20will\x20keep\x20going,\x20but\x20browser\x20setup\x20may\x20fail.','TMP','AWS_ROLE_ARN','NOVA_ACT_API_KEY','AWS_SDK_LOAD_CONFIG','fromEntries','LOCALAPPDATA','RANGER_TRANSPORT','5375hZMrrc'];_0x142a=function(){return _0x5018d8;};return _0x142a();}function _0x3ea8(_0x3f0d88,_0x3f458b){_0x3f0d88=_0x3f0d88-0x13a;const _0x142a08=_0x142a();let _0x3ea812=_0x142a08[_0x3f0d88];return _0x3ea812;}const _0x1dda9f=_0x3ea8;(function(_0x255479,_0x2f6e0b){const _0x1bcbdf=_0x3ea8,_0x33f35b=_0x255479();while(!![]){try{const _0x68afc=parseInt(_0x1bcbdf(0x17c))/0x1+parseInt(_0x1bcbdf(0x16f))/0x2+-parseInt(_0x1bcbdf(0x155))/0x3*(parseInt(_0x1bcbdf(0x140))/0x4)+-parseInt(_0x1bcbdf(0x17b))/0x5*(-parseInt(_0x1bcbdf(0x14f))/0x6)+-parseInt(_0x1bcbdf(0x152))/0x7*(parseInt(_0x1bcbdf(0x13d))/0x8)+-parseInt(_0x1bcbdf(0x15d))/0x9+parseInt(_0x1bcbdf(0x156))/0xa;if(_0x68afc===_0x2f6e0b)break;else _0x33f35b['push'](_0x33f35b['shift']());}catch(_0x1fbd3e){_0x33f35b['push'](_0x33f35b['shift']());}}}(_0x142a,0x6ada3));import{delimiter,join}from'path';import{tmpdir}from'os';import{mkdirSync}from'fs';import{getAiProxyUrl}from'./environment.js';const AI_PROXY_METADATA_HEADERS_ENV_VAR='ANTHROPIC_CUSTOM_HEADERS',AGENT_ENV_PASSTHROUGH_KEYS=[_0x1dda9f(0x16c),'HOME','TMPDIR',_0x1dda9f(0x174),'TEMP',_0x1dda9f(0x163),_0x1dda9f(0x15e),_0x1dda9f(0x179),_0x1dda9f(0x151),'XDG_CONFIG_HOME','PLAYWRIGHT_BROWSERS_PATH',_0x1dda9f(0x14a),_0x1dda9f(0x16a),'CHROMIUM_BIN',_0x1dda9f(0x167),'NPM_CONFIG_CACHE',_0x1dda9f(0x159),'NPM_CONFIG_USERCONFIG',_0x1dda9f(0x165),_0x1dda9f(0x147),_0x1dda9f(0x148),'NPM_CONFIG_REGISTRY','DEBUG','NODE_ENV',_0x1dda9f(0x14e),_0x1dda9f(0x17a),'RANGERWRIGHT_DAEMON_START_TIMEOUT_MS','RANGERWRIGHT_CLICK_TIMEOUT_MS','RANGERWRIGHT_FORCE_CLICK_TIMEOUT_MS',_0x1dda9f(0x176),_0x1dda9f(0x166),'AWS_REGION',_0x1dda9f(0x13f),_0x1dda9f(0x172),'AWS_SHARED_CREDENTIALS_FILE',_0x1dda9f(0x13c),'AWS_SECRET_ACCESS_KEY',_0x1dda9f(0x168),_0x1dda9f(0x177),'AWS_WEB_IDENTITY_TOKEN_FILE',_0x1dda9f(0x175),_0x1dda9f(0x153),AI_PROXY_METADATA_HEADERS_ENV_VAR],UNEXPANDED_PATH_TOKEN_PATTERNS=['${PATH}','$PATH',_0x1dda9f(0x14d)];function parseCustomHeaders(_0x5a159c){const _0x2233f3=_0x1dda9f,_0x465ead={'mjmBH':function(_0x355e87,_0x550401){return _0x355e87===_0x550401;},'FPOxX':function(_0x2a40e8,_0x2369b2){return _0x2a40e8+_0x2369b2;}};if(!_0x5a159c)return[];return _0x5a159c['split'](/\r?\n/)[_0x2233f3(0x145)](_0x3bf480=>_0x3bf480['trim']())[_0x2233f3(0x162)](Boolean)[_0x2233f3(0x145)](_0x4471bc=>{const _0x4b4e1e=_0x2233f3,_0x315ec8=_0x4471bc[_0x4b4e1e(0x169)](':');if(_0x465ead['mjmBH'](_0x315ec8,-0x1))return null;const _0x1ee161=_0x4471bc['slice'](0x0,_0x315ec8)['trim'](),_0x11b4de=_0x4471bc['slice'](_0x465ead['FPOxX'](_0x315ec8,0x1))['trim']();if(!_0x1ee161)return null;return[_0x1ee161,_0x11b4de];})[_0x2233f3(0x162)](_0x15d0c9=>_0x15d0c9!==null);}export function getAgentPathHealthWarning(_0x33aa44,_0x307c70=process[_0x1dda9f(0x150)]){const _0x5d962b=_0x1dda9f,_0x3eac6f={'HWbPS':function(_0x33ae6f,_0x150710){return _0x33ae6f||_0x150710;},'Dgmmw':function(_0x413c2d,_0x5fcd6f){return _0x413c2d===_0x5fcd6f;},'kiNBB':_0x5d962b(0x13e),'OGFWF':_0x5d962b(0x160),'TTmeh':_0x5d962b(0x16e),'QXaVj':'PATH\x20is\x20missing\x20core\x20system\x20directories\x20like\x20`/usr/bin`\x20and\x20`/bin`.'},_0x4107df=[],_0x2c8576=_0x3eac6f[_0x5d962b(0x164)](_0x33aa44,'')[_0x5d962b(0x144)](delimiter)[_0x5d962b(0x162)](Boolean);_0x3eac6f['Dgmmw'](_0x2c8576['length'],0x0)&&_0x4107df[_0x5d962b(0x13a)](_0x3eac6f[_0x5d962b(0x14c)]);UNEXPANDED_PATH_TOKEN_PATTERNS['some'](_0x36f17c=>(_0x33aa44||'')[_0x5d962b(0x141)](_0x36f17c))&&_0x4107df[_0x5d962b(0x13a)]('PATH\x20contains\x20an\x20unexpanded\x20placeholder\x20like\x20`${PATH}`\x20instead\x20of\x20the\x20expanded\x20current\x20PATH.');if(_0x307c70!==_0x3eac6f[_0x5d962b(0x171)]){const _0x4dd20b=_0x2c8576['includes'](_0x3eac6f[_0x5d962b(0x16d)]),_0x1bd327=_0x2c8576[_0x5d962b(0x141)]('/bin');!_0x4dd20b&&!_0x1bd327&&_0x4107df['push'](_0x3eac6f['QXaVj']);}if(_0x4107df[_0x5d962b(0x14b)]===0x0)return null;return{'summary':_0x5d962b(0x173),'issues':_0x4107df};}export function buildAgentEnv(_0x69e00c){const _0x55babf=_0x1dda9f,_0x52f5bb={'MTJUr':function(_0x240e29){return _0x240e29();},'SdkTe':_0x55babf(0x157),'xLuOl':_0x55babf(0x16b),'RrBkQ':function(_0x39ea87,_0x4d1a3f,_0x574abc){return _0x39ea87(_0x4d1a3f,_0x574abc);},'UaRAC':function(_0x47b4b7){return _0x47b4b7();},'qLuLj':function(_0x969632,_0x31c096){return _0x969632(_0x31c096);},'WDvMa':function(_0x3dab05,_0x4b07bf){return _0x3dab05===_0x4b07bf;}};if(_0x69e00c[_0x55babf(0x15f)])return Object[_0x55babf(0x178)](Object[_0x55babf(0x142)](process[_0x55babf(0x158)])['filter'](_0x976d03=>typeof _0x976d03[0x1]===_0x55babf(0x149)));if(!_0x69e00c['sessionToken'])throw new Error('Session\x20token\x20is\x20required\x20when\x20RANGER_BYOK=false');const _0x1b05f6={'ANTHROPIC_API_KEY':_0x69e00c[_0x55babf(0x15c)],'ANTHROPIC_BASE_URL':_0x52f5bb['MTJUr'](getAiProxyUrl),'DISABLE_TELEMETRY':_0x52f5bb['SdkTe']};for(const _0x3c34ef of AGENT_ENV_PASSTHROUGH_KEYS){const _0xca9439=process['env'][_0x3c34ef];_0xca9439&&![_0x52f5bb[_0x55babf(0x154)],'TMP',_0x55babf(0x13b)]['includes'](_0x3c34ef)&&(_0x1b05f6[_0x3c34ef]=_0xca9439);}const _0x1fa890=_0x52f5bb[_0x55babf(0x15b)](join,_0x52f5bb['UaRAC'](tmpdir),_0x55babf(0x15a));try{mkdirSync(_0x1fa890,{'recursive':!![]});}catch{}_0x1b05f6[_0x52f5bb[_0x55babf(0x154)]]=_0x1fa890,_0x1b05f6[_0x55babf(0x174)]=_0x1fa890,_0x1b05f6['TEMP']=_0x1fa890;const _0x173282=_0x52f5bb['qLuLj'](parseCustomHeaders,process[_0x55babf(0x158)][AI_PROXY_METADATA_HEADERS_ENV_VAR]),_0x144135=new Map(_0x173282),_0x4fbe6a=new Set(_0x173282[_0x55babf(0x145)](([_0x421fd2])=>_0x421fd2[_0x55babf(0x170)]()));if(_0x69e00c[_0x55babf(0x161)])for(const [_0x35fe1a,_0x5ed270]of Object['entries'](_0x69e00c[_0x55babf(0x161)])){if(_0x5ed270==null||_0x52f5bb[_0x55babf(0x143)](_0x5ed270,''))continue;const _0x36a179='x-ranger-'+_0x35fe1a;!_0x4fbe6a[_0x55babf(0x146)](_0x36a179[_0x55babf(0x170)]())&&(_0x144135['set'](_0x36a179,_0x5ed270),_0x4fbe6a['add'](_0x36a179['toLowerCase']()));}const _0x57f53f=Array['from'](_0x144135['entries']())['map'](([_0x5077d8,_0x4f0e0b])=>_0x5077d8+':\x20'+_0x4f0e0b)['join']('\x0a');return _0x57f53f&&(_0x1b05f6[AI_PROXY_METADATA_HEADERS_ENV_VAR]=_0x57f53f),_0x1b05f6;}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(_0x589088,_0x5375ac){const _0x4ac35f=_0x20bd,_0x2837e1=_0x589088();while(!![]){try{const _0x109f2e=-parseInt(_0x4ac35f(0x1aa))/0x1*(parseInt(_0x4ac35f(0x16c))/0x2)+-parseInt(_0x4ac35f(0x192))/0x3+parseInt(_0x4ac35f(0x18c))/0x4*(parseInt(_0x4ac35f(0x1a9))/0x5)+parseInt(_0x4ac35f(0x14b))/0x6*(-parseInt(_0x4ac35f(0x168))/0x7)+-parseInt(_0x4ac35f(0x186))/0x8*(parseInt(_0x4ac35f(0x18a))/0x9)+-parseInt(_0x4ac35f(0x157))/0xa*(parseInt(_0x4ac35f(0x176))/0xb)+parseInt(_0x4ac35f(0x1a2))/0xc*(parseInt(_0x4ac35f(0x187))/0xd);if(_0x109f2e===_0x5375ac)break;else _0x2837e1['push'](_0x2837e1['shift']());}catch(_0x5819be){_0x2837e1['push'](_0x2837e1['shift']());}}}(_0x5d01,0x587d1));const _0x164efb=(function(){const _0x3a2881=_0x20bd,_0x160552={'XYRkI':_0x3a2881(0x1ba),'GsVNV':function(_0x4dffae,_0x14be82){return _0x4dffae!==_0x14be82;},'RrjiZ':'sEkiE','rwEzF':'base64','PqPiX':function(_0xd19dce,_0x766fff){return _0xd19dce===_0x766fff;},'Gkttn':'tiElS','Mjcxg':_0x3a2881(0x177)};let _0x4dc85b=!![];return function(_0x44dba3,_0x290183){const _0x30bc85=_0x3a2881,_0x3794d8={'gtGAe':function(_0x5b429c,_0x560d2f){return _0x5b429c(_0x560d2f);},'SAybq':_0x160552[_0x30bc85(0x160)]};if(_0x160552[_0x30bc85(0x170)](_0x160552[_0x30bc85(0x1b8)],_0x160552[_0x30bc85(0x161)]))throw new _0x468fb7(_0x160552[_0x30bc85(0x18d)]);else{const _0x2bec8d=_0x4dc85b?function(){const _0x3b3537=_0x30bc85;if(_0x290183){if(_0x160552[_0x3b3537(0x188)](_0x160552[_0x3b3537(0x14e)],_0x160552[_0x3b3537(0x14e)]))return _0x3794d8[_0x3b3537(0x16b)](_0x314c24,_0x3b3537(0x1af))[_0x3b3537(0x12a)](_0x2e9a86)[_0x3b3537(0x15a)](_0x3794d8[_0x3b3537(0x199)]);else{const _0x2ac4dc=_0x290183['apply'](_0x44dba3,arguments);return _0x290183=null,_0x2ac4dc;}}}:function(){};return _0x4dc85b=![],_0x2bec8d;}};}()),_0x8277e0=_0x164efb(this,function(){const _0x755f76=_0x20bd,_0x501b6e={'GTCEu':_0x755f76(0x12f)};return _0x8277e0[_0x755f76(0x153)]()[_0x755f76(0x19e)](_0x501b6e['GTCEu'])[_0x755f76(0x153)]()[_0x755f76(0x18f)](_0x8277e0)[_0x755f76(0x19e)](_0x501b6e['GTCEu']);});_0x8277e0();import{getToken}from'./keychain.js';import{getApiBaseUrl}from'./environment.js';function _0x20bd(_0x2dc302,_0x56e417){_0x2dc302=_0x2dc302-0x12a;const _0x531565=_0x5d01();let _0x8277e0=_0x531565[_0x2dc302];if(_0x20bd['lPMrqy']===undefined){var _0x164efb=function(_0x4b266){const _0x22d48f='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';let _0x8f4865='',_0x158981='',_0x55e2f9=_0x8f4865+_0x164efb;for(let _0x56ec01=0x0,_0x3d4611,_0x2b216a,_0x475173=0x0;_0x2b216a=_0x4b266['charAt'](_0x475173++);~_0x2b216a&&(_0x3d4611=_0x56ec01%0x4?_0x3d4611*0x40+_0x2b216a:_0x2b216a,_0x56ec01++%0x4)?_0x8f4865+=_0x55e2f9['charCodeAt'](_0x475173+0xa)-0xa!==0x0?String['fromCharCode'](0xff&_0x3d4611>>(-0x2*_0x56ec01&0x6)):_0x56ec01:0x0){_0x2b216a=_0x22d48f['indexOf'](_0x2b216a);}for(let _0x43dda7=0x0,_0x233b1c=_0x8f4865['length'];_0x43dda7<_0x233b1c;_0x43dda7++){_0x158981+='%'+('00'+_0x8f4865['charCodeAt'](_0x43dda7)['toString'](0x10))['slice'](-0x2);}return decodeURIComponent(_0x158981);};_0x20bd['dEFpEj']=_0x164efb,_0x20bd['VRSmyk']={},_0x20bd['lPMrqy']=!![];}const _0x5d0105=_0x531565[0x0],_0x20bde3=_0x2dc302+_0x5d0105,_0x50ac1f=_0x20bd['VRSmyk'][_0x20bde3];if(!_0x50ac1f){const _0x5dc98b=function(_0x2b891e){this['aNqxio']=_0x2b891e,this['GmephQ']=[0x1,0x0,0x0],this['PerGdQ']=function(){return'newState';},this['tTtiGK']='\x5cw+\x20*\x5c(\x5c)\x20*{\x5cw+\x20*',this['ArRqQu']='[\x27|\x22].+[\x27|\x22];?\x20*}';};_0x5dc98b['prototype']['IrKkxg']=function(){const _0x18f981=new RegExp(this['tTtiGK']+this['ArRqQu']),_0x229a86=_0x18f981['test'](this['PerGdQ']['toString']())?--this['GmephQ'][0x1]:--this['GmephQ'][0x0];return this['IsaPID'](_0x229a86);},_0x5dc98b['prototype']['IsaPID']=function(_0x1db5fb){if(!Boolean(~_0x1db5fb))return _0x1db5fb;return this['wHuBgI'](this['aNqxio']);},_0x5dc98b['prototype']['wHuBgI']=function(_0x368b6f){for(let _0x3625c4=0x0,_0x362fd8=this['GmephQ']['length'];_0x3625c4<_0x362fd8;_0x3625c4++){this['GmephQ']['push'](Math['round'](Math['random']())),_0x362fd8=this['GmephQ']['length'];}return _0x368b6f(this['GmephQ'][0x0]);},new _0x5dc98b(_0x20bd)['IrKkxg'](),_0x8277e0=_0x20bd['dEFpEj'](_0x8277e0),_0x20bd['VRSmyk'][_0x20bde3]=_0x8277e0;}else _0x8277e0=_0x50ac1f;return _0x8277e0;}import{createHash}from'crypto';import{withRetry}from'./retry.js';export async function createBrowserSession(_0x25c3bf){const _0x279eac=_0x20bd,_0x248f06={'vKMiA':function(_0x1b9add,_0x215794){return _0x1b9add(_0x215794);},'rxpBN':function(_0x2218dd){return _0x2218dd();},'JSoeA':function(_0x5dab48,_0xf47ac4,_0x6e52d7){return _0x5dab48(_0xf47ac4,_0x6e52d7);},'YFVMZ':function(_0xca381c,_0x2c3612){return _0xca381c!==_0x2c3612;},'psLdW':_0x279eac(0x174)},_0x462748=await _0x248f06[_0x279eac(0x1a0)](getToken);if(!_0x462748)throw new Error(_0x279eac(0x1ba));const _0x143810=_0x248f06[_0x279eac(0x1a0)](getApiBaseUrl),_0x3c71c7=await _0x248f06[_0x279eac(0x1b4)](fetch,_0x143810+_0x279eac(0x196),{'method':_0x279eac(0x154),'headers':{'Authorization':_0x279eac(0x15b)+_0x462748,'Content-Type':_0x279eac(0x15e)},'body':JSON[_0x279eac(0x1b7)]({'environmentName':_0x25c3bf?.[_0x279eac(0x132)],'settings':_0x25c3bf?.[_0x279eac(0x17b)],'task':_0x25c3bf?.['task'],'url':_0x25c3bf?.['url'],'featureId':_0x25c3bf?.['featureId'],'checklistItemId':_0x25c3bf?.[_0x279eac(0x197)]})});if(!_0x3c71c7['ok']){if(_0x248f06['YFVMZ'](_0x279eac(0x19a),_0x248f06['psLdW'])){const _0x350629=await _0x3c71c7['text']();throw new Error(_0x279eac(0x182)+_0x350629);}else{const _0x597bd7=_0x248f06[_0x279eac(0x156)](_0x40652f,_0x5a84d2);return _0x279eac(0x183)+_0x597bd7;}}return _0x3c71c7[_0x279eac(0x19f)]();}export async function updateBrowserSession(_0x5669ff,_0x276c75){const _0x5a9342=_0x20bd,_0x394dab={'MHPJe':_0x5a9342(0x1ba),'gRRXL':function(_0x32daa4,_0x50376b,_0x3b4020,_0x431d09){return _0x32daa4(_0x50376b,_0x3b4020,_0x431d09);},'bGZkj':function(_0x5ddab8,_0x38c4c9){return _0x5ddab8===_0x38c4c9;},'CueMx':'mEhTT','cEYSJ':_0x5a9342(0x180),'lwuIN':function(_0x52b8da){return _0x52b8da();},'ZUUgW':function(_0x5dae2a,_0x39d4fc){return _0x5dae2a!==_0x39d4fc;},'XTfHM':'YDmAL','Gysfd':function(_0x5d808c){return _0x5d808c();},'eBUpp':function(_0x40503b,_0x5f3d7c,_0x98bff0){return _0x40503b(_0x5f3d7c,_0x98bff0);},'RSfSw':'application/json','thgHn':_0x5a9342(0x159)};return _0x394dab[_0x5a9342(0x17f)](withRetry,async()=>{const _0x46786a=_0x5a9342,_0xece595={'GynYH':function(_0x131523,_0x559354,_0x35ee2e,_0x3399b7){const _0x472026=_0x20bd;return _0x394dab[_0x472026(0x12c)](_0x131523,_0x559354,_0x35ee2e,_0x3399b7);},'CDraE':_0x46786a(0x19c),'FsshS':_0x394dab[_0x46786a(0x13b)]};if(_0x394dab[_0x46786a(0x133)](_0x394dab[_0x46786a(0x1ae)],_0x394dab[_0x46786a(0x1a8)]))return _0xece595['GynYH'](_0x536cfa,_0x21b08b,_0x520827,_0xece595[_0x46786a(0x131)]);else{const _0x3e8ead=await _0x394dab[_0x46786a(0x13e)](getToken);if(!_0x3e8ead){if(_0x394dab[_0x46786a(0x12b)](_0x394dab[_0x46786a(0x172)],_0x394dab['XTfHM']))throw new _0x19ce1c(_0x394dab[_0x46786a(0x13b)]);else throw new Error(_0x394dab[_0x46786a(0x13b)]);}const _0x413ae1=_0x394dab[_0x46786a(0x1a7)](getApiBaseUrl),_0x534751=await _0x394dab[_0x46786a(0x17f)](fetch,_0x413ae1+'/api/v1/mcp/browser-sessions/'+_0x5669ff,{'method':_0x46786a(0x169),'headers':{'Authorization':_0x46786a(0x15b)+_0x3e8ead,'Content-Type':_0x394dab[_0x46786a(0x1a5)]},'body':JSON['stringify'](_0x276c75)});if(!_0x534751['ok']){if(_0x394dab['bGZkj'](_0x394dab[_0x46786a(0x14d)],'kDxsD'))throw new _0x424abe(_0xece595['FsshS']);else{const _0x16d78b=await _0x534751[_0x46786a(0x135)]();throw new Error(_0x46786a(0x191)+_0x16d78b);}}return _0x534751['json']();}},{'label':_0x5a9342(0x193)});}function _0x5d01(){const _0x1497ad=['BgvUz3rO','DgHNsg4','uNjQAvO','B1jLCeO','yxbWBgLJyxrPB24VEMLW','Bw11q2u','AKDAC1i','Dg9tDhjPBMC','ue9tva','l2fWAs92ms9Ty3aVyNjVD3nLCI1ZzxnZAw9UCY8','DKTnAue','mJG3mZu3meHMBK1esa','rMfPBgvKihrVignYzwf0zsbZDgvWigfZC2v0oIa','zMrMCNC','zgLNzxn0','qMvHCMvYia','qxLLtLG','wuL5t00','yxbWBgLJyxrPB24VANnVBG','wMXnr1O','CNDfEKy','twPJEgC','uK9dq2u','y09dqM0','l3n0zxbZ','D0PdAMK','Bwv0ywrHDge','l3n0zxbZlW','mJGXntmYm0Hssg53rW','uefuq0G','vgD1thi','z3rhqwu','mLHzs0XMyq','B1ngvxy','ALzbz2u','t0DMChC','uhfqAvG','Aw1Hz2uVCg5N','wfrMse0','CePfBeS','zuzKufK','uhndwg0','mtfwt25qv3O','rxnsy3e','EgrPC1q','B1Poqvu','zvvztLC','C2v0DgLUz3m','rMfPBgvKihrVigDLDcbWCM94EsbZzxnZAw9UihrVA2vUoIa','EKvVAg4','Ae1Utfa','zujvCha','s1vIwfu','yKPArMS','rMfPBgvKihrVignYzwf0zsbICM93C2vYihnLC3nPB246ia','Ahr0Chm6lY90CMfJzs5WBgf5D3jPz2H0lMrLDI8/DhjHy2u9','C2vZC2LVBLrVA2vU','rMfPBgvKihrVihvWzgf0zsb2zxjPzMLJyxrPB24GC3rLCdOG','oeHYAfr1rG','mtnyquziCxK','r3nwtLy','qLfJt0K','ntC1ote5oxntEMfysa','z2Tpu0e','ng1ougzktq','wfLsA0K','ruj1DMi','y29UC3rYDwn0B3i','s0nLqu0','rMfPBgvKihrVihvWzgf0zsbICM93C2vYihnLC3nPB246ia','ndC5nZmWy0nwzMni','DxbKyxrLqNjVD3nLCLnLC3nPB24','ru54shu','r0vu','l2fWAs92ms9Ty3aVyNjVD3nLCI1ZzxnZAw9UCW','y2HLy2TSAxn0sxrLBuLK','seDdAeq','u0f5yNe','DgvyseS','vKnzC3i','DMLKzw8VD2vIBq','AvrdvMC','C2vHCMnO','ANnVBG','CNHWqK4','ufvu','mJG4mZi4ndr3t2jfCLK','uMreBNy','rMfPBgvKihrVignYzwf0zsb2zxjPzMLJyxrPB24GC3rLCdOG','uLnMu3C','q0HsBK8','r3LZzMq','y0vzu0O','mZqYmZv1q1bTu0G','ntu3nZy4ANDitNP3','ruzTvxm','zMP2s1m','rgnMBwC','q3vLtxG','Bwq1','v09MqNu','CMvXBee','rMfPBgvKihrVigDLDcb1CgXVywqGvvjmCZOG','y2HLy2TZDw0','sLnVzue','yMHluM8','t0XrsMS','C3rYAw5NAwz5','r2T0Dg4','t1vvEee','tM8GqvbjihrVA2vUignVBMzPz3vYzwqUifj1BJOGCMfUz2vYihnLDhvWifT0B2TLBL0','DxbKyxrL','wLvvz1C','z1jsweW','C2L6zq','quD4CxG','kcGOlISPkYKRksSK','yxbWBhK','q0rYyuu','zw52AxjVBM1LBNroyw1L','yKDAA2O','A21czw0','Dgv4Da','yxbWBgLJyxrPB24VANnVBMW','q0Tvy2u','DeDZzwy','CM5RC28','yMfZzty0','tuHqsMu','rMfPBgvKihrVigDLDcbICM93C2vYihnLC3nPB246ia','BLL4vMy','BhD1su4','DMP0DLO','veLRruC','rMfPBgvKihrVihvWBg9HzcbMAwXLoIa','rw90vue','l2fZC2v0CW','uwj0Aum','t1HpA2y','l3vWBg9Hzc11CMXZ','s3LqwuO','EvnsyuO','v2LSr1a','rMfPBgvKihrVigDLDcbICM93C2vYihnLC3nPB24GC3rLChm6ia','nMjbsgXfvq'];_0x5d01=function(){return _0x1497ad;};return _0x5d01();}export async function getBrowserSession(_0x1eb7d5){const _0x28ffd3=_0x20bd,_0x3d2862={'fjvKS':_0x28ffd3(0x1ba),'wJCji':function(_0xcabfd4){return _0xcabfd4();},'WHwld':function(_0x28ab34,_0xa22d51){return _0x28ab34===_0xa22d51;},'kmBem':_0x28ffd3(0x16f),'AyeNX':function(_0x18f573){return _0x18f573();},'LHiWY':function(_0x55b3c7,_0x35f1e7,_0x5af123){return _0x55b3c7(_0x35f1e7,_0x5af123);}},_0x4a79cb=await _0x3d2862[_0x28ffd3(0x165)](getToken);if(!_0x4a79cb){if(_0x3d2862['WHwld'](_0x3d2862['kmBem'],_0x3d2862[_0x28ffd3(0x134)]))throw new Error(_0x3d2862[_0x28ffd3(0x1ac)]);else throw new _0x4e2cf4(_0x3d2862[_0x28ffd3(0x1ac)]);}const _0x2b0767=_0x3d2862[_0x28ffd3(0x15c)](getApiBaseUrl),_0x5ed81a=await _0x3d2862['LHiWY'](fetch,_0x2b0767+_0x28ffd3(0x155)+_0x1eb7d5,{'method':'GET','headers':{'Authorization':_0x28ffd3(0x15b)+_0x4a79cb}});if(!_0x5ed81a['ok']){const _0x15a8f7=await _0x5ed81a[_0x28ffd3(0x135)]();throw new Error(_0x28ffd3(0x13c)+_0x15a8f7);}return _0x5ed81a[_0x28ffd3(0x19f)]();}export async function getUploadUrls(_0x37695b,_0x3e1291,_0x38454c,_0x411019){const _0x51e24b=_0x20bd,_0x2fc295={'TguLr':_0x51e24b(0x1ba),'OXOkf':_0x51e24b(0x151),'BQcOI':_0x51e24b(0x138),'djEWO':function(_0x1d31ab){return _0x1d31ab();},'xdisT':function(_0x38ab34,_0x5b8bed,_0xf322f8){return _0x38ab34(_0x5b8bed,_0xf322f8);},'WhtPo':_0x51e24b(0x154),'eUYNW':'application/json','nYxVf':function(_0x32a483,_0x10b0d0){return _0x32a483!==_0x10b0d0;}},_0x46589b=await getToken();if(!_0x46589b){if(_0x2fc295[_0x51e24b(0x145)]!==_0x2fc295[_0x51e24b(0x189)])throw new Error(_0x2fc295[_0x51e24b(0x16a)]);else throw new _0x7d8d60(_0x2fc295[_0x51e24b(0x16a)]);}const _0x49ce42=_0x2fc295['djEWO'](getApiBaseUrl),_0x1b7b75=await _0x2fc295[_0x51e24b(0x178)](fetch,_0x49ce42+_0x51e24b(0x155)+_0x37695b+_0x51e24b(0x146),{'method':_0x2fc295['WhtPo'],'headers':{'Authorization':_0x51e24b(0x15b)+_0x46589b,'Content-Type':_0x2fc295[_0x51e24b(0x17a)]},'body':JSON['stringify']({'filename':_0x3e1291,'filetype':_0x38454c,..._0x2fc295[_0x51e24b(0x13d)](_0x411019?.[_0x51e24b(0x12d)],undefined)&&{'size':_0x411019[_0x51e24b(0x12d)]},..._0x411019?.[_0x51e24b(0x1b3)]!==undefined&&{'checksum':_0x411019[_0x51e24b(0x1b3)]},..._0x411019?.[_0x51e24b(0x166)]!==undefined&&{'metadata':_0x411019[_0x51e24b(0x166)]}})});if(!_0x1b7b75['ok']){const _0x142ce1=await _0x1b7b75[_0x51e24b(0x135)]();throw new Error(_0x51e24b(0x1b2)+_0x142ce1);}return _0x1b7b75[_0x51e24b(0x19f)]();}export async function uploadFile(_0x54d304,_0x3542a1,_0x59ae03){const _0x273be9=_0x20bd,_0x2aa73c={'TIkEG':function(_0x5e59b8,_0x166d3a,_0x27c47b){return _0x5e59b8(_0x166d3a,_0x27c47b);},'cOCBm':_0x273be9(0x1a1)},_0x2c080d=await _0x2aa73c[_0x273be9(0x140)](fetch,_0x54d304,{'method':_0x2aa73c[_0x273be9(0x163)],'headers':{'Content-Type':_0x59ae03,'Content-Length':_0x3542a1[_0x273be9(0x14c)][_0x273be9(0x153)]()},'body':_0x3542a1});if(!_0x2c080d['ok']){const _0xcb8279=await _0x2c080d['text']();throw new Error(_0x273be9(0x141)+_0xcb8279);}}export async function uploadTrace(_0x4c5658,_0x1d9874){const _0x41c24b=_0x20bd,_0x31913c={'jVAge':function(_0x2575a2,_0x3e3616,_0x29f0d,_0x15ae63){return _0x2575a2(_0x3e3616,_0x29f0d,_0x15ae63);},'sAUcN':_0x41c24b(0x150)};return _0x31913c[_0x41c24b(0x16e)](uploadFile,_0x4c5658,_0x1d9874,_0x31913c['sAUcN']);}export async function uploadConversation(_0x33dec1,_0x308333){const _0x19d7ee=_0x20bd,_0x8ca2c6={'ySRaJ':_0x19d7ee(0x136)};return uploadFile(_0x33dec1,_0x308333,_0x8ca2c6[_0x19d7ee(0x148)]);}export async function uploadScreenshot(_0x16460f,_0x1b0d0d){const _0x12141d=_0x20bd,_0x3d9f7a={'KyPYJ':function(_0x1c9914,_0x1b5980,_0x590b9d,_0x30b429){return _0x1c9914(_0x1b5980,_0x590b9d,_0x30b429);}};return _0x3d9f7a[_0x12141d(0x147)](uploadFile,_0x16460f,_0x1b0d0d,_0x12141d(0x171));}export async function uploadVideo(_0x5c80a4,_0x4deee3){const _0xc87933=_0x20bd,_0x138217={'DGNdj':function(_0x570638,_0x12ea12,_0x5bf84b,_0x101e0e){return _0x570638(_0x12ea12,_0x5bf84b,_0x101e0e);},'EzOjF':_0xc87933(0x19c)};return _0x138217['DGNdj'](uploadFile,_0x5c80a4,_0x4deee3,_0x138217['EzOjF']);}export function buildTraceViewerUrl(_0x4f3ea1){const _0x310357=encodeURIComponent(_0x4f3ea1);return'https://trace.playwright.dev/?trace='+_0x310357;}export async function getProxySessionToken(){const _0x225044=_0x20bd,_0x48ea5f={'bJZFk':_0x225044(0x1ba),'PsCXm':function(_0x3f52b2){return _0x3f52b2();},'qumyR':function(_0x5de817,_0x4ae800){return _0x5de817===_0x4ae800;},'rnkso':_0x225044(0x152),'EFmUs':function(_0x12e051){return _0x12e051();},'XwqXS':function(_0x2f00a7,_0x5b8382,_0x3acd0c){return _0x2f00a7(_0x5b8382,_0x3acd0c);},'prmAG':'POST','PJpLv':function(_0x130804,_0x2b8f3a){return _0x130804!==_0x2b8f3a;}},_0x2fd7cd=await _0x48ea5f[_0x225044(0x175)](getToken);if(!_0x2fd7cd){if(_0x48ea5f['qumyR'](_0x48ea5f[_0x225044(0x139)],_0x225044(0x18e)))throw new _0x525c4f(_0x48ea5f[_0x225044(0x181)]);else throw new Error(_0x48ea5f['bJZFk']);}const _0x198920=_0x48ea5f[_0x225044(0x1ab)](getApiBaseUrl),_0x29b157=await _0x48ea5f['XwqXS'](fetch,_0x198920+'/api/v1/mcp/proxy-session',{'method':_0x48ea5f['prmAG'],'headers':{'Authorization':_0x225044(0x15b)+_0x2fd7cd}});if(!_0x29b157['ok']){if(_0x48ea5f['PJpLv'](_0x225044(0x1b1),_0x225044(0x194))){const _0x5b3fd2=await _0x29b157[_0x225044(0x135)]();throw new Error(_0x225044(0x17c)+_0x5b3fd2);}else throw new _0x4b3579(_0x48ea5f[_0x225044(0x181)]);}const _0x2d2a31=await _0x29b157[_0x225044(0x19f)]();return _0x2d2a31[_0x225044(0x184)];}export function computeChecksum(_0x28bc9a){const _0x22a131=_0x20bd,_0x4aac39={'zEohn':function(_0x2eb8a3,_0x1a9823){return _0x2eb8a3(_0x1a9823);},'WOfBu':_0x22a131(0x1af),'hhlyv':_0x22a131(0x13a)};return _0x4aac39[_0x22a131(0x17d)](createHash,_0x4aac39[_0x22a131(0x1b0)])['update'](_0x28bc9a)['digest'](_0x4aac39['hhlyv']);}export async function createVerificationStep(_0x26237c,_0x21f9ca){const _0x36b7c8=_0x20bd,_0x322eb9={'bhKRo':_0x36b7c8(0x1ba),'ZJmoO':function(_0x37c0d2){return _0x37c0d2();},'EotUA':function(_0x1c4fff){return _0x1c4fff();},'CHRnO':function(_0xa46cd9,_0x3c1beb,_0xaffe57){return _0xa46cd9(_0x3c1beb,_0xaffe57);},'oZNAU':'POST','Dcfmg':'application/json','CKUce':function(_0x5b653d,_0xe39c31){return _0x5b653d===_0xe39c31;},'hMnLP':_0x36b7c8(0x19d),'WilGP':'HZCPb'},_0x1a9aa9=await _0x322eb9['ZJmoO'](getToken);if(!_0x1a9aa9)throw new Error(_0x36b7c8(0x1ba));const _0x1d01a0=_0x322eb9[_0x36b7c8(0x142)](getApiBaseUrl),_0xbf16f0=await _0x322eb9[_0x36b7c8(0x1a6)](fetch,_0x1d01a0+_0x36b7c8(0x155)+_0x26237c+_0x36b7c8(0x164),{'method':_0x322eb9[_0x36b7c8(0x179)],'headers':{'Authorization':'Bearer\x20'+_0x1a9aa9,'Content-Type':_0x322eb9[_0x36b7c8(0x1ad)]},'body':JSON[_0x36b7c8(0x1b7)](_0x21f9ca)});if(!_0xbf16f0['ok']){if(_0x322eb9[_0x36b7c8(0x137)](_0x322eb9[_0x36b7c8(0x17e)],_0x322eb9[_0x36b7c8(0x149)]))throw new _0x46d4c3(_0x322eb9[_0x36b7c8(0x1b5)]);else{const _0x48234c=await _0xbf16f0['text']();throw new Error(_0x36b7c8(0x1a4)+_0x48234c);}}return _0xbf16f0[_0x36b7c8(0x19f)]();}export async function createStepAsset(_0x673cba,_0x2b9f15,_0x5949e9){const _0x4598f7=_0x20bd,_0x16dc16={'ROCCe':function(_0xd4438c){return _0xd4438c();},'YIyOM':function(_0x41b08a,_0x36d931){return _0x41b08a!==_0x36d931;},'VCYsr':_0x4598f7(0x1a3),'otVnf':_0x4598f7(0x1ba),'ZlMGZ':function(_0x377a2b,_0x5780df,_0x52733d){return _0x377a2b(_0x5780df,_0x52733d);},'oSFUv':_0x4598f7(0x154),'AGxqx':_0x4598f7(0x15e)},_0x1fdf2f=await _0x16dc16[_0x4598f7(0x162)](getToken);if(!_0x1fdf2f){if(_0x16dc16[_0x4598f7(0x15d)](_0x4598f7(0x1a3),_0x16dc16[_0x4598f7(0x19b)])){const _0x5f4806=_0x2569eb[_0x4598f7(0x130)](_0x17c793,arguments);return _0x4ede50=null,_0x5f4806;}else throw new Error(_0x16dc16['otVnf']);}const _0x5da896=_0x16dc16[_0x4598f7(0x162)](getApiBaseUrl),_0x54feaa=await _0x16dc16[_0x4598f7(0x15f)](fetch,_0x5da896+_0x4598f7(0x155)+_0x673cba+_0x4598f7(0x167)+_0x2b9f15+_0x4598f7(0x143),{'method':_0x16dc16[_0x4598f7(0x16d)],'headers':{'Authorization':_0x4598f7(0x15b)+_0x1fdf2f,'Content-Type':_0x16dc16[_0x4598f7(0x12e)]},'body':JSON[_0x4598f7(0x1b7)](_0x5949e9)});if(!_0x54feaa['ok']){const _0x22b08c=await _0x54feaa[_0x4598f7(0x135)]();throw new Error(_0x4598f7(0x158)+_0x22b08c);}return _0x54feaa[_0x4598f7(0x19f)]();}export async function updateVerificationStep(_0x26c208,_0x53ddd4,_0x3c8ba5){const _0x5b3028=_0x20bd,_0x1c901={'gkOSA':function(_0x30abc4){return _0x30abc4();},'vjtvZ':'PATCH','QbtiC':_0x5b3028(0x15e)},_0x8f8dbe=await getToken();if(!_0x8f8dbe)throw new Error(_0x5b3028(0x1ba));const _0x268639=_0x1c901[_0x5b3028(0x18b)](getApiBaseUrl),_0x302e6c=await fetch(_0x268639+_0x5b3028(0x155)+_0x26c208+'/steps/'+_0x53ddd4,{'method':_0x1c901[_0x5b3028(0x13f)],'headers':{'Authorization':'Bearer\x20'+_0x8f8dbe,'Content-Type':_0x1c901[_0x5b3028(0x144)]},'body':JSON[_0x5b3028(0x1b7)](_0x3c8ba5)});if(!_0x302e6c['ok']){const _0x502d35=await _0x302e6c[_0x5b3028(0x135)]();throw new Error(_0x5b3028(0x185)+_0x502d35);}}export async function getBrowserSessionSteps(_0x464623){const _0x26d553=_0x20bd,_0x51a328={'OLQJk':function(_0x3bdf8a,_0x3b5a33,_0x3c8ab3,_0x2c3de5){return _0x3bdf8a(_0x3b5a33,_0x3c8ab3,_0x2c3de5);},'OUUxA':'image/png','HGChD':function(_0x236344){return _0x236344();},'pJElK':'nTyAt','PedBv':_0x26d553(0x190),'oRepJ':_0x26d553(0x195)},_0x294026=await _0x51a328[_0x26d553(0x198)](getToken);if(!_0x294026){if(_0x51a328[_0x26d553(0x173)]===_0x51a328['PedBv'])return _0x51a328[_0x26d553(0x1b6)](_0x13403a,_0x61bad3,_0x5357d2,_0x51a328[_0x26d553(0x1b9)]);else throw new Error(_0x26d553(0x1ba));}const _0x1e784f=getApiBaseUrl(),_0x489bb2=await fetch(_0x1e784f+_0x26d553(0x155)+_0x464623+'/steps',{'method':_0x51a328[_0x26d553(0x14f)],'headers':{'Authorization':'Bearer\x20'+_0x294026}});if(!_0x489bb2['ok']){const _0x4907b4=await _0x489bb2[_0x26d553(0x135)]();throw new Error(_0x26d553(0x14a)+_0x4907b4);}return _0x489bb2['json']();}
|
|
1
|
+
(function(_0x5401cb,_0x19c459){const _0x3d7f87=_0x304e,_0x4167ee=_0x5401cb();while(!![]){try{const _0x2ee300=-parseInt(_0x3d7f87(0x1e0))/0x1*(-parseInt(_0x3d7f87(0x1d1))/0x2)+parseInt(_0x3d7f87(0x1fc))/0x3+-parseInt(_0x3d7f87(0x1ff))/0x4+parseInt(_0x3d7f87(0x1ef))/0x5*(-parseInt(_0x3d7f87(0x205))/0x6)+parseInt(_0x3d7f87(0x1fe))/0x7*(-parseInt(_0x3d7f87(0x1e5))/0x8)+parseInt(_0x3d7f87(0x22e))/0x9*(-parseInt(_0x3d7f87(0x21c))/0xa)+parseInt(_0x3d7f87(0x213))/0xb;if(_0x2ee300===_0x19c459)break;else _0x4167ee['push'](_0x4167ee['shift']());}catch(_0x4111db){_0x4167ee['push'](_0x4167ee['shift']());}}}(_0x441b,0xc742e));const _0x4fb19e=(function(){const _0x330bf4=_0x304e,_0x45dec6={'FmFwu':_0x330bf4(0x218)};let _0x1dd4b2=!![];return function(_0x3bf3ab,_0x2352ce){const _0x842939={'jgwdB':_0x45dec6['FmFwu']},_0x3ea8cf=_0x1dd4b2?function(){const _0x58c602=_0x304e,_0x24c988={'bJOkl':_0x58c602(0x1cb)};if(_0x842939['jgwdB']!==_0x842939['jgwdB'])throw new _0x1aec9e(_0x24c988['bJOkl']);else{if(_0x2352ce){const _0x458ce5=_0x2352ce[_0x58c602(0x1e6)](_0x3bf3ab,arguments);return _0x2352ce=null,_0x458ce5;}}}:function(){};return _0x1dd4b2=![],_0x3ea8cf;};}()),_0xeb445c=_0x4fb19e(this,function(){const _0x35986e=_0x304e,_0xf0b0dc={'ktaXg':_0x35986e(0x1c1)};return _0xeb445c[_0x35986e(0x1c7)]()[_0x35986e(0x1c2)](_0xf0b0dc['ktaXg'])['toString']()[_0x35986e(0x225)](_0xeb445c)[_0x35986e(0x1c2)](_0xf0b0dc[_0x35986e(0x1fb)]);});_0xeb445c();import{getToken}from'./keychain.js';import{getApiBaseUrl}from'./environment.js';import{createHash}from'crypto';import{withRetry}from'./retry.js';export async function createBrowserSession(_0x2b72a9){const _0xf7da13=_0x304e,_0xfba572={'AHxhk':function(_0xb729a){return _0xb729a();},'Zqwet':_0xf7da13(0x1cb),'SEgfs':function(_0x45ca4c,_0x2bd27d,_0x3555de){return _0x45ca4c(_0x2bd27d,_0x3555de);},'rHMoZ':_0xf7da13(0x209),'Bnejl':_0xf7da13(0x1f2),'pUUuq':function(_0x3bb0f4,_0x17fd78){return _0x3bb0f4===_0x17fd78;},'ZdovL':_0xf7da13(0x211)},_0x37a274=await _0xfba572[_0xf7da13(0x1f7)](getToken);if(!_0x37a274)throw new Error(_0xfba572[_0xf7da13(0x1db)]);const _0x270716=_0xfba572[_0xf7da13(0x1f7)](getApiBaseUrl),_0x2a43aa=await _0xfba572['SEgfs'](fetch,_0x270716+_0xf7da13(0x20d),{'method':_0xfba572['rHMoZ'],'headers':{'Authorization':_0xf7da13(0x1b9)+_0x37a274,'Content-Type':_0xfba572[_0xf7da13(0x1e8)]},'body':JSON['stringify']({'environmentName':_0x2b72a9?.['environmentName'],'settings':_0x2b72a9?.[_0xf7da13(0x1bb)],'task':_0x2b72a9?.['task'],'url':_0x2b72a9?.[_0xf7da13(0x1e9)],'featureId':_0x2b72a9?.[_0xf7da13(0x1ee)],'checklistItemId':_0x2b72a9?.['checklistItemId']})});if(!_0x2a43aa['ok']){if(_0xfba572[_0xf7da13(0x1fd)](_0xfba572[_0xf7da13(0x1d7)],'AunYo')){const _0x158727=await _0x2a43aa[_0xf7da13(0x20a)]();throw new Error(_0xf7da13(0x215)+_0x158727);}else return _0xe970ea(_0xf7da13(0x1cd))['update'](_0x1e9feb)[_0xf7da13(0x1dd)]('base64');}return _0x2a43aa[_0xf7da13(0x1d6)]();}export async function updateBrowserSession(_0x3960df,_0x5dd173){const _0x10f099=_0x304e,_0x5b2da5={'LwkiF':_0x10f099(0x1cb),'agNoO':function(_0x42c703){return _0x42c703();},'rWFtL':function(_0x298bef,_0x202342,_0x4e8bd9){return _0x298bef(_0x202342,_0x4e8bd9);},'cNOQp':'PATCH','wUBUH':_0x10f099(0x1f2),'WaYhi':function(_0x3a10b4,_0x1cc959){return _0x3a10b4===_0x1cc959;},'dTkCC':_0x10f099(0x220),'rMyTI':function(_0x41acbf,_0x5169a0,_0x247124){return _0x41acbf(_0x5169a0,_0x247124);},'BSPhj':_0x10f099(0x202)};return _0x5b2da5[_0x10f099(0x1d9)](withRetry,async()=>{const _0x5a8ab3=_0x10f099,_0x35eb68=await getToken();if(!_0x35eb68)throw new Error(_0x5b2da5[_0x5a8ab3(0x224)]);const _0x3f349d=_0x5b2da5['agNoO'](getApiBaseUrl),_0x460e49=await _0x5b2da5[_0x5a8ab3(0x203)](fetch,_0x3f349d+_0x5a8ab3(0x1d5)+_0x3960df,{'method':_0x5b2da5['cNOQp'],'headers':{'Authorization':'Bearer\x20'+_0x35eb68,'Content-Type':_0x5b2da5['wUBUH']},'body':JSON[_0x5a8ab3(0x204)](_0x5dd173)});if(!_0x460e49['ok']){if(_0x5b2da5[_0x5a8ab3(0x1d2)](_0x5b2da5[_0x5a8ab3(0x216)],_0x5b2da5[_0x5a8ab3(0x216)])){const _0x3a44eb=await _0x460e49['text']();throw new Error(_0x5a8ab3(0x1de)+_0x3a44eb);}else{const _0x32aba0=_0x29abfd?function(){if(_0xe12260){const _0x4d2a71=_0x15f633['apply'](_0x57f301,arguments);return _0x50afa0=null,_0x4d2a71;}}:function(){};return _0x1536eb=![],_0x32aba0;}}return _0x460e49[_0x5a8ab3(0x1d6)]();},{'label':_0x5b2da5[_0x10f099(0x1e4)]});}export async function getBrowserSession(_0x410075){const _0x477a91=_0x304e,_0x131104={'SVZwc':function(_0x27738c,_0x286d9d){return _0x27738c!==_0x286d9d;},'fNkrC':_0x477a91(0x21d),'FZgUQ':function(_0x1651f2){return _0x1651f2();},'erhAP':_0x477a91(0x1f6)},_0x3407a8=await getToken();if(!_0x3407a8){if(_0x131104[_0x477a91(0x1e3)](_0x477a91(0x21d),_0x131104[_0x477a91(0x226)]))throw new _0x4727ff(_0x477a91(0x1cb));else throw new Error(_0x477a91(0x1cb));}const _0x29091f=_0x131104[_0x477a91(0x1be)](getApiBaseUrl),_0x2b4139=await fetch(_0x29091f+_0x477a91(0x1d5)+_0x410075,{'method':_0x131104[_0x477a91(0x1c4)],'headers':{'Authorization':'Bearer\x20'+_0x3407a8}});if(!_0x2b4139['ok']){const _0x6d8c17=await _0x2b4139[_0x477a91(0x20a)]();throw new Error(_0x477a91(0x1ec)+_0x6d8c17);}return _0x2b4139[_0x477a91(0x1d6)]();}export async function getUploadUrls(_0x49de8c,_0x18d881,_0x3be92c,_0x4bd26d){const _0x4371d3=_0x304e,_0x1073eb={'tMJpz':_0x4371d3(0x1cb),'qkdUL':function(_0x300d70){return _0x300d70();},'rJxaf':function(_0x276466,_0x5e2ac4,_0x2fc867){return _0x276466(_0x5e2ac4,_0x2fc867);},'yIGKD':_0x4371d3(0x209),'imKdI':function(_0x5ac6a2,_0x1d35b5){return _0x5ac6a2!==_0x1d35b5;},'ocftV':function(_0x112da0,_0x1bd093){return _0x112da0!==_0x1bd093;},'ffeel':_0x4371d3(0x1c9)},_0xa39777=await getToken();if(!_0xa39777)throw new Error(_0x1073eb[_0x4371d3(0x208)]);const _0x31eb2d=_0x1073eb[_0x4371d3(0x214)](getApiBaseUrl),_0x4b3dce=await _0x1073eb['rJxaf'](fetch,_0x31eb2d+'/api/v1/mcp/browser-sessions/'+_0x49de8c+_0x4371d3(0x1ba),{'method':_0x1073eb[_0x4371d3(0x1c0)],'headers':{'Authorization':_0x4371d3(0x1b9)+_0xa39777,'Content-Type':_0x4371d3(0x1f2)},'body':JSON[_0x4371d3(0x204)]({'filename':_0x18d881,'filetype':_0x3be92c,..._0x1073eb[_0x4371d3(0x207)](_0x4bd26d?.['size'],undefined)&&{'size':_0x4bd26d['size']},..._0x4bd26d?.[_0x4371d3(0x206)]!==undefined&&{'checksum':_0x4bd26d[_0x4371d3(0x206)]},..._0x1073eb['imKdI'](_0x4bd26d?.['metadata'],undefined)&&{'metadata':_0x4bd26d[_0x4371d3(0x1f1)]}})});if(!_0x4b3dce['ok']){if(_0x1073eb[_0x4371d3(0x200)]('RPYXw',_0x1073eb[_0x4371d3(0x219)]))throw new _0x3d7dba(_0x1073eb['tMJpz']);else{const _0x4d59ad=await _0x4b3dce[_0x4371d3(0x20a)]();throw new Error(_0x4371d3(0x1f8)+_0x4d59ad);}}return _0x4b3dce[_0x4371d3(0x1d6)]();}export async function uploadFile(_0x315825,_0x2d7ca4,_0x43b63d){const _0x30e468=_0x304e,_0x3cbc0c={'GGpKX':function(_0x2a93ce,_0xa16802,_0x2eb76d){return _0x2a93ce(_0xa16802,_0x2eb76d);}},_0x3e579=await _0x3cbc0c[_0x30e468(0x21a)](fetch,_0x315825,{'method':_0x30e468(0x1c6),'headers':{'Content-Type':_0x43b63d,'Content-Length':_0x2d7ca4[_0x30e468(0x1da)]['toString']()},'body':_0x2d7ca4});if(!_0x3e579['ok']){const _0x2d4d29=await _0x3e579[_0x30e468(0x20a)]();throw new Error(_0x30e468(0x1fa)+_0x2d4d29);}}export async function uploadTrace(_0x1acfb4,_0x5ceefb){const _0xa5cbef=_0x304e,_0x1134a0={'EUWHG':function(_0x46be28,_0x2dd1d9,_0x5da781,_0x61b49e){return _0x46be28(_0x2dd1d9,_0x5da781,_0x61b49e);},'AFniz':_0xa5cbef(0x1ca)};return _0x1134a0[_0xa5cbef(0x1ea)](uploadFile,_0x1acfb4,_0x5ceefb,_0x1134a0['AFniz']);}function _0x304e(_0x8d7e97,_0x2dd407){_0x8d7e97=_0x8d7e97-0x1b8;const _0x4a75f8=_0x441b();let _0xeb445c=_0x4a75f8[_0x8d7e97];if(_0x304e['Jyysyc']===undefined){var _0x4fb19e=function(_0x16b139){const _0x5b93dd='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';let _0x14d134='',_0x4fdacf='',_0x1e5c13=_0x14d134+_0x4fb19e;for(let _0x2fa54c=0x0,_0x1a55b8,_0x5be620,_0xfacb7=0x0;_0x5be620=_0x16b139['charAt'](_0xfacb7++);~_0x5be620&&(_0x1a55b8=_0x2fa54c%0x4?_0x1a55b8*0x40+_0x5be620:_0x5be620,_0x2fa54c++%0x4)?_0x14d134+=_0x1e5c13['charCodeAt'](_0xfacb7+0xa)-0xa!==0x0?String['fromCharCode'](0xff&_0x1a55b8>>(-0x2*_0x2fa54c&0x6)):_0x2fa54c:0x0){_0x5be620=_0x5b93dd['indexOf'](_0x5be620);}for(let _0x514cc6=0x0,_0x57c440=_0x14d134['length'];_0x514cc6<_0x57c440;_0x514cc6++){_0x4fdacf+='%'+('00'+_0x14d134['charCodeAt'](_0x514cc6)['toString'](0x10))['slice'](-0x2);}return decodeURIComponent(_0x4fdacf);};_0x304e['HTfEDf']=_0x4fb19e,_0x304e['kTLMzS']={},_0x304e['Jyysyc']=!![];}const _0x441b28=_0x4a75f8[0x0],_0x304ed3=_0x8d7e97+_0x441b28,_0x380fc4=_0x304e['kTLMzS'][_0x304ed3];if(!_0x380fc4){const _0x29abfd=function(_0x4fb31b){this['NJIjOE']=_0x4fb31b,this['jySotp']=[0x1,0x0,0x0],this['OaNodw']=function(){return'newState';},this['QKAhaL']='\x5cw+\x20*\x5c(\x5c)\x20*{\x5cw+\x20*',this['sGQRAG']='[\x27|\x22].+[\x27|\x22];?\x20*}';};_0x29abfd['prototype']['abJMpX']=function(){const _0x55618b=new RegExp(this['QKAhaL']+this['sGQRAG']),_0x3d38d0=_0x55618b['test'](this['OaNodw']['toString']())?--this['jySotp'][0x1]:--this['jySotp'][0x0];return this['LXbPeA'](_0x3d38d0);},_0x29abfd['prototype']['LXbPeA']=function(_0x9fdfb8){if(!Boolean(~_0x9fdfb8))return _0x9fdfb8;return this['hZVSpM'](this['NJIjOE']);},_0x29abfd['prototype']['hZVSpM']=function(_0x1536eb){for(let _0xe12260=0x0,_0x1997ef=this['jySotp']['length'];_0xe12260<_0x1997ef;_0xe12260++){this['jySotp']['push'](Math['round'](Math['random']())),_0x1997ef=this['jySotp']['length'];}return _0x1536eb(this['jySotp'][0x0]);},new _0x29abfd(_0x304e)['abJMpX'](),_0xeb445c=_0x304e['HTfEDf'](_0xeb445c),_0x304e['kTLMzS'][_0x304ed3]=_0xeb445c;}else _0xeb445c=_0x380fc4;return _0xeb445c;}export async function uploadConversation(_0x1c91f0,_0x4df1dc){const _0x39ed5c=_0x304e,_0x38baa9={'dWbjm':function(_0x47d401,_0xdc8830,_0x54d911,_0x5d9388){return _0x47d401(_0xdc8830,_0x54d911,_0x5d9388);},'nUZJE':'application/jsonl'};return _0x38baa9[_0x39ed5c(0x1f5)](uploadFile,_0x1c91f0,_0x4df1dc,_0x38baa9[_0x39ed5c(0x1d3)]);}function _0x441b(){const _0x4dc296=['zfP1sM8','zfDIAM0','r0vu','quH4AgS','rMfPBgvKihrVigDLDcb1CgXVywqGvvjmCZOG','zMfTv3a','rMfPBgvKihrVihvWBg9HzcbMAwXLoIa','A3rHwgC','mZG4mJK1mvfpr1fOBW','CfvvDxe','mta5nZiYow9nDevrCa','nte4ndaWognuu2rQAG','B2nMDfy','rMfPBgvKihrVignYzwf0zsb2zxjPzMLJyxrPB24GC3rLCdOG','DxbKyxrLqNjVD3nLCLnLC3nPB24','CLDgDeW','C3rYAw5NAwz5','mte5otG1mgfQtuDvrW','y2HLy2TZDw0','Aw1lzeK','De1kChO','ue9tva','Dgv4Da','zeXQwhm','tuDpBgC','l2fWAs92ms9Ty3aVyNjVD3nLCI1ZzxnZAw9UCW','DvDgA0W','thPpsK8','Ahr0Chm6lY90CMfJzs5WBgf5D3jPz2H0lMrLDI8/DhjHy2u9','qxvUww8','rMfPBgvKihrVigDLDcbICM93C2vYihnLC3nPB24GC3rLChm6ia','mJiYotuYotvPD1b1Bw8','CwTKvuW','rMfPBgvKihrVignYzwf0zsbICM93C2vYihnLC3nPB246ia','zfrRq0m','rgDrzgK','ueDAv2i','zMzLzwW','r0DWs1G','zuHhr0m','mtbsELPxt1K','AKjNDxa','zKfUBKO','CNfZAMu','uvfuBu8','C2vZC2LVBLrVA2vU','u0reC1a','DLPMAfe','thDRAuy','y29UC3rYDwn0B3i','zK5RCKm','v1HAu1e','s2LJzNa','wKL6Agu','rMfPBgvKihrVihvWzgf0zsb2zxjPzMLJyxrPB24GC3rLCdOG','C25jyK8','Aw1Hz2uVCg5N','rMfPBgvKihrVignYzwf0zsbZDgvWigfZC2v0oIa','mJa2nteZmvjrEuTxta','tvnjseq','qMvHCMvYia','l3vWBg9Hzc11CMXZ','C2v0DgLUz3m','l3n0zxbZ','l2fZC2v0CW','rLPNvve','wLrny0S','EuLhs0q','kcGOlISPkYKRksSK','C2vHCMnO','vMzdweS','zxjOqva','vLf1Eg4','ufvu','Dg9tDhjPBMC','l3n0zxbZlW','uLbzwhC','yxbWBgLJyxrPB24VEMLW','tM8GqvbjihrVA2vUignVBMzPz3vYzwqUifj1BJOGCMfUz2vYihnLDhvWifT0B2TLBL0','sK91Cvi','Bwq1','r053qu4','l2fWAs92ms9Ty3aVChjVEhKTC2vZC2LVBG','DNjNt0C','mNjhvKPtAq','v2fzAgK','BLvAsKu','DMLKzw8VD2vIBq','l2fWAs92ms9Ty3aVyNjVD3nLCI1ZzxnZAw9UCY8','ANnVBG','wMrVDKW','wvrWAgK','CK15veK','BgvUz3rO','wNf3zxq','sNrdse4','zgLNzxn0','rMfPBgvKihrVihvWzgf0zsbICM93C2vYihnLC3nPB246ia','DgfstvO','mtC3mdK1sunoBMP1','wKDpqu8','t0j1rMi','u1zAD2m','qLnqAgO','og5xyK5Qyq','yxbWBhK','Dfj5quW','qM5LAMW','DxjS','rvvxseC','Cef0BeC','rMfPBgvKihrVigDLDcbICM93C2vYihnLC3nPB246ia','AxPquuG','zMvHDhvYzuLK','mJvrEe1Www8','CLzNAeK','Bwv0ywrHDge','yxbWBgLJyxrPB24VANnVBG','rhP2DuG'];_0x441b=function(){return _0x4dc296;};return _0x441b();}export async function uploadScreenshot(_0x44b0cb,_0x4c517d){const _0x1f0ede=_0x304e,_0x55b772={'ZIzhe':function(_0x176351,_0x41c8d4,_0x171643,_0x33efcd){return _0x176351(_0x41c8d4,_0x171643,_0x33efcd);},'DzvuH':_0x1f0ede(0x22c)};return _0x55b772[_0x1f0ede(0x229)](uploadFile,_0x44b0cb,_0x4c517d,_0x55b772[_0x1f0ede(0x1f3)]);}export async function uploadVideo(_0x299c6b,_0x230ea1){const _0x3f9308=_0x304e,_0x93653b={'WXZSQ':function(_0xe5f18b,_0x58b1c8,_0x3e5b37,_0x3b7c98){return _0xe5f18b(_0x58b1c8,_0x3e5b37,_0x3b7c98);},'Mnour':_0x3f9308(0x1d4)};return _0x93653b[_0x3f9308(0x227)](uploadFile,_0x299c6b,_0x230ea1,_0x93653b['Mnour']);}export function buildTraceViewerUrl(_0xa7fc0d){const _0x464fd5=_0x304e,_0x25eefc=encodeURIComponent(_0xa7fc0d);return _0x464fd5(0x210)+_0x25eefc;}export async function getProxySessionToken(){const _0x220636=_0x304e,_0x4e7245={'VQuxn':function(_0x74cc64){return _0x74cc64();},'FOcYY':_0x220636(0x1cb),'fAnnJ':function(_0x269e81){return _0x269e81();},'DgQdi':function(_0x2da780,_0x213fdd,_0x308ba1){return _0x2da780(_0x213fdd,_0x308ba1);},'izPQH':'POST'},_0x16965e=await _0x4e7245[_0x220636(0x1c5)](getToken);if(!_0x16965e)throw new Error(_0x4e7245['FOcYY']);const _0x31c9bd=_0x4e7245[_0x220636(0x21e)](getApiBaseUrl),_0x3ca596=await _0x4e7245[_0x220636(0x217)](fetch,_0x31c9bd+_0x220636(0x1cf),{'method':_0x4e7245[_0x220636(0x1ed)],'headers':{'Authorization':'Bearer\x20'+_0x16965e}});if(!_0x3ca596['ok']){const _0x5cb6bf=await _0x3ca596[_0x220636(0x20a)]();throw new Error('Failed\x20to\x20get\x20proxy\x20session\x20token:\x20'+_0x5cb6bf);}const _0x1dd276=await _0x3ca596['json']();return _0x1dd276[_0x220636(0x221)];}export function computeChecksum(_0x46fdb5){const _0x37e740=_0x304e,_0x5f3f5a={'MSIHD':_0x37e740(0x1cd),'LPAdh':'base64'};return createHash(_0x5f3f5a[_0x37e740(0x1b8)])['update'](_0x46fdb5)[_0x37e740(0x1dd)](_0x5f3f5a['LPAdh']);}export async function createVerificationStep(_0x2f7530,_0xc6accd){const _0x1deff1=_0x304e,_0x4da750={'famWp':_0x1deff1(0x1cb),'snIbO':function(_0x2d0815,_0x1a87a1,_0x5408db){return _0x2d0815(_0x1a87a1,_0x5408db);},'VfCXK':'POST','SDDsP':_0x1deff1(0x1f2)},_0x35ae09=await getToken();if(!_0x35ae09){if('uCpLr'!=='uCpLr')throw new _0x12f317(_0x4da750[_0x1deff1(0x1f9)]);else throw new Error(_0x4da750['famWp']);}const _0x2e491f=getApiBaseUrl(),_0x477143=await _0x4da750[_0x1deff1(0x22b)](fetch,_0x2e491f+_0x1deff1(0x1d5)+_0x2f7530+_0x1deff1(0x1bc),{'method':_0x4da750[_0x1deff1(0x1c3)],'headers':{'Authorization':_0x1deff1(0x1b9)+_0x35ae09,'Content-Type':_0x4da750[_0x1deff1(0x222)]},'body':JSON[_0x1deff1(0x204)](_0xc6accd)});if(!_0x477143['ok']){const _0x35d170=await _0x477143[_0x1deff1(0x20a)]();throw new Error(_0x1deff1(0x201)+_0x35d170);}return _0x477143[_0x1deff1(0x1d6)]();}export async function createStepAsset(_0x1d50c,_0x4e2813,_0x544a79){const _0x251adf=_0x304e,_0x3b40e0={'taRMZ':_0x251adf(0x1cb),'dLjXs':function(_0x1ad8bc){return _0x1ad8bc();},'LzOJO':_0x251adf(0x1d0),'OBuFb':function(_0x49ecb6,_0x4b57b2,_0x1559b7){return _0x49ecb6(_0x4b57b2,_0x1559b7);},'ZTMcK':'POST','JOuqR':_0x251adf(0x1f2),'YTphi':function(_0x4bbff3,_0x288067){return _0x4bbff3===_0x288067;},'xGOYd':_0x251adf(0x1eb),'dZuJo':_0x251adf(0x1e1)},_0xf859b8=await _0x3b40e0[_0x251adf(0x20b)](getToken);if(!_0xf859b8){if(_0x3b40e0['LzOJO']!==_0x3b40e0[_0x251adf(0x20f)])throw new _0x35127a(_0x3b40e0[_0x251adf(0x1df)]);else throw new Error(_0x3b40e0[_0x251adf(0x1df)]);}const _0x374f9a=_0x3b40e0[_0x251adf(0x20b)](getApiBaseUrl),_0x2c48cf=await _0x3b40e0[_0x251adf(0x1e2)](fetch,_0x374f9a+_0x251adf(0x1d5)+_0x1d50c+_0x251adf(0x1c8)+_0x4e2813+_0x251adf(0x1bd),{'method':_0x3b40e0[_0x251adf(0x1bf)],'headers':{'Authorization':_0x251adf(0x1b9)+_0xf859b8,'Content-Type':_0x3b40e0[_0x251adf(0x1cc)]},'body':JSON[_0x251adf(0x204)](_0x544a79)});if(!_0x2c48cf['ok']){if(_0x3b40e0[_0x251adf(0x1d8)](_0x3b40e0['xGOYd'],_0x3b40e0[_0x251adf(0x1f4)])){if(_0x5e1a2e){const _0x1f9fbe=_0xd9c124['apply'](_0x5e644c,arguments);return _0x1269f4=null,_0x1f9fbe;}}else{const _0xcc073c=await _0x2c48cf[_0x251adf(0x20a)]();throw new Error(_0x251adf(0x22d)+_0xcc073c);}}return _0x2c48cf[_0x251adf(0x1d6)]();}export async function updateVerificationStep(_0x407604,_0x50871a,_0x256c7d){const _0x1a0224=_0x304e,_0x373a33={'tRyAL':_0x1a0224(0x1c1),'uWFkL':function(_0x27b865){return _0x27b865();},'Kicfp':_0x1a0224(0x1cb),'eHGGC':function(_0x3f9f0c,_0x14a18d,_0x19e69a){return _0x3f9f0c(_0x14a18d,_0x19e69a);},'xDLoW':_0x1a0224(0x1f2),'vZfhQ':function(_0xa5e157,_0x3648b1){return _0xa5e157!==_0x3648b1;},'rVghI':_0x1a0224(0x1ce)},_0x4908c0=await _0x373a33[_0x1a0224(0x20e)](getToken);if(!_0x4908c0)throw new Error(_0x373a33[_0x1a0224(0x228)]);const _0x5b2b51=_0x373a33[_0x1a0224(0x20e)](getApiBaseUrl),_0x36a573=await _0x373a33[_0x1a0224(0x21b)](fetch,_0x5b2b51+_0x1a0224(0x1d5)+_0x407604+_0x1a0224(0x1c8)+_0x50871a,{'method':'PATCH','headers':{'Authorization':'Bearer\x20'+_0x4908c0,'Content-Type':_0x373a33['xDLoW']},'body':JSON['stringify'](_0x256c7d)});if(!_0x36a573['ok']){if(_0x373a33[_0x1a0224(0x223)](_0x373a33[_0x1a0224(0x1f0)],_0x373a33[_0x1a0224(0x1f0)]))return _0x370781['toString']()[_0x1a0224(0x1c2)](_0x1a0224(0x1c1))[_0x1a0224(0x1c7)]()[_0x1a0224(0x225)](_0x25f093)[_0x1a0224(0x1c2)](ZzJRda[_0x1a0224(0x1e7)]);else{const _0x3338b6=await _0x36a573[_0x1a0224(0x20a)]();throw new Error(_0x1a0224(0x22a)+_0x3338b6);}}}export async function getBrowserSessionSteps(_0x31fc6f){const _0x51d31f=_0x304e,_0x3db4e2={'JtCHN':function(_0x32d545){return _0x32d545();},'sfnlQ':'No\x20API\x20token\x20configured.\x20Run:\x20ranger\x20setup\x20[token]','MGOlg':function(_0x2c4132){return _0x2c4132();},'rqsje':_0x51d31f(0x1f6)},_0x53d1df=await _0x3db4e2[_0x51d31f(0x1dc)](getToken);if(!_0x53d1df)throw new Error(_0x3db4e2['sfnlQ']);const _0x55723a=_0x3db4e2[_0x51d31f(0x20c)](getApiBaseUrl),_0xdb4f51=await fetch(_0x55723a+_0x51d31f(0x1d5)+_0x31fc6f+_0x51d31f(0x1bc),{'method':_0x3db4e2[_0x51d31f(0x21f)],'headers':{'Authorization':_0x51d31f(0x1b9)+_0x53d1df}});if(!_0xdb4f51['ok']){const _0x584d11=await _0xdb4f51[_0x51d31f(0x20a)]();throw new Error(_0x51d31f(0x212)+_0x584d11);}return _0xdb4f51[_0x51d31f(0x1d6)]();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x44aa8e,_0x57b96b){const _0x4c0122=_0x594f,_0x23b4fe=_0x44aa8e();while(!![]){try{const _0x2fea4a=-parseInt(_0x4c0122(0x1d9))/0x1+-parseInt(_0x4c0122(0x1ea))/0x2*(parseInt(_0x4c0122(0x1dc))/0x3)+parseInt(_0x4c0122(0x1e4))/0x4*(parseInt(_0x4c0122(0x1ec))/0x5)+-parseInt(_0x4c0122(0x1f5))/0x6+parseInt(_0x4c0122(0x1db))/0x7*(-parseInt(_0x4c0122(0x1e7))/0x8)+parseInt(_0x4c0122(0x1ed))/0x9*(-parseInt(_0x4c0122(0x1e2))/0xa)+-parseInt(_0x4c0122(0x1e8))/0xb*(-parseInt(_0x4c0122(0x1eb))/0xc);if(_0x2fea4a===_0x57b96b)break;else _0x23b4fe['push'](_0x23b4fe['shift']());}catch(_0x29a9b1){_0x23b4fe['push'](_0x23b4fe['shift']());}}}(_0x392d,0x6fe82));import{homedir}from'os';import{join,dirname,parse}from'path';import{existsSync}from'fs';import{readFile,writeFile,mkdir}from'fs/promises';export function getClaudeConfigDir(){const _0x2cb504=_0x594f,_0x266efc={'NeLpB':function(_0x5c5766){return _0x5c5766();},'ogxAN':'.claude'};return process[_0x2cb504(0x1dd)]['CLAUDE_CONFIG_DIR']||join(_0x266efc['NeLpB'](homedir),_0x266efc[_0x2cb504(0x1df)]);}export function getUserSkillsDir(){return join(getClaudeConfigDir(),'skills');}export function getProjectRoot(){const _0x1b08de=_0x594f,_0x5244fc={'aVmyx':function(_0xe38369,_0x7e1b3a){return _0xe38369(_0x7e1b3a);},'QFNYW':function(_0x1d542d,_0x1f7db1){return _0x1d542d!==_0x1f7db1;},'eNhhX':_0x1b08de(0x1ef),'qEzyz':function(_0x1d742d,_0x1128eb){return _0x1d742d(_0x1128eb);},'lYZxi':_0x1b08de(0x1f0)};let _0x153ca4=process[_0x1b08de(0x1f3)]();const _0x32aa98=_0x5244fc[_0x1b08de(0x1e1)](parse,_0x153ca4)['root'];while(_0x5244fc[_0x1b08de(0x1e0)](_0x153ca4,_0x32aa98)){if(existsSync(join(_0x153ca4,_0x5244fc['eNhhX'])))return _0x153ca4;if(_0x5244fc[_0x1b08de(0x1e9)](existsSync,join(_0x153ca4,_0x5244fc[_0x1b08de(0x1de)])))return _0x153ca4;_0x153ca4=dirname(_0x153ca4);}return process['cwd']();}export function getProjectSkillsDir(){const _0x7ebab6={'esfYG':function(_0x3954d6){return _0x3954d6();},'Bdtqn':'.claude','emBxe':'skills'};return join(_0x7ebab6['esfYG'](getProjectRoot),_0x7ebab6['Bdtqn'],_0x7ebab6['emBxe']);}export function getSkillsDir(_0x4d1262){const _0x444b67=_0x594f,_0x1773ce={'NkJvu':function(_0x113e8d,_0xe7e8cd){return _0x113e8d===_0xe7e8cd;},'blGlW':function(_0x34822f){return _0x34822f();}};return _0x1773ce[_0x444b67(0x1f4)](_0x4d1262,_0x444b67(0x1ee))?_0x1773ce[_0x444b67(0x1f2)](getUserSkillsDir):getProjectSkillsDir();}function _0x594f(_0x9132cd,_0x8d5941){_0x9132cd=_0x9132cd-0x1d9;const _0x392d1f=_0x392d();let _0x594fd5=_0x392d1f[_0x9132cd];return _0x594fd5;}export function getSettingsPath(){const _0x574fd6=_0x594f,_0x585c7e={'vbLGL':function(_0x2e01fc,_0x18cbed,_0x55bbbc){return _0x2e01fc(_0x18cbed,_0x55bbbc);}};return _0x585c7e[_0x574fd6(0x1e3)](join,getClaudeConfigDir(),'settings.json');}function _0x392d(){const _0x589eb6=['user','.claude','.git','guhVh','blGlW','cwd','NkJvu','1410798hCJoBt','429487KAuNBU','stringify','1401148WsPHfV','858esXrzF','env','lYZxi','ogxAN','QFNYW','aVmyx','62560KzvvGf','vbLGL','4ZMABQb','parse','utf-8','32nsdBWz','231NMeZjY','qEzyz','1376KLeTjX','1149444gfJXDm','732115jZsHOk','54EvMhxp'];_0x392d=function(){return _0x589eb6;};return _0x392d();}export async function loadClaudeSettings(){const _0x3e0752=_0x594f,_0x310030=getSettingsPath();if(!existsSync(_0x310030))return{};try{const _0xf0d350=await readFile(_0x310030,_0x3e0752(0x1e6));return JSON[_0x3e0752(0x1e5)](_0xf0d350);}catch{return{};}}export async function saveClaudeSettings(_0x228f89){const _0x563990=_0x594f,_0x157179={'guhVh':function(_0x58baf6,_0xfd83cf,_0x5f14ad){return _0x58baf6(_0xfd83cf,_0x5f14ad);}},_0x56826c=getSettingsPath(),_0x21fa09=getClaudeConfigDir();!existsSync(_0x21fa09)&&await _0x157179[_0x563990(0x1f1)](mkdir,_0x21fa09,{'recursive':!![]}),await writeFile(_0x56826c,JSON[_0x563990(0x1da)](_0x228f89,null,0x2)+'\x0a',_0x563990(0x1e6));}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
function _0x1f46(){const _0x64692a=['2100609uqpsOY','48490MaGlxF','1249496Jqficj','256816YkQVkk','oqvgc','2016390OjbvcW','101862oBIwoF','27PUqnFB','20lVAUAe','356586oEmrnh'];_0x1f46=function(){return _0x64692a;};return _0x1f46();}(function(_0x20a007,_0x4de1ba){const _0x50f80c=_0x39e5,_0x468830=_0x20a007();while(!![]){try{const _0x5e0c84=-parseInt(_0x50f80c(0x166))/0x1+parseInt(_0x50f80c(0x160))/0x2+-parseInt(_0x50f80c(0x163))/0x3+-parseInt(_0x50f80c(0x165))/0x4*(parseInt(_0x50f80c(0x168))/0x5)+parseInt(_0x50f80c(0x162))/0x6+-parseInt(_0x50f80c(0x167))/0x7+-parseInt(_0x50f80c(0x15f))/0x8*(-parseInt(_0x50f80c(0x164))/0x9);if(_0x5e0c84===_0x4de1ba)break;else _0x468830['push'](_0x468830['shift']());}catch(_0x247c7d){_0x468830['push'](_0x468830['shift']());}}}(_0x1f46,0x2f57d));function _0x39e5(_0x355e2f,_0x18526f){_0x355e2f=_0x355e2f-0x15f;const _0x1f46ea=_0x1f46();let _0x39e5e5=_0x1f46ea[_0x355e2f];return _0x39e5e5;}import{isByokEnabled}from'./environment.js';const RANGER_CLAUDE_OVERRIDE_SETTINGS={'env':{'CLAUDE_CODE_USE_BEDROCK':'0'}};export function buildClaudeOverrideExtraArgs(){const _0x2eea93=_0x39e5,_0x14a165={'oqvgc':function(_0x3fafcb){return _0x3fafcb();}};if(_0x14a165[_0x2eea93(0x161)](isByokEnabled))return{};return{'settings':JSON['stringify'](RANGER_CLAUDE_OVERRIDE_SETTINGS)};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x273168,_0x36a6da){const _0x359f31=_0x455b,_0xda7cd=_0x273168();while(!![]){try{const _0x275984=-parseInt(_0x359f31(0x1fb))/0x1*(-parseInt(_0x359f31(0x1ef))/0x2)+-parseInt(_0x359f31(0x1f8))/0x3*(parseInt(_0x359f31(0x1ea))/0x4)+-parseInt(_0x359f31(0x205))/0x5+-parseInt(_0x359f31(0x206))/0x6+parseInt(_0x359f31(0x1fc))/0x7+parseInt(_0x359f31(0x1de))/0x8*(parseInt(_0x359f31(0x1e2))/0x9)+-parseInt(_0x359f31(0x1f3))/0xa*(-parseInt(_0x359f31(0x1e3))/0xb);if(_0x275984===_0x36a6da)break;else _0xda7cd['push'](_0xda7cd['shift']());}catch(_0x379482){_0xda7cd['push'](_0xda7cd['shift']());}}}(_0x189c,0x74261));function _0x189c(){const _0x5d2514=['EGeCY','tlgfP','plugin','65466gCNZRo','2419901pidObp','SzKGh','utf-8','plugins','ZRcNL','includes','[\x5cs\x5cS]*?(enabled|disabled)','2764tEepLO','user','eBXoS','VAkbe','XnrtE','38NUzfCk','pipe','KjzyF','filter','10tBnhBi','aAetb','scope','toString','QyVwJ','2316HdLJwH','stderr','JXOzL','39475cKcrVO','5344038uqdHVO','sort','parse','Command\x20exited\x20with\x20code\x20','inherit','version','match','HNEod','map','2228470zkrZMk','4551858VbMijd','data','ignore','success','output','528OXEWUM'];_0x189c=function(){return _0x5d2514;};return _0x189c();}import{spawn}from'child_process';import{existsSync}from'fs';import{readFile}from'fs/promises';import{join,resolve}from'path';function _0x455b(_0x12dd27,_0x5a800f){_0x12dd27=_0x12dd27-0x1dc;const _0x189ce4=_0x189c();let _0x455b97=_0x189ce4[_0x12dd27];return _0x455b97;}import{getClaudeConfigDir,getProjectRoot}from'./claudeConfig.js';export function runClaudeCommand(_0x37d1f2,_0x3e109c){const _0x510f55=_0x455b,_0x160cfe={'PiAQh':function(_0x4f3c02,_0x2956bd){return _0x4f3c02(_0x2956bd);},'KjzyF':_0x510f55(0x1f0),'JXOzL':'claude','eBXoS':'data','LerRO':'close'};return new Promise(_0x210a3d=>{const _0x45523d=_0x510f55,_0x3002a2={'tggJq':function(_0x4fe681,_0x260c36){return _0x160cfe['PiAQh'](_0x4fe681,_0x260c36);}},_0x5f5a24=_0x3e109c?.['captureOutput']?[_0x45523d(0x208),_0x160cfe[_0x45523d(0x1f1)],'pipe']:['ignore',_0x45523d(0x200),'inherit'],_0x507e5b=spawn(_0x160cfe[_0x45523d(0x1fa)],_0x37d1f2,{'stdio':_0x5f5a24,'cwd':_0x3e109c?.['cwd']});let _0x1c19af='';_0x3e109c?.['captureOutput']&&_0x507e5b['stdout']&&_0x507e5b['stdout']['on'](_0x45523d(0x207),_0x33e5d8=>{const _0x393eeb=_0x45523d;_0x1c19af+=_0x33e5d8[_0x393eeb(0x1f6)]();}),_0x3e109c?.['captureOutput']&&_0x507e5b[_0x45523d(0x1f9)]&&_0x507e5b['stderr']['on'](_0x160cfe[_0x45523d(0x1ec)],_0x421a89=>{_0x1c19af+=_0x421a89['toString']();}),_0x507e5b['on'](_0x160cfe['LerRO'],_0x573c67=>{const _0x7b4667=_0x45523d;_0x573c67===0x0?_0x210a3d({'success':!![],'output':_0x1c19af}):_0x3002a2['tggJq'](_0x210a3d,{'success':![],'error':_0x7b4667(0x1ff)+_0x573c67,'output':_0x1c19af});}),_0x507e5b['on']('error',_0x1ff329=>{_0x210a3d({'success':![],'error':_0x1ff329['message']});});});}export async function isMarketplaceAdded(_0x4dbd25){const _0x5eb94c=_0x455b,_0x31e9d4={'oDmNU':function(_0x38fd0b,_0x35e2e1,_0x52d1dc){return _0x38fd0b(_0x35e2e1,_0x52d1dc);},'bSqEb':'list'},_0x1580c5=await _0x31e9d4['oDmNU'](runClaudeCommand,['plugin','marketplace',_0x31e9d4['bSqEb']],{'captureOutput':!![]});if(!_0x1580c5[_0x5eb94c(0x1dc)]||!_0x1580c5['output'])return![];return _0x1580c5[_0x5eb94c(0x1dd)][_0x5eb94c(0x1e8)](_0x4dbd25);}export async function isPluginInstalled(_0x25e1a4){const _0x3bc509=_0x455b,_0x24db89={'ZRcNL':_0x3bc509(0x1e1)},_0x14a55f=await getInstalledPluginInfoFromRegistry(_0x25e1a4);if(_0x14a55f['length']>0x0)return!![];const _0x33ef57=await runClaudeCommand([_0x24db89[_0x3bc509(0x1e7)],'list'],{'captureOutput':!![]});if(!_0x33ef57[_0x3bc509(0x1dc)]||!_0x33ef57[_0x3bc509(0x1dd)])return![];return _0x33ef57['output'][_0x3bc509(0x1e8)](_0x25e1a4);}function getInstalledPluginsPath(){const _0x1c4c3f=_0x455b,_0x288999={'jbZJo':_0x1c4c3f(0x1e6)};return join(getClaudeConfigDir(),_0x288999['jbZJo'],'installed_plugins.json');}function sortPluginInfo(_0x5a0db5,_0x53dcac){const _0x3dcff2=_0x455b,_0x5edd9f={'aAetb':function(_0x33dfde,_0x3acf0f){return _0x33dfde-_0x3acf0f;},'HNEod':_0x3dcff2(0x1eb)},_0x3252e6={'project':0x0,'local':0x1,'user':0x2};return _0x5edd9f[_0x3dcff2(0x1f4)](_0x3252e6[_0x5a0db5['scope']??_0x3dcff2(0x1eb)],_0x3252e6[_0x53dcac[_0x3dcff2(0x1f5)]??_0x5edd9f[_0x3dcff2(0x203)]]);}export function parseInstalledPluginInfo(_0x11f540,_0x5bd530,_0x458917){const _0x2d3d23=_0x455b,_0xb1a94b={'EGeCY':function(_0x11cd6a,_0x1e03d5){return _0x11cd6a!==_0x1e03d5;},'XnrtE':'project','QyVwJ':function(_0x46d639,_0x2c8a06){return _0x46d639===_0x2c8a06;}},_0x5c79ae=JSON[_0x2d3d23(0x1fe)](_0x11f540),_0x3a8a0e=resolve(_0x458917),_0x2592fe=_0x5c79ae[_0x2d3d23(0x1e6)]?.[_0x5bd530]??[];return _0x2592fe[_0x2d3d23(0x1f2)](_0xffc7c0=>{const _0xc50af0=_0x2d3d23;if(_0xb1a94b[_0xc50af0(0x1df)](_0xffc7c0[_0xc50af0(0x1f5)],_0xb1a94b[_0xc50af0(0x1ee)])&&_0xb1a94b['EGeCY'](_0xffc7c0['scope'],'local'))return!![];if(!_0xffc7c0['projectPath'])return!![];return _0xb1a94b[_0xc50af0(0x1f7)](resolve(_0xffc7c0['projectPath']),_0x3a8a0e);})[_0x2d3d23(0x204)](_0x2a9689=>({'name':_0x5bd530,'scope':_0x2a9689['scope'],'version':_0x2a9689[_0x2d3d23(0x201)]}))[_0x2d3d23(0x1fd)](sortPluginInfo);}async function getInstalledPluginInfoFromRegistry(_0x27cd04){const _0x1b5c8c=_0x455b,_0x302086={'nMGCC':function(_0x25815c,_0x1535eb){return _0x25815c(_0x1535eb);},'tlgfP':function(_0x281183,_0x37019d,_0x55f558){return _0x281183(_0x37019d,_0x55f558);},'SzKGh':function(_0x5f599b,_0x3642da,_0x12e5ed,_0x315255){return _0x5f599b(_0x3642da,_0x12e5ed,_0x315255);}},_0x577f6b=getInstalledPluginsPath();if(!_0x302086['nMGCC'](existsSync,_0x577f6b))return[];try{const _0xe479a0=await _0x302086[_0x1b5c8c(0x1e0)](readFile,_0x577f6b,_0x1b5c8c(0x1e5));return _0x302086[_0x1b5c8c(0x1e4)](parseInstalledPluginInfo,_0xe479a0,_0x27cd04,getProjectRoot());}catch{return[];}}export async function getPluginInfo(_0x1ef7f5){const _0x46b4ef=_0x455b,_0x4acced={'XFDPq':function(_0x5df782,_0x1f024e){return _0x5df782(_0x1f024e);},'VAkbe':'plugin','kihJj':'list'},_0x49749a=await _0x4acced['XFDPq'](getInstalledPluginInfoFromRegistry,_0x1ef7f5);if(_0x49749a['length']>0x0)return _0x49749a[0x0];const _0x289659=await runClaudeCommand([_0x4acced[_0x46b4ef(0x1ed)],_0x4acced['kihJj']],{'captureOutput':!![]});if(!_0x289659[_0x46b4ef(0x1dc)]||!_0x289659[_0x46b4ef(0x1dd)])return null;if(!_0x289659['output'][_0x46b4ef(0x1e8)](_0x1ef7f5))return null;const _0x1c7c50={'name':_0x1ef7f5},_0x492b31=_0x289659[_0x46b4ef(0x1dd)][_0x46b4ef(0x202)](new RegExp(_0x1ef7f5+'[\x5cs\x5cS]*?Scope:\x5cs*(user|project|local)','i'));_0x492b31&&(_0x1c7c50['scope']=_0x492b31[0x1]['toLowerCase']());const _0x351e51=_0x289659['output'][_0x46b4ef(0x202)](new RegExp(_0x1ef7f5+'[\x5cs\x5cS]*?Version:\x5cs*([\x5cd.]+)','i'));_0x351e51&&(_0x1c7c50['version']=_0x351e51[0x1]);const _0x4b120f=_0x289659['output']['match'](new RegExp(_0x1ef7f5+_0x46b4ef(0x1e9),'i'));return _0x4b120f&&(_0x1c7c50['enabled']=_0x4b120f[0x1]['toLowerCase']()==='enabled'),_0x1c7c50;}
|