@ranger-testing/ranger-cli 3.1.6-alpha.cbf7608-55 → 3.1.6-alpha.e1ccb01-57
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 +2 -2
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(_0x2e0ef1,_0x4a83cf){const _0xb42e50=_0x1ef4,_0x2079dd=_0x2e0ef1();while(!![]){try{const _0x231135=parseInt(_0xb42e50(0xd0))/0x1+-parseInt(_0xb42e50(0xcc))/0x2+parseInt(_0xb42e50(0xe4))/0x3+parseInt(_0xb42e50(0xc3))/0x4*(parseInt(_0xb42e50(0xe6))/0x5)+-parseInt(_0xb42e50(0xf5))/0x6+-parseInt(_0xb42e50(0xe0))/0x7+-parseInt(_0xb42e50(0xd6))/0x8*(-parseInt(_0xb42e50(0xcd))/0x9);if(_0x231135===_0x4a83cf)break;else _0x2079dd['push'](_0x2079dd['shift']());}catch(_0x4190bd){_0x2079dd['push'](_0x2079dd['shift']());}}}(_0x687f,0x6a4fe));function _0x1ef4(_0x420433,_0x2a740f){_0x420433=_0x420433-0xb9;const _0x687f4b=_0x687f();let _0x1ef4b7=_0x687f4b[_0x420433];return _0x1ef4b7;}import{existsSync}from'fs';import _0x1363f6 from'inquirer';import{ApiError,fetchAuthConfig,fetchCloudProfile,listCloudProfiles,resolveAdHocProfile,resolveCloudProfileSession}from'./cloudProfile.js';import{isInteractive,resolveAuthEnvironmentLocally}from'./cloudProfileSession.js';import{mergeCloudProfileSettings,readProfileOverrides}from'./projectsConfig.js';import{readUrlEnvVars,resolveProfileUrl}from'./resolveProfileUrl.js';import{getEnvDir,loadSettings,resolveEnvVars}from'./settings.js';import{readActiveProfileName}from'./activeProfile.js';function _0x687f(){const _0x38e999=['string','fPucF','envBaseUrl','\x22\x20no\x20longer\x20exists\x20(or\x20could\x20not\x20be\x20fetched).\x20Options:\x0a','uBsTm','1555220VJgFWa','RANGER_TEST_USERNAME','resolvedEnv','cloud','Profile\x20\x22','\x20\x20Note:\x20--env\x20\x22','ZUiHs','\x20\x20(pass\x20--profile\x20<name>\x20to\x20pin,\x20or\x20RANGER_TEST_USERNAME=...\x20to\x20materialize\x20a\x20new\x20one)','\x22\x20only\x20affects\x20ad-hoc\x20profile\x20resolution;\x20set\x20RANGER_TEST_USERNAME\x20(+\x20RANGER_TEST_PASSWORD)\x20to\x20use\x20it.','15252uFRgNi','45IfdwwY','baseUrlSource','\x22\x20this\x20run\x20(overrides\x20the\x20profile\x27s\x20pinned\x20env\x20for\x20login).','439745AJIoYb','aNwSV','PPdim','wYzIe','\x20\x20-\x20set\x20RANGER_TEST_USERNAME\x20(+\x20RANGER_TEST_PASSWORD)\x20to\x20materialize\x20one\x20ad\x20hoc,\x20or\x0a','\x22\x20is\x20used\x20as\x20the\x20auth-environment\x20assertion\x20for\x20\x22','288128KUjxpp','\x20to\x20override.','\x20\x20Falling\x20back\x20to\x20saved\x20active\x20profile\x20\x22','list','\x20\x20Run\x20`ranger\x20profile\x20ls`\x20to\x20see\x20available\x20profiles,\x20or\x20','\x20\x20-\x20run\x20`ranger\x20profile\x20add\x20<name>`\x20to\x20create\x20a\x20new\x20one.','yfyxI','\x22.\x20Pass\x20--profile\x20','settings','baseUrl','1134476qDvfXR','RANGER_SESSION_STATE_PATH=','key','authPath','679860pAOWTg','cwd','5YMKHGf','prompt','uhDMv','BPJlt','`\x20to\x20recreate\x20it.','length','startPath','kEpTP','domains','\x20baseUrl\x20<url>','JHMDL','LOjtr','env','plFuR','\x20does\x20not\x20exist.','3780612CxJElX','Cloud\x20profile\x20(recommended)','\x20\x20-\x20run\x20`ranger\x20profile\x20use\x20<name>`\x20once,\x20or\x0a','name','log','OobHC','\x20\x20-\x20run\x20`ranger\x20profile\x20use\x20<name>`\x20to\x20switch\x20(see\x20`ranger\x20profile\x20ls`),\x20or\x0a','cdpEndpoint','Mzqla','\x22\x20exists\x20both\x20locally\x20and\x20in\x20the\x20cloud.\x20Which\x20one\x20should\x20be\x20used?','authEnv','uVtvr'];_0x687f=function(){return _0x38e999;};return _0x687f();}export async function resolveProfileContext(_0x4997e5){const _0x4a9dd4=_0x1ef4,_0x55d3da={'Mzqla':function(_0x46f697,_0x55ad68){return _0x46f697(_0x55ad68);},'kEpTP':function(_0x2fadf7,_0x39c81d){return _0x2fadf7!==_0x39c81d;},'uBsTm':function(_0x581ae5,_0x222136){return _0x581ae5 instanceof _0x222136;},'ZUiHs':function(_0x4a25e1,_0x20214d){return _0x4a25e1(_0x20214d);},'OobHC':function(_0x47462c,_0x3398d4){return _0x47462c??_0x3398d4;},'aNwSV':function(_0x35ae79){return _0x35ae79();},'LOjtr':function(_0x4ad407,_0x597b19){return _0x4ad407===_0x597b19;},'wYzIe':function(_0x53c070,_0x46c467){return _0x53c070+_0x46c467;},'begLA':function(_0x5737ec,_0x2b814f){return _0x5737ec+_0x2b814f;},'xGjGF':'\x20\x20-\x20set\x20RANGER_TEST_USERNAME\x20(+\x20RANGER_TEST_PASSWORD)\x20to\x20materialize\x20one,\x20or\x0a','plFuR':'\x20\x20-\x20pass\x20--profile\x20<name>\x20/\x20set\x20RANGER_PROFILE,\x20or\x0a','JHMDL':_0x4a9dd4(0xdb),'vHghF':function(_0x59febc,_0x4c240f){return _0x59febc(_0x4c240f);},'sSJWk':'`ranger\x20profile\x20add`\x20to\x20create\x20one.','fPucF':function(_0x5cd635,_0x85aaaf){return _0x5cd635&&_0x85aaaf;},'BPJlt':_0x4a9dd4(0xf6),'DqWOt':'cloud','CwuuS':'local','oQsts':function(_0x51860e,_0x2f96f9){return _0x51860e(_0x2f96f9);},'uhDMv':function(_0x39569d,_0x4b4ca5){return _0x39569d(_0x4b4ca5);},'LjDOX':function(_0x10635a,_0x1e79b8){return _0x10635a+_0x1e79b8;},'uVtvr':function(_0x36ecc9,_0x5474b2){return _0x36ecc9+_0x5474b2;},'vukbL':_0x4a9dd4(0xd4)},_0x199d20=_0x4997e5['profile'];let _0xe4e87c=_0x199d20,_0x2e072e=null;const _0x31ed8b=_0x199d20?null:await readActiveProfileName();if(_0x4997e5['authEnv']&&_0x199d20)console[_0x4a9dd4(0xf9)](_0x4a9dd4(0xc8)+_0x4997e5[_0x4a9dd4(0xbc)]+_0x4a9dd4(0xd5)+_0x199d20+_0x4a9dd4(0xcf));else _0x4997e5[_0x4a9dd4(0xbc)]&&!process[_0x4a9dd4(0xf2)][_0x4a9dd4(0xc4)]&&console[_0x4a9dd4(0xf9)]('\x20\x20Note:\x20--env\x20\x22'+_0x4997e5['authEnv']+_0x4a9dd4(0xcb));if(!_0x199d20&&process['env']['RANGER_TEST_USERNAME'])try{const _0x3604a7=await _0x55d3da[_0x4a9dd4(0xba)](resolveAdHocProfile,{'targetUrl':_0x4997e5['baseUrl']??readUrlEnvVars()[_0x4a9dd4(0xc0)],'envKey':_0x4997e5[_0x4a9dd4(0xbc)]});_0x3604a7&&(_0x31ed8b&&_0x55d3da[_0x4a9dd4(0xed)](_0x31ed8b,_0x3604a7[_0x4a9dd4(0xf8)])&&console['log']('\x20\x20RANGER_TEST_USERNAME\x20is\x20set\x20—\x20using\x20profile\x20\x22'+_0x3604a7[_0x4a9dd4(0xf8)]+'\x22\x20instead\x20of\x20the\x20saved\x20active\x20profile\x20\x22'+_0x31ed8b+_0x4a9dd4(0xdd)+_0x31ed8b+_0x4a9dd4(0xd7)),_0xe4e87c=_0x3604a7['name'],_0x2e072e=_0x3604a7['profile']);}catch(_0x560236){if(!_0x31ed8b||_0x4997e5['authEnv'])throw _0x560236;console[_0x4a9dd4(0xf9)]('\x20\x20Warning:\x20'+(_0x55d3da['uBsTm'](_0x560236,Error)?_0x560236['message']:_0x55d3da[_0x4a9dd4(0xc9)](String,_0x560236))),console[_0x4a9dd4(0xf9)](_0x4a9dd4(0xd8)+_0x31ed8b+'\x22.');}if(!_0xe4e87c)_0xe4e87c=_0x55d3da[_0x4a9dd4(0xfa)](_0x31ed8b,undefined);if(!_0xe4e87c)try{const _0x4534de=await _0x55d3da[_0x4a9dd4(0xd1)](listCloudProfiles);if(_0x55d3da['LOjtr'](_0x4534de[_0x4a9dd4(0xeb)],0x1)){const _0x581a5a=_0x4534de[0x0];_0xe4e87c=_0x581a5a[_0x4a9dd4(0xf8)],console[_0x4a9dd4(0xf9)]('\x0aUsing\x20the\x20only\x20cloud\x20profile\x20for\x20your\x20org:\x20'+_0x581a5a[_0x4a9dd4(0xf8)]),console['log'](_0x4a9dd4(0xca));}}catch{}if(!_0xe4e87c)throw new Error(_0x55d3da['wYzIe'](_0x55d3da[_0x4a9dd4(0xd3)](_0x55d3da['begLA']('Ranger\x20can\x27t\x20verify\x20with\x20a\x20browser\x20until\x20a\x20profile\x20is\x20set\x20up.\x20Options:\x0a',_0x55d3da['xGjGF']),_0x55d3da[_0x4a9dd4(0xf3)])+_0x4a9dd4(0xf7),_0x55d3da[_0x4a9dd4(0xf0)]));const _0xb59514=_0x55d3da[_0x4a9dd4(0xba)](getEnvDir,_0xe4e87c),_0x58761b=_0x55d3da['ZUiHs'](existsSync,_0xb59514);let _0x2952a2=_0x2e072e,_0x2fa072=![];if(!_0x2952a2)try{_0x2952a2=await _0x55d3da['vHghF'](fetchCloudProfile,_0xe4e87c);if(!_0x2952a2)_0x2fa072=!![];}catch(_0xd61d60){_0x55d3da[_0x4a9dd4(0xc2)](_0xd61d60,ApiError)&&_0xd61d60['status']===0x194&&(_0x2fa072=!![]);}if(_0x199d20&&_0x2fa072&&!_0x58761b&&!_0x2952a2)throw new Error('Profile\x20\x22'+_0x199d20+'\x22\x20not\x20found\x20locally\x20or\x20in\x20the\x20cloud.\x0a'+_0x4a9dd4(0xda)+_0x55d3da['sSJWk']);if(_0x55d3da[_0x4a9dd4(0xbf)](_0x2952a2,_0x58761b)){let _0x3d9d27=!![];if(_0x55d3da[_0x4a9dd4(0xd1)](isInteractive)){const {source:_0x5957a9}=await _0x1363f6[_0x4a9dd4(0xe7)]([{'type':_0x4a9dd4(0xd9),'name':'source','message':_0x4a9dd4(0xc7)+_0xe4e87c+_0x4a9dd4(0xbb),'choices':[{'name':_0x55d3da[_0x4a9dd4(0xe9)],'value':_0x55d3da['DqWOt']},{'name':'Local\x20profile','value':_0x55d3da['CwuuS']}],'default':_0x55d3da['DqWOt']}]);_0x3d9d27=_0x55d3da[_0x4a9dd4(0xf1)](_0x5957a9,_0x4a9dd4(0xc6));}if(!_0x3d9d27)_0x2952a2=null;}const _0x5083ec=readProfileOverrides(process[_0x4a9dd4(0xe5)](),_0xe4e87c);let _0x47d1be=null,_0x7e638b,_0x8c9f3c,_0x2806fc,_0x12844e,_0xd67085=null,_0x4ae29e,_0x4169a7;const _0x2febe6=expandOverrides(_0x5083ec),_0xce00c0=_0x55d3da[_0x4a9dd4(0xd1)](readUrlEnvVars);if(_0x2952a2){_0x47d1be=_0x2952a2;const _0x48e367=_0x2952a2['settings']??{},_0x3f490e=mergeCloudProfileSettings(_0x48e367,_0x5083ec??undefined),_0x43e8ab={..._0x2952a2,'settings':_0x3f490e};_0xd67085={'baseUrl':_0x55d3da['oQsts'](expandString,_0x48e367['baseUrl']),'startPath':expandString(_0x48e367[_0x4a9dd4(0xec)])};const _0x57a6a2=await fetchAuthConfig(),_0x222f24=_0x57a6a2?resolveAuthEnvironmentLocally(_0x57a6a2,_0x2952a2['environmentKey']):null;_0x4ae29e=_0x222f24?.[_0x4a9dd4(0xee)]?.[0x0],_0x4169a7=_0x222f24?.[_0x4a9dd4(0xe2)];const _0x19369d=resolveProfileUrl({'flagBaseUrl':_0x4997e5['baseUrl'],'flagStartPath':_0x4997e5['startPath'],'envBaseUrl':_0xce00c0[_0x4a9dd4(0xc0)],'envStartPath':_0xce00c0['envStartPath'],'projectOverrides':_0x2febe6,'cloudSettings':_0xd67085,'authEnvironmentDomain':_0x4ae29e}),_0x1d3893=process[_0x4a9dd4(0xf2)]['RANGER_SESSION_STATE_PATH'];if(_0x1d3893){if(!_0x55d3da[_0x4a9dd4(0xe8)](existsSync,_0x1d3893))throw new Error(_0x4a9dd4(0xe1)+_0x1d3893+_0x4a9dd4(0xf4));_0x7e638b=_0x1d3893,_0x8c9f3c=_0x55d3da['oQsts'](resolveEnvVars,_0x3f490e),_0x2806fc=Boolean(_0x8c9f3c[_0x4a9dd4(0xb9)]);}else{const _0x5513cd=await resolveCloudProfileSession(_0x43e8ab,{'effectiveBaseUrl':_0x19369d['baseUrl'],'telemetry':_0x4997e5['telemetry'],'assertedEnv':_0x4997e5[_0x4a9dd4(0xbc)]});_0x7e638b=_0x5513cd[_0x4a9dd4(0xe3)],_0x8c9f3c=resolveEnvVars(_0x5513cd[_0x4a9dd4(0xde)]),_0x2806fc=Boolean(_0x8c9f3c['cdpEndpoint']),_0x4ae29e=_0x5513cd['resolvedEnv']?.[_0x4a9dd4(0xee)]?.[0x0],_0x4169a7=_0x5513cd[_0x4a9dd4(0xc5)]?.[_0x4a9dd4(0xe2)];}}else{if(!_0x58761b){const _0x30713f=!_0x199d20;throw new Error(_0x30713f?_0x55d3da['LjDOX'](_0x55d3da[_0x4a9dd4(0xbd)]('Active\x20profile\x20\x22'+_0xe4e87c+_0x4a9dd4(0xc1),_0x4a9dd4(0xfb))+_0x55d3da['vukbL'],'\x20\x20-\x20run\x20`ranger\x20profile\x20add\x20'+_0xe4e87c+_0x4a9dd4(0xea)):_0x4a9dd4(0xc7)+_0xe4e87c+'\x22\x20not\x20found.\x20Run:\x20ranger\x20profile\x20add\x20'+_0xe4e87c);}const _0x36b913=await _0x55d3da['vHghF'](loadSettings,_0xe4e87c);_0x8c9f3c=resolveEnvVars(_0x36b913),_0x2806fc=Boolean(_0x8c9f3c['cdpEndpoint']),_0x12844e=_0x8c9f3c[_0x4a9dd4(0xdf)];}const _0xde258c=resolveProfileUrl({'flagBaseUrl':_0x4997e5['baseUrl'],'flagStartPath':_0x4997e5[_0x4a9dd4(0xec)],'envBaseUrl':_0xce00c0[_0x4a9dd4(0xc0)],'envStartPath':_0xce00c0['envStartPath'],'localSettingsBaseUrl':_0x12844e,'projectOverrides':_0x2febe6,'cloudSettings':_0xd67085,'authEnvironmentDomain':_0x4ae29e}),_0x532568=_0xde258c['url']??_0xde258c['baseUrl'];if(_0x55d3da['fPucF'](!_0x532568,!_0x2806fc))throw new Error('No\x20baseUrl\x20configured\x20for\x20profile\x20\x22'+_0xe4e87c+'\x22.\x20Run:\x20ranger\x20profile\x20config\x20set\x20'+_0xe4e87c+_0x4a9dd4(0xef));return{'activeProfile':_0xe4e87c,'resolvedCloudProfile':_0x47d1be,'cloudAuthPath':_0x7e638b,'resolvedSettings':_0x8c9f3c,'isCdpMode':_0x2806fc,'url':_0x532568,'baseUrlSource':_0xde258c[_0x4a9dd4(0xce)],'authEnvKey':_0x4169a7,'startPath':_0xde258c[_0x4a9dd4(0xec)]};}function expandString(_0x2bfb50){if(typeof _0x2bfb50!=='string')return _0x2bfb50;return resolveEnvVars(_0x2bfb50);}function expandOverrides(_0x2edcc0){const _0x24d820=_0x1ef4,_0x339b4a={'PPdim':function(_0x47d8e1,_0x48f21b){return _0x47d8e1===_0x48f21b;},'yfyxI':_0x24d820(0xbe),'axxEc':function(_0xf37c18,_0x228df6){return _0xf37c18(_0x228df6);}};if(!_0x2edcc0)return _0x2edcc0;const _0x468752={..._0x2edcc0};return _0x339b4a[_0x24d820(0xd2)](typeof _0x468752['baseUrl'],_0x339b4a['yfyxI'])&&(_0x468752['baseUrl']=_0x339b4a['axxEc'](resolveEnvVars,_0x468752['baseUrl'])),typeof _0x468752['startPath']===_0x339b4a[_0x24d820(0xdc)]&&(_0x468752['startPath']=resolveEnvVars(_0x468752['startPath'])),_0x468752;}
|
|
1
|
+
(function(_0x4f852f,_0x19c125){const _0x2194d6=_0x426f,_0x116b24=_0x4f852f();while(!![]){try{const _0xa2b1bd=-parseInt(_0x2194d6(0xf2))/0x1*(parseInt(_0x2194d6(0xfe))/0x2)+-parseInt(_0x2194d6(0x123))/0x3*(parseInt(_0x2194d6(0x128))/0x4)+-parseInt(_0x2194d6(0x118))/0x5*(-parseInt(_0x2194d6(0x125))/0x6)+parseInt(_0x2194d6(0x102))/0x7+-parseInt(_0x2194d6(0x12d))/0x8+-parseInt(_0x2194d6(0x115))/0x9*(parseInt(_0x2194d6(0xf6))/0xa)+parseInt(_0x2194d6(0x11d))/0xb*(parseInt(_0x2194d6(0x11a))/0xc);if(_0xa2b1bd===_0x19c125)break;else _0x116b24['push'](_0x116b24['shift']());}catch(_0x153e86){_0x116b24['push'](_0x116b24['shift']());}}}(_0xf95a,0x2d6f5));function _0xf95a(){const _0x3d74b5=['cloud','\x20\x20Note:\x20--env\x20\x22','\x20\x20-\x20set\x20RANGER_TEST_USERNAME\x20(+\x20RANGER_TEST_PASSWORD)\x20to\x20materialize\x20one,\x20or\x0a','avCtk','envStartPath','5IZMTZs','\x20\x20-\x20pass\x20--profile\x20<name>\x20/\x20set\x20RANGER_PROFILE,\x20or\x0a','XyzKF','cwd','46140PJynKz','bfcrC','\x22\x20this\x20run\x20(overrides\x20the\x20profile\x27s\x20pinned\x20env\x20for\x20login).','cdpEndpoint','GKnvn','env','prompt','\x20\x20-\x20set\x20RANGER_TEST_USERNAME\x20(+\x20RANGER_TEST_PASSWORD)\x20to\x20materialize\x20one\x20ad\x20hoc,\x20or\x0a','108494Mvwgtw','AIsCq','string','RANGER_TEST_USERNAME','472745umbZFV','Ranger\x20can\x27t\x20verify\x20with\x20a\x20browser\x20until\x20a\x20profile\x20is\x20set\x20up.\x20Options:\x0a','envBaseUrl','cgeWE','\x20to\x20override.','iDqeg','ZAmJt','nLjMp','RANGER_SESSION_STATE_PATH=','resolvedEnv','wMFvL','startPath','KVvmE','\x0aUsing\x20the\x20only\x20cloud\x20profile\x20for\x20your\x20org:\x20','baseUrl','KoJet','authEnv','\x20\x20-\x20run\x20`ranger\x20profile\x20add\x20<name>`\x20to\x20create\x20a\x20new\x20one.','list','18wZKoER','\x20\x20-\x20run\x20`ranger\x20profile\x20use\x20<name>`\x20once,\x20or\x0a','local','923590hQuDNL','\x22\x20no\x20longer\x20exists\x20(or\x20could\x20not\x20be\x20fetched).\x20Options:\x0a','1836YItiww','\x22\x20instead\x20of\x20the\x20saved\x20active\x20profile\x20\x22','domains','40986VHePTf','UpIJg','zvfUI','`\x20to\x20recreate\x20it.','name','source','9513SOgTcr','key','6eZQjps','EiLSI','RANGER_SESSION_STATE_PATH','436IuPhKk','fUAyU','DrJDg','Profile\x20\x22','wOIXv','81024OVmGMI','log','ujkfR','No\x20baseUrl\x20configured\x20for\x20profile\x20\x22','settings','status','jsLnd'];_0xf95a=function(){return _0x3d74b5;};return _0xf95a();}import{existsSync}from'fs';import _0x17edb2 from'inquirer';import{ApiError,fetchAuthConfig,fetchCloudProfile,listCloudProfiles,resolveAdHocProfile,resolveCloudProfileSession}from'./cloudProfile.js';function _0x426f(_0x113bfc,_0x1fbc50){_0x113bfc=_0x113bfc-0xec;const _0xf95a11=_0xf95a();let _0x426f0f=_0xf95a11[_0x113bfc];return _0x426f0f;}import{isInteractive,resolveAuthEnvironmentLocally}from'./cloudProfileSession.js';import{mergeCloudProfileSettings,readProfileOverrides}from'./projectsConfig.js';import{readUrlEnvVars,resolveProfileUrl}from'./resolveProfileUrl.js';import{getEnvDir,loadSettings,resolveEnvVars}from'./settings.js';import{readActiveProfileName}from'./activeProfile.js';export async function resolveProfileContext(_0x2e2570){const _0x44a71a=_0x426f,_0x1cb6bb={'DrJDg':function(_0xe316e2,_0x165132){return _0xe316e2(_0x165132);},'bfcrC':function(_0x38c5bc){return _0x38c5bc();},'nLjMp':function(_0x46fc3b,_0x572a29){return _0x46fc3b!==_0x572a29;},'cgeWE':function(_0x4321f6,_0x5730f4){return _0x4321f6 instanceof _0x5730f4;},'UpIJg':function(_0x4427f0,_0x23956f){return _0x4427f0??_0x23956f;},'jsLnd':function(_0x179c9b){return _0x179c9b();},'iDqeg':function(_0x216fb2,_0x4c7039){return _0x216fb2+_0x4c7039;},'BthtB':function(_0x64a755,_0x5b5d0c){return _0x64a755+_0x5b5d0c;},'KjTfy':function(_0x18723b,_0x23d2e4){return _0x18723b+_0x23d2e4;},'WHxXu':_0x44a71a(0xef),'avCtk':_0x44a71a(0x116),'ZAmJt':_0x44a71a(0x113),'AIsCq':function(_0x480daa,_0x28a9c6){return _0x480daa(_0x28a9c6);},'hdLhl':function(_0x3b23a7,_0x54c2ec){return _0x3b23a7&&_0x54c2ec;},'KoJet':function(_0x5c844e){return _0x5c844e();},'oOvkH':_0x44a71a(0x122),'wMFvL':_0x44a71a(0x117),'yuaos':function(_0x1d4ca4,_0x102ff){return _0x1d4ca4===_0x102ff;},'GKnvn':'cloud','XyzKF':function(_0x37d899,_0x150d17){return _0x37d899(_0x150d17);},'KVvmE':function(_0x4dfbfb,_0x55b1c5){return _0x4dfbfb(_0x55b1c5);},'yYVOc':function(_0x292e0f,_0x3bec92){return _0x292e0f+_0x3bec92;},'JcPFq':'\x20\x20-\x20run\x20`ranger\x20profile\x20use\x20<name>`\x20to\x20switch\x20(see\x20`ranger\x20profile\x20ls`),\x20or\x0a','EiLSI':_0x44a71a(0xfd),'wOIXv':function(_0x232e8f,_0x4ed3a9){return _0x232e8f(_0x4ed3a9);}},_0x37d03f=_0x2e2570['profile'];let _0x199cf8=_0x37d03f,_0x59ea34=null;const _0x2f2d44=_0x37d03f?null:await readActiveProfileName();if(_0x2e2570[_0x44a71a(0x112)]&&_0x37d03f)console['log']('\x20\x20Note:\x20--env\x20\x22'+_0x2e2570['authEnv']+'\x22\x20is\x20used\x20as\x20the\x20auth-environment\x20assertion\x20for\x20\x22'+_0x37d03f+_0x44a71a(0xf8));else _0x2e2570['authEnv']&&!process[_0x44a71a(0xfb)][_0x44a71a(0x101)]&&console[_0x44a71a(0x12e)](_0x44a71a(0xee)+_0x2e2570['authEnv']+'\x22\x20only\x20affects\x20ad-hoc\x20profile\x20resolution;\x20set\x20RANGER_TEST_USERNAME\x20(+\x20RANGER_TEST_PASSWORD)\x20to\x20use\x20it.');if(!_0x37d03f&&process['env']['RANGER_TEST_USERNAME'])try{const _0x2e21ed=await _0x1cb6bb[_0x44a71a(0x12a)](resolveAdHocProfile,{'targetUrl':_0x2e2570[_0x44a71a(0x110)]??_0x1cb6bb[_0x44a71a(0xf7)](readUrlEnvVars)[_0x44a71a(0x104)],'envKey':_0x2e2570[_0x44a71a(0x112)]});_0x2e21ed&&(_0x2f2d44&&_0x1cb6bb[_0x44a71a(0x109)](_0x2f2d44,_0x2e21ed[_0x44a71a(0x121)])&&console[_0x44a71a(0x12e)]('\x20\x20RANGER_TEST_USERNAME\x20is\x20set\x20—\x20using\x20profile\x20\x22'+_0x2e21ed[_0x44a71a(0x121)]+_0x44a71a(0x11b)+_0x2f2d44+'\x22.\x20Pass\x20--profile\x20'+_0x2f2d44+_0x44a71a(0x106)),_0x199cf8=_0x2e21ed['name'],_0x59ea34=_0x2e21ed['profile']);}catch(_0x2d14fe){if(!_0x2f2d44||_0x2e2570[_0x44a71a(0x112)])throw _0x2d14fe;console['log']('\x20\x20Warning:\x20'+(_0x1cb6bb[_0x44a71a(0x105)](_0x2d14fe,Error)?_0x2d14fe['message']:String(_0x2d14fe))),console[_0x44a71a(0x12e)]('\x20\x20Falling\x20back\x20to\x20saved\x20active\x20profile\x20\x22'+_0x2f2d44+'\x22.');}if(!_0x199cf8)_0x199cf8=_0x1cb6bb[_0x44a71a(0x11e)](_0x2f2d44,undefined);if(!_0x199cf8)try{const _0x41e999=await _0x1cb6bb[_0x44a71a(0xec)](listCloudProfiles);if(_0x41e999['length']===0x1){const _0x23bb39=_0x41e999[0x0];_0x199cf8=_0x23bb39[_0x44a71a(0x121)],console[_0x44a71a(0x12e)](_0x44a71a(0x10f)+_0x23bb39['name']),console[_0x44a71a(0x12e)]('\x20\x20(pass\x20--profile\x20<name>\x20to\x20pin,\x20or\x20RANGER_TEST_USERNAME=...\x20to\x20materialize\x20a\x20new\x20one)');}}catch{}if(!_0x199cf8)throw new Error(_0x1cb6bb[_0x44a71a(0x107)](_0x1cb6bb['BthtB'](_0x1cb6bb['KjTfy'](_0x44a71a(0x103),_0x1cb6bb['WHxXu']),_0x44a71a(0xf3))+_0x1cb6bb[_0x44a71a(0xf0)],_0x1cb6bb[_0x44a71a(0x108)]));const _0x591ea1=_0x1cb6bb[_0x44a71a(0xff)](getEnvDir,_0x199cf8),_0x37d145=existsSync(_0x591ea1);let _0x4f3203=_0x59ea34,_0x1396b8=![];if(!_0x4f3203)try{_0x4f3203=await fetchCloudProfile(_0x199cf8);if(!_0x4f3203)_0x1396b8=!![];}catch(_0x1171c1){_0x1171c1 instanceof ApiError&&_0x1171c1[_0x44a71a(0x132)]===0x194&&(_0x1396b8=!![]);}if(_0x1cb6bb['hdLhl'](_0x37d03f,_0x1396b8)&&!_0x37d145&&!_0x4f3203)throw new Error('Profile\x20\x22'+_0x37d03f+'\x22\x20not\x20found\x20locally\x20or\x20in\x20the\x20cloud.\x0a'+'\x20\x20Run\x20`ranger\x20profile\x20ls`\x20to\x20see\x20available\x20profiles,\x20or\x20'+'`ranger\x20profile\x20add`\x20to\x20create\x20one.');if(_0x4f3203&&_0x37d145){let _0x18d221=!![];if(_0x1cb6bb[_0x44a71a(0x111)](isInteractive)){const {source:_0x31c832}=await _0x17edb2[_0x44a71a(0xfc)]([{'type':_0x44a71a(0x114),'name':_0x1cb6bb['oOvkH'],'message':'Profile\x20\x22'+_0x199cf8+'\x22\x20exists\x20both\x20locally\x20and\x20in\x20the\x20cloud.\x20Which\x20one\x20should\x20be\x20used?','choices':[{'name':'Cloud\x20profile\x20(recommended)','value':'cloud'},{'name':'Local\x20profile','value':_0x1cb6bb[_0x44a71a(0x10c)]}],'default':_0x44a71a(0xed)}]);_0x18d221=_0x1cb6bb['yuaos'](_0x31c832,_0x1cb6bb[_0x44a71a(0xfa)]);}if(!_0x18d221)_0x4f3203=null;}const _0x13b3de=readProfileOverrides(process[_0x44a71a(0xf5)](),_0x199cf8);let _0x2d5378=null,_0x9f5bac,_0xf6ebce,_0x4a6bce,_0x475bb6,_0x18b8fa=null,_0x212540,_0x29c755;const _0x1a1f1b=expandOverrides(_0x13b3de),_0x1f791c=_0x1cb6bb['jsLnd'](readUrlEnvVars);if(_0x4f3203){_0x2d5378=_0x4f3203;const _0x3cde88=_0x4f3203[_0x44a71a(0x131)]??{},_0x552ac4=mergeCloudProfileSettings(_0x3cde88,_0x1cb6bb[_0x44a71a(0x11e)](_0x13b3de,undefined)),_0x41c53f={..._0x4f3203,'settings':_0x552ac4};_0x18b8fa={'baseUrl':expandString(_0x3cde88[_0x44a71a(0x110)]),'startPath':expandString(_0x3cde88[_0x44a71a(0x10d)])};const _0x1e2148=await _0x1cb6bb['bfcrC'](fetchAuthConfig),_0x5072bb=_0x1e2148?resolveAuthEnvironmentLocally(_0x1e2148,_0x4f3203['environmentKey']):null;_0x212540=_0x5072bb?.['domains']?.[0x0],_0x29c755=_0x5072bb?.[_0x44a71a(0x124)];const _0x249070=_0x1cb6bb[_0x44a71a(0xf4)](resolveProfileUrl,{'flagBaseUrl':_0x2e2570[_0x44a71a(0x110)],'flagStartPath':_0x2e2570['startPath'],'envBaseUrl':_0x1f791c['envBaseUrl'],'envStartPath':_0x1f791c[_0x44a71a(0xf1)],'projectOverrides':_0x1a1f1b,'cloudSettings':_0x18b8fa,'authEnvironmentDomain':_0x212540}),_0x457f85=process['env'][_0x44a71a(0x127)];if(_0x457f85){if(!_0x1cb6bb['AIsCq'](existsSync,_0x457f85))throw new Error(_0x44a71a(0x10a)+_0x457f85+'\x20does\x20not\x20exist.');_0x9f5bac=_0x457f85,_0xf6ebce=resolveEnvVars(_0x552ac4),_0x4a6bce=_0x1cb6bb[_0x44a71a(0xf4)](Boolean,_0xf6ebce['cdpEndpoint']);}else{const _0x444cb7=await resolveCloudProfileSession(_0x41c53f,{'effectiveBaseUrl':_0x249070['baseUrl'],'telemetry':_0x2e2570['telemetry'],'assertedEnv':_0x2e2570[_0x44a71a(0x112)]});_0x9f5bac=_0x444cb7['authPath'],_0xf6ebce=resolveEnvVars(_0x444cb7['settings']),_0x4a6bce=_0x1cb6bb[_0x44a71a(0x10e)](Boolean,_0xf6ebce['cdpEndpoint']),_0x212540=_0x444cb7['resolvedEnv']?.[_0x44a71a(0x11c)]?.[0x0],_0x29c755=_0x444cb7[_0x44a71a(0x10b)]?.['key'];}}else{if(!_0x37d145){const _0x3588f9=!_0x37d03f;throw new Error(_0x3588f9?_0x1cb6bb['yYVOc']('Active\x20profile\x20\x22'+_0x199cf8+_0x44a71a(0x119)+_0x1cb6bb['JcPFq'],_0x1cb6bb[_0x44a71a(0x126)])+('\x20\x20-\x20run\x20`ranger\x20profile\x20add\x20'+_0x199cf8+_0x44a71a(0x120)):_0x44a71a(0x12b)+_0x199cf8+'\x22\x20not\x20found.\x20Run:\x20ranger\x20profile\x20add\x20'+_0x199cf8);}const _0x2937de=await _0x1cb6bb['DrJDg'](loadSettings,_0x199cf8);_0xf6ebce=resolveEnvVars(_0x2937de),_0x4a6bce=_0x1cb6bb['AIsCq'](Boolean,_0xf6ebce[_0x44a71a(0xf9)]),_0x475bb6=_0xf6ebce[_0x44a71a(0x110)];}const _0x1eccfb=_0x1cb6bb[_0x44a71a(0x12c)](resolveProfileUrl,{'flagBaseUrl':_0x2e2570[_0x44a71a(0x110)],'flagStartPath':_0x2e2570['startPath'],'envBaseUrl':_0x1f791c['envBaseUrl'],'envStartPath':_0x1f791c[_0x44a71a(0xf1)],'localSettingsBaseUrl':_0x475bb6,'projectOverrides':_0x1a1f1b,'cloudSettings':_0x18b8fa,'authEnvironmentDomain':_0x212540}),_0x1a4b6=_0x1eccfb['url']??_0x1eccfb['baseUrl'];if(!_0x1a4b6&&!_0x4a6bce)throw new Error(_0x44a71a(0x130)+_0x199cf8+'\x22.\x20Run:\x20ranger\x20profile\x20config\x20set\x20'+_0x199cf8+'\x20baseUrl\x20<url>');return{'activeProfile':_0x199cf8,'resolvedCloudProfile':_0x2d5378,'cloudAuthPath':_0x9f5bac,'resolvedSettings':_0xf6ebce,'isCdpMode':_0x4a6bce,'url':_0x1a4b6,'baseUrlSource':_0x1eccfb['baseUrlSource'],'authEnvKey':_0x29c755,'startPath':_0x1eccfb['startPath']};}function expandString(_0x3c8ece){const _0x36c051=_0x426f,_0x8e04d7={'JyHRr':function(_0x3273d2,_0x2c028a){return _0x3273d2!==_0x2c028a;},'zvfUI':'string'};if(_0x8e04d7['JyHRr'](typeof _0x3c8ece,_0x8e04d7[_0x36c051(0x11f)]))return _0x3c8ece;return resolveEnvVars(_0x3c8ece);}function expandOverrides(_0x4db076){const _0x3d3742=_0x426f,_0x5951e2={'fUAyU':_0x3d3742(0x100),'xPDei':function(_0x51e8b4,_0x525bff){return _0x51e8b4(_0x525bff);},'ujkfR':function(_0x5f2f75,_0x5c67c3){return _0x5f2f75===_0x5c67c3;}};if(!_0x4db076)return _0x4db076;const _0x43170b={..._0x4db076};return typeof _0x43170b['baseUrl']===_0x5951e2['fUAyU']&&(_0x43170b[_0x3d3742(0x110)]=_0x5951e2['xPDei'](resolveEnvVars,_0x43170b[_0x3d3742(0x110)])),_0x5951e2[_0x3d3742(0x12f)](typeof _0x43170b[_0x3d3742(0x10d)],_0x5951e2[_0x3d3742(0x129)])&&(_0x43170b['startPath']=resolveEnvVars(_0x43170b['startPath'])),_0x43170b;}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
const _0x6a9221=_0x2a9d;(function(_0xb02736,_0x5918ee){const _0x5e0170=_0x2a9d,_0x333c5c=_0xb02736();while(!![]){try{const _0x1df5c8=parseInt(_0x5e0170(0x19f))/0x1+-parseInt(_0x5e0170(0x1b2))/0x2*(-parseInt(_0x5e0170(0x1a8))/0x3)+-parseInt(_0x5e0170(0x1b0))/0x4*(parseInt(_0x5e0170(0x1a1))/0x5)+parseInt(_0x5e0170(0x1bb))/0x6+parseInt(_0x5e0170(0x1aa))/0x7+parseInt(_0x5e0170(0x1a9))/0x8+-parseInt(_0x5e0170(0x1b6))/0x9*(parseInt(_0x5e0170(0x1a5))/0xa);if(_0x1df5c8===_0x5918ee)break;else _0x333c5c['push'](_0x333c5c['shift']());}catch(_0x417a86){_0x333c5c['push'](_0x333c5c['shift']());}}}(_0x101c,0x6cf9e));function firstDefined(..._0x7df818){const _0x362392=_0x2a9d,_0x47f928={'bCNtc':function(_0x3901f5,_0x51410e){return _0x3901f5!==_0x51410e;},'QSobw':function(_0x539efb,_0xdbc62d){return _0x539efb!==_0xdbc62d;}};for(const _0x4322c4 of _0x7df818){if(_0x47f928[_0x362392(0x1b4)](_0x4322c4,undefined)&&_0x47f928['QSobw'](_0x4322c4,null)&&_0x47f928[_0x362392(0x1ab)](_0x4322c4,''))return _0x4322c4;}return undefined;}function normalizeAuthEnvironmentDomain(_0x5afbdf){const _0x53baf1=_0x2a9d;if(!_0x5afbdf)return undefined;if(/^[a-z][a-z0-9+.-]*:\/\//i[_0x53baf1(0x1bc)](_0x5afbdf))return _0x5afbdf;return'https://'+_0x5afbdf;}export function resolveBaseUrlWithSource(_0x574fc0){const _0x37b7b8=_0x2a9d,_0x1a63d1={'XWrkF':'local\x20profile\x20settings','sLvAq':'string','HsWDl':_0x37b7b8(0x19d),'nhjJo':function(_0x58b2dd,_0x5bad00){return _0x58b2dd(_0x5bad00);},'EXNFF':'auth\x20environment\x20domain','Tfiav':function(_0x143a1f,_0x421730){return _0x143a1f!==_0x421730;},'Brlqx':function(_0x45ea76,_0x56489d){return _0x45ea76!==_0x56489d;}},_0x13426e=_0x574fc0[_0x37b7b8(0x1a6)],_0xe0696f=!!_0x13426e&&_0x37b7b8(0x1a4)in _0x13426e,_0x9b7757=_0x13426e?.['baseUrl'],_0x1065c6=!(_0xe0696f&&_0x9b7757===null),_0x305490=[[_0x574fc0['flagBaseUrl'],_0x37b7b8(0x1ae)],[_0x574fc0[_0x37b7b8(0x1b9)],'RANGER_BASE_URL'],[_0x574fc0['localSettingsBaseUrl'],_0x1a63d1['XWrkF']],[typeof _0x9b7757===_0x1a63d1[_0x37b7b8(0x1ad)]?_0x9b7757:undefined,_0x37b7b8(0x19e)],[_0x1065c6?_0x574fc0['cloudSettings']?.[_0x37b7b8(0x1a4)]:undefined,_0x1a63d1[_0x37b7b8(0x1b3)]],[_0x1065c6?_0x1a63d1[_0x37b7b8(0x1a3)](normalizeAuthEnvironmentDomain,_0x574fc0[_0x37b7b8(0x1b5)]):undefined,_0x1a63d1[_0x37b7b8(0x1a2)]]];for(const [_0x1f320f,_0x1f43a0]of _0x305490){if(_0x1a63d1[_0x37b7b8(0x1af)](_0x1f320f,undefined)&&_0x1f320f!==null&&_0x1a63d1['Brlqx'](_0x1f320f,''))return{'baseUrl':_0x1f320f,'source':_0x1f43a0};}return{};}export function resolveBaseUrl(_0x49aee6){const _0x681fb5=_0x2a9d;return resolveBaseUrlWithSource(_0x49aee6)[_0x681fb5(0x1a4)];}export function resolveStartPath(_0x2d8ec5){const _0x1369c1=_0x2a9d,_0x37fc30={'gpBuy':function(_0x1776c7,_0x57f564,_0xa64e2f,_0x21ebdc,_0x559992){return _0x1776c7(_0x57f564,_0xa64e2f,_0x21ebdc,_0x559992);},'NRSEB':'string'},_0x8569e9=_0x2d8ec5['projectOverrides'],_0x1763ad=!!_0x8569e9&&'startPath'in _0x8569e9,_0x2b309c=_0x8569e9?.['startPath'],_0x4850c2=!(_0x1763ad&&_0x2b309c===null);return _0x37fc30['gpBuy'](firstDefined,_0x2d8ec5[_0x1369c1(0x1b8)],_0x2d8ec5[_0x1369c1(0x1a7)],typeof _0x2b309c===_0x37fc30['NRSEB']?_0x2b309c:undefined,_0x4850c2?_0x2d8ec5[_0x1369c1(0x1ba)]?.['startPath']:undefined);}export function joinBaseAndPath(_0x3f6228,_0x3d9d51){const _0x4cefd4=_0x2a9d,_0x5077dd={'oMYck':function(_0x18ab1e,_0x3cd961){return _0x18ab1e+_0x3cd961;}};if(!_0x3f6228)return undefined;if(!_0x3d9d51)return _0x3f6228;const _0x4a47df=_0x3f6228['endsWith']('/')?_0x3f6228[_0x4cefd4(0x19c)](0x0,-0x1):_0x3f6228,_0x5a5b6d=_0x3d9d51[_0x4cefd4(0x1b1)]('/')?_0x3d9d51:'/'+_0x3d9d51;return _0x5077dd[_0x4cefd4(0x1b7)](_0x4a47df,_0x5a5b6d);}function _0x2a9d(_0x5e4730,_0x2b4270){_0x5e4730=_0x5e4730-0x19b;const _0x101c77=_0x101c();let _0x2a9da2=_0x101c77[_0x5e4730];return _0x2a9da2;}export function resolveProfileUrl(_0x44ca35){const _0x64565c=_0x2a9d,_0x18a9d2={'vmPBu':function(_0x18a36d,_0x759bc){return _0x18a36d(_0x759bc);},'JSNtl':function(_0x222042,_0x5f57e6,_0x3a06ca){return _0x222042(_0x5f57e6,_0x3a06ca);}},{baseUrl:_0x213f97,source:_0x2bc53c}=_0x18a9d2[_0x64565c(0x19b)](resolveBaseUrlWithSource,_0x44ca35),_0x348ad9=resolveStartPath(_0x44ca35);return{'baseUrl':_0x213f97,'baseUrlSource':_0x2bc53c,'startPath':_0x348ad9,'url':_0x18a9d2['JSNtl'](joinBaseAndPath,_0x213f97,_0x348ad9)};}function _0x101c(){const _0x4f2eda=['cloudSettings','3999210oRAduS','test','vmPBu','slice','cloud\x20profile\x20settings','projects.json\x20override','778441GoyIOS','env','900irzjUF','EXNFF','nhjJo','baseUrl','440GwyEHM','projectOverrides','envStartPath','2013Cpouzm','1824584Cpkpxf','4707899vyXxXR','QSobw','RANGER_START_PATH','sLvAq','--base-url','Tfiav','17404GsIKro','startsWith','8edZLRq','HsWDl','bCNtc','authEnvironmentDomain','228834CVuFDx','oMYck','flagStartPath','envBaseUrl'];_0x101c=function(){return _0x4f2eda;};return _0x101c();}export function readUrlEnvVars(_0x4495c3=process[_0x6a9221(0x1a0)]){const _0x2b4a0d=_0x6a9221;return{'envBaseUrl':_0x4495c3['RANGER_BASE_URL'],'envStartPath':_0x4495c3[_0x2b4a0d(0x1ac)]};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x4cb483,_0xf0207a){const _0x4dc749=_0x406f,_0x1deb1c=_0x4cb483();while(!![]){try{const _0x340c54=parseInt(_0x4dc749(0x15a))/0x1*(parseInt(_0x4dc749(0x151))/0x2)+-parseInt(_0x4dc749(0x15c))/0x3+-parseInt(_0x4dc749(0x157))/0x4+parseInt(_0x4dc749(0x15e))/0x5+parseInt(_0x4dc749(0x15d))/0x6*(-parseInt(_0x4dc749(0x152))/0x7)+-parseInt(_0x4dc749(0x153))/0x8+parseInt(_0x4dc749(0x156))/0x9;if(_0x340c54===_0xf0207a)break;else _0x1deb1c['push'](_0x1deb1c['shift']());}catch(_0x4e016d){_0x1deb1c['push'](_0x1deb1c['shift']());}}}(_0x3b2a,0x2ea1f));function _0x3b2a(){const _0x5dd684=['YqkJr','961494ERAUXN','6SQBRlm','182380YbTHGO','\x20failed\x20(attempt\x20','30mEbgkI','608426iPcGQw','1499144hQnbbP','maxRetries','label','5320962LQGbIE','406892bIsycs','pow','Butfz','17323TRNdoa'];_0x3b2a=function(){return _0x5dd684;};return _0x3b2a();}function _0x406f(_0x36e054,_0x25f921){_0x36e054=_0x36e054-0x150;const _0x3b2a8a=_0x3b2a();let _0x406fd3=_0x3b2a8a[_0x36e054];return _0x406fd3;}const DEFAULT_MAX_RETRIES=0x3,DEFAULT_BASE_DELAY_MS=0x1f4;export async function withRetry(_0x3dd5e9,_0x1cfd2b){const _0x2949dd=_0x406f,_0x3ed8c5={'tihLt':function(_0x2fc7dd,_0x521e10){return _0x2fc7dd<=_0x521e10;},'cWKKE':function(_0x167829,_0x10e591){return _0x167829 instanceof _0x10e591;},'YqkJr':function(_0x4041ee,_0x38d5e4){return _0x4041ee(_0x38d5e4);},'Butfz':function(_0x45f718,_0x2c8eca){return _0x45f718+_0x2c8eca;}},_0x186d4f=_0x1cfd2b?.[_0x2949dd(0x154)]??DEFAULT_MAX_RETRIES,_0x3d05e9=_0x1cfd2b?.['baseDelayMs']??DEFAULT_BASE_DELAY_MS;let _0x1dd1a7;for(let _0x1b8815=0x0;_0x3ed8c5['tihLt'](_0x1b8815,_0x186d4f);_0x1b8815++){try{return await _0x3dd5e9();}catch(_0xe00844){_0x1dd1a7=_0x3ed8c5['cWKKE'](_0xe00844,Error)?_0xe00844:new Error(_0x3ed8c5[_0x2949dd(0x15b)](String,_0xe00844));if(_0x1b8815<_0x186d4f){const _0x112282=_0x3d05e9*Math[_0x2949dd(0x158)](0x2,_0x1b8815);_0x1cfd2b?.[_0x2949dd(0x155)]&&console['error'](_0x1cfd2b['label']+_0x2949dd(0x150)+_0x3ed8c5[_0x2949dd(0x159)](_0x1b8815,0x1)+'/'+(_0x186d4f+0x1)+'),\x20retrying\x20in\x20'+_0x112282+'ms...'),await new Promise(_0x174daa=>setTimeout(_0x174daa,_0x112282));}}}throw _0x1dd1a7;}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x3acdc3,_0x30490b){const _0xa95374=_0x11f7,_0x146c5e=_0x3acdc3();while(!![]){try{const _0x46ca0e=-parseInt(_0xa95374(0xe3))/0x1+parseInt(_0xa95374(0xe6))/0x2+parseInt(_0xa95374(0xe7))/0x3+parseInt(_0xa95374(0xe0))/0x4*(parseInt(_0xa95374(0xdf))/0x5)+-parseInt(_0xa95374(0xde))/0x6+-parseInt(_0xa95374(0xe4))/0x7+parseInt(_0xa95374(0xe2))/0x8;if(_0x46ca0e===_0x30490b)break;else _0x146c5e['push'](_0x146c5e['shift']());}catch(_0x58e55f){_0x146c5e['push'](_0x146c5e['shift']());}}}(_0x4f33,0x54303));const ABSOLUTE_URL_PATTERN=/https?:\/\/[^\s"'<>()\[\]]+/gi;function _0x11f7(_0xe1f85e,_0x5e7798){_0xe1f85e=_0xe1f85e-0xde;const _0x4f3353=_0x4f33();let _0x11f7c4=_0x4f3353[_0xe1f85e];return _0x11f7c4;}export function extractUrlOrigins(_0xd4f2b7){const _0x1a74cf=_0x11f7,_0x5364f1=new Set();for(const _0x591a97 of _0xd4f2b7['matchAll'](ABSOLUTE_URL_PATTERN)){const _0x50f902=_0x591a97[0x0]['replace'](/[.,;:!?]+$/,'');try{_0x5364f1[_0x1a74cf(0xe5)](new URL(_0x50f902)['origin']);}catch{}}return[..._0x5364f1];}export function findScenarioOriginMismatches(_0x5df0db,_0x3031ba){const _0x11d8f0=_0x11f7;let _0x3cf323;try{_0x3cf323=new URL(_0x3031ba)[_0x11d8f0(0xe1)];}catch{return[];}return extractUrlOrigins(_0x5df0db)['filter'](_0x525736=>_0x525736!==_0x3cf323);}function _0x4f33(){const _0x251528=['755WtbxHz','2284QrmEFg','origin','5631976aTYqKi','558544OWgkcx','2871764GeIqyr','add','1002328HgxDlY','826212qNGESk','1518930cqizdf'];_0x4f33=function(){return _0x251528;};return _0x4f33();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const _0x24ffec=_0x49ac;(function(_0x3de06c,_0x1e7411){const _0x300986=_0x49ac,_0x474829=_0x3de06c();while(!![]){try{const _0x923c30=-parseInt(_0x300986(0x69))/0x1+parseInt(_0x300986(0x91))/0x2*(-parseInt(_0x300986(0x8a))/0x3)+-parseInt(_0x300986(0x7c))/0x4+parseInt(_0x300986(0x82))/0x5+-parseInt(_0x300986(0x8c))/0x6+-parseInt(_0x300986(0x88))/0x7*(-parseInt(_0x300986(0x74))/0x8)+parseInt(_0x300986(0x71))/0x9;if(_0x923c30===_0x1e7411)break;else _0x474829['push'](_0x474829['shift']());}catch(_0xe57155){_0x474829['push'](_0x474829['shift']());}}}(_0x1b8e,0xcd55e));import*as _0x363721 from'fs';import*as _0x52bc9b from'path';import*as _0x24a75c from'os';import{execSync}from'child_process';const CACHE_FILE=_0x52bc9b[_0x24ffec(0x7a)](_0x24a75c[_0x24ffec(0x83)](),'.claude','.ranger_cache.json');function createEmptyCache(){return{'version':0x3,'sessions':{},'branches':{}};}function loadCache(){const _0x325096=_0x24ffec,_0x5c5cbc={'FpqxK':function(_0x2185c4){return _0x2185c4();}};try{if(_0x363721['existsSync'](CACHE_FILE)){const _0x39b33f=JSON['parse'](_0x363721[_0x325096(0x67)](CACHE_FILE,_0x325096(0x6d)));return{'version':0x3,'sessions':_0x39b33f[_0x325096(0x6e)]||{},'branches':_0x39b33f[_0x325096(0x6b)]||{},'lastEnabledSessionClearedAt':_0x39b33f['lastEnabledSessionClearedAt']};}}catch{}return _0x5c5cbc['FpqxK'](createEmptyCache);}function saveCache(_0x2d1c5b){const _0x143723=_0x24ffec;try{const _0x9fecb1=_0x52bc9b['dirname'](CACHE_FILE);!_0x363721[_0x143723(0x89)](_0x9fecb1)&&_0x363721['mkdirSync'](_0x9fecb1,{'recursive':!![]}),_0x363721['writeFileSync'](CACHE_FILE,JSON[_0x143723(0x73)](_0x2d1c5b,null,0x2));}catch{}}export function getCurrentBranch(){const _0x10d4c2=_0x24ffec,_0x15b27e={'OYhwL':'git\x20rev-parse\x20--abbrev-ref\x20HEAD','eQwXa':'pipe'};try{const _0x38ef57=execSync(_0x15b27e['OYhwL'],{'encoding':_0x10d4c2(0x6d),'stdio':[_0x15b27e['eQwXa'],_0x10d4c2(0x78),_0x15b27e[_0x10d4c2(0x84)]]})[_0x10d4c2(0x93)]();if(!_0x38ef57||_0x38ef57===_0x10d4c2(0x70))return null;return _0x38ef57;}catch{return null;}}export function enableBranch(_0x49893e){const _0x36ba01=_0x24ffec,_0x27e0ee={'GJBeJ':function(_0x297cae){return _0x297cae();},'VZYjJ':function(_0x154380,_0x3d23dc){return _0x154380(_0x3d23dc);}},_0x11c032=_0x27e0ee[_0x36ba01(0x7b)](loadCache);_0x11c032[_0x36ba01(0x6b)][_0x49893e]=!![],_0x27e0ee['VZYjJ'](saveCache,_0x11c032);}export function disableBranch(_0x4ee243){const _0x1a81a2=_0x24ffec,_0x484c09=loadCache();delete _0x484c09[_0x1a81a2(0x6b)][_0x4ee243],saveCache(_0x484c09);}export function isBranchEnabled(_0x26b28b){const _0x11985b=_0x24ffec,_0x567874={'CtPar':function(_0x499266,_0x4fc961){return _0x499266===_0x4fc961;}},_0x3af0e6=loadCache();return _0x567874[_0x11985b(0x96)](_0x3af0e6['branches'][_0x26b28b],!![]);}function getOrCreateSession(_0x2b127c,_0x61fec0){const _0x22147f=_0x24ffec;return!_0x2b127c[_0x22147f(0x6e)][_0x61fec0]&&(_0x2b127c['sessions'][_0x61fec0]={}),_0x2b127c[_0x22147f(0x6e)][_0x61fec0];}export function enableSession(_0x32199d){const _0x591a05=_0x24ffec,_0x2e6e26={'RnOIe':function(_0x3ffda7,_0x3d33c4,_0x39bfea){return _0x3ffda7(_0x3d33c4,_0x39bfea);},'FaUBf':function(_0x349831){return _0x349831();},'vvcdn':'master'},_0x2044a8=loadCache(),_0x435324=_0x2e6e26[_0x591a05(0x87)](getOrCreateSession,_0x2044a8,_0x32199d);_0x435324[_0x591a05(0x8f)]=!![];const _0x484e94=_0x2e6e26['FaUBf'](getCurrentBranch);_0x484e94&&_0x484e94!==_0x591a05(0x8e)&&_0x484e94!==_0x2e6e26[_0x591a05(0x80)]&&(_0x2044a8[_0x591a05(0x6b)][_0x484e94]=!![],_0x435324[_0x591a05(0x90)]=_0x484e94),saveCache(_0x2044a8);}export function isSessionEnabled(_0x588dc4){const _0x29460a=_0x24ffec,_0x455edf={'ymrMP':function(_0x4646c0){return _0x4646c0();},'MKxjZ':function(_0x3a57ef,_0x1e2c8e){return _0x3a57ef===_0x1e2c8e;},'DqCay':function(_0x3791cb,_0x12c5f0){return _0x3791cb||_0x12c5f0;}},_0x5726c7=_0x455edf['ymrMP'](loadCache),_0x5326d7=getCurrentBranch();if(!_0x5326d7||_0x455edf['MKxjZ'](_0x5326d7,'main')||_0x5326d7===_0x29460a(0x6f))return _0x455edf[_0x29460a(0x6a)](_0x5726c7['sessions'][_0x588dc4]?.['enabled'],!![]);const _0x4431dc=_0x455edf[_0x29460a(0x6a)](_0x5726c7['branches'][_0x5326d7],!![]),_0x5de428=_0x455edf['MKxjZ'](_0x5726c7[_0x29460a(0x6e)][_0x588dc4]?.['enabled'],!![]);return _0x455edf['DqCay'](_0x4431dc,_0x5de428);}export function disableSession(_0x3cbff6){const _0x14e774=_0x24ffec,_0x2ba518={'xmKYt':function(_0x522d19){return _0x522d19();},'VQAWZ':function(_0x4eefc7,_0x4c81d9,_0x39fbea){return _0x4eefc7(_0x4c81d9,_0x39fbea);},'ZIwcH':function(_0x398867,_0xe7453b){return _0x398867(_0xe7453b);}},_0x593946=_0x2ba518[_0x14e774(0x86)](loadCache),_0x5cf31e=_0x2ba518['VQAWZ'](getOrCreateSession,_0x593946,_0x3cbff6);_0x5cf31e['enabled']=![],_0x2ba518['ZIwcH'](saveCache,_0x593946);}export function updateBranchTracking(_0xcdf2c4){const _0x5d7d55=_0x24ffec,_0x48dd38={'anAEz':function(_0x25a416){return _0x25a416();},'bxeoB':function(_0x2c92b0){return _0x2c92b0();},'hRofL':function(_0x3bf89e,_0x457669){return _0x3bf89e===_0x457669;},'AILHR':_0x5d7d55(0x8e),'QGrYo':function(_0xee5554,_0xa21fff){return _0xee5554(_0xa21fff);}},_0x4258a0=_0x48dd38[_0x5d7d55(0x7f)](loadCache),_0x8b8ad3=_0x4258a0[_0x5d7d55(0x6e)][_0xcdf2c4];if(!_0x8b8ad3?.['enabled'])return;const _0x26c381=_0x48dd38[_0x5d7d55(0x77)](getCurrentBranch);if(!_0x26c381||_0x48dd38[_0x5d7d55(0x75)](_0x26c381,_0x48dd38[_0x5d7d55(0x76)])||_0x48dd38[_0x5d7d55(0x75)](_0x26c381,'master'))return;_0x8b8ad3['currentBranch']!==_0x26c381&&(_0x4258a0[_0x5d7d55(0x6b)][_0x26c381]=!![],_0x8b8ad3[_0x5d7d55(0x90)]=_0x26c381,_0x48dd38[_0x5d7d55(0x66)](saveCache,_0x4258a0));}export function initBranchTracking(_0x27ea7d){const _0x27eb24=_0x24ffec,_0x39d060={'rixOx':function(_0x23d502){return _0x23d502();},'Nkyus':function(_0x5bb972,_0x33c4ca){return _0x5bb972===_0x33c4ca;},'IZUVH':_0x27eb24(0x8e),'NpFQl':function(_0x4df4e3,_0x1a847b){return _0x4df4e3(_0x1a847b);}},_0xaa656d=loadCache(),_0x2bf44f=_0x39d060[_0x27eb24(0x8b)](getCurrentBranch);if(!_0x2bf44f||_0x39d060[_0x27eb24(0x7d)](_0x2bf44f,_0x39d060['IZUVH'])||_0x2bf44f==='master')return;if(_0xaa656d[_0x27eb24(0x6b)][_0x2bf44f]===!![]){const _0xf711a2=getOrCreateSession(_0xaa656d,_0x27ea7d);_0xf711a2[_0x27eb24(0x8f)]=!![],_0xf711a2['currentBranch']=_0x2bf44f,_0x39d060[_0x27eb24(0x79)](saveCache,_0xaa656d);}}const CLEAR_AUTO_ENABLE_WINDOW_MS=0x1388;export function recordEnabledSessionCleared(_0x55d1a0){const _0x3eecaf=_0x24ffec,_0x15d603={'sFGng':function(_0x1707aa){return _0x1707aa();}},_0x17e7c1=_0x15d603['sFGng'](loadCache),_0x2560b2=_0x17e7c1['sessions'][_0x55d1a0];_0x2560b2?.['enabled']&&(_0x17e7c1['lastEnabledSessionClearedAt']=Date[_0x3eecaf(0x97)](),saveCache(_0x17e7c1));}export function shouldAutoEnableAfterClear(_0x24f896){const _0x2cde92=_0x24ffec,_0x5925fd={'bBwjr':function(_0x3e0ea4,_0x1c82ea){return _0x3e0ea4!==_0x1c82ea;},'tUlJS':function(_0x4c1aba){return _0x4c1aba();},'VZAMS':function(_0x1403bc,_0x3e3081){return _0x1403bc-_0x3e3081;}};if(_0x5925fd[_0x2cde92(0x65)](_0x24f896,'clear'))return![];const _0xf36581=_0x5925fd[_0x2cde92(0x95)](loadCache),_0x22ef98=_0xf36581['lastEnabledSessionClearedAt'];if(!_0x22ef98)return![];const _0x1bf9bc=_0x5925fd['VZAMS'](Date['now'](),_0x22ef98);return _0x1bf9bc<=CLEAR_AUTO_ENABLE_WINDOW_MS;}export function autoEnableAfterClear(_0x2f4191){const _0x34b4eb=_0x24ffec,_0x319e7e={'gXHQV':function(_0x1a6d0b,_0x140a78,_0x142b62){return _0x1a6d0b(_0x140a78,_0x142b62);},'MXhok':function(_0x203c5a){return _0x203c5a();},'UZfsX':_0x34b4eb(0x8e),'SfKbm':function(_0x2daf75,_0xac84f8){return _0x2daf75!==_0xac84f8;}},_0x3f1ca2=loadCache(),_0x45654b=_0x319e7e[_0x34b4eb(0x99)](getOrCreateSession,_0x3f1ca2,_0x2f4191);_0x45654b['enabled']=!![];const _0x47b044=_0x319e7e[_0x34b4eb(0x8d)](getCurrentBranch);_0x47b044&&_0x47b044!==_0x319e7e[_0x34b4eb(0x81)]&&_0x319e7e['SfKbm'](_0x47b044,'master')&&(_0x45654b[_0x34b4eb(0x90)]=_0x47b044),delete _0x3f1ca2['lastEnabledSessionClearedAt'],saveCache(_0x3f1ca2);}export function registerSession(_0x32102b,_0x3f4069){const _0x1e206e={'XUpyf':function(_0x1e302a){return _0x1e302a();},'oIqYu':function(_0x1ea534,_0x401ba0,_0xe03382){return _0x1ea534(_0x401ba0,_0xe03382);}},_0x42acf2=_0x1e206e['XUpyf'](loadCache),_0xe12f06=_0x1e206e['oIqYu'](getOrCreateSession,_0x42acf2,_0x32102b);_0xe12f06['featureId']=_0x3f4069,_0xe12f06['registeredAt']=new Date()['toISOString'](),saveCache(_0x42acf2);}export function getSessionEntry(_0xcb36e8){const _0x4004ad=_0x24ffec,_0x6cc45d={'wFWaF':function(_0x56e864){return _0x56e864();}},_0x2ff37d=_0x6cc45d['wFWaF'](loadCache),_0x15a614=_0x2ff37d[_0x4004ad(0x6e)][_0xcb36e8];if(_0x15a614?.[_0x4004ad(0x92)]&&_0x15a614?.[_0x4004ad(0x7e)])return{'featureId':_0x15a614['featureId'],'registeredAt':_0x15a614['registeredAt']};return null;}export function unregisterSession(_0x58c7b7){const _0x5aaa2c=_0x24ffec,_0x20065f={'cXBOI':function(_0x49d22f,_0x437e06){return _0x49d22f(_0x437e06);}},_0x4837f8=loadCache(),_0xfbd9bf=_0x4837f8['sessions'][_0x58c7b7];_0xfbd9bf&&(delete _0xfbd9bf[_0x5aaa2c(0x92)],delete _0xfbd9bf['registeredAt'],_0x20065f['cXBOI'](saveCache,_0x4837f8));}const PLAN_REMINDER_INTERVAL_MS=0x5*0x3c*0x3e8,STOP_REMINDER_INTERVAL_MS=0x5*0x3c*0x3e8;export function shouldShowPlanReminder(_0x5cbade){const _0x7d2880=_0x24ffec,_0x5632ca={'IWlWn':function(_0x4bb1bd){return _0x4bb1bd();},'yoHji':function(_0xc521b7,_0x2cd2b4){return _0xc521b7>=_0x2cd2b4;}},_0x4282ba=_0x5632ca['IWlWn'](loadCache),_0x5be0b2=getOrCreateSession(_0x4282ba,_0x5cbade),_0x19ef51=_0x5be0b2[_0x7d2880(0x94)]||0x0,_0x448006=Date[_0x7d2880(0x97)]();if(_0x5632ca['yoHji'](_0x448006-_0x19ef51,PLAN_REMINDER_INTERVAL_MS))return _0x5be0b2['lastPlanReminderAt']=_0x448006,saveCache(_0x4282ba),!![];return![];}function _0x1b8e(){const _0x593527=['AILHR','bxeoB','pipe','NpFQl','join','GJBeJ','6701228izpVsV','Nkyus','registeredAt','anAEz','vvcdn','UZfsX','7183510QNaIiQ','homedir','eQwXa','CmgwV','xmKYt','RnOIe','791QAHSHT','existsSync','3VGulkz','rixOx','6675924BLwSgG','MXhok','main','enabled','currentBranch','247602eyOOXN','featureId','trim','lastPlanReminderAt','tUlJS','CtPar','now','HVbDQ','gXHQV','OdtAb','bBwjr','QGrYo','readFileSync','lastStopReminderAt','1627441RxpxUn','MKxjZ','branches','prompted','utf-8','sessions','master','HEAD','23431392KWkbfW','WEmJc','stringify','94872DtERow','hRofL'];_0x1b8e=function(){return _0x593527;};return _0x1b8e();}export function shouldShowStopReminder(_0x4f8c30){const _0x5de0d1=_0x24ffec,_0xe0834c={'OiXLL':function(_0x332f17){return _0x332f17();},'TqWRy':function(_0x26fb25,_0x32f5f6,_0x197401){return _0x26fb25(_0x32f5f6,_0x197401);},'OdtAb':function(_0x16cdb2,_0x35f83d){return _0x16cdb2(_0x35f83d);}},_0x59536a=_0xe0834c['OiXLL'](loadCache),_0x5027ef=_0xe0834c['TqWRy'](getOrCreateSession,_0x59536a,_0x4f8c30),_0x24c1d0=_0x5027ef['lastStopReminderAt']||0x0,_0x12a356=Date[_0x5de0d1(0x97)]();if(_0x12a356-_0x24c1d0>=STOP_REMINDER_INTERVAL_MS)return _0x5027ef[_0x5de0d1(0x68)]=_0x12a356,_0xe0834c[_0x5de0d1(0x9a)](saveCache,_0x59536a),!![];return![];}function _0x49ac(_0x4ca607,_0x37dd0b){_0x4ca607=_0x4ca607-0x65;const _0x1b8e99=_0x1b8e();let _0x49ace4=_0x1b8e99[_0x4ca607];return _0x49ace4;}export function hasSessionBeenPrompted(_0x22ea22){const _0x8566e2=_0x24ffec,_0xc68cb8={'VBeeA':function(_0x30b300){return _0x30b300();},'WEmJc':function(_0x1885d8,_0x5b971d){return _0x1885d8===_0x5b971d;}},_0x5f1e45=_0xc68cb8['VBeeA'](loadCache);return _0xc68cb8[_0x8566e2(0x72)](_0x5f1e45[_0x8566e2(0x6e)][_0x22ea22]?.['prompted'],!![]);}export function markSessionPrompted(_0x150861){const _0x3804dd=_0x24ffec,_0x1e1ceb={'CmgwV':function(_0x72a3a8){return _0x72a3a8();},'sNaNR':function(_0x3036b6,_0x2217c6,_0xd5a0bd){return _0x3036b6(_0x2217c6,_0xd5a0bd);},'HVbDQ':function(_0x1d7fd0,_0x5c32f0){return _0x1d7fd0(_0x5c32f0);}},_0x367912=_0x1e1ceb[_0x3804dd(0x85)](loadCache),_0x2052a8=_0x1e1ceb['sNaNR'](getOrCreateSession,_0x367912,_0x150861);_0x2052a8[_0x3804dd(0x6c)]=!![],_0x1e1ceb[_0x3804dd(0x98)](saveCache,_0x367912);}export function getCacheFile(){return CACHE_FILE;}
|
|
1
|
+
const _0x5d81ba=_0x1186;(function(_0x154e22,_0x1a21e2){const _0x1a6444=_0x1186,_0x25e3fb=_0x154e22();while(!![]){try{const _0x301894=parseInt(_0x1a6444(0xeb))/0x1+-parseInt(_0x1a6444(0xfb))/0x2+parseInt(_0x1a6444(0x104))/0x3+parseInt(_0x1a6444(0xfc))/0x4+-parseInt(_0x1a6444(0xf2))/0x5*(parseInt(_0x1a6444(0xf5))/0x6)+-parseInt(_0x1a6444(0xe5))/0x7+-parseInt(_0x1a6444(0xee))/0x8;if(_0x301894===_0x1a21e2)break;else _0x25e3fb['push'](_0x25e3fb['shift']());}catch(_0xfa3a1b){_0x25e3fb['push'](_0x25e3fb['shift']());}}}(_0x21b5,0x3c0f7));import*as _0x3cee18 from'fs';import*as _0x84a647 from'path';import*as _0x4d634e from'os';import{execSync}from'child_process';const CACHE_FILE=_0x84a647[_0x5d81ba(0xed)](_0x4d634e['homedir'](),_0x5d81ba(0xf3),_0x5d81ba(0x10e));function createEmptyCache(){return{'version':0x3,'sessions':{},'branches':{}};}function loadCache(){const _0x48d2e3=_0x5d81ba,_0xf88fe7={'PwsbN':function(_0x553b6d){return _0x553b6d();}};try{if(_0x3cee18[_0x48d2e3(0xff)](CACHE_FILE)){const _0xfe835=JSON['parse'](_0x3cee18['readFileSync'](CACHE_FILE,'utf-8'));return{'version':0x3,'sessions':_0xfe835['sessions']||{},'branches':_0xfe835['branches']||{},'lastEnabledSessionClearedAt':_0xfe835['lastEnabledSessionClearedAt']};}}catch{}return _0xf88fe7[_0x48d2e3(0x116)](createEmptyCache);}function saveCache(_0x454382){const _0x5d4a5e=_0x5d81ba;try{const _0x3a3fb=_0x84a647[_0x5d4a5e(0xfa)](CACHE_FILE);!_0x3cee18['existsSync'](_0x3a3fb)&&_0x3cee18[_0x5d4a5e(0x10f)](_0x3a3fb,{'recursive':!![]}),_0x3cee18[_0x5d4a5e(0xf4)](CACHE_FILE,JSON['stringify'](_0x454382,null,0x2));}catch{}}export function getCurrentBranch(){const _0x1e13dc=_0x5d81ba,_0x5c8738={'RCrVQ':_0x1e13dc(0x115),'CoTdg':function(_0x3103d4,_0x4d61f5){return _0x3103d4===_0x4d61f5;},'CulxK':_0x1e13dc(0x112)};try{const _0xec7d35=execSync(_0x1e13dc(0xef),{'encoding':_0x1e13dc(0xf8),'stdio':['pipe',_0x5c8738[_0x1e13dc(0xe9)],_0x1e13dc(0x115)]})[_0x1e13dc(0x101)]();if(!_0xec7d35||_0x5c8738[_0x1e13dc(0xe8)](_0xec7d35,_0x5c8738[_0x1e13dc(0xf6)]))return null;return _0xec7d35;}catch{return null;}}export function enableBranch(_0x5e869e){const _0x2d88b7=_0x5d81ba,_0x49a82e={'AWrgw':function(_0x2423cd){return _0x2423cd();}},_0x13cb67=_0x49a82e[_0x2d88b7(0xea)](loadCache);_0x13cb67['branches'][_0x5e869e]=!![],saveCache(_0x13cb67);}function _0x21b5(){const _0x1539fd=['HmDTj','registeredAt','branches','.ranger_cache.json','mkdirSync','featureId','pgUJP','HEAD','pRERv','mtAIF','pipe','PwsbN','DPALb','CXXbr','now','Mwfuz','1032913wGGQWO','lastStopReminderAt','jFAhv','CoTdg','RCrVQ','AWrgw','424512AXSHUk','PLJQr','join','1144960zUZvpW','git\x20rev-parse\x20--abbrev-ref\x20HEAD','aKpoK','CcQrR','5665Ciweqm','.claude','writeFileSync','1038MkcWhy','CulxK','master','utf-8','enabled','dirname','928998FqVQjP','1695192KncChq','ydccl','currentBranch','existsSync','wjYjq','trim','azcSy','main','1046652vzxYzv','lastEnabledSessionClearedAt','MWAIG','sessions','BDACf','PBuGn','OiHQj'];_0x21b5=function(){return _0x1539fd;};return _0x21b5();}export function disableBranch(_0x145764){const _0x50718a=_0x5d81ba,_0x650e42={'mUfdw':function(_0x23df73){return _0x23df73();}},_0x51d1c9=_0x650e42['mUfdw'](loadCache);delete _0x51d1c9[_0x50718a(0x10d)][_0x145764],saveCache(_0x51d1c9);}function _0x1186(_0x2e7bfc,_0x404319){_0x2e7bfc=_0x2e7bfc-0xe5;const _0x21b5ae=_0x21b5();let _0x118662=_0x21b5ae[_0x2e7bfc];return _0x118662;}export function isBranchEnabled(_0xa02aa3){const _0x43aca6=_0x5d81ba,_0x103152=loadCache();return _0x103152[_0x43aca6(0x10d)][_0xa02aa3]===!![];}function getOrCreateSession(_0x22d837,_0x146a87){const _0xd8008e=_0x5d81ba;return!_0x22d837[_0xd8008e(0x107)][_0x146a87]&&(_0x22d837['sessions'][_0x146a87]={}),_0x22d837['sessions'][_0x146a87];}export function enableSession(_0x2b0367){const _0x4009b8=_0x5d81ba,_0x38df17={'DPALb':function(_0x1a8f70){return _0x1a8f70();},'DGmEi':function(_0x2b020c,_0x18e96a,_0x5b9773){return _0x2b020c(_0x18e96a,_0x5b9773);},'OiHQj':_0x4009b8(0x103),'aKpoK':function(_0x45bd4e,_0x15de7e){return _0x45bd4e!==_0x15de7e;}},_0x2a35a4=_0x38df17['DPALb'](loadCache),_0x116243=_0x38df17['DGmEi'](getOrCreateSession,_0x2a35a4,_0x2b0367);_0x116243[_0x4009b8(0xf9)]=!![];const _0x317b4e=_0x38df17[_0x4009b8(0x117)](getCurrentBranch);_0x317b4e&&_0x317b4e!==_0x38df17[_0x4009b8(0x10a)]&&_0x38df17[_0x4009b8(0xf0)](_0x317b4e,_0x4009b8(0xf7))&&(_0x2a35a4['branches'][_0x317b4e]=!![],_0x116243['currentBranch']=_0x317b4e),saveCache(_0x2a35a4);}export function isSessionEnabled(_0xa3da3b){const _0x26bde8=_0x5d81ba,_0x296ce4={'LjmPm':function(_0x10761b){return _0x10761b();},'HHTBi':_0x26bde8(0x103),'PLJQr':_0x26bde8(0xf7),'HmDTj':function(_0x8c3c5d,_0x2830df){return _0x8c3c5d===_0x2830df;},'qMxba':function(_0x5f3e48,_0x455802){return _0x5f3e48||_0x455802;}},_0x1e05cd=loadCache(),_0x442cd7=_0x296ce4['LjmPm'](getCurrentBranch);if(!_0x442cd7||_0x442cd7===_0x296ce4['HHTBi']||_0x442cd7===_0x296ce4[_0x26bde8(0xec)])return _0x296ce4[_0x26bde8(0x10b)](_0x1e05cd['sessions'][_0xa3da3b]?.[_0x26bde8(0xf9)],!![]);const _0x264bce=_0x1e05cd['branches'][_0x442cd7]===!![],_0x5e90fa=_0x1e05cd['sessions'][_0xa3da3b]?.['enabled']===!![];return _0x296ce4['qMxba'](_0x264bce,_0x5e90fa);}export function disableSession(_0x2ee8a4){const _0x7d0539=_0x5d81ba,_0x38f2dd={'ydccl':function(_0x2ab5ab){return _0x2ab5ab();},'veinV':function(_0x3d02eb,_0x21af82,_0x5de278){return _0x3d02eb(_0x21af82,_0x5de278);}},_0x40fd3d=_0x38f2dd[_0x7d0539(0xfd)](loadCache),_0x19aa3f=_0x38f2dd['veinV'](getOrCreateSession,_0x40fd3d,_0x2ee8a4);_0x19aa3f[_0x7d0539(0xf9)]=![],saveCache(_0x40fd3d);}export function updateBranchTracking(_0x409c0e){const _0x12a99b=_0x5d81ba,_0x195388={'ZswVm':function(_0x47bac5){return _0x47bac5();},'MObVk':function(_0xdad4dd,_0x57cc56){return _0xdad4dd===_0x57cc56;}},_0x494525=loadCache(),_0x51dd87=_0x494525['sessions'][_0x409c0e];if(!_0x51dd87?.[_0x12a99b(0xf9)])return;const _0x3135e1=_0x195388['ZswVm'](getCurrentBranch);if(!_0x3135e1||_0x195388['MObVk'](_0x3135e1,'main')||_0x195388['MObVk'](_0x3135e1,'master'))return;_0x51dd87[_0x12a99b(0xfe)]!==_0x3135e1&&(_0x494525['branches'][_0x3135e1]=!![],_0x51dd87[_0x12a99b(0xfe)]=_0x3135e1,saveCache(_0x494525));}export function initBranchTracking(_0xe8272f){const _0xa36c01=_0x5d81ba,_0x5262df={'cjdim':function(_0x27a0e2){return _0x27a0e2();},'pRERv':function(_0x4838c5,_0xa0d652){return _0x4838c5===_0xa0d652;},'azcSy':'master','vmaHz':function(_0xa62e33,_0x5cbf90){return _0xa62e33(_0x5cbf90);}},_0x37ee3a=loadCache(),_0x5b809b=_0x5262df['cjdim'](getCurrentBranch);if(!_0x5b809b||_0x5b809b===_0xa36c01(0x103)||_0x5262df[_0xa36c01(0x113)](_0x5b809b,_0x5262df[_0xa36c01(0x102)]))return;if(_0x37ee3a['branches'][_0x5b809b]===!![]){const _0x409506=getOrCreateSession(_0x37ee3a,_0xe8272f);_0x409506['enabled']=!![],_0x409506['currentBranch']=_0x5b809b,_0x5262df['vmaHz'](saveCache,_0x37ee3a);}}const CLEAR_AUTO_ENABLE_WINDOW_MS=0x1388;export function recordEnabledSessionCleared(_0x953da5){const _0x30a1c7=_0x5d81ba,_0x495f74={'CcQrR':function(_0x6502c8){return _0x6502c8();}},_0x14a78c=_0x495f74[_0x30a1c7(0xf1)](loadCache),_0x48913b=_0x14a78c['sessions'][_0x953da5];_0x48913b?.[_0x30a1c7(0xf9)]&&(_0x14a78c[_0x30a1c7(0x105)]=Date['now'](),saveCache(_0x14a78c));}export function shouldAutoEnableAfterClear(_0x187bb4){const _0x3673e6={'Jopno':function(_0x44fe36){return _0x44fe36();},'EUeCS':function(_0x329761,_0x14c73d){return _0x329761-_0x14c73d;}};if(_0x187bb4!=='clear')return![];const _0x2b1de6=_0x3673e6['Jopno'](loadCache),_0x1fa61b=_0x2b1de6['lastEnabledSessionClearedAt'];if(!_0x1fa61b)return![];const _0x5db982=_0x3673e6['EUeCS'](Date['now'](),_0x1fa61b);return _0x5db982<=CLEAR_AUTO_ENABLE_WINDOW_MS;}export function autoEnableAfterClear(_0x3b3ac0){const _0x3cf439=_0x5d81ba,_0x3b135d={'pgUJP':function(_0x9a00e7){return _0x9a00e7();},'RKdbZ':function(_0x4d7062,_0x3f482d){return _0x4d7062!==_0x3f482d;},'Mwfuz':'master'},_0x4acf91=loadCache(),_0x368154=getOrCreateSession(_0x4acf91,_0x3b3ac0);_0x368154['enabled']=!![];const _0x489e8b=_0x3b135d[_0x3cf439(0x111)](getCurrentBranch);_0x489e8b&&_0x3b135d['RKdbZ'](_0x489e8b,'main')&&_0x489e8b!==_0x3b135d[_0x3cf439(0x11a)]&&(_0x368154[_0x3cf439(0xfe)]=_0x489e8b),delete _0x4acf91[_0x3cf439(0x105)],saveCache(_0x4acf91);}export function registerSession(_0x405008,_0x50fdc8){const _0x54308f=_0x5d81ba,_0x336d65={'UimuF':function(_0x48b512){return _0x48b512();},'GOOzR':function(_0x19a5fa,_0x347f51,_0x2f1fcf){return _0x19a5fa(_0x347f51,_0x2f1fcf);}},_0x47e9b1=_0x336d65['UimuF'](loadCache),_0x4a5773=_0x336d65['GOOzR'](getOrCreateSession,_0x47e9b1,_0x405008);_0x4a5773['featureId']=_0x50fdc8,_0x4a5773[_0x54308f(0x10c)]=new Date()['toISOString'](),saveCache(_0x47e9b1);}export function getSessionEntry(_0x48eb59){const _0x1d42b7=_0x5d81ba,_0x41f5a2=loadCache(),_0x279973=_0x41f5a2[_0x1d42b7(0x107)][_0x48eb59];if(_0x279973?.['featureId']&&_0x279973?.[_0x1d42b7(0x10c)])return{'featureId':_0x279973[_0x1d42b7(0x110)],'registeredAt':_0x279973[_0x1d42b7(0x10c)]};return null;}export function unregisterSession(_0x458b13){const _0x17daa5=_0x5d81ba,_0x569f2a={'jFAhv':function(_0x1ec3da){return _0x1ec3da();}},_0x23346f=_0x569f2a[_0x17daa5(0xe7)](loadCache),_0xdb837f=_0x23346f[_0x17daa5(0x107)][_0x458b13];_0xdb837f&&(delete _0xdb837f['featureId'],delete _0xdb837f['registeredAt'],saveCache(_0x23346f));}const PLAN_REMINDER_INTERVAL_MS=0x5*0x3c*0x3e8,STOP_REMINDER_INTERVAL_MS=0x5*0x3c*0x3e8;export function shouldShowPlanReminder(_0x47105c){const _0x4ab5bf=_0x5d81ba,_0x46391a={'isAGM':function(_0x5f01c1){return _0x5f01c1();},'BDACf':function(_0x320fcb,_0x1a45c6,_0x5b1858){return _0x320fcb(_0x1a45c6,_0x5b1858);},'PBuGn':function(_0x18a7f5,_0x340dfa){return _0x18a7f5-_0x340dfa;},'nsQGa':function(_0x1060b5,_0x26cabf){return _0x1060b5(_0x26cabf);}},_0x5044af=_0x46391a['isAGM'](loadCache),_0x23bfdc=_0x46391a[_0x4ab5bf(0x108)](getOrCreateSession,_0x5044af,_0x47105c),_0x55957a=_0x23bfdc['lastPlanReminderAt']||0x0,_0xff65ae=Date[_0x4ab5bf(0x119)]();if(_0x46391a[_0x4ab5bf(0x109)](_0xff65ae,_0x55957a)>=PLAN_REMINDER_INTERVAL_MS)return _0x23bfdc['lastPlanReminderAt']=_0xff65ae,_0x46391a['nsQGa'](saveCache,_0x5044af),!![];return![];}export function shouldShowStopReminder(_0x3477d7){const _0x183aa5=_0x5d81ba,_0x850a31={'wjYjq':function(_0x578864,_0x9b968a,_0x2c477e){return _0x578864(_0x9b968a,_0x2c477e);},'vCGKQ':function(_0x41f07f,_0x2cfeaa){return _0x41f07f>=_0x2cfeaa;},'XmWsU':function(_0x2ea3ea,_0x1e38a4){return _0x2ea3ea-_0x1e38a4;},'mtAIF':function(_0x334799,_0x2521c5){return _0x334799(_0x2521c5);}},_0x1c79a1=loadCache(),_0x595e82=_0x850a31[_0x183aa5(0x100)](getOrCreateSession,_0x1c79a1,_0x3477d7),_0x3ca618=_0x595e82['lastStopReminderAt']||0x0,_0x35419d=Date[_0x183aa5(0x119)]();if(_0x850a31['vCGKQ'](_0x850a31['XmWsU'](_0x35419d,_0x3ca618),STOP_REMINDER_INTERVAL_MS))return _0x595e82[_0x183aa5(0xe6)]=_0x35419d,_0x850a31[_0x183aa5(0x114)](saveCache,_0x1c79a1),!![];return![];}export function hasSessionBeenPrompted(_0x2489ac){const _0x2151e2=_0x5d81ba,_0x1adebe={'YSpcw':function(_0x2e2930){return _0x2e2930();}},_0x2748a6=_0x1adebe['YSpcw'](loadCache);return _0x2748a6[_0x2151e2(0x107)][_0x2489ac]?.['prompted']===!![];}export function markSessionPrompted(_0x26a0cb){const _0xeeed78=_0x5d81ba,_0x399f8b={'CXXbr':function(_0x239a0e){return _0x239a0e();},'MWAIG':function(_0x41a06a,_0x589f64,_0xa89671){return _0x41a06a(_0x589f64,_0xa89671);}},_0x44cb16=_0x399f8b[_0xeeed78(0x118)](loadCache),_0x5b3d27=_0x399f8b[_0xeeed78(0x106)](getOrCreateSession,_0x44cb16,_0x26a0cb);_0x5b3d27['prompted']=!![],saveCache(_0x44cb16);}export function getCacheFile(){return CACHE_FILE;}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const _0x257913=_0x3583;(function(_0x3dcf56,_0x4b75b7){const _0x2bae39=_0x3583,_0xb289ba=_0x3dcf56();while(!![]){try{const _0x1ec3fb=parseInt(_0x2bae39(0x213))/0x1*(-parseInt(_0x2bae39(0x1fe))/0x2)+-parseInt(_0x2bae39(0x1f8))/0x3*(-parseInt(_0x2bae39(0x222))/0x4)+parseInt(_0x2bae39(0x235))/0x5*(-parseInt(_0x2bae39(0x205))/0x6)+parseInt(_0x2bae39(0x245))/0x7+-parseInt(_0x2bae39(0x1d0))/0x8*(parseInt(_0x2bae39(0x1d6))/0x9)+parseInt(_0x2bae39(0x1f7))/0xa+parseInt(_0x2bae39(0x1dd))/0xb;if(_0x1ec3fb===_0x4b75b7)break;else _0xb289ba['push'](_0xb289ba['shift']());}catch(_0x9afe6b){_0xb289ba['push'](_0xb289ba['shift']());}}}(_0x1cbe,0xda2c3));import{readFile,writeFile,mkdir,unlink}from'fs/promises';import{join,dirname}from'path';import{existsSync}from'fs';import{tmpdir}from'os';import{randomUUID}from'crypto';import{chromium}from'playwright';import{decrypt}from'./crypto.js';import{getToken}from'./keychain.js';import{getRangerDir,getRangerHomeDir}from'./rangerRoot.js';function findEnvInRoot(_0x1895b8,_0x51d39f){const _0x4fea5c=_0x3583,_0x9acb92={'nfdaz':function(_0x26fad0,_0x162e4c,_0x2cb8e0){return _0x26fad0(_0x162e4c,_0x2cb8e0);},'GMlaB':function(_0x7187cc,_0x498789){return _0x7187cc(_0x498789);},'HtrxP':function(_0x281559,_0x319cb3){return _0x281559!==_0x319cb3;},'mvtIj':function(_0x2789cd,_0x41ab2d){return _0x2789cd(_0x41ab2d);}},_0x152c21=join(_0x51d39f,'ci',_0x1895b8),_0x5109bd=join(_0x51d39f,_0x4fea5c(0x201),_0x1895b8),_0x10f3e2=_0x9acb92[_0x4fea5c(0x1f0)](join,_0x51d39f,_0x1895b8),_0x3a7b29=join(_0x51d39f,_0x4fea5c(0x201)),_0x2b4df3=join(_0x51d39f,'ci');if(existsSync(_0x152c21))return _0x152c21;if(_0x9acb92['GMlaB'](existsSync,_0x5109bd))return _0x5109bd;if(existsSync(_0x10f3e2)&&(_0x9acb92['HtrxP'](_0x10f3e2,_0x3a7b29)&&_0x10f3e2!==_0x2b4df3?!![]:_0x9acb92['mvtIj'](hasLegacyProfileFiles,_0x10f3e2)))return _0x10f3e2;return null;}export function getEnvDir(_0x4d9e81,_0x1d01b5={}){const _0x3c6f7d=_0x3583,_0x1df703={'iboCF':function(_0x1c5604){return _0x1c5604();},'qBWsm':function(_0x3eb3da,_0x393740,_0x51d158){return _0x3eb3da(_0x393740,_0x51d158);},'SxmFT':_0x3c6f7d(0x201)},_0x5515ad=_0x1df703[_0x3c6f7d(0x215)](getRangerDir),_0x3942d6=findEnvInRoot(_0x4d9e81,_0x5515ad);if(_0x3942d6){if(_0x1d01b5['forWrite']&&isLegacyEnvPath(_0x3942d6))throw _0x1df703['qBWsm'](legacyWriteError,_0x4d9e81,_0x3942d6);return _0x3942d6;}const _0x48245b=getRangerHomeDir();if(_0x48245b!==_0x5515ad){const _0x217ee4=findEnvInRoot(_0x4d9e81,_0x48245b);if(_0x217ee4){if(_0x1d01b5['forWrite']&&isLegacyEnvPath(_0x217ee4))throw _0x1df703['qBWsm'](legacyWriteError,_0x4d9e81,_0x217ee4);return _0x217ee4;}}const _0x5bee5e=join(_0x48245b,_0x1df703['SxmFT'],_0x4d9e81);if(_0x1d01b5[_0x3c6f7d(0x1e1)])throw legacyWriteError(_0x4d9e81,_0x5bee5e);return _0x5bee5e;}function isLegacyEnvPath(_0xc27b31){const _0x358267={'HBzhp':function(_0x24c1b0){return _0x24c1b0();}},_0x33fe77=_0x358267['HBzhp'](getRangerDir),_0x295b1d=getRangerHomeDir();for(const _0x56f38f of new Set([_0x33fe77,_0x295b1d])){const _0x5a3fd5=_0x56f38f['endsWith']('/')?_0x56f38f:_0x56f38f+'/';if(_0xc27b31===_0x56f38f||_0xc27b31['startsWith'](_0x5a3fd5))return!![];}return![];}function legacyWriteError(_0x35fdd6,_0xf96e8f){const _0x1ccb62=_0x3583,_0x1b3270={'qkIUD':function(_0x555aec,_0xf28f8c){return _0x555aec+_0xf28f8c;}};return new Error(_0x1b3270['qkIUD'](_0x1b3270[_0x1ccb62(0x23b)]('Refusing\x20to\x20write\x20profile\x20\x22'+_0x35fdd6+_0x1ccb62(0x236)+_0xf96e8f+'.\x0a'+_0x1ccb62(0x1d5),_0x1ccb62(0x241)),_0x1ccb62(0x1cb)));}export function findExistingEnv(_0x363326,_0x4ae696){const _0x10b744=_0x3583,_0x580ad1={'tDObf':function(_0x5c5be6){return _0x5c5be6();},'dsFGV':_0x10b744(0x201),'umIpM':'legacy','JaabB':function(_0x11e524,_0x4b478a,_0x1d7627,_0x3c169f){return _0x11e524(_0x4b478a,_0x1d7627,_0x3c169f);},'jqTRo':function(_0x19c26f,_0x2dce5b){return _0x19c26f(_0x2dce5b);},'bMXAI':function(_0x1d5325,_0x6e3c63){return _0x1d5325===_0x6e3c63;},'Zjide':function(_0x150d9f,_0x3f2c29){return _0x150d9f===_0x3f2c29;},'YIdcP':function(_0x4f4f65,_0x46aa66){return _0x4f4f65===_0x46aa66;}},_0x450fc8=_0x4ae696?.[_0x10b744(0x22b)],_0x160a5a=_0x450fc8?[_0x450fc8]:[_0x580ad1['tDObf'](getRangerDir),getRangerHomeDir()]['filter']((_0x4042ea,_0x1fd634,_0x3b62a4)=>_0x3b62a4['indexOf'](_0x4042ea)===_0x1fd634),_0x305e67=_0x4ae696?.[_0x10b744(0x1e3)]??['ci',_0x580ad1['dsFGV'],_0x580ad1[_0x10b744(0x23c)]];for(const _0x2b7a7f of _0x160a5a){const _0x52d08a=join(_0x2b7a7f,'local'),_0x11d302=join(_0x2b7a7f,'ci'),_0x120702=[{'location':'ci','path':join(_0x2b7a7f,'ci',_0x363326)},{'location':'local','path':_0x580ad1['JaabB'](join,_0x2b7a7f,'local',_0x363326)},{'location':_0x580ad1[_0x10b744(0x23c)],'path':join(_0x2b7a7f,_0x363326)}];for(const _0x47b388 of _0x120702){if(_0x305e67['includes'](_0x47b388['location'])&&_0x580ad1[_0x10b744(0x1de)](existsSync,_0x47b388[_0x10b744(0x1f5)])){if(_0x580ad1[_0x10b744(0x1cf)](_0x47b388['location'],_0x580ad1['umIpM'])&&(_0x580ad1['Zjide'](_0x47b388['path'],_0x52d08a)||_0x580ad1[_0x10b744(0x1d4)](_0x47b388[_0x10b744(0x1f5)],_0x11d302))&&!_0x580ad1[_0x10b744(0x1de)](hasLegacyProfileFiles,_0x47b388[_0x10b744(0x1f5)]))continue;return{'path':_0x47b388['path'],'location':_0x47b388['location']};}}}return null;}function hasLegacyProfileFiles(_0x1582aa){const _0x411678=_0x3583,_0x30c3b3={'RTjtq':function(_0xf89195,_0xe58ee5,_0x197347){return _0xf89195(_0xe58ee5,_0x197347);},'xOZYE':_0x411678(0x231),'zEPuI':'auth.json.enc'};return existsSync(_0x30c3b3[_0x411678(0x243)](join,_0x1582aa,_0x30c3b3['xOZYE']))||existsSync(_0x30c3b3['RTjtq'](join,_0x1582aa,'auth.json'))||existsSync(_0x30c3b3[_0x411678(0x243)](join,_0x1582aa,_0x30c3b3['zEPuI']));}export function isEnvCi(_0x3980b2){const _0x5c0957=_0x3583,_0x26d7d4={'rlHUQ':function(_0x4bed4c){return _0x4bed4c();},'DxfCV':function(_0x6a1d82,_0x1c06af,_0x2a5ae3,_0x564be2){return _0x6a1d82(_0x1c06af,_0x2a5ae3,_0x564be2);}};if(existsSync(join(getRangerDir(),'ci',_0x3980b2)))return!![];const _0x37e0f4=_0x26d7d4[_0x5c0957(0x233)](getRangerHomeDir);if(_0x37e0f4!==getRangerDir()&&existsSync(_0x26d7d4[_0x5c0957(0x22a)](join,_0x37e0f4,'ci',_0x3980b2)))return!![];return![];}export async function cleanupTempFiles(_0x44ba9e){const _0x4d610d=_0x3583,_0x2a43ea={'awdrl':function(_0x19f8dc,_0x5851c7){return _0x19f8dc!==_0x5851c7;}},_0x44c1ad=[_0x44ba9e[_0x4d610d(0x1df)],_0x44ba9e['configPath']][_0x4d610d(0x20d)](Boolean);await Promise[_0x4d610d(0x1e2)](_0x44c1ad['map'](_0x529dd1=>unlink(_0x529dd1)[_0x4d610d(0x23a)](_0x1c4473=>{const _0x421cb2=_0x4d610d;_0x2a43ea[_0x421cb2(0x1d7)](_0x1c4473[_0x421cb2(0x1e4)],_0x421cb2(0x230))&&console[_0x421cb2(0x209)]('Failed\x20to\x20clean\x20up\x20temp\x20file\x20'+_0x529dd1+':',_0x1c4473['message']);})));}export function getSettingsPath(_0x9a57b5){const _0x32f3c3=_0x3583,_0x4ec807={'ziuWU':function(_0x39b478,_0x45e894,_0x5eca45){return _0x39b478(_0x45e894,_0x5eca45);},'FmIbe':function(_0x241caa,_0x2f51f9){return _0x241caa(_0x2f51f9);},'KWOQn':'settings.json'};return _0x4ec807['ziuWU'](join,_0x4ec807[_0x32f3c3(0x212)](getEnvDir,_0x9a57b5),_0x4ec807['KWOQn']);}export async function loadSettings(_0x2d6217){const _0x59bd04=_0x3583,_0x362b27={'unJsH':function(_0xaad51b,_0x1614a9){return _0xaad51b(_0x1614a9);},'ItDoq':_0x59bd04(0x207)},_0x491c90=_0x362b27['unJsH'](getSettingsPath,_0x2d6217);if(!existsSync(_0x491c90))return{};try{const _0xfea052=await readFile(_0x491c90,_0x362b27[_0x59bd04(0x228)]);return JSON['parse'](_0xfea052);}catch{return{};}}export async function saveSettings(_0x961cf7,_0x46074b){const _0x4c9db9={'dVTry':function(_0x1d9623,_0x5db1b0){return _0x1d9623(_0x5db1b0);},'VbfDW':function(_0x2c8fe4,_0x3546fa,_0x422a46){return _0x2c8fe4(_0x3546fa,_0x422a46);}},_0x29db72=getSettingsPath(_0x961cf7),_0x5e4ee1=dirname(_0x29db72);!_0x4c9db9['dVTry'](existsSync,_0x5e4ee1)&&await _0x4c9db9['VbfDW'](mkdir,_0x5e4ee1,{'recursive':!![]}),await writeFile(_0x29db72,JSON['stringify'](_0x46074b,null,0x2));}export function resolveEnvVars(_0x22d62a){const _0x90f5cb=_0x3583,_0x5465cc={'mNkXY':'object'};if(typeof _0x22d62a==='string')return _0x22d62a[_0x90f5cb(0x1d2)](/\$\{(\w+)\}/g,(_0x3ff302,_0x165a2c)=>{const _0x1883da=_0x90f5cb,_0x43550c=process['env'][_0x165a2c];if(_0x43550c===undefined)throw new Error(_0x1883da(0x1f3)+_0x165a2c+_0x1883da(0x1fd));return _0x43550c;});if(Array['isArray'](_0x22d62a))return _0x22d62a['map'](resolveEnvVars);if(_0x22d62a&&typeof _0x22d62a===_0x5465cc['mNkXY'])return Object[_0x90f5cb(0x208)](Object[_0x90f5cb(0x1d1)](_0x22d62a)[_0x90f5cb(0x1d8)](([_0x479768,_0x1c8df1])=>[_0x479768,resolveEnvVars(_0x1c8df1)]));return _0x22d62a;}const isRecord=_0x7ec5f5=>typeof _0x7ec5f5===_0x257913(0x1e5)&&_0x7ec5f5!==null&&!Array[_0x257913(0x1c7)](_0x7ec5f5),asRecord=_0x28d175=>isRecord(_0x28d175)?_0x28d175:undefined,mergeHeaders=(_0x541fda,_0x3d0776)=>{const _0x1b93f3=_0x257913,_0x118d34={'bTMEF':function(_0x4f98e5,_0x44d476){return _0x4f98e5??_0x44d476;}},_0x343546={..._0x541fda??{},..._0x118d34['bTMEF'](_0x3d0776,{})};return Object[_0x1b93f3(0x1f6)](_0x343546)[_0x1b93f3(0x239)]?_0x343546:undefined;},SAFE_MODE_ARGS=[_0x257913(0x223)],ALLOW_LOCALHOST_ARGS=['--disable-web-security','--allow-running-insecure-content',_0x257913(0x1e6),_0x257913(0x1e0)];export function buildBrowserOptionsFromSettings(_0xc5d4ef,_0x106e07={}){const _0x330484=_0x257913,_0x44468f={'XiFUU':function(_0x1617d7,_0x122229){return _0x1617d7===_0x122229;},'lswgJ':'boolean','TlKxx':function(_0x3fe64e,_0x11fb33){return _0x3fe64e(_0x11fb33);},'cvrai':'string','OLkMP':function(_0x450ebb,_0xd07bd2,_0x18e8f2){return _0x450ebb(_0xd07bd2,_0x18e8f2);},'VnVcj':function(_0x1e8506,_0x17750b){return _0x1e8506(_0x17750b);}},_0x1d1f8b=asRecord(_0xc5d4ef['browser']),_0x5681f2={...asRecord(_0x1d1f8b?.['launchOptions'])??{}};_0x44468f['XiFUU'](typeof _0x106e07[_0x330484(0x1e9)],_0x44468f['lswgJ'])&&(_0x5681f2['headless']=_0x106e07['headless']);if(_0xc5d4ef['safeMode']){const _0xed8644=_0x5681f2['args']??[],_0x4850d9=SAFE_MODE_ARGS['filter'](_0x4d513c=>!_0xed8644['includes'](_0x4d513c));_0x5681f2['args']=[..._0xed8644,..._0x4850d9];}if(_0xc5d4ef[_0x330484(0x20e)]){const _0x2f1a75=_0x5681f2[_0x330484(0x216)]??[],_0x1286bb=ALLOW_LOCALHOST_ARGS['filter'](_0x194d4c=>!_0x2f1a75[_0x330484(0x1ed)](_0x194d4c));_0x5681f2['args']=[..._0x2f1a75,..._0x1286bb];}const _0x254466={..._0x44468f['TlKxx'](asRecord,_0x1d1f8b?.['contextOptions'])??{}};_0x254466[_0x330484(0x237)]=!![];typeof _0xc5d4ef['userAgent']===_0x44468f['cvrai']&&(_0x254466['userAgent']=_0xc5d4ef['userAgent']);const _0x5dd7f6=_0x44468f['OLkMP'](mergeHeaders,asRecord(_0x254466['extraHTTPHeaders']),_0x44468f[_0x330484(0x1f4)](asRecord,_0xc5d4ef['headers']));return _0x5dd7f6?_0x254466['extraHTTPHeaders']=_0x5dd7f6:delete _0x254466['extraHTTPHeaders'],_0x106e07['storageStatePath']&&(_0x254466['storageState']=_0x106e07[_0x330484(0x1c9)]),{'launchOptions':_0x5681f2,'contextOptions':_0x254466};}export async function resolveProfileStorageState(_0x4f3615){const _0x442f1c={'vJfpB':function(_0x4c7a32,_0x3c394a){return _0x4c7a32(_0x3c394a);}};return resolveLocalAuthPath(_0x442f1c['vJfpB'](getEnvDir,_0x4f3615));}async function resolveLocalAuthPath(_0x401de9){const _0x302823=_0x257913,_0x14fc10={'odFCE':_0x302823(0x21f),'ndXNn':_0x302823(0x1cd),'zxIfM':function(_0x37af58,_0x1eae35){return _0x37af58(_0x1eae35);},'aYKoE':function(_0x257cec){return _0x257cec();},'tMbxO':'No\x20API\x20token\x20found.\x20Run:\x20ranger\x20setup\x20[token]','TIwNE':function(_0x2e5688,_0x143aa5,_0x427c6b){return _0x2e5688(_0x143aa5,_0x427c6b);},'KOfIX':function(_0x54ed70,_0x34ad1b){return _0x54ed70(_0x34ad1b);}},_0x2ccf2b=join(_0x401de9,_0x14fc10[_0x302823(0x1dc)]),_0x1d5f1c=join(_0x401de9,_0x14fc10[_0x302823(0x226)]);if(_0x14fc10['zxIfM'](existsSync,_0x2ccf2b))try{const _0x3b77f6=await _0x14fc10['aYKoE'](getToken);if(!_0x3b77f6)throw new Error(_0x14fc10['tMbxO']);const _0x335e6f=await readFile(_0x2ccf2b),_0x1563cc=_0x14fc10[_0x302823(0x21a)](decrypt,_0x335e6f,_0x3b77f6),_0x6790f7=join(_0x14fc10['aYKoE'](tmpdir),'ranger-auth-'+Date['now']()+_0x302823(0x1fc));return await writeFile(_0x6790f7,_0x1563cc),{'storageStatePath':_0x6790f7,'tempAuthPath':_0x6790f7};}catch(_0x224d67){const _0x50882e=_0x224d67 instanceof Error?_0x224d67[_0x302823(0x1ca)]:_0x14fc10['KOfIX'](String,_0x224d67);throw new Error('Failed\x20to\x20decrypt\x20auth\x20state:\x20'+_0x50882e);}if(existsSync(_0x1d5f1c))return{'storageStatePath':_0x1d5f1c};return{};}export async function buildPlaywrightConfig(_0x5b97d1,_0xf3ba32,_0xa11f31,_0xbf5014,_0x13cb53){const _0x4b5e78=_0x257913,_0x11b20f={'Ibket':function(_0x17f840,_0x24b96e){return _0x17f840(_0x24b96e);},'rWSFd':function(_0x3a3c7d,_0x136431,_0x5f563a,_0x519b5a,_0x2f0d80,_0x3a68d4,_0x227e78){return _0x3a3c7d(_0x136431,_0x5f563a,_0x519b5a,_0x2f0d80,_0x3a68d4,_0x227e78);}};if(_0x13cb53)return buildPlaywrightConfigCore(_0x5b97d1,_0x13cb53,_0xf3ba32,_0xa11f31,_0xbf5014,_0x4b5e78(0x214));const {storageStatePath:_0x50c992,tempAuthPath:_0x33a15d}=await _0x11b20f['Ibket'](resolveLocalAuthPath,getEnvDir(_0xf3ba32));try{const _0x2778c7=await _0x11b20f[_0x4b5e78(0x204)](buildPlaywrightConfigCore,_0x5b97d1,_0x50c992,_0xf3ba32,_0xa11f31,_0xbf5014,'stagehand');return{..._0x2778c7,'tempAuthPath':_0x33a15d};}catch(_0x417069){_0x33a15d&&await _0x11b20f[_0x4b5e78(0x227)](unlink,_0x33a15d)['catch'](()=>{});throw _0x417069;}}export async function buildPlaywrightConfigCore(_0x528430,_0x29d899,_0x21534f,_0x430b14,_0x4aab1a,_0x46d61f=_0x257913(0x214)){const _0x2c871b=_0x257913,_0x35eaa9={'Rywcz':function(_0x3bcbf1,_0x3402cf,_0x3bfd14){return _0x3bcbf1(_0x3402cf,_0x3bfd14);},'fewoO':function(_0x3e3c44,_0x2ae5c4){return _0x3e3c44===_0x2ae5c4;},'cpGRr':'--disable-setuid-sandbox','ENnCi':'chromium','TuwLa':_0x2c871b(0x23f),'yvXpt':function(_0x3c3b96,_0x15a8b7,_0x4730bd,_0x134ffd){return _0x3c3b96(_0x15a8b7,_0x4730bd,_0x134ffd);},'eSMvA':_0x2c871b(0x217),'FHqlV':function(_0x1d538a,_0x230cb3){return _0x1d538a(_0x230cb3);},'AHtvL':function(_0x13ce1d,_0xf31936){return _0x13ce1d===_0xf31936;},'GdvBA':_0x2c871b(0x21d),'NBnjn':_0x2c871b(0x23d),'Lhbsn':_0x2c871b(0x1eb),'ZMHBu':_0x2c871b(0x1cc),'kAwYs':function(_0x110871,_0x41abe4){return _0x110871(_0x41abe4);},'ORKum':'-cli'},_0xb33829=_0x430b14||randomUUID(),_0x47e176=_0x35eaa9['yvXpt'](join,getRangerDir(),_0x35eaa9[_0x2c871b(0x225)],_0xb33829),_0xf3ab32=_0x35eaa9['FHqlV'](Boolean,_0x528430[_0x2c871b(0x219)]),_0x438091=_0xf3ab32?{'browserName':'chromium','cdpEndpoint':_0x528430['cdpEndpoint']}:((()=>{const _0x9fb64e=_0x2c871b,{launchOptions:_0x4fecde,contextOptions:_0x1385cf}=_0x35eaa9['Rywcz'](buildBrowserOptionsFromSettings,_0x528430,{'headless':_0x4aab1a?![]:_0x528430[_0x9fb64e(0x1e9)]??!![],'storageStatePath':_0x29d899});if(_0x35eaa9[_0x9fb64e(0x22f)](process['getuid']?.(),0x0)){const _0x1bddba=['--no-sandbox',_0x35eaa9['cpGRr']],_0x434726=_0x4fecde[_0x9fb64e(0x216)]??[],_0x4a0cfa=_0x1bddba['filter'](_0x2fbe18=>!_0x434726['includes'](_0x2fbe18));_0x4fecde[_0x9fb64e(0x216)]=[..._0x434726,..._0x4a0cfa];}return{'isolated':!![],'browserName':_0x35eaa9['ENnCi'],'launchOptions':_0x4fecde,'contextOptions':{..._0x1385cf,'permissions':[_0x35eaa9[_0x9fb64e(0x1da)],_0x9fb64e(0x240)],'viewport':{'width':0x500,'height':0x2d0}}};})()),_0x7e8d59=_0x35eaa9[_0x2c871b(0x1c8)](_0x46d61f,_0x35eaa9['GdvBA'])?{'browser':_0x438091,'saveVideo':{'width':0x500,'height':0x2d0},'outputDir':_0x47e176,'outputMode':_0x2c871b(0x234),'codegen':_0x35eaa9['NBnjn']}:{'name':_0x21534f,'browser':_0x438091,'capabilities':[_0x35eaa9['Lhbsn'],_0x2c871b(0x1d9),_0x2c871b(0x210),'devtools'],'imageResponses':'allow','outputDir':_0x47e176};if(!_0xf3ab32){const _0x11cb9c=_0x7e8d59['browser'],_0xc2adb5=_0x11cb9c['contextOptions'];if(_0xc2adb5['userAgent']===undefined)delete _0xc2adb5['userAgent'];if(_0xc2adb5[_0x2c871b(0x220)]===undefined)delete _0xc2adb5[_0x2c871b(0x220)];}const _0x1cddd5=join(tmpdir(),_0x35eaa9[_0x2c871b(0x232)]);!_0x35eaa9['kAwYs'](existsSync,_0x1cddd5)&&await mkdir(_0x1cddd5,{'recursive':!![]});const _0x43af8c=_0x35eaa9['AHtvL'](_0x46d61f,_0x35eaa9[_0x2c871b(0x1fb)])?_0x35eaa9[_0x2c871b(0x22e)]:'',_0x3e072a=join(_0x1cddd5,_0x21534f+'-'+Date['now']()+_0x43af8c+_0x2c871b(0x1fc));return await writeFile(_0x3e072a,JSON['stringify'](_0x7e8d59,null,0x2)),{'configPath':_0x3e072a,'storageStatePath':_0x29d899};}export async function buildPlaywrightCliConfig(_0x219eb1,_0x2247bb,_0xdc9576,_0x160e54,_0x36e12a){const _0x3b7817=_0x257913,_0x44ffae={'PLQqf':function(_0x510b20,_0x584760){return _0x510b20(_0x584760);}};if(_0x36e12a)return buildPlaywrightConfigCore(_0x219eb1,_0x36e12a,_0x2247bb,_0xdc9576,_0x160e54,_0x3b7817(0x21d));const {storageStatePath:_0x20cbb3,tempAuthPath:_0x5fa2b4}=await _0x44ffae[_0x3b7817(0x20a)](resolveLocalAuthPath,getEnvDir(_0x2247bb));try{const _0x29a41a=await buildPlaywrightConfigCore(_0x219eb1,_0x20cbb3,_0x2247bb,_0xdc9576,_0x160e54,_0x3b7817(0x21d));return{..._0x29a41a,'tempAuthPath':_0x5fa2b4};}catch(_0x532cbd){_0x5fa2b4&&await _0x44ffae[_0x3b7817(0x20a)](unlink,_0x5fa2b4)['catch'](()=>{});throw _0x532cbd;}}export async function buildRangerwrightCliConfig(_0x369368,_0x22ef27,_0x3a30da,_0xa631e0,_0x180a65){const _0x38a012=_0x257913,_0x50ea38={'Epmon':function(_0x57c1b9,_0x497511){return _0x57c1b9===_0x497511;},'lmzbO':_0x38a012(0x22d),'teJzS':'chromium','GDRqH':function(_0x1794b8,_0x4e751f){return _0x1794b8(_0x4e751f);},'Fkrmz':function(_0x17b6e1,_0x2a5da0,_0x34aa5b,_0x7d0f8){return _0x17b6e1(_0x2a5da0,_0x34aa5b,_0x7d0f8);},'vssCP':function(_0x4fb2e7,_0x1c6c94){return _0x4fb2e7(_0x1c6c94);},'GetAG':function(_0x2ca616,_0x17035b){return _0x2ca616===_0x17035b;},'xJLdR':function(_0x1917e6,_0x1a3ba7){return _0x1917e6===_0x1a3ba7;},'ciElO':_0x38a012(0x1cc),'evIUP':function(_0x490777,_0x1857d1){return _0x490777(_0x1857d1);},'oKYxa':function(_0x83d9b3,_0x204f4c,_0x447727){return _0x83d9b3(_0x204f4c,_0x447727);},'cdDEy':function(_0x25d0cc,_0xc52036,_0x3ba0ea){return _0x25d0cc(_0xc52036,_0x3ba0ea);}},{storageStatePath:_0x535684,tempAuthPath:_0x32539b}=_0x180a65?{'storageStatePath':_0x180a65,'tempAuthPath':undefined}:await resolveLocalAuthPath(_0x50ea38['GDRqH'](getEnvDir,_0x22ef27)),_0x3cdc57=_0x3a30da||randomUUID(),_0x45e48b=_0x50ea38[_0x38a012(0x202)](join,getRangerDir(),'sessions',_0x3cdc57),_0x1b013e=_0x50ea38[_0x38a012(0x221)](Boolean,_0x369368['cdpEndpoint']),_0x3717b7=_0x1b013e?{'browserName':'chromium','cdpEndpoint':_0x369368['cdpEndpoint']}:((()=>{const _0x152390=_0x38a012,{launchOptions:_0x3a334d,contextOptions:_0x4dfa6a}=buildBrowserOptionsFromSettings(_0x369368,{'headless':_0xa631e0?![]:_0x369368['headless']??!![],'storageStatePath':_0x535684});if(_0x50ea38['Epmon'](process['getuid']?.(),0x0)){const _0x24067d=[_0x152390(0x238),_0x50ea38['lmzbO']],_0x2b8544=_0x3a334d[_0x152390(0x216)]??[],_0x446da1=_0x24067d['filter'](_0x152bbd=>!_0x2b8544['includes'](_0x152bbd));_0x3a334d['args']=[..._0x2b8544,..._0x446da1];}return{'browserName':_0x50ea38[_0x152390(0x21e)],'launchOptions':_0x3a334d,'contextOptions':{..._0x4dfa6a,'permissions':['clipboard-read',_0x152390(0x240)],'viewport':{'width':0x500,'height':0x2d0}}};})());if(!_0x1b013e){const _0x50b6d1=_0x3717b7[_0x38a012(0x242)];if(_0x50b6d1){if(_0x50ea38[_0x38a012(0x1e8)](_0x50b6d1['userAgent'],undefined))delete _0x50b6d1[_0x38a012(0x203)];if(_0x50ea38[_0x38a012(0x20f)](_0x50b6d1[_0x38a012(0x220)],undefined))delete _0x50b6d1['storageState'];}}const _0x276160={'browser':_0x3717b7,'outputDir':_0x45e48b,'saveTrace':!![],'saveVideo':{'width':0x500,'height':0x2d0},'settle':{'navigationLoadTimeoutMs':0x7530,'networkSettleTimeoutMs':0x1388,'networkIdleWindowMs':0x1f4,'postActionAnimationFrameCount':0x2}};let _0x3217ed;try{const _0x42b10f=join(tmpdir(),_0x50ea38['ciElO']);!_0x50ea38['evIUP'](existsSync,_0x42b10f)&&await mkdir(_0x42b10f,{'recursive':!![]}),_0x3217ed=_0x50ea38['oKYxa'](join,_0x42b10f,_0x22ef27+'-'+Date[_0x38a012(0x21c)]()+_0x38a012(0x1db)),await _0x50ea38['cdDEy'](writeFile,_0x3217ed,JSON['stringify'](_0x276160,null,0x2));}catch(_0x359373){_0x32539b&&await unlink(_0x32539b)[_0x38a012(0x23a)](()=>{});throw _0x359373;}return{'configPath':_0x3217ed,'storageStatePath':_0x535684,'tempAuthPath':_0x32539b,'outputDir':_0x45e48b};}export async function buildNovaActCliConfig(_0x4891d9,_0x217805,_0x38f812,_0x1759d6,_0x4fe498){const _0x4886ab=_0x257913,_0x5d57ea={'oqePL':function(_0x1ad295,_0xb91b57){return _0x1ad295(_0xb91b57);},'BIdQO':function(_0x24a9e8){return _0x24a9e8();},'nczVl':function(_0x1528f8,_0x12423f,_0x1e8737,_0x55703e){return _0x1528f8(_0x12423f,_0x1e8737,_0x55703e);},'eoXof':'sessions','UjdaL':function(_0xc17cb7,_0x7a9ce2,_0x49c662){return _0xc17cb7(_0x7a9ce2,_0x49c662);},'PUbEp':_0x4886ab(0x23e),'aYpvP':function(_0x78312e,_0x1389f3,_0x4c6b88){return _0x78312e(_0x1389f3,_0x4c6b88);},'qvflz':function(_0x2f5c0d,_0x150c8c){return _0x2f5c0d===_0x150c8c;},'NHTnf':_0x4886ab(0x238),'bfHNY':'--disable-setuid-sandbox','Zvpos':function(_0x50b596,_0x469124){return _0x50b596(_0x469124);}},{storageStatePath:_0x5b1516,tempAuthPath:_0x27c827}=_0x4fe498?{'storageStatePath':_0x4fe498,'tempAuthPath':undefined}:await resolveLocalAuthPath(_0x5d57ea['oqePL'](getEnvDir,_0x217805)),_0x52bcf7=_0x38f812||_0x5d57ea['BIdQO'](randomUUID),_0xec1295=_0x5d57ea['nczVl'](join,getRangerDir(),_0x5d57ea['eoXof'],_0x52bcf7),_0x5b8cb8=_0x5d57ea[_0x4886ab(0x20b)](join,_0xec1295,'nova-user-data'),_0x3d4418=_0x5b1516?join(_0x5b8cb8,_0x5d57ea['PUbEp']):undefined,{launchOptions:_0x5c32ed,contextOptions:_0x4c312b}=_0x5d57ea['aYpvP'](buildBrowserOptionsFromSettings,_0x4891d9,{'headless':_0x1759d6?![]:_0x4891d9[_0x4886ab(0x1e9)]??!![],'storageStatePath':_0x5b1516});if(_0x5d57ea[_0x4886ab(0x1e7)](process['getuid']?.(),0x0)){const _0x247aad=[_0x5d57ea['NHTnf'],_0x5d57ea['bfHNY']],_0x56b492=_0x5c32ed['args']??[],_0x2c29b8=_0x247aad['filter'](_0x1e3ecf=>!_0x56b492['includes'](_0x1e3ecf));_0x5c32ed['args']=[..._0x56b492,..._0x2c29b8];}const _0x3fde64=typeof _0x5c32ed[_0x4886ab(0x211)]===_0x4886ab(0x218)?_0x5c32ed['executablePath']:_0x5b1516?chromium[_0x4886ab(0x211)]():undefined;return{'storageStatePath':_0x5b1516,'tempAuthPath':_0x27c827,'baseUrl':_0x4891d9[_0x4886ab(0x224)],'headless':Boolean(_0x5c32ed['headless']),'userDataDir':_0x5b8cb8,'browserProfilePath':_0x3d4418,'executablePath':_0x3fde64,'launchArgs':Array[_0x4886ab(0x1c7)](_0x5c32ed[_0x4886ab(0x216)])?_0x5c32ed[_0x4886ab(0x216)]['filter'](_0x1d5cf6=>typeof _0x1d5cf6==='string'):[],'userAgent':typeof _0x4c312b[_0x4886ab(0x203)]===_0x4886ab(0x218)?_0x4c312b['userAgent']:undefined,'extraHTTPHeaders':_0x4c312b['extraHTTPHeaders'],'allowInsecureLocalhost':_0x5d57ea[_0x4886ab(0x1fa)](Boolean,_0x4891d9[_0x4886ab(0x20e)]),'safeMode':_0x5d57ea[_0x4886ab(0x1f2)](Boolean,_0x4891d9[_0x4886ab(0x206)]),'cdpEndpoint':_0x4891d9['cdpEndpoint'],'isCdpMode':Boolean(_0x4891d9[_0x4886ab(0x219)])};}export function getNestedValue(_0x4f894f,_0x175319){const _0x204d4f=_0x257913,_0x2b9ceb={'moffE':function(_0x37d707,_0xc8a7ed){return _0x37d707(_0xc8a7ed);},'AsQyM':function(_0xf9590d,_0x212287){return _0xf9590d===_0x212287;},'sJSxP':function(_0x39ec01,_0x4492c4){return _0x39ec01!==_0x4492c4;},'lociQ':'object'},_0x15ebba=_0x2b9ceb[_0x204d4f(0x22c)](parseKeyPath,_0x175319);let _0x30680b=_0x4f894f;for(const _0x1cd62a of _0x15ebba){if(_0x2b9ceb['AsQyM'](_0x30680b,null)||_0x30680b===undefined||_0x2b9ceb[_0x204d4f(0x200)](typeof _0x30680b,_0x2b9ceb[_0x204d4f(0x1f1)]))return undefined;_0x30680b=_0x30680b[_0x1cd62a];}return _0x30680b;}export function setNestedValue(_0xf2f989,_0x5e6fc1,_0x263988){const _0x4ee17d=_0x257913,_0x498df6={'FEMyW':function(_0x45e8d8,_0x236ef9){return _0x45e8d8(_0x236ef9);},'TqTop':function(_0x309cc0,_0x3e726e){return _0x309cc0-_0x3e726e;},'JVERE':_0x4ee17d(0x1e5)},_0x10cadb=_0x498df6['FEMyW'](parseKeyPath,_0x5e6fc1);let _0xb8e218=_0xf2f989;for(let _0x46deb2=0x0;_0x46deb2<_0x498df6[_0x4ee17d(0x1ce)](_0x10cadb['length'],0x1);_0x46deb2++){const _0x4c1450=_0x10cadb[_0x46deb2];(!(_0x4c1450 in _0xb8e218)||typeof _0xb8e218[_0x4c1450]!==_0x498df6['JVERE'])&&(_0xb8e218[_0x4c1450]={}),_0xb8e218=_0xb8e218[_0x4c1450];}_0xb8e218[_0x10cadb[_0x10cadb[_0x4ee17d(0x239)]-0x1]]=_0x263988;}export function deleteNestedValue(_0x4885cc,_0x2c1e3f){const _0xe8aba7=_0x257913,_0x3b3669={'EiNOF':function(_0x590c39,_0x3b1a1f){return _0x590c39(_0x3b1a1f);},'nFxYf':function(_0x24c7a4,_0x4a226f){return _0x24c7a4===_0x4a226f;},'TEtJS':_0xe8aba7(0x1e5),'LiDgn':function(_0x3a4bfb,_0x8a5210){return _0x3a4bfb===_0x8a5210;},'ocesW':function(_0x17c151,_0x5d5e4b){return _0x17c151!==_0x5d5e4b;},'RCqkO':function(_0xbf962f,_0x59c179){return _0xbf962f-_0x59c179;}},_0x1a8d61=_0x3b3669[_0xe8aba7(0x21b)](parseKeyPath,_0x2c1e3f);let _0x365186=_0x4885cc;for(let _0x14f3f7=0x0;_0x14f3f7<_0x1a8d61['length']-0x1;_0x14f3f7++){if(_0x3b3669['nFxYf'](_0x365186,null)||_0x365186===undefined||typeof _0x365186!==_0x3b3669[_0xe8aba7(0x1ec)])return![];_0x365186=_0x365186[_0x1a8d61[_0x14f3f7]];}if(_0x3b3669[_0xe8aba7(0x20c)](_0x365186,null)||_0x3b3669['LiDgn'](_0x365186,undefined)||_0x3b3669['ocesW'](typeof _0x365186,'object'))return![];const _0x14a3cc=_0x1a8d61[_0x3b3669[_0xe8aba7(0x1ee)](_0x1a8d61[_0xe8aba7(0x239)],0x1)];if(_0x14a3cc in _0x365186)return delete _0x365186[_0x14a3cc],!![];return![];}function parseKeyPath(_0x2a5ece){const _0x4407f5=_0x257913,_0x2b3004={'swMKU':_0x4407f5(0x1d3),'bWthw':function(_0x5417e1,_0x10aee1){return _0x5417e1===_0x10aee1;}},_0x1a2f87=_0x2a5ece[_0x4407f5(0x1ff)]('.');return _0x1a2f87[0x0]===_0x4407f5(0x1ea)&&(_0x1a2f87[0x0]=_0x2b3004[_0x4407f5(0x244)]),_0x2b3004['bWthw'](_0x1a2f87[0x0],_0x4407f5(0x229))&&(_0x1a2f87[0x0]='setupHeaders'),_0x1a2f87;}function _0x3583(_0x42198c,_0x19527a){_0x42198c=_0x42198c-0x1c7;const _0x1cbef5=_0x1cbe();let _0x35835f=_0x1cbef5[_0x42198c];return _0x35835f;}export function formatSettings(_0x2d51d0,_0x44e395=0x0){const _0x1aec4f=_0x257913,_0x2165fd={'ZAZoT':function(_0x241106,_0x1d129a){return _0x241106===_0x1d129a;},'wYDkg':function(_0x4a8b4a,_0x138970){return _0x4a8b4a!==_0x138970;}},_0x4b0e0c=[],_0x18a9e2='\x20\x20'['repeat'](_0x44e395);for(const [_0x3755b9,_0x5a1ff9]of Object[_0x1aec4f(0x1d1)](_0x2d51d0)){if(_0x2165fd['ZAZoT'](_0x5a1ff9,undefined))continue;if(_0x2165fd[_0x1aec4f(0x1f9)](typeof _0x5a1ff9,'object')&&_0x2165fd['wYDkg'](_0x5a1ff9,null)){_0x4b0e0c['push'](''+_0x18a9e2+_0x3755b9+':');for(const [_0x2be576,_0x352ff5]of Object['entries'](_0x5a1ff9)){_0x4b0e0c[_0x1aec4f(0x1ef)](_0x18a9e2+'\x20\x20'+_0x2be576+':\x20'+_0x352ff5);}}else _0x4b0e0c['push'](''+_0x18a9e2+_0x3755b9+':\x20'+_0x5a1ff9);}return _0x4b0e0c['join']('\x0a');}function _0x1cbe(){const _0x4e1cf2=['keys','8001520BumIvX','6858fHdJXv','ZAZoT','Zvpos','GdvBA','.json','\x20is\x20not\x20set','6364BFdlTS','split','sJSxP','local','Fkrmz','userAgent','rWSFd','1740XJFzUD','safeMode','utf-8','fromEntries','warn','PLQqf','UjdaL','nFxYf','filter','allowInsecureLocalhost','xJLdR','vision','executablePath','FmIbe','335MqZQHy','stagehand','iboCF','args','sessions','string','cdpEndpoint','TIwNE','EiNOF','now','playwright-cli','teJzS','auth.json.enc','storageState','vssCP','188WRShBt','--disable-features=WebBluetooth','baseUrl','eSMvA','ndXNn','Ibket','ItDoq','setupHeader','DxfCV','rangerDir','moffE','--disable-setuid-sandbox','ORKum','fewoO','ENOENT','settings.json','ZMHBu','rlHUQ','file','9370WbxJcE','\x22\x20to\x20legacy\x20path\x20','ignoreHTTPSErrors','--no-sandbox','length','catch','qkIUD','umIpM','none','Default','clipboard-read','clipboard-write','\x20\x20ranger\x20profile\x20add\x20<name>\x0a','contextOptions','RTjtq','swMKU','10290IlJTQi','isArray','AHtvL','storageStatePath','message','See\x20https://docs.ranger.net/main/concepts/profiles\x20for\x20setup\x20options.','ranger-config','auth.json','TqTop','bMXAI','5744AbyFht','entries','replace','headers','YIdcP','That\x20directory\x20is\x20read-only\x20now.\x20To\x20set\x20up\x20a\x20fresh\x20profile,\x20run:\x0a','14463IFXlYT','awdrl','map','pdf','TuwLa','-rangerwright.json','odFCE','30226097OCRbom','jqTRo','tempAuthPath','--allow-insecure-localhost','forWrite','all','locations','code','object','--unsafely-treat-insecure-origin-as-secure=http://localhost','qvflz','GetAG','headless','header','core','TEtJS','includes','RCqkO','push','nfdaz','lociQ','oqePL','Environment\x20variable\x20','VnVcj','path'];_0x1cbe=function(){return _0x4e1cf2;};return _0x1cbe();}
|
|
1
|
+
const _0x2b2e19=_0x1ee5;(function(_0x5ed2e5,_0x43fca2){const _0x9e4472=_0x1ee5,_0x4e3ae7=_0x5ed2e5();while(!![]){try{const _0x581abe=parseInt(_0x9e4472(0x1f7))/0x1+parseInt(_0x9e4472(0x220))/0x2+parseInt(_0x9e4472(0x1f9))/0x3*(-parseInt(_0x9e4472(0x23c))/0x4)+-parseInt(_0x9e4472(0x214))/0x5*(parseInt(_0x9e4472(0x269))/0x6)+-parseInt(_0x9e4472(0x267))/0x7+-parseInt(_0x9e4472(0x242))/0x8+parseInt(_0x9e4472(0x239))/0x9;if(_0x581abe===_0x43fca2)break;else _0x4e3ae7['push'](_0x4e3ae7['shift']());}catch(_0x4bc3c2){_0x4e3ae7['push'](_0x4e3ae7['shift']());}}}(_0x718d,0xc7ed7));import{readFile,writeFile,mkdir,unlink}from'fs/promises';import{join,dirname}from'path';import{existsSync}from'fs';import{tmpdir}from'os';import{randomUUID}from'crypto';import{chromium}from'playwright';import{decrypt}from'./crypto.js';import{getToken}from'./keychain.js';import{getRangerDir,getRangerHomeDir}from'./rangerRoot.js';function findEnvInRoot(_0x954fb8,_0x3ab98e){const _0x28d8ac=_0x1ee5,_0x5b1a43={'nYbmV':function(_0x3ebbce,_0x20f40e,_0x486f0b,_0x3fd476){return _0x3ebbce(_0x20f40e,_0x486f0b,_0x3fd476);},'DkSwr':'local','aTXZL':function(_0x2789b0,_0x5321a8,_0x275772){return _0x2789b0(_0x5321a8,_0x275772);},'qiYDL':function(_0x109980,_0x521837){return _0x109980(_0x521837);}},_0xf58d60=join(_0x3ab98e,'ci',_0x954fb8),_0x1fce14=_0x5b1a43['nYbmV'](join,_0x3ab98e,_0x5b1a43[_0x28d8ac(0x218)],_0x954fb8),_0x51d7e8=join(_0x3ab98e,_0x954fb8),_0x19abfe=_0x5b1a43['aTXZL'](join,_0x3ab98e,_0x28d8ac(0x206)),_0x2da3b2=join(_0x3ab98e,'ci');if(_0x5b1a43['qiYDL'](existsSync,_0xf58d60))return _0xf58d60;if(existsSync(_0x1fce14))return _0x1fce14;if(existsSync(_0x51d7e8)&&(_0x51d7e8!==_0x19abfe&&_0x51d7e8!==_0x2da3b2?!![]:hasLegacyProfileFiles(_0x51d7e8)))return _0x51d7e8;return null;}export function getEnvDir(_0x151777,_0x311118={}){const _0x11aa58=_0x1ee5,_0x57fc9f={'ckXhM':function(_0x3df58b){return _0x3df58b();},'lyyru':function(_0x21f103,_0x17dd65){return _0x21f103(_0x17dd65);},'RNVmV':function(_0x42a5bc){return _0x42a5bc();},'CEfWC':function(_0x3577b2,_0xc8679f,_0x23ad14){return _0x3577b2(_0xc8679f,_0x23ad14);},'QzymC':function(_0x226ef1,_0x3f67d7,_0x1733ef){return _0x226ef1(_0x3f67d7,_0x1733ef);},'aqeop':function(_0x2c1c05,_0x4df1f1,_0x1e6ffc,_0x53bda1){return _0x2c1c05(_0x4df1f1,_0x1e6ffc,_0x53bda1);}},_0x2f51b1=_0x57fc9f['ckXhM'](getRangerDir),_0x108ca9=findEnvInRoot(_0x151777,_0x2f51b1);if(_0x108ca9){if(_0x311118['forWrite']&&_0x57fc9f['lyyru'](isLegacyEnvPath,_0x108ca9))throw legacyWriteError(_0x151777,_0x108ca9);return _0x108ca9;}const _0x487bec=_0x57fc9f[_0x11aa58(0x256)](getRangerHomeDir);if(_0x487bec!==_0x2f51b1){const _0x3f394a=_0x57fc9f[_0x11aa58(0x253)](findEnvInRoot,_0x151777,_0x487bec);if(_0x3f394a){if(_0x311118['forWrite']&&isLegacyEnvPath(_0x3f394a))throw _0x57fc9f['QzymC'](legacyWriteError,_0x151777,_0x3f394a);return _0x3f394a;}}const _0x441943=_0x57fc9f['aqeop'](join,_0x487bec,_0x11aa58(0x206),_0x151777);if(_0x311118[_0x11aa58(0x248)])throw legacyWriteError(_0x151777,_0x441943);return _0x441943;}function isLegacyEnvPath(_0x17876d){const _0x1e1262=_0x1ee5,_0x3689d9={'UqVQG':function(_0x47ee8c){return _0x47ee8c();}},_0x400f0a=_0x3689d9['UqVQG'](getRangerDir),_0xfd9f51=getRangerHomeDir();for(const _0x50230d of new Set([_0x400f0a,_0xfd9f51])){const _0x12412a=_0x50230d['endsWith']('/')?_0x50230d:_0x50230d+'/';if(_0x17876d===_0x50230d||_0x17876d[_0x1e1262(0x208)](_0x12412a))return!![];}return![];}function legacyWriteError(_0x180181,_0x5b4b2b){const _0x2efcb7=_0x1ee5,_0x1fcaa={'fFPZb':function(_0x4543a6,_0x5c8549){return _0x4543a6+_0x5c8549;},'FxSZT':function(_0xbec5e7,_0x28a702){return _0xbec5e7+_0x28a702;}};return new Error(_0x1fcaa[_0x2efcb7(0x249)](_0x1fcaa['FxSZT']('Refusing\x20to\x20write\x20profile\x20\x22'+_0x180181+'\x22\x20to\x20legacy\x20path\x20'+_0x5b4b2b+'.\x0a',_0x2efcb7(0x235))+'\x20\x20ranger\x20profile\x20add\x20<name>\x0a',_0x2efcb7(0x229)));}export function findExistingEnv(_0x5ad009,_0xf31028){const _0x3b04f8=_0x1ee5,_0x5646a8={'CIzSg':_0x3b04f8(0x206),'wERLN':_0x3b04f8(0x24f),'xRMTB':function(_0x3ea92d,_0x3be637,_0x80026d){return _0x3ea92d(_0x3be637,_0x80026d);},'ywmwQ':function(_0x11b13d,_0xf34127,_0x41412b){return _0x11b13d(_0xf34127,_0x41412b);},'OlzMU':function(_0x374ffa,_0x4937f4){return _0x374ffa===_0x4937f4;}},_0x44572a=_0xf31028?.[_0x3b04f8(0x238)],_0x184a8a=_0x44572a?[_0x44572a]:[getRangerDir(),getRangerHomeDir()][_0x3b04f8(0x237)]((_0x4cb036,_0x327330,_0x18f46d)=>_0x18f46d[_0x3b04f8(0x25f)](_0x4cb036)===_0x327330),_0x138634=_0xf31028?.[_0x3b04f8(0x24c)]??['ci',_0x5646a8[_0x3b04f8(0x21e)],_0x5646a8[_0x3b04f8(0x1f5)]];for(const _0x5df030 of _0x184a8a){const _0x3f5488=join(_0x5df030,_0x5646a8[_0x3b04f8(0x21e)]),_0x406264=_0x5646a8['xRMTB'](join,_0x5df030,'ci'),_0x1f1132=[{'location':'ci','path':join(_0x5df030,'ci',_0x5ad009)},{'location':_0x3b04f8(0x206),'path':join(_0x5df030,_0x5646a8['CIzSg'],_0x5ad009)},{'location':_0x5646a8[_0x3b04f8(0x1f5)],'path':_0x5646a8[_0x3b04f8(0x236)](join,_0x5df030,_0x5ad009)}];for(const _0x2f4d95 of _0x1f1132){if(_0x138634[_0x3b04f8(0x1f6)](_0x2f4d95[_0x3b04f8(0x25b)])&&existsSync(_0x2f4d95[_0x3b04f8(0x212)])){if(_0x5646a8['OlzMU'](_0x2f4d95['location'],_0x3b04f8(0x24f))&&(_0x2f4d95['path']===_0x3f5488||_0x2f4d95[_0x3b04f8(0x212)]===_0x406264)&&!hasLegacyProfileFiles(_0x2f4d95[_0x3b04f8(0x212)]))continue;return{'path':_0x2f4d95[_0x3b04f8(0x212)],'location':_0x2f4d95[_0x3b04f8(0x25b)]};}}}return null;}function hasLegacyProfileFiles(_0x2fafdf){const _0x530875=_0x1ee5,_0x3e012b={'faJxX':function(_0x2a5f70,_0x5db2ed,_0x375025){return _0x2a5f70(_0x5db2ed,_0x375025);},'aLDGt':_0x530875(0x23a),'WwkeZ':function(_0x13532e,_0x183c76){return _0x13532e(_0x183c76);},'QiRAT':function(_0xee17e9,_0x3d83d9,_0x172c94){return _0xee17e9(_0x3d83d9,_0x172c94);}};return existsSync(_0x3e012b['faJxX'](join,_0x2fafdf,_0x530875(0x221)))||existsSync(_0x3e012b['faJxX'](join,_0x2fafdf,_0x3e012b['aLDGt']))||_0x3e012b[_0x530875(0x219)](existsSync,_0x3e012b['QiRAT'](join,_0x2fafdf,_0x530875(0x24e)));}function _0x718d(){const _0x258970=['core','stagehand','parse','CEfWC','mbRsX','code','RNVmV','catch','vknlJ','ranger-auth-','isArray','location','jpjqk','pdf','--disable-setuid-sandbox','indexOf','--allow-running-insecure-content','KvPIJ','entries','clipboard-read','allow','MUyXv','map','353122AomhUc','OHDLK','42gNqOEm','Environment\x20variable\x20','getuid','--disable-features=WebBluetooth','--unsafely-treat-insecure-origin-as-secure=http://localhost','Xqtue','replace','qCpfO','wERLN','includes','636373XGrsKL','storageStatePath','151341ogysQA','yqZpg','IGWBa','extraHTTPHeaders','cdpEndpoint','NIBID','--no-sandbox','UPRPs','DjceI','stringify','yIfts','allowInsecureLocalhost','XWKmL','local','LQpKY','startsWith','ENOENT','AKsbK','BNpwX','QoFbx','qzoxA','args','utf-8','push','safeMode','path','ignoreHTTPSErrors','363570jJKYfY','HZRtX','zUfIk','contextOptions','DkSwr','WwkeZ','GmXro','BpORK','GaGCW','playwright-cli','CIzSg','SqRaT','1264740eVDNiY','settings.json','PRDCs','rmHsO','clipboard-write','psoOd','ISboD','devtools','PpVRo','See\x20https://docs.ranger.net/main/concepts/profiles\x20for\x20setup\x20options.','warn','object','length','OuuGU','VioBL','executablePath','string','all','wmQoT','userAgent','storageState','That\x20directory\x20is\x20read-only\x20now.\x20To\x20set\x20up\x20a\x20fresh\x20profile,\x20run:\x0a','ywmwQ','filter','rangerDir','13933188yQQvAy','auth.json','ranger-config','108GwacOr','fromEntries','Ddixh','QvZes','.json','AgPQf','611672Oitgby','Failed\x20to\x20decrypt\x20auth\x20state:\x20','nTrYi','PjUcl','now','chromium','forWrite','fFPZb','setupHeader','headless','locations','ScXni','auth.json.enc','legacy'];_0x718d=function(){return _0x258970;};return _0x718d();}export function isEnvCi(_0x4c3619){const _0x4e6113=_0x1ee5,_0x1f943b={'MUyXv':function(_0x3537cd,_0xa490b4){return _0x3537cd(_0xa490b4);},'vknlJ':function(_0x33f5ee){return _0x33f5ee();},'BpORK':function(_0x401278,_0x48f2cb,_0x473dc5,_0x10be41){return _0x401278(_0x48f2cb,_0x473dc5,_0x10be41);}};if(_0x1f943b['MUyXv'](existsSync,join(_0x1f943b[_0x4e6113(0x258)](getRangerDir),'ci',_0x4c3619)))return!![];const _0x5a8d3b=getRangerHomeDir();if(_0x5a8d3b!==_0x1f943b['vknlJ'](getRangerDir)&&_0x1f943b[_0x4e6113(0x265)](existsSync,_0x1f943b[_0x4e6113(0x21b)](join,_0x5a8d3b,'ci',_0x4c3619)))return!![];return![];}export async function cleanupTempFiles(_0x3946d9){const _0x1f4336=_0x1ee5,_0x4e5de7={'RyeEd':_0x1f4336(0x209)},_0x503b4d=[_0x3946d9['tempAuthPath'],_0x3946d9['configPath']][_0x1f4336(0x237)](Boolean);await Promise[_0x1f4336(0x231)](_0x503b4d[_0x1f4336(0x266)](_0x2eca08=>unlink(_0x2eca08)[_0x1f4336(0x257)](_0x359d3a=>{const _0xadbcc2=_0x1f4336;_0x359d3a[_0xadbcc2(0x255)]!==_0x4e5de7['RyeEd']&&console[_0xadbcc2(0x22a)]('Failed\x20to\x20clean\x20up\x20temp\x20file\x20'+_0x2eca08+':',_0x359d3a['message']);})));}export function getSettingsPath(_0x2fdb90){const _0xcf19=_0x1ee5,_0x5a2624={'PRDCs':function(_0x10284b,_0x118d8f,_0x2c2f61){return _0x10284b(_0x118d8f,_0x2c2f61);},'FjJLf':_0xcf19(0x221)};return _0x5a2624[_0xcf19(0x222)](join,getEnvDir(_0x2fdb90),_0x5a2624['FjJLf']);}export async function loadSettings(_0x5b0450){const _0x2a9d1a=_0x1ee5,_0x2e21cc={'UPRPs':function(_0x103ce1,_0x26fa8f){return _0x103ce1(_0x26fa8f);},'KCRST':_0x2a9d1a(0x20f)},_0x21f352=_0x2e21cc[_0x2a9d1a(0x200)](getSettingsPath,_0x5b0450);if(!existsSync(_0x21f352))return{};try{const _0x1c4b76=await readFile(_0x21f352,_0x2e21cc['KCRST']);return JSON[_0x2a9d1a(0x252)](_0x1c4b76);}catch{return{};}}export async function saveSettings(_0x5f7223,_0x159c41){const _0x4af82e=_0x1ee5,_0x4e526b={'HZRtX':function(_0x23b4db,_0x3db465){return _0x23b4db(_0x3db465);},'yqZpg':function(_0x302350,_0x2671d8,_0x420ef6){return _0x302350(_0x2671d8,_0x420ef6);}},_0xef64a3=_0x4e526b[_0x4af82e(0x215)](getSettingsPath,_0x5f7223),_0x4a33e0=_0x4e526b[_0x4af82e(0x215)](dirname,_0xef64a3);!existsSync(_0x4a33e0)&&await _0x4e526b[_0x4af82e(0x1fa)](mkdir,_0x4a33e0,{'recursive':!![]}),await _0x4e526b[_0x4af82e(0x1fa)](writeFile,_0xef64a3,JSON[_0x4af82e(0x202)](_0x159c41,null,0x2));}export function resolveEnvVars(_0x519a60){const _0x4c71e9=_0x1ee5,_0x5866fe={'EsEdU':function(_0x2765cb,_0x5290b9){return _0x2765cb===_0x5290b9;},'AKsbK':'string'};if(_0x5866fe['EsEdU'](typeof _0x519a60,_0x5866fe[_0x4c71e9(0x20a)]))return _0x519a60[_0x4c71e9(0x1f3)](/\$\{(\w+)\}/g,(_0x155d13,_0x373f63)=>{const _0x4aeac1=_0x4c71e9,_0x4fa7f8=process['env'][_0x373f63];if(_0x4fa7f8===undefined)throw new Error(_0x4aeac1(0x26a)+_0x373f63+'\x20is\x20not\x20set');return _0x4fa7f8;});if(Array['isArray'](_0x519a60))return _0x519a60['map'](resolveEnvVars);if(_0x519a60&&typeof _0x519a60==='object')return Object[_0x4c71e9(0x23d)](Object[_0x4c71e9(0x262)](_0x519a60)[_0x4c71e9(0x266)](([_0x2df35d,_0xea602e])=>[_0x2df35d,resolveEnvVars(_0xea602e)]));return _0x519a60;}const isRecord=_0x5f0c8c=>typeof _0x5f0c8c==='object'&&_0x5f0c8c!==null&&!Array[_0x2b2e19(0x25a)](_0x5f0c8c),asRecord=_0x1d99ee=>isRecord(_0x1d99ee)?_0x1d99ee:undefined,mergeHeaders=(_0x2201a3,_0x43f0ba)=>{const _0xa3bb3f=_0x2b2e19,_0x3da0d8={'UbYny':function(_0x4342ff,_0x180065){return _0x4342ff??_0x180065;}},_0xb0f4c2={..._0x3da0d8['UbYny'](_0x2201a3,{}),..._0x43f0ba??{}};return Object['keys'](_0xb0f4c2)[_0xa3bb3f(0x22c)]?_0xb0f4c2:undefined;},SAFE_MODE_ARGS=[_0x2b2e19(0x26c)],ALLOW_LOCALHOST_ARGS=['--disable-web-security',_0x2b2e19(0x260),_0x2b2e19(0x1f1),'--allow-insecure-localhost'];export function buildBrowserOptionsFromSettings(_0x1646fc,_0x3b5b4b={}){const _0x2a21e8=_0x2b2e19,_0x17ec0b={'PjUcl':function(_0x220496,_0xc2993e){return _0x220496(_0xc2993e);},'LjDtq':function(_0x30b464,_0x350adf){return _0x30b464===_0x350adf;},'WaAJb':'string','hUzJT':function(_0x3d96c9,_0x1b86cf,_0x52396f){return _0x3d96c9(_0x1b86cf,_0x52396f);}},_0xe7703e=asRecord(_0x1646fc['browser']),_0x5a918c={..._0x17ec0b[_0x2a21e8(0x245)](asRecord,_0xe7703e?.['launchOptions'])??{}};typeof _0x3b5b4b['headless']==='boolean'&&(_0x5a918c[_0x2a21e8(0x24b)]=_0x3b5b4b['headless']);if(_0x1646fc['safeMode']){const _0x5b2028=_0x5a918c[_0x2a21e8(0x20e)]??[],_0xa29e55=SAFE_MODE_ARGS['filter'](_0x243e26=>!_0x5b2028[_0x2a21e8(0x1f6)](_0x243e26));_0x5a918c[_0x2a21e8(0x20e)]=[..._0x5b2028,..._0xa29e55];}if(_0x1646fc[_0x2a21e8(0x204)]){const _0x2514e9=_0x5a918c[_0x2a21e8(0x20e)]??[],_0x7175f6=ALLOW_LOCALHOST_ARGS[_0x2a21e8(0x237)](_0x3bca5a=>!_0x2514e9[_0x2a21e8(0x1f6)](_0x3bca5a));_0x5a918c[_0x2a21e8(0x20e)]=[..._0x2514e9,..._0x7175f6];}const _0x12e6dc={...asRecord(_0xe7703e?.[_0x2a21e8(0x217)])??{}};_0x12e6dc[_0x2a21e8(0x213)]=!![];_0x17ec0b['LjDtq'](typeof _0x1646fc['userAgent'],_0x17ec0b['WaAJb'])&&(_0x12e6dc['userAgent']=_0x1646fc['userAgent']);const _0x21611a=_0x17ec0b['hUzJT'](mergeHeaders,asRecord(_0x12e6dc[_0x2a21e8(0x1fc)]),_0x17ec0b['PjUcl'](asRecord,_0x1646fc['headers']));return _0x21611a?_0x12e6dc['extraHTTPHeaders']=_0x21611a:delete _0x12e6dc[_0x2a21e8(0x1fc)],_0x3b5b4b[_0x2a21e8(0x1f8)]&&(_0x12e6dc['storageState']=_0x3b5b4b['storageStatePath']),{'launchOptions':_0x5a918c,'contextOptions':_0x12e6dc};}export async function resolveProfileStorageState(_0x4c2955){const _0x39b836=_0x2b2e19,_0x15fb82={'qzoxA':function(_0x3d61f7,_0x270e94){return _0x3d61f7(_0x270e94);}};return _0x15fb82[_0x39b836(0x20d)](resolveLocalAuthPath,getEnvDir(_0x4c2955));}async function resolveLocalAuthPath(_0x178dd4){const _0x48edea=_0x2b2e19,_0x4a17ed={'hNsQe':'No\x20API\x20token\x20found.\x20Run:\x20ranger\x20setup\x20[token]','IGWBa':function(_0x4e42c5,_0x2f6e29){return _0x4e42c5(_0x2f6e29);},'BNpwX':function(_0x565933,_0x1c52b7,_0x2cc37a){return _0x565933(_0x1c52b7,_0x2cc37a);},'psoOd':function(_0x1428a8,_0x206712,_0x5a8f16){return _0x1428a8(_0x206712,_0x5a8f16);},'sXmZd':function(_0x3928d9){return _0x3928d9();},'jpjqk':function(_0x1c2724,_0x1d092f,_0x371207){return _0x1c2724(_0x1d092f,_0x371207);}},_0x10fc56=join(_0x178dd4,'auth.json.enc'),_0x538d38=join(_0x178dd4,'auth.json');if(existsSync(_0x10fc56))try{const _0x4697fe=await getToken();if(!_0x4697fe)throw new Error(_0x4a17ed['hNsQe']);const _0x288083=await _0x4a17ed[_0x48edea(0x1fb)](readFile,_0x10fc56),_0x4f259b=_0x4a17ed[_0x48edea(0x20b)](decrypt,_0x288083,_0x4697fe),_0x33fd85=_0x4a17ed[_0x48edea(0x225)](join,_0x4a17ed['sXmZd'](tmpdir),_0x48edea(0x259)+Date['now']()+_0x48edea(0x240));return await _0x4a17ed[_0x48edea(0x25c)](writeFile,_0x33fd85,_0x4f259b),{'storageStatePath':_0x33fd85,'tempAuthPath':_0x33fd85};}catch(_0x4d708b){const _0x53b363=_0x4d708b instanceof Error?_0x4d708b['message']:_0x4a17ed['IGWBa'](String,_0x4d708b);throw new Error(_0x48edea(0x243)+_0x53b363);}if(existsSync(_0x538d38))return{'storageStatePath':_0x538d38};return{};}export async function buildPlaywrightConfig(_0x462fd6,_0xae0b69,_0xb6908f,_0x54acc5,_0x375571){const _0x1f5fb9=_0x2b2e19,_0x5d2443={'SqRaT':function(_0x47df17,_0x5e3fff,_0x4eacc3,_0x43b16d,_0x7df65e,_0x4e8225,_0xce050){return _0x47df17(_0x5e3fff,_0x4eacc3,_0x43b16d,_0x7df65e,_0x4e8225,_0xce050);},'QoFbx':_0x1f5fb9(0x251),'KvPIJ':function(_0x1d0a59,_0x28bd5d){return _0x1d0a59(_0x28bd5d);}};if(_0x375571)return _0x5d2443[_0x1f5fb9(0x21f)](buildPlaywrightConfigCore,_0x462fd6,_0x375571,_0xae0b69,_0xb6908f,_0x54acc5,_0x5d2443['QoFbx']);const {storageStatePath:_0x1042b1,tempAuthPath:_0x18e67c}=await _0x5d2443[_0x1f5fb9(0x261)](resolveLocalAuthPath,getEnvDir(_0xae0b69));try{const _0x3fdb77=await buildPlaywrightConfigCore(_0x462fd6,_0x1042b1,_0xae0b69,_0xb6908f,_0x54acc5,_0x5d2443[_0x1f5fb9(0x20c)]);return{..._0x3fdb77,'tempAuthPath':_0x18e67c};}catch(_0x2e983e){_0x18e67c&&await _0x5d2443[_0x1f5fb9(0x261)](unlink,_0x18e67c)[_0x1f5fb9(0x257)](()=>{});throw _0x2e983e;}}export async function buildPlaywrightConfigCore(_0x5c849e,_0x3d5b1e,_0x225765,_0x37e57e,_0x2d08d5,_0x5851ad='stagehand'){const _0x2e0464=_0x2b2e19,_0x4150d2={'GmXro':_0x2e0464(0x1ff),'Ckskc':function(_0x21d4d0){return _0x21d4d0();},'Yeybr':function(_0x311aff,_0x12a9eb,_0x443051,_0x28a866){return _0x311aff(_0x12a9eb,_0x443051,_0x28a866);},'AgPQf':function(_0x3390e0){return _0x3390e0();},'NZdbz':function(_0x10f4ac,_0x38aa34){return _0x10f4ac(_0x38aa34);},'mbRsX':'chromium','OHDLK':function(_0x1d14b1,_0x1f1313){return _0x1d14b1===_0x1f1313;},'AtEIa':'file','DFhtg':'none','Wnkwn':_0x2e0464(0x250),'epDpc':_0x2e0464(0x25d),'gRUpQ':'vision','tURLa':_0x2e0464(0x264),'ScXni':function(_0x8dbfec,_0xeb77df,_0x318b44){return _0x8dbfec(_0xeb77df,_0x318b44);},'rmHsO':'ranger-config','aCglS':function(_0x562616,_0x29395d){return _0x562616(_0x29395d);},'JfsjF':'-cli','PpVRo':function(_0x4987bb,_0x291f1b,_0x4b4ebb){return _0x4987bb(_0x291f1b,_0x4b4ebb);}},_0x5e6bf0=_0x37e57e||_0x4150d2['Ckskc'](randomUUID),_0x164dd5=_0x4150d2['Yeybr'](join,_0x4150d2[_0x2e0464(0x241)](getRangerDir),'sessions',_0x5e6bf0),_0x2ebbe5=_0x4150d2['NZdbz'](Boolean,_0x5c849e[_0x2e0464(0x1fd)]),_0x698338=_0x2ebbe5?{'browserName':_0x4150d2[_0x2e0464(0x254)],'cdpEndpoint':_0x5c849e[_0x2e0464(0x1fd)]}:((()=>{const _0x1f5e7c=_0x2e0464,{launchOptions:_0x3e2323,contextOptions:_0x289e34}=buildBrowserOptionsFromSettings(_0x5c849e,{'headless':_0x2d08d5?![]:_0x5c849e[_0x1f5e7c(0x24b)]??!![],'storageStatePath':_0x3d5b1e});if(process[_0x1f5e7c(0x26b)]?.()===0x0){const _0x559e11=[_0x4150d2[_0x1f5e7c(0x21a)],_0x1f5e7c(0x25e)],_0xfe1fd6=_0x3e2323[_0x1f5e7c(0x20e)]??[],_0x39fad6=_0x559e11[_0x1f5e7c(0x237)](_0x5a0834=>!_0xfe1fd6[_0x1f5e7c(0x1f6)](_0x5a0834));_0x3e2323[_0x1f5e7c(0x20e)]=[..._0xfe1fd6,..._0x39fad6];}return{'isolated':!![],'browserName':'chromium','launchOptions':_0x3e2323,'contextOptions':{..._0x289e34,'permissions':['clipboard-read','clipboard-write'],'viewport':{'width':0x500,'height':0x2d0}}};})()),_0x37be67=_0x4150d2[_0x2e0464(0x268)](_0x5851ad,_0x2e0464(0x21d))?{'browser':_0x698338,'saveVideo':{'width':0x500,'height':0x2d0},'outputDir':_0x164dd5,'outputMode':_0x4150d2['AtEIa'],'codegen':_0x4150d2['DFhtg']}:{'name':_0x225765,'browser':_0x698338,'capabilities':[_0x4150d2['Wnkwn'],_0x4150d2['epDpc'],_0x4150d2['gRUpQ'],_0x2e0464(0x227)],'imageResponses':_0x4150d2['tURLa'],'outputDir':_0x164dd5};if(!_0x2ebbe5){const _0x2d79f2=_0x37be67['browser'],_0x5c7c3d=_0x2d79f2['contextOptions'];if(_0x5c7c3d[_0x2e0464(0x233)]===undefined)delete _0x5c7c3d['userAgent'];if(_0x4150d2[_0x2e0464(0x268)](_0x5c7c3d[_0x2e0464(0x234)],undefined))delete _0x5c7c3d[_0x2e0464(0x234)];}const _0x1b39e0=_0x4150d2[_0x2e0464(0x24d)](join,tmpdir(),_0x4150d2[_0x2e0464(0x223)]);!_0x4150d2['aCglS'](existsSync,_0x1b39e0)&&await mkdir(_0x1b39e0,{'recursive':!![]});const _0x11c8a7=_0x5851ad==='playwright-cli'?_0x4150d2['JfsjF']:'',_0xfba64f=_0x4150d2[_0x2e0464(0x228)](join,_0x1b39e0,_0x225765+'-'+Date['now']()+_0x11c8a7+'.json');return await writeFile(_0xfba64f,JSON['stringify'](_0x37be67,null,0x2)),{'configPath':_0xfba64f,'storageStatePath':_0x3d5b1e};}export async function buildPlaywrightCliConfig(_0x39c6bb,_0x37da18,_0x5c38b9,_0x1360e0,_0x233102){const _0x2753f1=_0x2b2e19,_0x5b8f15={'DjceI':_0x2753f1(0x21d),'XWKmL':function(_0x2b9301,_0x23c021,_0x1bed77,_0x3c7f6d,_0x2fab6c,_0x2de93d,_0x64c06){return _0x2b9301(_0x23c021,_0x1bed77,_0x3c7f6d,_0x2fab6c,_0x2de93d,_0x64c06);},'WAKbW':function(_0x487b83,_0x6b12ce){return _0x487b83(_0x6b12ce);}};if(_0x233102)return buildPlaywrightConfigCore(_0x39c6bb,_0x233102,_0x37da18,_0x5c38b9,_0x1360e0,_0x5b8f15[_0x2753f1(0x201)]);const {storageStatePath:_0x1351fc,tempAuthPath:_0x61596b}=await resolveLocalAuthPath(getEnvDir(_0x37da18));try{const _0x2655f7=await _0x5b8f15[_0x2753f1(0x205)](buildPlaywrightConfigCore,_0x39c6bb,_0x1351fc,_0x37da18,_0x5c38b9,_0x1360e0,_0x5b8f15['DjceI']);return{..._0x2655f7,'tempAuthPath':_0x61596b};}catch(_0x3e5b00){_0x61596b&&await _0x5b8f15['WAKbW'](unlink,_0x61596b)['catch'](()=>{});throw _0x3e5b00;}}export async function buildRangerwrightCliConfig(_0x58362d,_0x3b0bc8,_0x194519,_0xb5f0a7,_0x2d529b){const _0x5340bf=_0x2b2e19,_0x13c694={'KZifA':_0x5340bf(0x1ff),'qijPm':_0x5340bf(0x263),'NIBID':_0x5340bf(0x224),'LQpKY':function(_0x16cf67,_0x4ba335){return _0x16cf67(_0x4ba335);},'pgHro':function(_0x5d0dee,_0x528b2a,_0x57b4fd,_0x2f652c){return _0x5d0dee(_0x528b2a,_0x57b4fd,_0x2f652c);},'wmQoT':function(_0x183b6d){return _0x183b6d();},'UZKUi':'sessions','UeZYA':function(_0x1b27f9,_0x579739){return _0x1b27f9(_0x579739);},'XSQtF':_0x5340bf(0x247),'bHZAM':function(_0x517641,_0x2b9c14){return _0x517641===_0x2b9c14;},'yIfts':function(_0x274445,_0x1dd6b4){return _0x274445===_0x1dd6b4;},'YbUkT':function(_0x567ab6){return _0x567ab6();},'lQizN':function(_0x1e1cdf,_0x49f887,_0x38d906){return _0x1e1cdf(_0x49f887,_0x38d906);}},{storageStatePath:_0x3fd3e5,tempAuthPath:_0x5659a6}=_0x2d529b?{'storageStatePath':_0x2d529b,'tempAuthPath':undefined}:await resolveLocalAuthPath(_0x13c694[_0x5340bf(0x207)](getEnvDir,_0x3b0bc8)),_0x4b9e87=_0x194519||randomUUID(),_0x730049=_0x13c694['pgHro'](join,_0x13c694[_0x5340bf(0x232)](getRangerDir),_0x13c694['UZKUi'],_0x4b9e87),_0x3124d4=_0x13c694['UeZYA'](Boolean,_0x58362d[_0x5340bf(0x1fd)]),_0x240d6d=_0x3124d4?{'browserName':_0x13c694['XSQtF'],'cdpEndpoint':_0x58362d[_0x5340bf(0x1fd)]}:((()=>{const _0x129a63=_0x5340bf,{launchOptions:_0xc165a1,contextOptions:_0x5b9eec}=buildBrowserOptionsFromSettings(_0x58362d,{'headless':_0xb5f0a7?![]:_0x58362d['headless']??!![],'storageStatePath':_0x3fd3e5});if(process[_0x129a63(0x26b)]?.()===0x0){const _0x9445a9=[_0x13c694['KZifA'],_0x129a63(0x25e)],_0xf77d9e=_0xc165a1[_0x129a63(0x20e)]??[],_0x52e2a1=_0x9445a9['filter'](_0x20bcde=>!_0xf77d9e[_0x129a63(0x1f6)](_0x20bcde));_0xc165a1[_0x129a63(0x20e)]=[..._0xf77d9e,..._0x52e2a1];}return{'browserName':_0x129a63(0x247),'launchOptions':_0xc165a1,'contextOptions':{..._0x5b9eec,'permissions':[_0x13c694['qijPm'],_0x13c694[_0x129a63(0x1fe)]],'viewport':{'width':0x500,'height':0x2d0}}};})());if(!_0x3124d4){const _0x4c1685=_0x240d6d[_0x5340bf(0x217)];if(_0x4c1685){if(_0x13c694['bHZAM'](_0x4c1685['userAgent'],undefined))delete _0x4c1685[_0x5340bf(0x233)];if(_0x13c694[_0x5340bf(0x203)](_0x4c1685['storageState'],undefined))delete _0x4c1685[_0x5340bf(0x234)];}}const _0x80fe46={'browser':_0x240d6d,'outputDir':_0x730049,'saveTrace':!![],'saveVideo':{'width':0x500,'height':0x2d0},'settle':{'navigationLoadTimeoutMs':0x7530,'networkSettleTimeoutMs':0x1388,'networkIdleWindowMs':0x1f4,'postActionAnimationFrameCount':0x2}};let _0x5e0ba4;try{const _0x4b3af0=join(_0x13c694['YbUkT'](tmpdir),_0x5340bf(0x23b));!existsSync(_0x4b3af0)&&await mkdir(_0x4b3af0,{'recursive':!![]}),_0x5e0ba4=_0x13c694['lQizN'](join,_0x4b3af0,_0x3b0bc8+'-'+Date[_0x5340bf(0x246)]()+'-rangerwright.json'),await writeFile(_0x5e0ba4,JSON[_0x5340bf(0x202)](_0x80fe46,null,0x2));}catch(_0x14006f){_0x5659a6&&await unlink(_0x5659a6)[_0x5340bf(0x257)](()=>{});throw _0x14006f;}return{'configPath':_0x5e0ba4,'storageStatePath':_0x3fd3e5,'tempAuthPath':_0x5659a6,'outputDir':_0x730049};}export async function buildNovaActCliConfig(_0x17ca71,_0x16afb9,_0x2d4f64,_0x1ecfcc,_0x54ff9c){const _0x4e2599=_0x2b2e19,_0x57154d={'ISboD':function(_0x35f25a,_0xc4da7){return _0x35f25a(_0xc4da7);},'zUfIk':function(_0x1b2a93,_0x2222f1,_0x48b399,_0x11fc99){return _0x1b2a93(_0x2222f1,_0x48b399,_0x11fc99);},'TJysX':function(_0xcb67b7){return _0xcb67b7();},'WzmUz':'sessions','PElTr':function(_0x27f3f2,_0x27704b,_0x4e4d8f){return _0x27f3f2(_0x27704b,_0x4e4d8f);},'UMeiE':'nova-user-data','NPgpt':function(_0x3c85c0,_0x698099,_0xd295a3){return _0x3c85c0(_0x698099,_0xd295a3);},'JgfVM':function(_0x2bc21f,_0x230301){return _0x2bc21f===_0x230301;},'eDSfS':_0x4e2599(0x230)},{storageStatePath:_0x323bbb,tempAuthPath:_0x58e14f}=_0x54ff9c?{'storageStatePath':_0x54ff9c,'tempAuthPath':undefined}:await _0x57154d['ISboD'](resolveLocalAuthPath,getEnvDir(_0x16afb9)),_0xbb5223=_0x2d4f64||randomUUID(),_0x27e747=_0x57154d[_0x4e2599(0x216)](join,_0x57154d['TJysX'](getRangerDir),_0x57154d['WzmUz'],_0xbb5223),_0x5bbe31=_0x57154d['PElTr'](join,_0x27e747,_0x57154d['UMeiE']),_0x3656c5=_0x323bbb?_0x57154d['NPgpt'](join,_0x5bbe31,'Default'):undefined,{launchOptions:_0x2fe8e7,contextOptions:_0x37b809}=buildBrowserOptionsFromSettings(_0x17ca71,{'headless':_0x1ecfcc?![]:_0x17ca71[_0x4e2599(0x24b)]??!![],'storageStatePath':_0x323bbb});if(_0x57154d['JgfVM'](process['getuid']?.(),0x0)){const _0x2720bb=['--no-sandbox','--disable-setuid-sandbox'],_0x27dfa1=_0x2fe8e7['args']??[],_0x157283=_0x2720bb['filter'](_0x506843=>!_0x27dfa1[_0x4e2599(0x1f6)](_0x506843));_0x2fe8e7['args']=[..._0x27dfa1,..._0x157283];}const _0x11385d=typeof _0x2fe8e7['executablePath']===_0x57154d['eDSfS']?_0x2fe8e7[_0x4e2599(0x22f)]:_0x323bbb?chromium['executablePath']():undefined;return{'storageStatePath':_0x323bbb,'tempAuthPath':_0x58e14f,'baseUrl':_0x17ca71['baseUrl'],'headless':_0x57154d[_0x4e2599(0x226)](Boolean,_0x2fe8e7['headless']),'userDataDir':_0x5bbe31,'browserProfilePath':_0x3656c5,'executablePath':_0x11385d,'launchArgs':Array[_0x4e2599(0x25a)](_0x2fe8e7[_0x4e2599(0x20e)])?_0x2fe8e7['args'][_0x4e2599(0x237)](_0xb1bd1e=>typeof _0xb1bd1e===_0x4e2599(0x230)):[],'userAgent':_0x57154d['JgfVM'](typeof _0x37b809[_0x4e2599(0x233)],_0x4e2599(0x230))?_0x37b809['userAgent']:undefined,'extraHTTPHeaders':_0x37b809['extraHTTPHeaders'],'allowInsecureLocalhost':Boolean(_0x17ca71[_0x4e2599(0x204)]),'safeMode':Boolean(_0x17ca71[_0x4e2599(0x211)]),'cdpEndpoint':_0x17ca71['cdpEndpoint'],'isCdpMode':Boolean(_0x17ca71['cdpEndpoint'])};}export function getNestedValue(_0x70839e,_0x25e915){const _0x419864=_0x2b2e19,_0x26b15d={'GOutp':function(_0x8aa666,_0x3bd943){return _0x8aa666(_0x3bd943);},'OuuGU':function(_0x40437a,_0x4705dc){return _0x40437a===_0x4705dc;}},_0x1c2bc8=_0x26b15d['GOutp'](parseKeyPath,_0x25e915);let _0xddcf67=_0x70839e;for(const _0xe57840 of _0x1c2bc8){if(_0x26b15d[_0x419864(0x22d)](_0xddcf67,null)||_0x26b15d[_0x419864(0x22d)](_0xddcf67,undefined)||typeof _0xddcf67!=='object')return undefined;_0xddcf67=_0xddcf67[_0xe57840];}return _0xddcf67;}export function setNestedValue(_0x4b15fc,_0x20ac10,_0x25fa5c){const _0x1d9328=_0x2b2e19,_0x27ebc3={'jKWip':function(_0x1709a4,_0x2f9d4b){return _0x1709a4(_0x2f9d4b);},'Ddixh':function(_0xa7e849,_0x565e85){return _0xa7e849<_0x565e85;},'ZJXiE':function(_0x4972c1,_0x29bd4e){return _0x4972c1-_0x29bd4e;},'WNhJW':function(_0x46524a,_0x474f14){return _0x46524a!==_0x474f14;}},_0x26d50e=_0x27ebc3['jKWip'](parseKeyPath,_0x20ac10);let _0x4846c1=_0x4b15fc;for(let _0x15d1c4=0x0;_0x27ebc3[_0x1d9328(0x23e)](_0x15d1c4,_0x27ebc3['ZJXiE'](_0x26d50e['length'],0x1));_0x15d1c4++){const _0x6f461=_0x26d50e[_0x15d1c4];(!(_0x6f461 in _0x4846c1)||_0x27ebc3['WNhJW'](typeof _0x4846c1[_0x6f461],'object'))&&(_0x4846c1[_0x6f461]={}),_0x4846c1=_0x4846c1[_0x6f461];}_0x4846c1[_0x26d50e[_0x26d50e[_0x1d9328(0x22c)]-0x1]]=_0x25fa5c;}function _0x1ee5(_0x45c622,_0x5a8d89){_0x45c622=_0x45c622-0x1f1;const _0x718d77=_0x718d();let _0x1ee5d6=_0x718d77[_0x45c622];return _0x1ee5d6;}export function deleteNestedValue(_0x50d19a,_0x1ffc86){const _0x3418c5=_0x2b2e19,_0x119ed8={'qCpfO':function(_0x2c1c35,_0x4afb43){return _0x2c1c35(_0x4afb43);},'VioBL':function(_0x1ea657,_0x449c8f){return _0x1ea657<_0x449c8f;},'DoNfm':function(_0x21e2f8,_0x5b338c){return _0x21e2f8===_0x5b338c;},'Xqtue':function(_0x3b11d2,_0x13698c){return _0x3b11d2===_0x13698c;},'yiVTp':function(_0x1e7366,_0x5a75e4){return _0x1e7366!==_0x5a75e4;}},_0x20638a=_0x119ed8[_0x3418c5(0x1f4)](parseKeyPath,_0x1ffc86);let _0x1fd844=_0x50d19a;for(let _0x3681ff=0x0;_0x119ed8[_0x3418c5(0x22e)](_0x3681ff,_0x20638a['length']-0x1);_0x3681ff++){if(_0x119ed8['DoNfm'](_0x1fd844,null)||_0x119ed8[_0x3418c5(0x1f2)](_0x1fd844,undefined)||_0x119ed8['yiVTp'](typeof _0x1fd844,'object'))return![];_0x1fd844=_0x1fd844[_0x20638a[_0x3681ff]];}if(_0x1fd844===null||_0x1fd844===undefined||typeof _0x1fd844!==_0x3418c5(0x22b))return![];const _0x3cd58f=_0x20638a[_0x20638a['length']-0x1];if(_0x3cd58f in _0x1fd844)return delete _0x1fd844[_0x3cd58f],!![];return![];}function parseKeyPath(_0x18edcc){const _0x24b8d3=_0x2b2e19,_0x2f3829={'GaGCW':function(_0x10d49d,_0x35a610){return _0x10d49d===_0x35a610;},'kCuXs':function(_0x17bcfc,_0x136eb0){return _0x17bcfc===_0x136eb0;}},_0x579c7f=_0x18edcc['split']('.');return _0x2f3829[_0x24b8d3(0x21c)](_0x579c7f[0x0],'header')&&(_0x579c7f[0x0]='headers'),_0x2f3829['kCuXs'](_0x579c7f[0x0],_0x24b8d3(0x24a))&&(_0x579c7f[0x0]='setupHeaders'),_0x579c7f;}export function formatSettings(_0x953df5,_0x2f8870=0x0){const _0x357f28=_0x2b2e19,_0x1dd305={'nTrYi':function(_0x47dee3,_0x23a1d1){return _0x47dee3===_0x23a1d1;},'QvZes':'object'},_0x2c4740=[],_0x1d0223='\x20\x20'['repeat'](_0x2f8870);for(const [_0x471a71,_0x11553e]of Object[_0x357f28(0x262)](_0x953df5)){if(_0x11553e===undefined)continue;if(_0x1dd305[_0x357f28(0x244)](typeof _0x11553e,_0x1dd305[_0x357f28(0x23f)])&&_0x11553e!==null){_0x2c4740[_0x357f28(0x210)](''+_0x1d0223+_0x471a71+':');for(const [_0x27aa0c,_0x48e3f0]of Object[_0x357f28(0x262)](_0x11553e)){_0x2c4740['push'](_0x1d0223+'\x20\x20'+_0x27aa0c+':\x20'+_0x48e3f0);}}else _0x2c4740['push'](''+_0x1d0223+_0x471a71+':\x20'+_0x11553e);}return _0x2c4740['join']('\x0a');}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x3154fa,_0x532c16){const _0x2b596d=_0x1468,_0x16f57d=_0x3154fa();while(!![]){try{const _0x1133a9=parseInt(_0x2b596d(0x115))/0x1+parseInt(_0x2b596d(0x11d))/0x2*(-parseInt(_0x2b596d(0x11f))/0x3)+parseInt(_0x2b596d(0x116))/0x4+parseInt(_0x2b596d(0x11e))/0x5+-parseInt(_0x2b596d(0x114))/0x6*(parseInt(_0x2b596d(0x11b))/0x7)+-parseInt(_0x2b596d(0x119))/0x8*(-parseInt(_0x2b596d(0x120))/0x9)+-parseInt(_0x2b596d(0x118))/0xa;if(_0x1133a9===_0x532c16)break;else _0x16f57d['push'](_0x16f57d['shift']());}catch(_0x211d1c){_0x16f57d['push'](_0x16f57d['shift']());}}}(_0x565d,0x2cba8));function _0x1468(_0x5738af,_0x3cc70f){_0x5738af=_0x5738af-0x114;const _0x565d0d=_0x565d();let _0x146890=_0x565d0d[_0x5738af];return _0x146890;}import{readFileSync}from'fs';function _0x565d(){const _0x6ae689=['471462zwiujs','362491IdotDN','1258216CcqxWw','frBrQ','4582410IjsCuF','1505824ZGzaRy','utf-8','7wFUSTC','gihzb','10aghAqo','909340KRmBTy','196269NdxvRj','9HAMbtt'];_0x565d=function(){return _0x6ae689;};return _0x565d();}import{dirname,join}from'path';import{fileURLToPath}from'url';const __filename=fileURLToPath(import.meta.url),__dirname=dirname(__filename);export function readSkillContent(_0x381a8c){const _0x4f3eda=_0x1468,_0x48ad9b={'frBrQ':'skills','GOBKs':function(_0x10f627,_0x70402,_0x10bcfd){return _0x10f627(_0x70402,_0x10bcfd);}},_0x45696f=join(__dirname,'..','..',_0x48ad9b[_0x4f3eda(0x117)]),_0x2592b0=join(_0x45696f,_0x381a8c);try{return _0x48ad9b['GOBKs'](readFileSync,_0x2592b0,_0x4f3eda(0x11a));}catch{return'';}}export function getRangerSkillContent(){const _0x471b65=_0x1468,_0x57e02b={'gihzb':'ranger/SKILL.md'};return readSkillContent(_0x57e02b[_0x471b65(0x11c)]);}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x4475cd,_0x50f2ae){const _0x442cfc=_0x3511,_0x5e5100=_0x4475cd();while(!![]){try{const _0x321b98=parseInt(_0x442cfc(0x79))/0x1*(-parseInt(_0x442cfc(0x76))/0x2)+parseInt(_0x442cfc(0x78))/0x3*(parseInt(_0x442cfc(0x7d))/0x4)+-parseInt(_0x442cfc(0x7f))/0x5*(parseInt(_0x442cfc(0x83))/0x6)+-parseInt(_0x442cfc(0x6f))/0x7*(parseInt(_0x442cfc(0x73))/0x8)+-parseInt(_0x442cfc(0x86))/0x9+parseInt(_0x442cfc(0x72))/0xa*(-parseInt(_0x442cfc(0x71))/0xb)+parseInt(_0x442cfc(0x80))/0xc*(parseInt(_0x442cfc(0x70))/0xd);if(_0x321b98===_0x50f2ae)break;else _0x5e5100['push'](_0x5e5100['shift']());}catch(_0xc09758){_0x5e5100['push'](_0x5e5100['shift']());}}}(_0x4879,0x1c306));import{readFile,writeFile,mkdir,readdir,copyFile,rm}from'fs/promises';import{join,dirname}from'path';import{existsSync,statSync}from'fs';import{fileURLToPath}from'url';import{logLocalAgentInstallation}from'./localAgentInstallationsApi.js';import{getSkillsDir}from'./claudeConfig.js';function _0x4879(){const _0x551899=['XeCJK','join','24KIZXHy','.md','push','450801wSOWfr','log','filter','utf-8','\x20\x20Removed\x20deprecated\x20skill:\x20','trim','NWqIf','match','jGPbV','ONVdZ','\x20\x20Failed\x20to\x20remove\x20deprecated\x20skill:\x20','length','16051YLdbtt','13nGUxAY','64669vDXlJW','130FpOsZp','48tbeLOr','warn','catch','6702QIwWAe','opencode','114981jSnvCc','2vCGBus','\x20\x20Files:\x20','skills','\x20\x20Installed\x20skill:\x20','4esfnkh','project','249310QNofLk','5082708QrUXPy'];_0x4879=function(){return _0x551899;};return _0x4879();}import{getOpencodeSkillsDir}from'./opencodeConfig.js';const __filename=fileURLToPath(import.meta.url),__dirname=dirname(__filename);export const RANGER_MANAGED_SKILLS=['ranger'];function _0x3511(_0x475a73,_0x3c7ca3){_0x475a73=_0x475a73-0x6a;const _0x48792a=_0x4879();let _0x351111=_0x48792a[_0x475a73];return _0x351111;}export const DEPRECATED_SKILLS=['e2e-test-recommender','bug-bash','feature-tracker'];export async function installSkill(_0xc75d55,_0x68bf94={}){const _0x3b31d2=_0x3511,_0xf2cbf={'cVmzq':_0x3b31d2(0x7e),'whOwK':function(_0x4dd6d2,_0x18df6d,_0xcd4de8){return _0x4dd6d2(_0x18df6d,_0xcd4de8);},'QvdwD':function(_0x1caeb0,_0x424c2c){return _0x1caeb0(_0x424c2c);},'fZTnV':function(_0x340fb3,_0x2dafb8){return _0x340fb3(_0x2dafb8);},'jGPbV':'SKILL.md','ONVdZ':function(_0x4401d4,_0xece407){return _0x4401d4(_0xece407);},'iBiLD':function(_0x1ae2cd,_0x2e56a3){return _0x1ae2cd===_0x2e56a3;},'tHjDu':function(_0x5e388b,_0x20fcf6,_0x323218){return _0x5e388b(_0x20fcf6,_0x323218);},'RJbnA':function(_0x5d49ea,_0x31fcab,_0x463cb8){return _0x5d49ea(_0x31fcab,_0x463cb8);},'RuEJY':_0x3b31d2(0x89),'NWqIf':function(_0x5b5137,_0x507674){return _0x5b5137>_0x507674;},'XeCJK':function(_0x4ae31d,_0x5abea7,_0x1ca03b,_0x31f9da){return _0x4ae31d(_0x5abea7,_0x1ca03b,_0x31f9da);}},{level:level=_0xf2cbf['cVmzq'],cliVersion:_0x577b9a,platform:platform='claude'}=_0x68bf94,_0xb79d22=getSourceSkillsDir(),_0x28bc92=join(_0xb79d22,_0xc75d55),_0x33d33f=_0xf2cbf['whOwK'](join,_0xb79d22,_0xc75d55+_0x3b31d2(0x84)),_0x7fe96d=_0xf2cbf['QvdwD'](existsSync,_0x28bc92)&&_0xf2cbf['QvdwD'](statSync,_0x28bc92)['isDirectory']()&&_0xf2cbf['fZTnV'](existsSync,join(_0x28bc92,_0xf2cbf[_0x3b31d2(0x6b)])),_0xb95347=_0xf2cbf[_0x3b31d2(0x6c)](existsSync,_0x33d33f);if(!_0x7fe96d&&!_0xb95347)return console[_0x3b31d2(0x74)]('\x20\x20Skill\x20not\x20found:\x20'+_0xc75d55),![];const _0x4f294e=_0xf2cbf['iBiLD'](platform,_0x3b31d2(0x77))?getOpencodeSkillsDir(level):getSkillsDir(level),_0x2a510d=join(_0x4f294e,_0xc75d55);await mkdir(_0x2a510d,{'recursive':!![]});let _0x1a8be7,_0x2c253e=[];if(_0x7fe96d){const _0x5e90c4=await readdir(_0x28bc92),_0x4d91a3=_0x5e90c4[_0x3b31d2(0x88)](_0x4ecd63=>_0x4ecd63['endsWith'](_0x3b31d2(0x84)));for(const _0x23b9e1 of _0x4d91a3){const _0x9c1882=_0xf2cbf['tHjDu'](join,_0x28bc92,_0x23b9e1),_0x411bb9=join(_0x2a510d,_0x23b9e1);await _0xf2cbf['RJbnA'](copyFile,_0x9c1882,_0x411bb9),_0x2c253e['push'](_0x23b9e1);}_0x1a8be7=await _0xf2cbf['whOwK'](readFile,join(_0x28bc92,_0xf2cbf['jGPbV']),_0xf2cbf['RuEJY']);}else{_0x1a8be7=await readFile(_0x33d33f,_0xf2cbf['RuEJY']);const _0x424214=_0xf2cbf['tHjDu'](join,_0x2a510d,_0xf2cbf['jGPbV']);await writeFile(_0x424214,_0x1a8be7,_0x3b31d2(0x89)),_0x2c253e[_0x3b31d2(0x85)](_0xf2cbf['jGPbV']);}const {name:_0x140f56}=parseFrontmatter(_0x1a8be7);return console[_0x3b31d2(0x87)](_0x3b31d2(0x7c)+_0x140f56),console[_0x3b31d2(0x87)]('\x20\x20Location:\x20'+_0x2a510d),_0xf2cbf[_0x3b31d2(0x8c)](_0x2c253e[_0x3b31d2(0x6e)],0x1)&&console[_0x3b31d2(0x87)](_0x3b31d2(0x7a)+_0x2c253e[_0x3b31d2(0x82)](',\x20')),_0xf2cbf[_0x3b31d2(0x81)](logLocalAgentInstallation,_0xc75d55,{'skillDisplayName':_0x140f56,'installLevel':level},_0x577b9a)[_0x3b31d2(0x75)](()=>{}),!![];}function getSourceSkillsDir(){const _0x3a830d=_0x3511,_0x3234b8=[join(__dirname,'..','..',_0x3a830d(0x7b)),join(__dirname,'..','..','..',_0x3a830d(0x7b))];for(const _0x467959 of _0x3234b8){if(existsSync(_0x467959))return _0x467959;}return _0x3234b8[0x0];}function parseFrontmatter(_0x5adb96){const _0x26684f=_0x3511,_0xe75c53=_0x5adb96[_0x26684f(0x6a)](/^---\n([\s\S]+?)\n---/);if(!_0xe75c53)throw new Error('Invalid\x20skill\x20frontmatter');const _0x4750ee=_0xe75c53[0x1],_0x38ac48=_0x4750ee['match'](/name:\s*(.+)/),_0x4e935e=_0x4750ee[_0x26684f(0x6a)](/description:\s*"?(.+?)"?\n/);return{'name':_0x38ac48?.[0x1][_0x26684f(0x8b)]()||'','description':_0x4e935e?.[0x1]['trim']()||''};}export async function removeSkill(_0x56c647,_0x5289cc){const _0x3fbf2c=_0x3511,_0x18a3b0={'sAEux':function(_0x4d5154,_0x46b0d6,_0xef7121){return _0x4d5154(_0x46b0d6,_0xef7121);}},_0xd17bfb=getSkillsDir(_0x5289cc),_0x504e32=_0x18a3b0['sAEux'](join,_0xd17bfb,_0x56c647);if(!existsSync(_0x504e32))return![];try{return await _0x18a3b0['sAEux'](rm,_0x504e32,{'recursive':!![]}),console['log'](_0x3fbf2c(0x8a)+_0x56c647),!![];}catch{return console['warn'](_0x3fbf2c(0x6d)+_0x56c647),![];}}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const _0x21fdc8=_0x23ab;(function(_0x4a3293,_0x593627){const _0x2f5b7f=_0x23ab,_0x8f758=_0x4a3293();while(!![]){try{const _0x2c083b=parseInt(_0x2f5b7f(0x20f))/0x1+parseInt(_0x2f5b7f(0x22d))/0x2+-parseInt(_0x2f5b7f(0x201))/0x3*(parseInt(_0x2f5b7f(0x21d))/0x4)+-parseInt(_0x2f5b7f(0x202))/0x5+parseInt(_0x2f5b7f(0x219))/0x6+parseInt(_0x2f5b7f(0x207))/0x7*(-parseInt(_0x2f5b7f(0x224))/0x8)+parseInt(_0x2f5b7f(0x223))/0x9;if(_0x2c083b===_0x593627)break;else _0x8f758['push'](_0x8f758['shift']());}catch(_0x4b85ae){_0x8f758['push'](_0x8f758['shift']());}}}(_0x242a,0x9684e));import{readFileSync,writeFileSync}from'fs';const ID_SEGMENT=0x18538067,ID_INFO=0x1549a966,ID_CLUSTER=0x1f43b675,ID_TIMESTAMP=0xe7,ID_TIMESTAMP_SCALE=0x2ad7b1,ID_SIMPLE_BLOCK=0xa3;function readVint(_0x4d9793,_0x321190){const _0x635cbb=_0x23ab,_0x466e1b={'fGksK':function(_0x1e4e82,_0x1ff757){return _0x1e4e82>=_0x1ff757;},'fOxwb':function(_0x2925d5,_0x1e698e){return _0x2925d5>_0x1e698e;},'TwiRy':function(_0x577d91,_0x459ac8){return _0x577d91&_0x459ac8;},'vaKsl':function(_0x45a1a3,_0x251953){return _0x45a1a3*_0x251953;},'dxvNM':function(_0x400b5a,_0x288ed4){return _0x400b5a+_0x288ed4;}};if(_0x466e1b[_0x635cbb(0x213)](_0x321190,_0x4d9793[_0x635cbb(0x21c)]))return[0x0,0x0];const _0x1ab646=_0x4d9793[_0x321190];let _0x504332=0x1,_0x2c46f1=0x80;while(_0x504332<=0x8&&!(_0x1ab646&_0x2c46f1)){_0x504332++,_0x2c46f1>>=0x1;}if(_0x466e1b['fOxwb'](_0x321190+_0x504332,_0x4d9793['length']))return[0x0,0x0];let _0x386f57=_0x466e1b['TwiRy'](_0x1ab646,_0x2c46f1-0x1);for(let _0x5cae54=0x1;_0x5cae54<_0x504332;_0x5cae54++){_0x386f57=_0x466e1b[_0x635cbb(0x218)](_0x386f57,0x100)+_0x4d9793[_0x466e1b[_0x635cbb(0x225)](_0x321190,_0x5cae54)];}return[_0x386f57,_0x504332];}function readId(_0x2d6e74,_0x58119e){const _0x71d7c4=_0x23ab,_0x4efa59={'RtQRs':function(_0x594f85,_0xfeae35){return _0x594f85>=_0xfeae35;},'oXGiw':function(_0x4a6e92,_0x4be6b6){return _0x4a6e92+_0x4be6b6;},'DCZJw':function(_0x48f1d7,_0x818fad){return _0x48f1d7<_0x818fad;},'jlenZ':function(_0x44c41f,_0x8c9658){return _0x44c41f*_0x8c9658;}};if(_0x4efa59['RtQRs'](_0x58119e,_0x2d6e74['length']))return[0x0,0x0];const _0x5ae76c=_0x2d6e74[_0x58119e];let _0x5b5516;if(_0x5ae76c>=0x80)_0x5b5516=0x1;else{if(_0x5ae76c>=0x40)_0x5b5516=0x2;else{if(_0x5ae76c>=0x20)_0x5b5516=0x3;else{if(_0x4efa59['RtQRs'](_0x5ae76c,0x10))_0x5b5516=0x4;else return[_0x5ae76c,0x1];}}}if(_0x4efa59[_0x71d7c4(0x1f3)](_0x58119e,_0x5b5516)>_0x2d6e74[_0x71d7c4(0x21c)])return[0x0,0x0];let _0x240535=0x0;for(let _0x38b3eb=0x0;_0x4efa59[_0x71d7c4(0x203)](_0x38b3eb,_0x5b5516);_0x38b3eb++){_0x240535=_0x4efa59[_0x71d7c4(0x217)](_0x240535,0x100)+_0x2d6e74[_0x4efa59['oXGiw'](_0x58119e,_0x38b3eb)];}return[_0x240535,_0x5b5516];}function readUint(_0x554779,_0x5ac609,_0x5b98ae){const _0x576fd5=_0x23ab,_0x4efd15={'zadMA':function(_0x4142c1,_0x29bc81){return _0x4142c1<_0x29bc81;},'jMNuI':function(_0x2fc9c9,_0x2fb2be){return _0x2fc9c9+_0x2fb2be;}};let _0x24cd66=0x0;for(let _0x5235d5=0x0;_0x4efd15['zadMA'](_0x5235d5,_0x5b98ae);_0x5235d5++){_0x24cd66=_0x4efd15[_0x576fd5(0x1f6)](_0x24cd66*0x100,_0x554779[_0x5ac609+_0x5235d5]);}return _0x24cd66;}function isUnknownSize(_0x590ef2,_0x5e49e9){const _0x5c2024=_0x23ab,_0x114cef={'hNpDQ':function(_0x1f4d19,_0x19238d){return _0x1f4d19===_0x19238d;},'gglBa':function(_0x355b7a,_0x4805d4){return _0x355b7a-_0x4805d4;},'hBMRM':function(_0x124c40,_0x31da40){return _0x124c40*_0x31da40;}};return _0x114cef[_0x5c2024(0x205)](_0x590ef2,_0x114cef[_0x5c2024(0x1f2)](Math['pow'](0x2,_0x114cef[_0x5c2024(0x209)](0x7,_0x5e49e9)),0x1));}function writeVint(_0x3bea5f,_0x1e173f){const _0xf5b0ed=_0x23ab,_0x72670d={'vtAkZ':function(_0x20350b,_0x2e2fd6){return _0x20350b*_0x2e2fd6;},'RoKBV':function(_0x4aff62,_0x271570){return _0x4aff62-_0x271570;},'Ydxbw':function(_0x2fdf5f,_0x4683b3){return _0x2fdf5f/_0x4683b3;},'BJHTb':function(_0x33ad32,_0x5d14e7){return _0x33ad32<<_0x5d14e7;}};let _0x3f6336=_0x1e173f||0x1;while(Math[_0xf5b0ed(0x1fc)](0x2,_0x72670d[_0xf5b0ed(0x1ff)](0x7,_0x3f6336))-0x2<_0x3bea5f)_0x3f6336++;const _0x5cde85=Buffer[_0xf5b0ed(0x211)](_0x3f6336);for(let _0xa2da23=_0x72670d[_0xf5b0ed(0x220)](_0x3f6336,0x1);_0xa2da23>=0x0;_0xa2da23--){_0x5cde85[_0xa2da23]=_0x3bea5f&0xff,_0x3bea5f=Math[_0xf5b0ed(0x227)](_0x72670d['Ydxbw'](_0x3bea5f,0x100));}return _0x5cde85[0x0]|=_0x72670d[_0xf5b0ed(0x21b)](0x1,0x8-_0x3f6336),_0x5cde85;}function writeUint(_0x45abe7,_0x16e45f){const _0x317df0=Buffer['alloc'](_0x16e45f);for(let _0x54a873=_0x16e45f-0x1;_0x54a873>=0x0;_0x54a873--){_0x317df0[_0x54a873]=_0x45abe7&0xff,_0x45abe7=Math['floor'](_0x45abe7/0x100);}return _0x317df0;}function writeUnknownSizeVint(_0x3172b1){const _0x10482d=_0x23ab,_0x2a6c77={'Awlbl':function(_0x74dc23,_0x327486){return _0x74dc23>>_0x327486;}},_0x3901d8=Buffer[_0x10482d(0x211)](_0x3172b1,0xff);return _0x3901d8[0x0]=_0x2a6c77[_0x10482d(0x206)](0xff,_0x3172b1-0x1),_0x3901d8;}function uintSize(_0xd9593c){const _0xd3e1be={'IfYzE':function(_0x10d300,_0x49717c){return _0x10d300===_0x49717c;},'SnSuA':function(_0x4c0758,_0x1abae8){return _0x4c0758/_0x1abae8;}};if(_0xd3e1be['IfYzE'](_0xd9593c,0x0))return 0x1;let _0x24a653=0x0,_0x9298b3=_0xd9593c;while(_0x9298b3>0x0){_0x24a653++,_0x9298b3=Math['floor'](_0xd3e1be['SnSuA'](_0x9298b3,0x100));}return _0x24a653;}function findTimestampScale(_0x7bb326,_0x5b5f11){const _0x1fe238=_0x23ab,_0x4a5489={'XjdqJ':function(_0xf55cd9,_0x463825){return _0xf55cd9<_0x463825;},'lNwEV':function(_0x300a26,_0x4d95fe,_0x4fcc12){return _0x300a26(_0x4d95fe,_0x4fcc12);},'iWNTA':function(_0x353f1f,_0x42abb6,_0x449989){return _0x353f1f(_0x42abb6,_0x449989);},'rvndl':function(_0x6e0de8,_0x1a928b){return _0x6e0de8+_0x1a928b;},'cGFxy':function(_0x2e9f1f,_0x1c8902){return _0x2e9f1f+_0x1c8902;},'yiZKA':function(_0x4ca8f3,_0x127e76,_0x1b2351){return _0x4ca8f3(_0x127e76,_0x1b2351);},'gQwfD':function(_0x21781d,_0x13dd82){return _0x21781d+_0x13dd82;},'VThgG':function(_0x2c9511,_0x118a61){return _0x2c9511===_0x118a61;},'cfxYu':function(_0x54cdc6,_0xef1051){return _0x54cdc6+_0xef1051;}};let _0x267e77=_0x5b5f11;const _0x11425d=Math['min'](_0x7bb326[_0x1fe238(0x21c)],_0x5b5f11+0x2710);while(_0x4a5489['XjdqJ'](_0x267e77,_0x11425d)){const [_0x221bc4,_0x58d96c]=_0x4a5489[_0x1fe238(0x1f8)](readId,_0x7bb326,_0x267e77),[_0x3c6987,_0x23a93a]=_0x4a5489[_0x1fe238(0x20a)](readVint,_0x7bb326,_0x267e77+_0x58d96c);if(_0x221bc4===ID_INFO){let _0xfe9b9c=_0x4a5489[_0x1fe238(0x20b)](_0x267e77,_0x58d96c)+_0x23a93a;const _0x4eebe9=_0x4a5489['cGFxy'](_0xfe9b9c,_0x3c6987);while(_0xfe9b9c<_0x4eebe9){const [_0x5bb9f3,_0xfca710]=_0x4a5489['yiZKA'](readId,_0x7bb326,_0xfe9b9c),[_0x569257,_0xd18568]=_0x4a5489['yiZKA'](readVint,_0x7bb326,_0xfe9b9c+_0xfca710);if(_0x5bb9f3===ID_TIMESTAMP_SCALE)return readUint(_0x7bb326,_0x4a5489['rvndl'](_0x4a5489[_0x1fe238(0x210)](_0xfe9b9c,_0xfca710),_0xd18568),_0x569257);_0xfe9b9c+=_0xfca710+_0xd18568+_0x569257;}break;}if(_0x4a5489['VThgG'](_0x221bc4,ID_CLUSTER))break;if(isUnknownSize(_0x3c6987,_0x23a93a))break;_0x267e77+=_0x4a5489[_0x1fe238(0x1fd)](_0x58d96c,_0x23a93a)+_0x3c6987;}return 0xf4240;}function findFirstClusterOffset(_0x494c49,_0x6269ba){const _0x12616e=_0x23ab,_0x5c456c={'MvpyC':function(_0x4ff5c1,_0xc8410f){return _0x4ff5c1<_0xc8410f;},'TiWgR':function(_0x13cd64,_0x58b7b0,_0x2f381c){return _0x13cd64(_0x58b7b0,_0x2f381c);},'FXhLL':function(_0x7a00c4,_0x418fbc){return _0x7a00c4+_0x418fbc;},'wIBLw':function(_0x2be097,_0xd5f515){return _0x2be097+_0xd5f515;}};let _0x30aecf=_0x6269ba;while(_0x5c456c[_0x12616e(0x1f9)](_0x30aecf,_0x494c49[_0x12616e(0x21c)])){const [_0x36201b,_0x4d62ed]=_0x5c456c['TiWgR'](readId,_0x494c49,_0x30aecf);if(_0x36201b===ID_CLUSTER)return _0x30aecf;const [_0x126b3e,_0x4dae3a]=_0x5c456c['TiWgR'](readVint,_0x494c49,_0x5c456c['FXhLL'](_0x30aecf,_0x4d62ed));if(isUnknownSize(_0x126b3e,_0x4dae3a))return _0x30aecf;_0x30aecf+=_0x5c456c[_0x12616e(0x200)](_0x4d62ed,_0x4dae3a)+_0x126b3e;}return _0x494c49[_0x12616e(0x21c)];}function findClusterEnd(_0x36ddd4,_0x23ca96,_0x4d89e6,_0x26735b){const _0x4a46a4=_0x23ab,_0x4e0ebf={'Jaxlt':function(_0x516cc2,_0x192cdb){return _0x516cc2-_0x192cdb;},'gzYAi':function(_0x11ff23,_0x4bfb8f,_0x47c17f){return _0x11ff23(_0x4bfb8f,_0x47c17f);},'HLbFi':function(_0x3cfa31,_0x50163f){return _0x3cfa31+_0x50163f;}};if(!isUnknownSize(_0x4d89e6,_0x26735b))return _0x23ca96+_0x4d89e6;const _0x5a2655=new Set([ID_CLUSTER,0x1c53bb6b,0x1254c367]);let _0x215643=_0x23ca96;while(_0x215643<_0x4e0ebf[_0x4a46a4(0x222)](_0x36ddd4['length'],0x4)){const [_0x25a6e1,_0x1effdf]=readId(_0x36ddd4,_0x215643);if(_0x5a2655['has'](_0x25a6e1))return _0x215643;const [_0x3c89f6,_0x28f8b6]=_0x4e0ebf['gzYAi'](readVint,_0x36ddd4,_0x215643+_0x1effdf);if(isUnknownSize(_0x3c89f6,_0x28f8b6))return _0x36ddd4['length'];_0x215643+=_0x4e0ebf[_0x4a46a4(0x1ef)](_0x1effdf+_0x28f8b6,_0x3c89f6);}return _0x36ddd4[_0x4a46a4(0x21c)];}function extractClusters(_0x5a0a4b,_0x527832){const _0x2d2a8b=_0x23ab,_0x3b5c66={'yqEch':function(_0x5d1311,_0x61ead3){return _0x5d1311===_0x61ead3;},'zPBCs':function(_0x4f2b76,_0x523edd){return _0x4f2b76!==_0x523edd;},'jxwru':function(_0x19266d,_0x47ebf1){return _0x19266d+_0x47ebf1;},'xTzGv':function(_0x49cdaa,_0x50a987,_0x20b010,_0x39b08a,_0x2114bf){return _0x49cdaa(_0x50a987,_0x20b010,_0x39b08a,_0x2114bf);},'rUIzP':function(_0x39ba5f,_0x47de50,_0x24ffc0){return _0x39ba5f(_0x47de50,_0x24ffc0);},'XsDrZ':function(_0x5b4595,_0x5f45fd,_0x345da2,_0x3d78ec){return _0x5b4595(_0x5f45fd,_0x345da2,_0x3d78ec);},'VdaKM':function(_0x4835cb,_0x271b54){return _0x4835cb+_0x271b54;},'ZEyEN':function(_0x5ba8f6,_0x1727be){return _0x5ba8f6<_0x1727be;},'KWUkA':function(_0x2ddffe,_0x221367,_0x49dbce){return _0x2ddffe(_0x221367,_0x49dbce);},'CUxwK':function(_0x445159,_0x57835a){return _0x445159+_0x57835a;},'XnGKF':function(_0x41ef1c,_0xfd8298){return _0x41ef1c>_0xfd8298;},'MLGcy':function(_0x1ac16d,_0x1ab18b){return _0x1ac16d===_0x1ab18b;},'knWHa':function(_0x19a7db,_0x1707a9){return _0x19a7db+_0x1707a9;},'thEVD':function(_0x19d582,_0xecbb1e){return _0x19d582+_0xecbb1e;}},_0x221c32=[],_0xa5a2a7=Buffer['from']([0x1f,0x43,0xb6,0x75]);let _0x1cc28e=0x0;while(_0x1cc28e<_0x5a0a4b[_0x2d2a8b(0x21c)]){const _0x39c845=_0x5a0a4b[_0x2d2a8b(0x226)](_0xa5a2a7,_0x1cc28e);if(_0x3b5c66[_0x2d2a8b(0x1f5)](_0x39c845,-0x1))break;const [_0x4e5ef2,_0x11150b]=readId(_0x5a0a4b,_0x39c845);if(_0x3b5c66['zPBCs'](_0x4e5ef2,ID_CLUSTER)){_0x1cc28e=_0x39c845+0x1;continue;}const [_0xa24945,_0x37cc22]=readVint(_0x5a0a4b,_0x3b5c66[_0x2d2a8b(0x22f)](_0x39c845,_0x11150b)),_0x152958=_0x39c845+_0x11150b+_0x37cc22,_0x4cb91f=_0x3b5c66['xTzGv'](findClusterEnd,_0x5a0a4b,_0x152958,_0xa24945,_0x37cc22);let _0x58c163=_0x152958,_0x5cd879=0x0,_0x1834cb=0x2,_0x3dc39e=![],_0x44ff9b=Buffer[_0x2d2a8b(0x211)](0x0),_0x35cecc=Buffer['alloc'](0x0);while(_0x58c163<_0x4cb91f){const [_0x2d9bac,_0x3b22fd]=readId(_0x5a0a4b,_0x58c163),[_0x2f8f50,_0x5db758]=_0x3b5c66[_0x2d2a8b(0x231)](readVint,_0x5a0a4b,_0x3b5c66[_0x2d2a8b(0x22f)](_0x58c163,_0x3b22fd));if(_0x2d9bac===ID_TIMESTAMP){_0x5cd879=_0x3b5c66['XsDrZ'](readUint,_0x5a0a4b,_0x3b5c66['VdaKM'](_0x58c163+_0x3b22fd,_0x5db758),_0x2f8f50),_0x1834cb=_0x2f8f50,_0x3dc39e=!![],_0x44ff9b=_0x5a0a4b['slice'](_0x152958,_0x58c163);const _0x38f9d5=_0x3b5c66[_0x2d2a8b(0x22f)](_0x3b5c66['jxwru'](_0x58c163+_0x3b22fd,_0x5db758),_0x2f8f50);_0x35cecc=_0x5a0a4b['slice'](_0x38f9d5,_0x4cb91f);break;}if(_0x2d9bac===ID_CLUSTER)break;if(isUnknownSize(_0x2f8f50,_0x5db758))break;_0x58c163+=_0x3b5c66[_0x2d2a8b(0x20c)](_0x3b5c66['VdaKM'](_0x3b22fd,_0x5db758),_0x2f8f50);}!_0x3dc39e&&(_0x35cecc=_0x5a0a4b[_0x2d2a8b(0x22e)](_0x152958,_0x4cb91f));let _0x24068e=_0x5cd879;_0x58c163=_0x152958;while(_0x3b5c66['ZEyEN'](_0x58c163,_0x4cb91f)){const [_0x196be1,_0x3eb2ff]=_0x3b5c66[_0x2d2a8b(0x22c)](readId,_0x5a0a4b,_0x58c163),[_0x52e216,_0x1ff436]=_0x3b5c66['rUIzP'](readVint,_0x5a0a4b,_0x58c163+_0x3eb2ff);if(_0x3b5c66['yqEch'](_0x196be1,ID_SIMPLE_BLOCK)&&_0x52e216>=0x4){const _0x37e899=_0x3b5c66['CUxwK'](_0x58c163+_0x3eb2ff,_0x1ff436),[,_0x56bb98]=readVint(_0x5a0a4b,_0x37e899),_0x2513da=_0x5a0a4b[_0x2d2a8b(0x1fa)](_0x3b5c66[_0x2d2a8b(0x20c)](_0x37e899,_0x56bb98)),_0x53cbc5=_0x5cd879+_0x2513da;if(_0x3b5c66['XnGKF'](_0x53cbc5,_0x24068e))_0x24068e=_0x53cbc5;}if(_0x3b5c66['MLGcy'](_0x196be1,ID_CLUSTER))break;if(isUnknownSize(_0x52e216,_0x1ff436))break;_0x58c163+=_0x3b5c66[_0x2d2a8b(0x208)](_0x3b5c66['thEVD'](_0x3eb2ff,_0x1ff436),_0x52e216);}_0x221c32[_0x2d2a8b(0x232)]({'timestamp':_0x5cd879,'maxTicks':_0x24068e,'bodyBeforeTimestamp':_0x44ff9b,'bodyAfterTimestamp':_0x35cecc,'timestampElementSize':_0x1834cb}),_0x1cc28e=_0x4cb91f;}return _0x221c32;}function parseWebm(_0xeb0659){const _0x43a6eb=_0x23ab,_0x565754={'iFyTc':function(_0x5a2a0c,_0xb3b1eb,_0x3be606){return _0x5a2a0c(_0xb3b1eb,_0x3be606);},'CRshU':function(_0x528c8d,_0x463566){return _0x528c8d+_0x463566;},'wooVM':function(_0x2f6be7,_0xf9cda4){return _0x2f6be7!==_0xf9cda4;},'xLPaQ':function(_0x592419,_0x2e8443,_0x2f4548){return _0x592419(_0x2e8443,_0x2f4548);},'DzHrP':function(_0x2d8d26,_0x41fba8){return _0x2d8d26+_0x41fba8;},'GIZBv':function(_0x12a4a7,_0x2ecf0e){return _0x12a4a7+_0x2ecf0e;}};let _0x5d9b77=0x0;const [,_0x2ca045]=_0x565754[_0x43a6eb(0x1f4)](readId,_0xeb0659,_0x5d9b77),[_0x5b4421,_0x7c9df9]=readVint(_0xeb0659,_0x5d9b77+_0x2ca045);_0x5d9b77+=_0x565754[_0x43a6eb(0x22a)](_0x2ca045+_0x7c9df9,_0x5b4421);const [_0x2f4bca,_0x264a58]=readId(_0xeb0659,_0x5d9b77);if(_0x565754['wooVM'](_0x2f4bca,ID_SEGMENT))return null;const [,_0x23ed42]=_0x565754['xLPaQ'](readVint,_0xeb0659,_0x5d9b77+_0x264a58),_0x1d1ffc=_0x565754[_0x43a6eb(0x1f7)](_0x565754['GIZBv'](_0x5d9b77,_0x264a58),_0x23ed42),_0x27185f=findTimestampScale(_0xeb0659,_0x1d1ffc),_0xc2948a=findFirstClusterOffset(_0xeb0659,_0x1d1ffc),_0x186967=_0xeb0659['slice'](0x0,_0xc2948a),_0x4c1bd1=extractClusters(_0xeb0659,_0x27185f);let _0x179b42=0x0;for(const _0x12d80e of _0x4c1bd1){if(_0x12d80e['maxTicks']>_0x179b42)_0x179b42=_0x12d80e['maxTicks'];}return{'header':_0x186967,'clusters':_0x4c1bd1,'timestampScale':_0x27185f,'maxTimestampTicks':_0x179b42};}function _0x23ab(_0x1c84f1,_0x4f2378){_0x1c84f1=_0x1c84f1-0x1ef;const _0x242ad3=_0x242a();let _0x23ab8a=_0x242ad3[_0x1c84f1];return _0x23ab8a;}function _0x242a(){const _0x3e757d=['slice','jxwru','clusters','rUIzP','push','HLbFi','endsWith','puQle','gglBa','oXGiw','iFyTc','yqEch','jMNuI','DzHrP','lNwEV','MvpyC','readInt16BE','argv','pow','cfxYu','bodyBeforeTimestamp','vtAkZ','wIBLw','3549QlDmDJ','6084545dtOpug','DCZJw','hiAlj','hNpDQ','Awlbl','1246MeHnhj','knWHa','hBMRM','iWNTA','rvndl','VdaKM','copy','nqDQG','927730SXfgUL','gQwfD','alloc','hvgog','fGksK','Stitching\x20failed\x20or\x20only\x20one\x20input\x20file.','gdZiQ','from','jlenZ','vaKsl','3973146tqpeyp','Usage:\x20stitchWebmFiles\x20<input1.webm>\x20<input2.webm>\x20[...]\x20<output.webm>','BJHTb','length','40gyhxnV','XJwRs','XacxZ','RoKBV','concat','Jaxlt','2490498dMppPu','22680LMKICS','dxvNM','indexOf','floor','stitchWebmFiles.ts','ScPfY','CRshU','log','KWUkA','966504TfmTMZ'];_0x242a=function(){return _0x3e757d;};return _0x242a();}function buildCluster(_0x5a04e6,_0x51ba8f,_0x54104f){const _0x1d8ce7=_0x23ab,_0x4a5019={'CHqcT':function(_0x496293,_0x4db431,_0x35d305){return _0x496293(_0x4db431,_0x35d305);},'XdRXp':function(_0x5426b5,_0x2501f3){return _0x5426b5(_0x2501f3);}},_0xf318e7=Buffer[_0x1d8ce7(0x216)]([0x1f,0x43,0xb6,0x75]),_0x9f019c=Math['max'](0x4,uintSize(_0x5a04e6)),_0x33ad50=Buffer['concat']([Buffer[_0x1d8ce7(0x216)]([ID_TIMESTAMP]),writeVint(_0x9f019c),_0x4a5019['CHqcT'](writeUint,_0x5a04e6,_0x9f019c)]),_0x1a3836=Buffer[_0x1d8ce7(0x221)]([_0x51ba8f,_0x33ad50,_0x54104f]),_0x539908=_0x4a5019['XdRXp'](writeVint,_0x1a3836[_0x1d8ce7(0x21c)]);return Buffer[_0x1d8ce7(0x221)]([_0xf318e7,_0x539908,_0x1a3836]);}const ID_DURATION=0x4489;function rebuildHeaderWithoutDuration(_0x313bee){const _0x3d1fa5=_0x23ab,_0x4002c9={'TfpYO':function(_0x5d5341,_0x30f075){return _0x5d5341+_0x30f075;},'XJwRs':function(_0x44218c,_0x255be4){return _0x44218c+_0x255be4;},'hvgog':function(_0xcfd650,_0x185c6a,_0x3b3877){return _0xcfd650(_0x185c6a,_0x3b3877);},'ScPfY':function(_0x4f408f,_0x4d108e){return _0x4f408f(_0x4d108e);},'gdZiQ':function(_0x1a3095,_0x15c518,_0x38f9d0){return _0x1a3095(_0x15c518,_0x38f9d0);},'XacxZ':function(_0x1b7670,_0x281000){return _0x1b7670===_0x281000;},'BKqbw':function(_0x5057de,_0x5ef136){return _0x5057de<_0x5ef136;},'puQle':function(_0x539c2a,_0x5f0645,_0x42698d){return _0x539c2a(_0x5f0645,_0x42698d);},'Uzyij':function(_0x1d6f70,_0x10eb8b){return _0x1d6f70+_0x10eb8b;},'spTAp':function(_0xbd454,_0x5ec5f0){return _0xbd454!==_0x5ec5f0;}},_0x4a5da6=Buffer['from'](_0x313bee);let _0x405c26=0x0;const [,_0x4e7e53]=readId(_0x4a5da6,_0x405c26),[_0x5c0682,_0x13fc3f]=readVint(_0x4a5da6,_0x4002c9['TfpYO'](_0x405c26,_0x4e7e53)),_0x5b2b68=_0x4002c9[_0x3d1fa5(0x21e)](_0x405c26,_0x4e7e53)+_0x13fc3f+_0x5c0682,[,_0x8dedac]=_0x4002c9[_0x3d1fa5(0x212)](readId,_0x4a5da6,_0x5b2b68),[,_0x161370]=_0x4002c9[_0x3d1fa5(0x212)](readVint,_0x4a5da6,_0x4002c9[_0x3d1fa5(0x21e)](_0x5b2b68,_0x8dedac)),_0x2c6628=_0x5b2b68+_0x8dedac+_0x161370,_0x137915=_0x4002c9[_0x3d1fa5(0x229)](writeUnknownSizeVint,_0x161370);_0x137915[_0x3d1fa5(0x20d)](_0x4a5da6,_0x5b2b68+_0x8dedac);let _0x43e732=_0x2c6628;const _0x5aa8e7=Math['min'](_0x4a5da6['length'],_0x2c6628+0x2710);while(_0x43e732<_0x5aa8e7){const [_0x5ec8d0,_0x1e40a9]=_0x4002c9[_0x3d1fa5(0x215)](readId,_0x4a5da6,_0x43e732),[_0xec47ba,_0x27c038]=readVint(_0x4a5da6,_0x4002c9['TfpYO'](_0x43e732,_0x1e40a9));if(_0x4002c9['XacxZ'](_0x5ec8d0,ID_CLUSTER))break;if(_0x4002c9[_0x3d1fa5(0x215)](isUnknownSize,_0xec47ba,_0x27c038))break;if(_0x4002c9[_0x3d1fa5(0x21f)](_0x5ec8d0,ID_INFO)){const _0x40a6bf=_0x43e732+_0x1e40a9+_0x27c038,_0x53021c=_0x40a6bf+_0xec47ba,_0x571a52=[];let _0x156ae3=_0x40a6bf;while(_0x4002c9['BKqbw'](_0x156ae3,_0x53021c)){const [_0x5f4d5f,_0x3ab7cc]=_0x4002c9[_0x3d1fa5(0x212)](readId,_0x4a5da6,_0x156ae3),[_0x2ddfd4,_0x424795]=_0x4002c9['puQle'](readVint,_0x4a5da6,_0x4002c9['TfpYO'](_0x156ae3,_0x3ab7cc)),_0x2b9825=_0x4002c9['Uzyij'](_0x3ab7cc,_0x424795)+_0x2ddfd4;_0x4002c9['spTAp'](_0x5f4d5f,ID_DURATION)&&_0x571a52[_0x3d1fa5(0x232)](_0x4a5da6[_0x3d1fa5(0x22e)](_0x156ae3,_0x156ae3+_0x2b9825)),_0x156ae3+=_0x2b9825;}const _0x3e635a=Buffer[_0x3d1fa5(0x221)](_0x571a52),_0x481961=Buffer[_0x3d1fa5(0x221)]([_0x4a5da6['slice'](_0x43e732,_0x43e732+_0x1e40a9),_0x4002c9[_0x3d1fa5(0x1f1)](writeVint,_0x3e635a[_0x3d1fa5(0x21c)],_0x27c038)]);return Buffer['concat']([_0x4a5da6['slice'](0x0,_0x43e732),_0x481961,_0x3e635a,_0x4a5da6['slice'](_0x53021c)]);}_0x43e732+=_0x1e40a9+_0x27c038+_0xec47ba;}return _0x4a5da6;}export function stitchWebmFiles(_0x57bbff,_0x1721da){const _0x715296=_0x23ab,_0x1ae5c={'ZvzxM':function(_0x13be19,_0x30b240){return _0x13be19(_0x30b240);},'IQXTY':function(_0x2573d8,_0x15660d){return _0x2573d8(_0x15660d);},'ZKFxO':function(_0x481d19,_0x2f3481){return _0x481d19===_0x2f3481;},'hiAlj':function(_0x4a59d0,_0x4eb693,_0x5b2918,_0x417200){return _0x4a59d0(_0x4eb693,_0x5b2918,_0x417200);},'nqDQG':function(_0x3aa213,_0x4c2824,_0x28fb91){return _0x3aa213(_0x4c2824,_0x28fb91);}};if(_0x57bbff[_0x715296(0x21c)]<=0x1)return![];const _0x42da6e=[];for(const _0xbcd37e of _0x57bbff){const _0x7833a4=_0x1ae5c['ZvzxM'](readFileSync,_0xbcd37e),_0x589e3d=_0x1ae5c['IQXTY'](parseWebm,_0x7833a4);if(!_0x589e3d||_0x1ae5c['ZKFxO'](_0x589e3d[_0x715296(0x230)]['length'],0x0))return![];_0x42da6e['push'](_0x589e3d);}const _0x248415=_0x42da6e[0x0],_0x1be245=_0x1ae5c['ZvzxM'](rebuildHeaderWithoutDuration,_0x248415['header']),_0x30ce1b=[_0x1be245];let _0x42b30b=0x0;for(let _0x694983=0x0;_0x694983<_0x42da6e[_0x715296(0x21c)];_0x694983++){const _0x243eb5=_0x42da6e[_0x694983];for(const _0xd24a2c of _0x243eb5[_0x715296(0x230)]){const _0x122d83=_0xd24a2c['timestamp']+_0x42b30b;_0x30ce1b['push'](_0x1ae5c[_0x715296(0x204)](buildCluster,_0x122d83,_0xd24a2c[_0x715296(0x1fe)],_0xd24a2c['bodyAfterTimestamp']));}const _0x5276b3=0x1e;_0x42b30b+=_0x243eb5['maxTimestampTicks']+_0x5276b3;}return _0x1ae5c[_0x715296(0x20e)](writeFileSync,_0x1721da,Buffer['concat'](_0x30ce1b)),!![];}if(process['argv'][0x1]?.[_0x21fdc8(0x1f0)](_0x21fdc8(0x228))||process['argv'][0x1]?.['endsWith']('stitchWebmFiles.js')){const args=process[_0x21fdc8(0x1fb)][_0x21fdc8(0x22e)](0x2);args[_0x21fdc8(0x21c)]<0x3&&(console['error'](_0x21fdc8(0x21a)),process['exit'](0x1));const output=args[args['length']-0x1],inputs=args['slice'](0x0,-0x1),ok=stitchWebmFiles(inputs,output);ok?console['log']('Stitched\x20'+inputs[_0x21fdc8(0x21c)]+'\x20files\x20->\x20'+output):console[_0x21fdc8(0x22b)](_0x21fdc8(0x214));}
|
|
1
|
+
const _0x4e7c39=_0xe647;(function(_0x3d7d83,_0x498843){const _0x2186b8=_0xe647,_0x2cbe6c=_0x3d7d83();while(!![]){try{const _0x5a512c=parseInt(_0x2186b8(0x171))/0x1+parseInt(_0x2186b8(0x177))/0x2*(parseInt(_0x2186b8(0x13c))/0x3)+parseInt(_0x2186b8(0x148))/0x4*(-parseInt(_0x2186b8(0x164))/0x5)+parseInt(_0x2186b8(0x14b))/0x6*(-parseInt(_0x2186b8(0x16b))/0x7)+-parseInt(_0x2186b8(0x17b))/0x8*(parseInt(_0x2186b8(0x152))/0x9)+-parseInt(_0x2186b8(0x151))/0xa*(-parseInt(_0x2186b8(0x144))/0xb)+-parseInt(_0x2186b8(0x14c))/0xc;if(_0x5a512c===_0x498843)break;else _0x2cbe6c['push'](_0x2cbe6c['shift']());}catch(_0x3afe1c){_0x2cbe6c['push'](_0x2cbe6c['shift']());}}}(_0x5525,0x35e6d));import{readFileSync,writeFileSync}from'fs';const ID_SEGMENT=0x18538067,ID_INFO=0x1549a966,ID_CLUSTER=0x1f43b675,ID_TIMESTAMP=0xe7,ID_TIMESTAMP_SCALE=0x2ad7b1,ID_SIMPLE_BLOCK=0xa3;function _0xe647(_0x679c77,_0x33c61d){_0x679c77=_0x679c77-0x12f;const _0x55256f=_0x5525();let _0xe6478f=_0x55256f[_0x679c77];return _0xe6478f;}function readVint(_0x3568bb,_0x520f5d){const _0x5d0b69=_0xe647,_0xc330ac={'muReE':function(_0x1ef1c1,_0x1ff4f7){return _0x1ef1c1+_0x1ff4f7;},'PwHuh':function(_0x5e338d,_0x1550e8){return _0x5e338d&_0x1550e8;},'BKvOx':function(_0x101eac,_0x1e320c){return _0x101eac-_0x1e320c;},'MLnur':function(_0x36baca,_0x33e584){return _0x36baca<_0x33e584;}};if(_0x520f5d>=_0x3568bb[_0x5d0b69(0x162)])return[0x0,0x0];const _0x5262e4=_0x3568bb[_0x520f5d];let _0x2bdf97=0x1,_0x274105=0x80;while(_0x2bdf97<=0x8&&!(_0x5262e4&_0x274105)){_0x2bdf97++,_0x274105>>=0x1;}if(_0xc330ac[_0x5d0b69(0x170)](_0x520f5d,_0x2bdf97)>_0x3568bb[_0x5d0b69(0x162)])return[0x0,0x0];let _0x26294b=_0xc330ac[_0x5d0b69(0x143)](_0x5262e4,_0xc330ac['BKvOx'](_0x274105,0x1));for(let _0xe0b40a=0x1;_0xc330ac['MLnur'](_0xe0b40a,_0x2bdf97);_0xe0b40a++){_0x26294b=_0xc330ac[_0x5d0b69(0x170)](_0x26294b*0x100,_0x3568bb[_0x520f5d+_0xe0b40a]);}return[_0x26294b,_0x2bdf97];}function readId(_0x3e5412,_0x4d774f){const _0x1336e2=_0xe647,_0x29012e={'HQXQq':function(_0x4394a8,_0x443f63){return _0x4394a8>=_0x443f63;},'TIgra':function(_0x5caf8f,_0x20a75d){return _0x5caf8f>=_0x20a75d;},'CEnDu':function(_0x5d6b1d,_0x431167){return _0x5d6b1d>=_0x431167;},'sULcw':function(_0x3f49f8,_0x4d8a6c){return _0x3f49f8>_0x4d8a6c;},'Rgkca':function(_0x47823d,_0x4411a7){return _0x47823d+_0x4411a7;},'XNCSc':function(_0x4d4b7b,_0x13e2ac){return _0x4d4b7b<_0x13e2ac;},'iuggx':function(_0x183847,_0x1e3755){return _0x183847+_0x1e3755;}};if(_0x29012e['HQXQq'](_0x4d774f,_0x3e5412[_0x1336e2(0x162)]))return[0x0,0x0];const _0xd40c24=_0x3e5412[_0x4d774f];let _0x584e1c;if(_0x29012e[_0x1336e2(0x15d)](_0xd40c24,0x80))_0x584e1c=0x1;else{if(_0xd40c24>=0x40)_0x584e1c=0x2;else{if(_0x29012e['CEnDu'](_0xd40c24,0x20))_0x584e1c=0x3;else{if(_0xd40c24>=0x10)_0x584e1c=0x4;else return[_0xd40c24,0x1];}}}if(_0x29012e[_0x1336e2(0x15b)](_0x29012e[_0x1336e2(0x15e)](_0x4d774f,_0x584e1c),_0x3e5412[_0x1336e2(0x162)]))return[0x0,0x0];let _0x24815c=0x0;for(let _0x576bb9=0x0;_0x29012e['XNCSc'](_0x576bb9,_0x584e1c);_0x576bb9++){_0x24815c=_0x29012e['iuggx'](_0x24815c*0x100,_0x3e5412[_0x4d774f+_0x576bb9]);}return[_0x24815c,_0x584e1c];}function readUint(_0x2aca6f,_0x49b206,_0x1ccc02){const _0x227e38=_0xe647,_0x53518c={'ABEtr':function(_0x5ac128,_0x29baf4){return _0x5ac128<_0x29baf4;},'sZokz':function(_0x5d1ed1,_0x4410af){return _0x5d1ed1+_0x4410af;}};let _0x2978b9=0x0;for(let _0x39e794=0x0;_0x53518c[_0x227e38(0x161)](_0x39e794,_0x1ccc02);_0x39e794++){_0x2978b9=_0x2978b9*0x100+_0x2aca6f[_0x53518c['sZokz'](_0x49b206,_0x39e794)];}return _0x2978b9;}function isUnknownSize(_0x149e56,_0x3f51fd){const _0x5904ad=_0xe647,_0x31cca9={'DzTaL':function(_0x2383ae,_0x347a55){return _0x2383ae-_0x347a55;}};return _0x149e56===_0x31cca9['DzTaL'](Math[_0x5904ad(0x130)](0x2,0x7*_0x3f51fd),0x1);}function writeVint(_0x5ca290,_0x20df12){const _0x310229=_0xe647,_0x40fbff={'bZQjq':function(_0x227931,_0x34fa66){return _0x227931<_0x34fa66;},'QmUAV':function(_0x4bc871,_0x123beb){return _0x4bc871-_0x123beb;},'qXAsw':function(_0x4d4fba,_0x45c3a4){return _0x4d4fba&_0x45c3a4;},'OlJWU':function(_0x57bc6f,_0x252339){return _0x57bc6f/_0x252339;},'ONVyC':function(_0x2382c6,_0x527948){return _0x2382c6<<_0x527948;}};let _0x3aa4bc=_0x20df12||0x1;while(_0x40fbff['bZQjq'](_0x40fbff[_0x310229(0x167)](Math[_0x310229(0x130)](0x2,0x7*_0x3aa4bc),0x2),_0x5ca290))_0x3aa4bc++;const _0x119e50=Buffer[_0x310229(0x14e)](_0x3aa4bc);for(let _0x11ef3e=_0x3aa4bc-0x1;_0x11ef3e>=0x0;_0x11ef3e--){_0x119e50[_0x11ef3e]=_0x40fbff['qXAsw'](_0x5ca290,0xff),_0x5ca290=Math[_0x310229(0x153)](_0x40fbff[_0x310229(0x178)](_0x5ca290,0x100));}return _0x119e50[0x0]|=_0x40fbff['ONVyC'](0x1,0x8-_0x3aa4bc),_0x119e50;}function _0x5525(){const _0x4d9fa9=['rVHOq','PwHuh','22IulrJm','Usage:\x20stitchWebmFiles\x20<input1.webm>\x20<input2.webm>\x20[...]\x20<output.webm>','gTfLY','GpvoZ','944cpkLji','aiiZN','push','6MLZyWv','738180XDJDsn','msQXl','alloc','readInt16BE','wfGVs','1910620tODxhu','1791IyzUfB','floor','Stitching\x20failed\x20or\x20only\x20one\x20input\x20file.','byTSo','Idqwm','BUrFF','bodyBeforeTimestamp','header','JOMLT','sULcw','QYAqR','TIgra','Rgkca','max','bodyAfterTimestamp','ABEtr','length','NVDDZ','2355yRXtMA','slice','GbvFo','QmUAV','FHdRh','has','shHFl','1871492sKMBxL','yAERU','BtXQX','copy','cNcCf','muReE','329490wXtlXM','ztNty','maxTicks','vIIxv','ENLXS','from','32KKvWSc','OlJWU','QNXdP','XXABv','10576JLlZiH','clusters','pow','TjTrT','dAGCn','exit','KlxpK','maxTimestampTicks','log','pbXiW','KCLtV','concat','OWFpJ','Stitched\x20','39801EvJCKE','yBsFF','lWqXB','indexOf','KEwrN','endsWith'];_0x5525=function(){return _0x4d9fa9;};return _0x5525();}function writeUint(_0x16df05,_0x415ae9){const _0x2481e6=_0xe647,_0x2ba712={'YCyVW':function(_0x337156,_0x3c7aa4){return _0x337156>=_0x3c7aa4;},'BEJDx':function(_0x59a52f,_0xdc419a){return _0x59a52f&_0xdc419a;}},_0x54fb57=Buffer[_0x2481e6(0x14e)](_0x415ae9);for(let _0x24191e=_0x415ae9-0x1;_0x2ba712['YCyVW'](_0x24191e,0x0);_0x24191e--){_0x54fb57[_0x24191e]=_0x2ba712['BEJDx'](_0x16df05,0xff),_0x16df05=Math['floor'](_0x16df05/0x100);}return _0x54fb57;}function writeUnknownSizeVint(_0x533550){const _0x47183c=Buffer['alloc'](_0x533550,0xff);return _0x47183c[0x0]=0xff>>_0x533550-0x1,_0x47183c;}function uintSize(_0xbac7f9){const _0x7d3bb5=_0xe647,_0x1aa0dd={'byTSo':function(_0x4fb5b1,_0x208806){return _0x4fb5b1===_0x208806;},'NpjHf':function(_0x2c2dfb,_0x4d702c){return _0x2c2dfb>_0x4d702c;},'bQhup':function(_0x365289,_0x454bb6){return _0x365289/_0x454bb6;}};if(_0x1aa0dd[_0x7d3bb5(0x155)](_0xbac7f9,0x0))return 0x1;let _0x51e650=0x0,_0x33e43a=_0xbac7f9;while(_0x1aa0dd['NpjHf'](_0x33e43a,0x0)){_0x51e650++,_0x33e43a=Math[_0x7d3bb5(0x153)](_0x1aa0dd['bQhup'](_0x33e43a,0x100));}return _0x51e650;}function findTimestampScale(_0x57b9be,_0x335cd9){const _0x4c80df=_0xe647,_0x55fedf={'btYmu':function(_0x491eee,_0x1b1844){return _0x491eee<_0x1b1844;},'rVHOq':function(_0x54df32,_0x9e4e55,_0x4420a7){return _0x54df32(_0x9e4e55,_0x4420a7);},'GbvFo':function(_0x5990bc,_0x50760e){return _0x5990bc+_0x50760e;},'pbXiW':function(_0x3be979,_0x4c1956){return _0x3be979===_0x4c1956;},'TzGiw':function(_0x128770,_0x29ab31){return _0x128770+_0x29ab31;},'shHFl':function(_0x4e3c39,_0x122598){return _0x4e3c39===_0x122598;},'Idqwm':function(_0x7ae4d5,_0x3ad72b,_0x423d1b,_0x6d851){return _0x7ae4d5(_0x3ad72b,_0x423d1b,_0x6d851);},'SKwoP':function(_0x385042,_0x493bb9){return _0x385042+_0x493bb9;},'OWFpJ':function(_0xcd18d1,_0x41d0db){return _0xcd18d1+_0x41d0db;},'QYAqR':function(_0x1c603f,_0x3df5b1){return _0x1c603f+_0x3df5b1;}};let _0x4b3629=_0x335cd9;const _0x11538e=Math['min'](_0x57b9be['length'],_0x335cd9+0x2710);while(_0x55fedf['btYmu'](_0x4b3629,_0x11538e)){const [_0x228cfa,_0x5851fa]=_0x55fedf[_0x4c80df(0x142)](readId,_0x57b9be,_0x4b3629),[_0x644cc6,_0x4b110e]=_0x55fedf[_0x4c80df(0x142)](readVint,_0x57b9be,_0x55fedf['GbvFo'](_0x4b3629,_0x5851fa));if(_0x55fedf[_0x4c80df(0x137)](_0x228cfa,ID_INFO)){let _0x255022=_0x55fedf[_0x4c80df(0x166)](_0x4b3629+_0x5851fa,_0x4b110e);const _0x39be69=_0x55fedf['TzGiw'](_0x255022,_0x644cc6);while(_0x255022<_0x39be69){const [_0x3d1042,_0x560081]=_0x55fedf[_0x4c80df(0x142)](readId,_0x57b9be,_0x255022),[_0x496368,_0x365d51]=_0x55fedf[_0x4c80df(0x142)](readVint,_0x57b9be,_0x55fedf['TzGiw'](_0x255022,_0x560081));if(_0x55fedf[_0x4c80df(0x16a)](_0x3d1042,ID_TIMESTAMP_SCALE))return _0x55fedf[_0x4c80df(0x156)](readUint,_0x57b9be,_0x55fedf[_0x4c80df(0x166)](_0x255022,_0x560081)+_0x365d51,_0x496368);_0x255022+=_0x55fedf['SKwoP'](_0x560081,_0x365d51)+_0x496368;}break;}if(_0x55fedf[_0x4c80df(0x16a)](_0x228cfa,ID_CLUSTER))break;if(isUnknownSize(_0x644cc6,_0x4b110e))break;_0x4b3629+=_0x55fedf[_0x4c80df(0x13a)](_0x55fedf[_0x4c80df(0x15c)](_0x5851fa,_0x4b110e),_0x644cc6);}return 0xf4240;}function findFirstClusterOffset(_0x12d488,_0x3e177a){const _0x240252=_0xe647,_0x65c5c1={'FDEdP':function(_0x18bb78,_0x4103c5,_0x5a8093){return _0x18bb78(_0x4103c5,_0x5a8093);},'QjPBB':function(_0x93d457,_0x148430,_0x1796e3){return _0x93d457(_0x148430,_0x1796e3);},'vIIxv':function(_0x382308,_0x51501c){return _0x382308+_0x51501c;}};let _0x40d8be=_0x3e177a;while(_0x40d8be<_0x12d488['length']){const [_0x2075c1,_0x264077]=readId(_0x12d488,_0x40d8be);if(_0x2075c1===ID_CLUSTER)return _0x40d8be;const [_0x2f277d,_0x5b3e85]=_0x65c5c1['FDEdP'](readVint,_0x12d488,_0x40d8be+_0x264077);if(_0x65c5c1['QjPBB'](isUnknownSize,_0x2f277d,_0x5b3e85))return _0x40d8be;_0x40d8be+=_0x65c5c1[_0x240252(0x174)](_0x264077,_0x5b3e85)+_0x2f277d;}return _0x12d488['length'];}function findClusterEnd(_0x47f445,_0x2da1ec,_0x1010aa,_0x4ebd45){const _0x135846=_0xe647,_0x3a11d7={'foXFW':function(_0x5605e4,_0x260e18){return _0x5605e4-_0x260e18;},'BUrFF':function(_0x8f3f79,_0x53826a,_0x1c8d00){return _0x8f3f79(_0x53826a,_0x1c8d00);},'KEwrN':function(_0x21add3,_0x52757f){return _0x21add3+_0x52757f;}};if(!isUnknownSize(_0x1010aa,_0x4ebd45))return _0x2da1ec+_0x1010aa;const _0x371fa1=new Set([ID_CLUSTER,0x1c53bb6b,0x1254c367]);let _0x5de4e6=_0x2da1ec;while(_0x5de4e6<_0x3a11d7['foXFW'](_0x47f445['length'],0x4)){const [_0x2a60a0,_0x4024bc]=_0x3a11d7[_0x135846(0x157)](readId,_0x47f445,_0x5de4e6);if(_0x371fa1[_0x135846(0x169)](_0x2a60a0))return _0x5de4e6;const [_0x34fe72,_0x4d2fbd]=readVint(_0x47f445,_0x5de4e6+_0x4024bc);if(_0x3a11d7['BUrFF'](isUnknownSize,_0x34fe72,_0x4d2fbd))return _0x47f445[_0x135846(0x162)];_0x5de4e6+=_0x3a11d7[_0x135846(0x140)](_0x4024bc+_0x4d2fbd,_0x34fe72);}return _0x47f445[_0x135846(0x162)];}function extractClusters(_0x5387a9,_0x582efe){const _0x3b7624=_0xe647,_0x481ee0={'ENLXS':function(_0x44a09a,_0x70c157,_0x21c89c){return _0x44a09a(_0x70c157,_0x21c89c);},'dAGCn':function(_0x495375,_0x3db05a){return _0x495375+_0x3db05a;},'FHdRh':function(_0x26f464,_0x351d43){return _0x26f464+_0x351d43;},'BtXQX':function(_0x9fb3cf,_0x5eb2b8,_0x2cd593,_0x275c79,_0x5d9f46){return _0x9fb3cf(_0x5eb2b8,_0x2cd593,_0x275c79,_0x5d9f46);},'dHTLU':function(_0x5e0417,_0x43b4a5){return _0x5e0417===_0x43b4a5;},'KCLtV':function(_0x5e3f0f,_0x673602,_0x16f3f5,_0x17702a){return _0x5e3f0f(_0x673602,_0x16f3f5,_0x17702a);},'ZMNPk':function(_0x157adb,_0x5152ee,_0x4d1803){return _0x157adb(_0x5152ee,_0x4d1803);},'yBsFF':function(_0x435fe,_0x1871f2){return _0x435fe+_0x1871f2;},'NVDDZ':function(_0x4b8927,_0x47f8e1){return _0x4b8927+_0x47f8e1;}},_0x41832f=[],_0x2948dc=Buffer[_0x3b7624(0x176)]([0x1f,0x43,0xb6,0x75]);let _0x249104=0x0;while(_0x249104<_0x5387a9['length']){const _0x457023=_0x5387a9[_0x3b7624(0x13f)](_0x2948dc,_0x249104);if(_0x457023===-0x1)break;const [_0x409b18,_0x155661]=_0x481ee0[_0x3b7624(0x175)](readId,_0x5387a9,_0x457023);if(_0x409b18!==ID_CLUSTER){_0x249104=_0x481ee0['dAGCn'](_0x457023,0x1);continue;}const [_0x87cdf9,_0x365751]=_0x481ee0[_0x3b7624(0x175)](readVint,_0x5387a9,_0x481ee0['FHdRh'](_0x457023,_0x155661)),_0x191ac9=_0x481ee0['FHdRh'](_0x457023+_0x155661,_0x365751),_0x360a06=_0x481ee0[_0x3b7624(0x16d)](findClusterEnd,_0x5387a9,_0x191ac9,_0x87cdf9,_0x365751);let _0x17990e=_0x191ac9,_0x42040f=0x0,_0x320cee=0x2,_0x38e580=![],_0x3a724b=Buffer['alloc'](0x0),_0x63ff89=Buffer[_0x3b7624(0x14e)](0x0);while(_0x17990e<_0x360a06){const [_0x5cfb3e,_0x25c0f0]=_0x481ee0['ENLXS'](readId,_0x5387a9,_0x17990e),[_0x22e228,_0x57ab2e]=readVint(_0x5387a9,_0x17990e+_0x25c0f0);if(_0x481ee0['dHTLU'](_0x5cfb3e,ID_TIMESTAMP)){_0x42040f=_0x481ee0[_0x3b7624(0x138)](readUint,_0x5387a9,_0x481ee0[_0x3b7624(0x168)](_0x17990e+_0x25c0f0,_0x57ab2e),_0x22e228),_0x320cee=_0x22e228,_0x38e580=!![],_0x3a724b=_0x5387a9['slice'](_0x191ac9,_0x17990e);const _0x3341a2=_0x481ee0['dAGCn'](_0x17990e+_0x25c0f0,_0x57ab2e)+_0x22e228;_0x63ff89=_0x5387a9['slice'](_0x3341a2,_0x360a06);break;}if(_0x5cfb3e===ID_CLUSTER)break;if(isUnknownSize(_0x22e228,_0x57ab2e))break;_0x17990e+=_0x481ee0[_0x3b7624(0x132)](_0x481ee0[_0x3b7624(0x132)](_0x25c0f0,_0x57ab2e),_0x22e228);}!_0x38e580&&(_0x63ff89=_0x5387a9[_0x3b7624(0x165)](_0x191ac9,_0x360a06));let _0x3c8d31=_0x42040f;_0x17990e=_0x191ac9;while(_0x17990e<_0x360a06){const [_0x422e24,_0x1539a9]=_0x481ee0['ZMNPk'](readId,_0x5387a9,_0x17990e),[_0x4f9374,_0x45fd20]=readVint(_0x5387a9,_0x17990e+_0x1539a9);if(_0x422e24===ID_SIMPLE_BLOCK&&_0x4f9374>=0x4){const _0x582ab8=_0x481ee0['FHdRh'](_0x17990e,_0x1539a9)+_0x45fd20,[,_0x5ea713]=readVint(_0x5387a9,_0x582ab8),_0x1313a0=_0x5387a9[_0x3b7624(0x14f)](_0x481ee0[_0x3b7624(0x13d)](_0x582ab8,_0x5ea713)),_0x1006c8=_0x481ee0[_0x3b7624(0x163)](_0x42040f,_0x1313a0);if(_0x1006c8>_0x3c8d31)_0x3c8d31=_0x1006c8;}if(_0x481ee0['dHTLU'](_0x422e24,ID_CLUSTER))break;if(isUnknownSize(_0x4f9374,_0x45fd20))break;_0x17990e+=_0x1539a9+_0x45fd20+_0x4f9374;}_0x41832f['push']({'timestamp':_0x42040f,'maxTicks':_0x3c8d31,'bodyBeforeTimestamp':_0x3a724b,'bodyAfterTimestamp':_0x63ff89,'timestampElementSize':_0x320cee}),_0x249104=_0x360a06;}return _0x41832f;}function parseWebm(_0x34f8ea){const _0x4f9555=_0xe647,_0x128688={'ESlXl':function(_0x1d9d8e,_0x1b60f8,_0x1becb8){return _0x1d9d8e(_0x1b60f8,_0x1becb8);},'JOMLT':function(_0xaf9cb7,_0x564d8d){return _0xaf9cb7+_0x564d8d;},'MuLDP':function(_0x33498d,_0x17d322,_0x7a7dac){return _0x33498d(_0x17d322,_0x7a7dac);},'GpvoZ':function(_0x919e94,_0x4377df){return _0x919e94>_0x4377df;}};let _0x4904db=0x0;const [,_0x303d9c]=_0x128688['ESlXl'](readId,_0x34f8ea,_0x4904db),[_0x3ebb01,_0x49dc96]=readVint(_0x34f8ea,_0x128688[_0x4f9555(0x15a)](_0x4904db,_0x303d9c));_0x4904db+=_0x128688['JOMLT'](_0x303d9c,_0x49dc96)+_0x3ebb01;const [_0x3efa18,_0x96d55e]=readId(_0x34f8ea,_0x4904db);if(_0x3efa18!==ID_SEGMENT)return null;const [,_0x248bd2]=readVint(_0x34f8ea,_0x4904db+_0x96d55e),_0x1ecd8a=_0x128688['JOMLT'](_0x4904db+_0x96d55e,_0x248bd2),_0x5065a6=findTimestampScale(_0x34f8ea,_0x1ecd8a),_0x4055c0=_0x128688['MuLDP'](findFirstClusterOffset,_0x34f8ea,_0x1ecd8a),_0x5707b8=_0x34f8ea['slice'](0x0,_0x4055c0),_0x287720=_0x128688['ESlXl'](extractClusters,_0x34f8ea,_0x5065a6);let _0x2d4e77=0x0;for(const _0x462ff7 of _0x287720){if(_0x128688[_0x4f9555(0x147)](_0x462ff7['maxTicks'],_0x2d4e77))_0x2d4e77=_0x462ff7[_0x4f9555(0x173)];}return{'header':_0x5707b8,'clusters':_0x287720,'timestampScale':_0x5065a6,'maxTimestampTicks':_0x2d4e77};}function buildCluster(_0x35573b,_0x583128,_0x2d41f0){const _0x593268=_0xe647,_0x8893fa={'TjTrT':function(_0x322209,_0x1b0c92){return _0x322209(_0x1b0c92);}},_0x3fabbd=Buffer['from']([0x1f,0x43,0xb6,0x75]),_0x3472e7=Math[_0x593268(0x15f)](0x4,_0x8893fa[_0x593268(0x131)](uintSize,_0x35573b)),_0xe802e0=Buffer['concat']([Buffer[_0x593268(0x176)]([ID_TIMESTAMP]),writeVint(_0x3472e7),writeUint(_0x35573b,_0x3472e7)]),_0x4775b0=Buffer['concat']([_0x583128,_0xe802e0,_0x2d41f0]),_0x1417a5=writeVint(_0x4775b0['length']);return Buffer['concat']([_0x3fabbd,_0x1417a5,_0x4775b0]);}const ID_DURATION=0x4489;function rebuildHeaderWithoutDuration(_0x4b0424){const _0x1c4e24=_0xe647,_0x3e7c9e={'MTKbf':function(_0x36b931,_0xf0c83e,_0x2b661f){return _0x36b931(_0xf0c83e,_0x2b661f);},'ztNty':function(_0x1120d7,_0x164a5a){return _0x1120d7+_0x164a5a;},'yAERU':function(_0x3d0348,_0x470299){return _0x3d0348+_0x470299;},'QNXdP':function(_0x5dc5a7,_0x5383c2){return _0x5dc5a7+_0x5383c2;},'wfGVs':function(_0x1f1a66,_0x314e10){return _0x1f1a66+_0x314e10;},'lWqXB':function(_0xc6fa16,_0x3f0d12,_0x53a2a5){return _0xc6fa16(_0x3f0d12,_0x53a2a5);},'XXABv':function(_0x1d5f7a,_0x131e0c){return _0x1d5f7a+_0x131e0c;},'CKRpl':function(_0x58dc1b,_0x570608){return _0x58dc1b+_0x570608;},'cNcCf':function(_0x4e9c56,_0x15cfdd){return _0x4e9c56+_0x15cfdd;},'aiiZN':function(_0x4a5663,_0x21475b){return _0x4a5663<_0x21475b;},'DlQYC':function(_0x2660bd,_0x11c73a,_0x16d1d3){return _0x2660bd(_0x11c73a,_0x16d1d3);},'msQXl':function(_0x5c5cd1,_0x58d4d2){return _0x5c5cd1+_0x58d4d2;},'WidGW':function(_0x58caab,_0x68d07f){return _0x58caab!==_0x68d07f;},'KlxpK':function(_0x560530,_0x4d54d4){return _0x560530+_0x4d54d4;},'SMEag':function(_0x4dfaa7,_0x4f6eec){return _0x4dfaa7+_0x4f6eec;}},_0x5e33b8=Buffer[_0x1c4e24(0x176)](_0x4b0424);let _0x69fe28=0x0;const [,_0x224102]=_0x3e7c9e['MTKbf'](readId,_0x5e33b8,_0x69fe28),[_0x3709ec,_0x46dca1]=readVint(_0x5e33b8,_0x3e7c9e['ztNty'](_0x69fe28,_0x224102)),_0x2d12ee=_0x3e7c9e[_0x1c4e24(0x16c)](_0x69fe28+_0x224102+_0x46dca1,_0x3709ec),[,_0x28ec96]=readId(_0x5e33b8,_0x2d12ee),[,_0x46b3b4]=readVint(_0x5e33b8,_0x3e7c9e[_0x1c4e24(0x179)](_0x2d12ee,_0x28ec96)),_0x2b9f21=_0x3e7c9e[_0x1c4e24(0x150)](_0x2d12ee,_0x28ec96)+_0x46b3b4,_0x520aa0=writeUnknownSizeVint(_0x46b3b4);_0x520aa0[_0x1c4e24(0x16e)](_0x5e33b8,_0x2d12ee+_0x28ec96);let _0x251702=_0x2b9f21;const _0x8c236f=Math['min'](_0x5e33b8[_0x1c4e24(0x162)],_0x2b9f21+0x2710);while(_0x251702<_0x8c236f){const [_0x4eb5cb,_0x50322d]=readId(_0x5e33b8,_0x251702),[_0x40d85d,_0xeed202]=_0x3e7c9e[_0x1c4e24(0x13e)](readVint,_0x5e33b8,_0x3e7c9e[_0x1c4e24(0x17a)](_0x251702,_0x50322d));if(_0x4eb5cb===ID_CLUSTER)break;if(isUnknownSize(_0x40d85d,_0xeed202))break;if(_0x4eb5cb===ID_INFO){const _0x31b7f0=_0x3e7c9e['CKRpl'](_0x251702+_0x50322d,_0xeed202),_0x72f0e8=_0x3e7c9e[_0x1c4e24(0x16f)](_0x31b7f0,_0x40d85d),_0x454b76=[];let _0x2388c8=_0x31b7f0;while(_0x3e7c9e[_0x1c4e24(0x149)](_0x2388c8,_0x72f0e8)){const [_0xcf205a,_0x3abc7d]=readId(_0x5e33b8,_0x2388c8),[_0x3e97e9,_0x42ca3c]=_0x3e7c9e['DlQYC'](readVint,_0x5e33b8,_0x2388c8+_0x3abc7d),_0x5422a2=_0x3e7c9e[_0x1c4e24(0x14d)](_0x3e7c9e[_0x1c4e24(0x172)](_0x3abc7d,_0x42ca3c),_0x3e97e9);_0x3e7c9e['WidGW'](_0xcf205a,ID_DURATION)&&_0x454b76[_0x1c4e24(0x14a)](_0x5e33b8['slice'](_0x2388c8,_0x3e7c9e['msQXl'](_0x2388c8,_0x5422a2))),_0x2388c8+=_0x5422a2;}const _0x471e9b=Buffer['concat'](_0x454b76),_0x518cb0=Buffer[_0x1c4e24(0x139)]([_0x5e33b8[_0x1c4e24(0x165)](_0x251702,_0x251702+_0x50322d),writeVint(_0x471e9b[_0x1c4e24(0x162)],_0xeed202)]);return Buffer['concat']([_0x5e33b8[_0x1c4e24(0x165)](0x0,_0x251702),_0x518cb0,_0x471e9b,_0x5e33b8[_0x1c4e24(0x165)](_0x72f0e8)]);}_0x251702+=_0x3e7c9e[_0x1c4e24(0x134)](_0x3e7c9e['SMEag'](_0x50322d,_0xeed202),_0x40d85d);}return _0x5e33b8;}export function stitchWebmFiles(_0x5a35ba,_0x2a85d7){const _0x111207=_0xe647,_0x525a8b={'gTfLY':function(_0x7dd98a,_0x3feae2){return _0x7dd98a===_0x3feae2;},'vHcRg':function(_0x6ec39e,_0x33106f){return _0x6ec39e(_0x33106f);},'SWQfH':function(_0x4dbb3c,_0xe2aa63){return _0x4dbb3c<_0xe2aa63;},'AivNC':function(_0x302ce9,_0x138c67){return _0x302ce9+_0x138c67;}};if(_0x5a35ba['length']<=0x1)return![];const _0x599a34=[];for(const _0x56089a of _0x5a35ba){const _0x5e37da=readFileSync(_0x56089a),_0x27b51d=parseWebm(_0x5e37da);if(!_0x27b51d||_0x525a8b[_0x111207(0x146)](_0x27b51d[_0x111207(0x12f)][_0x111207(0x162)],0x0))return![];_0x599a34[_0x111207(0x14a)](_0x27b51d);}const _0x5a942b=_0x599a34[0x0],_0x226e90=_0x525a8b['vHcRg'](rebuildHeaderWithoutDuration,_0x5a942b[_0x111207(0x159)]),_0x4e1fe1=[_0x226e90];let _0x571ff2=0x0;for(let _0xeb6137=0x0;_0x525a8b['SWQfH'](_0xeb6137,_0x599a34[_0x111207(0x162)]);_0xeb6137++){const _0x3a1a1b=_0x599a34[_0xeb6137];for(const _0x388ada of _0x3a1a1b['clusters']){const _0x16dd72=_0x388ada['timestamp']+_0x571ff2;_0x4e1fe1[_0x111207(0x14a)](buildCluster(_0x16dd72,_0x388ada[_0x111207(0x158)],_0x388ada[_0x111207(0x160)]));}const _0x4e10b0=0x1e;_0x571ff2+=_0x525a8b['AivNC'](_0x3a1a1b[_0x111207(0x135)],_0x4e10b0);}return writeFileSync(_0x2a85d7,Buffer['concat'](_0x4e1fe1)),!![];}if(process['argv'][0x1]?.['endsWith']('stitchWebmFiles.ts')||process['argv'][0x1]?.[_0x4e7c39(0x141)]('stitchWebmFiles.js')){const args=process['argv']['slice'](0x2);args[_0x4e7c39(0x162)]<0x3&&(console['error'](_0x4e7c39(0x145)),process[_0x4e7c39(0x133)](0x1));const output=args[args[_0x4e7c39(0x162)]-0x1],inputs=args[_0x4e7c39(0x165)](0x0,-0x1),ok=stitchWebmFiles(inputs,output);ok?console[_0x4e7c39(0x136)](_0x4e7c39(0x13b)+inputs['length']+'\x20files\x20->\x20'+output):console['log'](_0x4e7c39(0x154));}
|