@ranger-testing/ranger-cli 3.0.1-alpha.bb18058-34 → 3.0.1-alpha.ebe0997-35
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/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/userApi.js +1 -1
- package/build/commands/utils/version.js +1 -1
- package/build/commands/verifyFeature.js +1 -1
- package/build/commands/verifyFeatureCli.js +1 -1
- package/build/commands/verifyFeatureNovaCli.js +1 -1
- package/build/commands/verifyFeatureRangerwrightCli.js +1 -1
- package/package.json +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function _0x5003(_0x2f521d,_0x50a73f){_0x2f521d=_0x2f521d-0x1f3;const _0x45f5a4=_0x45f5();let _0x5003b5=_0x45f5a4[_0x2f521d];return _0x5003b5;}(function(_0x557c91,_0x4a3a27){const _0x51a347=_0x5003,_0x56022e=_0x557c91();while(!![]){try{const _0x597e6d=parseInt(_0x51a347(0x207))/0x1+parseInt(_0x51a347(0x1ff))/0x2*(parseInt(_0x51a347(0x1f3))/0x3)+parseInt(_0x51a347(0x208))/0x4*(-parseInt(_0x51a347(0x21e))/0x5)+-parseInt(_0x51a347(0x213))/0x6+-parseInt(_0x51a347(0x1f8))/0x7+-parseInt(_0x51a347(0x216))/0x8*(-parseInt(_0x51a347(0x20a))/0x9)+parseInt(_0x51a347(0x1f5))/0xa*(parseInt(_0x51a347(0x227))/0xb);if(_0x597e6d===_0x4a3a27)break;else _0x56022e['push'](_0x56022e['shift']());}catch(_0x2c03ee){_0x56022e['push'](_0x56022e['shift']());}}}(_0x45f5,0xb4a40));import{existsSync}from'fs';import _0x2ccc6b from'inquirer';import{ApiError,fetchCloudProfile,listCloudProfiles,resolveAdHocProfile,resolveCloudProfileSession}from'./cloudProfile.js';import{isInteractive}from'./cloudProfileSession.js';import{mergeCloudProfileSettings,readProfileOverrides}from'./projectsConfig.js';import{readUrlEnvVars,resolveProfileUrl}from'./resolveProfileUrl.js';import{getEnvDir,loadSettings,resolveEnvVars}from'./settings.js';function _0x45f5(){const _0x226d50=['656IugoLk','cBOJJ','171wMnbdY','UHXod','fVjpN','authPath','oIUWW','startPath','local','JbdPA','url','1845702kpwKqN','\x22.\x20Run:\x20ranger\x20profile\x20config\x20set\x20','log','345520oMfgtt','string','envStartPath','jNEBb','hDFer','\x20\x20Run\x20`ranger\x20profile\x20ls`\x20to\x20see\x20available\x20profiles,\x20or\x20','name','3|2|4|1|0','37640vWDlZi','RANGER_TEST_USERNAME','Local\x20profile','cdpEndpoint','cloud','Profile\x20\x22','\x20\x20(pass\x20--profile\x20<name>\x20to\x20pin,\x20or\x20RANGER_TEST_USERNAME=...\x20to\x20materialize\x20a\x20new\x20one)','cwd','\x22\x20not\x20found.\x20Run:\x20ranger\x20profile\x20add\x20','44nJQpdc','1152gTXwYN','Ranger\x20can\x27t\x20verify\x20with\x20a\x20browser\x20until\x20a\x20profile\x20is\x20set\x20up.\x20Options:\x0a','2818560qxaGsr','source','resolvedEnv','7408751PUhmDb','baseUrl','RANGER_SESSION_STATE_PATH=','\x0aUsing\x20the\x20only\x20cloud\x20profile\x20for\x20your\x20org:\x20','\x20\x20-\x20run\x20`ranger\x20profile\x20add\x20<name>`\x20to\x20create\x20a\x20new\x20one.','hnaXY','gkaiR','6268jbJkZC','FdpSS','settings','prompt','No\x20baseUrl\x20configured\x20for\x20profile\x20\x22','UWzjl','\x22\x20not\x20found\x20locally\x20or\x20in\x20the\x20cloud.\x0a','\x20\x20-\x20run\x20`ranger\x20profile\x20use\x20<name>`\x20once,\x20or\x0a','189016NXVRxY'];_0x45f5=function(){return _0x226d50;};return _0x45f5();}import{readActiveProfileName}from'./activeProfile.js';export async function resolveProfileContext(_0x4faa9f){const _0x3cc7a7=_0x5003,_0x302c6f={'cBOJJ':function(_0x3585db,_0x413e6f){return _0x3585db===_0x413e6f;},'hnaXY':function(_0x4628b1,_0x867601){return _0x4628b1+_0x867601;},'jNEBb':'\x20\x20-\x20set\x20RANGER_TEST_USERNAME\x20(+\x20RANGER_TEST_PASSWORD)\x20to\x20materialize\x20one,\x20or\x0a','UWzjl':function(_0x5b47f4,_0x4cf9bd){return _0x5b47f4(_0x4cf9bd);},'JvoCb':function(_0x4b7ee2,_0x4be9cb){return _0x4b7ee2 instanceof _0x4be9cb;},'oIUWW':_0x3cc7a7(0x21b),'bCGbo':function(_0x11ee6f,_0x44c1e5){return _0x11ee6f&&_0x44c1e5;},'JbdPA':function(_0x19ef75){return _0x19ef75();},'gkaiR':'list','MIkpA':_0x3cc7a7(0x1f6),'fVjpN':'Cloud\x20profile\x20(recommended)','FdpSS':_0x3cc7a7(0x210),'GyoRJ':_0x3cc7a7(0x222),'vMUul':function(_0x45b249,_0x2aca8b,_0x4d3d4d){return _0x45b249(_0x2aca8b,_0x4d3d4d);},'Jigkt':function(_0x1334b7,_0x250d05){return _0x1334b7(_0x250d05);},'hDFer':function(_0x1e29e6,_0x17b9a8){return _0x1e29e6(_0x17b9a8);},'tVyVg':function(_0x3e40f0,_0x23f439){return _0x3e40f0(_0x23f439);}},_0x6950a6=_0x4faa9f['profile'];let _0x542320=_0x4faa9f['profile']??await readActiveProfileName(),_0x264647=null;if(!_0x542320&&process['env'][_0x3cc7a7(0x21f)]){const _0x45a0ea=await resolveAdHocProfile();_0x45a0ea&&(_0x542320=_0x45a0ea['name'],_0x264647=_0x45a0ea['profile']);}if(!_0x542320)try{const _0x4d3636=await listCloudProfiles();if(_0x302c6f[_0x3cc7a7(0x209)](_0x4d3636['length'],0x1)){const _0x57fb11=_0x4d3636[0x0];_0x542320=_0x57fb11['name'],console[_0x3cc7a7(0x215)](_0x3cc7a7(0x1fb)+_0x57fb11[_0x3cc7a7(0x21c)]),console['log'](_0x3cc7a7(0x224));}}catch{}if(!_0x542320)throw new Error(_0x302c6f[_0x3cc7a7(0x1fd)](_0x3cc7a7(0x1f4),_0x302c6f[_0x3cc7a7(0x219)])+'\x20\x20-\x20pass\x20--profile\x20<name>\x20/\x20set\x20RANGER_PROFILE,\x20or\x0a'+_0x3cc7a7(0x206)+_0x3cc7a7(0x1fc));const _0x46e39f=_0x302c6f[_0x3cc7a7(0x204)](getEnvDir,_0x542320),_0x17d97a=_0x302c6f[_0x3cc7a7(0x204)](existsSync,_0x46e39f);let _0x3fc473=_0x264647,_0x3c5ad9=![];if(!_0x3fc473)try{_0x3fc473=await fetchCloudProfile(_0x542320);if(!_0x3fc473)_0x3c5ad9=!![];}catch(_0x5ca14f){_0x302c6f['JvoCb'](_0x5ca14f,ApiError)&&_0x5ca14f['status']===0x194&&(_0x3c5ad9=!![]);}if(_0x6950a6&&_0x3c5ad9&&!_0x17d97a&&!_0x3fc473)throw new Error(_0x3cc7a7(0x223)+_0x6950a6+_0x3cc7a7(0x205)+_0x302c6f[_0x3cc7a7(0x20e)]+'`ranger\x20profile\x20add`\x20to\x20create\x20one.');if(_0x302c6f['bCGbo'](_0x3fc473,_0x17d97a)){let _0x29e39f=!![];if(_0x302c6f[_0x3cc7a7(0x211)](isInteractive)){const {source:_0x371271}=await _0x2ccc6b[_0x3cc7a7(0x202)]([{'type':_0x302c6f[_0x3cc7a7(0x1fe)],'name':_0x302c6f['MIkpA'],'message':_0x3cc7a7(0x223)+_0x542320+'\x22\x20exists\x20both\x20locally\x20and\x20in\x20the\x20cloud.\x20Which\x20one\x20should\x20be\x20used?','choices':[{'name':_0x302c6f[_0x3cc7a7(0x20c)],'value':'cloud'},{'name':_0x3cc7a7(0x220),'value':_0x302c6f[_0x3cc7a7(0x200)]}],'default':_0x3cc7a7(0x222)}]);_0x29e39f=_0x371271===_0x302c6f['GyoRJ'];}if(!_0x29e39f)_0x3fc473=null;}const _0x59c952=_0x302c6f['vMUul'](readProfileOverrides,process[_0x3cc7a7(0x225)](),_0x542320);let _0x21d91b=null,_0x25a125,_0x5d7fc0,_0x206729,_0x44a699,_0x13457a=null,_0x24af06;const _0x4225ce=expandOverrides(_0x59c952);if(_0x3fc473){_0x21d91b=_0x3fc473;const _0x3d2ce6=_0x3fc473[_0x3cc7a7(0x201)]??{},_0xf272cc=mergeCloudProfileSettings(_0x3d2ce6,_0x59c952??undefined),_0x11b3db={..._0x3fc473,'settings':_0xf272cc},_0x317ae3=process['env']['RANGER_SESSION_STATE_PATH'];if(_0x317ae3){const _0x544dbc=_0x3cc7a7(0x21d)['split']('|');let _0x570fc4=0x0;while(!![]){switch(_0x544dbc[_0x570fc4++]){case'0':_0x13457a={'baseUrl':expandString(_0x3d2ce6['baseUrl']),'startPath':_0x302c6f['Jigkt'](expandString,_0x3d2ce6[_0x3cc7a7(0x20f)])};continue;case'1':_0x206729=_0x302c6f['hDFer'](Boolean,_0x5d7fc0['cdpEndpoint']);continue;case'2':_0x25a125=_0x317ae3;continue;case'3':if(!existsSync(_0x317ae3))throw new Error(_0x3cc7a7(0x1fa)+_0x317ae3+'\x20does\x20not\x20exist.');continue;case'4':_0x5d7fc0=resolveEnvVars(_0xf272cc);continue;}break;}}else{const _0x3bcdf1=await resolveCloudProfileSession(_0x11b3db);_0x25a125=_0x3bcdf1[_0x3cc7a7(0x20d)],_0x5d7fc0=resolveEnvVars(_0x3bcdf1[_0x3cc7a7(0x201)]),_0x206729=_0x302c6f['tVyVg'](Boolean,_0x5d7fc0[_0x3cc7a7(0x221)]),_0x13457a={'baseUrl':expandString(_0x3d2ce6[_0x3cc7a7(0x1f9)]),'startPath':expandString(_0x3d2ce6['startPath'])},_0x24af06=_0x3bcdf1[_0x3cc7a7(0x1f7)]?.['domains']?.[0x0];}}else{if(!_0x17d97a)throw new Error('Profile\x20\x22'+_0x542320+_0x3cc7a7(0x226)+_0x542320);const _0x14c012=await loadSettings(_0x542320);_0x5d7fc0=resolveEnvVars(_0x14c012),_0x206729=_0x302c6f['UWzjl'](Boolean,_0x5d7fc0['cdpEndpoint']),_0x44a699=_0x5d7fc0['baseUrl'];}const _0x343b36=readUrlEnvVars(),_0x12086c=_0x302c6f[_0x3cc7a7(0x21a)](resolveProfileUrl,{'flagBaseUrl':_0x4faa9f[_0x3cc7a7(0x1f9)],'flagStartPath':_0x4faa9f[_0x3cc7a7(0x20f)],'envBaseUrl':_0x343b36['envBaseUrl'],'envStartPath':_0x343b36[_0x3cc7a7(0x218)],'localSettingsBaseUrl':_0x44a699,'projectOverrides':_0x4225ce,'cloudSettings':_0x13457a,'authEnvironmentDomain':_0x24af06}),_0x20f27a=_0x12086c[_0x3cc7a7(0x212)]??_0x12086c['baseUrl'];if(!_0x20f27a&&!_0x206729)throw new Error(_0x3cc7a7(0x203)+_0x542320+_0x3cc7a7(0x214)+_0x542320+'\x20baseUrl\x20<url>');return{'activeProfile':_0x542320,'resolvedCloudProfile':_0x21d91b,'cloudAuthPath':_0x25a125,'resolvedSettings':_0x5d7fc0,'isCdpMode':_0x206729,'url':_0x20f27a,'startPath':_0x12086c['startPath']};}function expandString(_0x5999c5){const _0x1aa786=_0x5003,_0x196ea4={'UHXod':function(_0x2a7549,_0x5931a0){return _0x2a7549(_0x5931a0);}};if(typeof _0x5999c5!==_0x1aa786(0x217))return _0x5999c5;return _0x196ea4[_0x1aa786(0x20b)](resolveEnvVars,_0x5999c5);}function expandOverrides(_0x3695ec){const _0x1a4f1e=_0x5003,_0x5095f8={'ZvKMG':function(_0x1aa92d,_0x239b65){return _0x1aa92d(_0x239b65);}};if(!_0x3695ec)return _0x3695ec;const _0x2818e0={..._0x3695ec};return typeof _0x2818e0['baseUrl']===_0x1a4f1e(0x217)&&(_0x2818e0[_0x1a4f1e(0x1f9)]=resolveEnvVars(_0x2818e0[_0x1a4f1e(0x1f9)])),typeof _0x2818e0[_0x1a4f1e(0x20f)]===_0x1a4f1e(0x217)&&(_0x2818e0[_0x1a4f1e(0x20f)]=_0x5095f8['ZvKMG'](resolveEnvVars,_0x2818e0[_0x1a4f1e(0x20f)])),_0x2818e0;}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x542be1,_0x75ee8d){const _0x23d8fa=_0x54e8,_0x2a524f=_0x542be1();while(!![]){try{const _0x412fa1=-parseInt(_0x23d8fa(0x165))/0x1+-parseInt(_0x23d8fa(0x163))/0x2*(parseInt(_0x23d8fa(0x173))/0x3)+parseInt(_0x23d8fa(0x161))/0x4*(-parseInt(_0x23d8fa(0x175))/0x5)+-parseInt(_0x23d8fa(0x16f))/0x6+-parseInt(_0x23d8fa(0x166))/0x7+parseInt(_0x23d8fa(0x16b))/0x8*(parseInt(_0x23d8fa(0x174))/0x9)+parseInt(_0x23d8fa(0x16e))/0xa;if(_0x412fa1===_0x75ee8d)break;else _0x2a524f['push'](_0x2a524f['shift']());}catch(_0x311f87){_0x2a524f['push'](_0x2a524f['shift']());}}}(_0x26f0,0xeed72));function firstDefined(..._0x4ad0f3){const _0x4c735a={'ujHQV':function(_0x243fef,_0x484362){return _0x243fef!==_0x484362;}};for(const _0x4417ed of _0x4ad0f3){if(_0x4417ed!==undefined&&_0x4c735a['ujHQV'](_0x4417ed,null)&&_0x4417ed!=='')return _0x4417ed;}return undefined;}function normalizeAuthEnvironmentDomain(_0x2bd3a3){if(!_0x2bd3a3)return undefined;if(/^[a-z][a-z0-9+.-]*:\/\//i['test'](_0x2bd3a3))return _0x2bd3a3;return'https://'+_0x2bd3a3;}export function resolveBaseUrl(_0x3d64c3){const _0xa67da1=_0x54e8,_0x173955={'irWoD':function(_0xad8074,_0x5858b4){return _0xad8074 in _0x5858b4;}},_0x9d7d87=_0x3d64c3[_0xa67da1(0x170)],_0x4a25cb=!!_0x9d7d87&&_0x173955[_0xa67da1(0x16c)]('baseUrl',_0x9d7d87),_0x3fae50=_0x9d7d87?.['baseUrl'],_0x523980=!(_0x4a25cb&&_0x3fae50===null);return firstDefined(_0x3d64c3['flagBaseUrl'],_0x3d64c3['envBaseUrl'],_0x3d64c3[_0xa67da1(0x162)],typeof _0x3fae50==='string'?_0x3fae50:undefined,_0x523980?_0x3d64c3['cloudSettings']?.['baseUrl']:undefined,_0x523980?normalizeAuthEnvironmentDomain(_0x3d64c3[_0xa67da1(0x16d)]):undefined);}function _0x54e8(_0x548901,_0x12176c){_0x548901=_0x548901-0x160;const _0x26f06f=_0x26f0();let _0x54e8d1=_0x26f06f[_0x548901];return _0x54e8d1;}export function resolveStartPath(_0x125193){const _0x3d2a42=_0x54e8,_0x178762={'aooFD':'startPath','cMLKG':function(_0xe6d79,_0x24bb3d){return _0xe6d79===_0x24bb3d;},'Sizxg':function(_0x16cc9f,_0x5bdec2,_0x3446a5,_0x540331,_0x225899){return _0x16cc9f(_0x5bdec2,_0x3446a5,_0x540331,_0x225899);}},_0x1fa609=_0x125193['projectOverrides'],_0x320771=!!_0x1fa609&&_0x178762[_0x3d2a42(0x168)]in _0x1fa609,_0x5d1431=_0x1fa609?.[_0x3d2a42(0x172)],_0x2690b1=!(_0x320771&&_0x178762[_0x3d2a42(0x167)](_0x5d1431,null));return _0x178762['Sizxg'](firstDefined,_0x125193['flagStartPath'],_0x125193['envStartPath'],typeof _0x5d1431==='string'?_0x5d1431:undefined,_0x2690b1?_0x125193['cloudSettings']?.['startPath']:undefined);}function _0x26f0(){const _0x435c45=['startsWith','1875260TZcJSE','9485532vNpzyr','cMLKG','aooFD','mqkHs','slice','11682760rYoYUJ','irWoD','authEnvironmentDomain','58036930USWKDZ','7457244WAPpAo','projectOverrides','RANGER_BASE_URL','startPath','235491Amhbkj','9cZseDv','1510jJvcPr','RANGER_START_PATH','7372lnRntv','localSettingsBaseUrl','32AYbcWv'];_0x26f0=function(){return _0x435c45;};return _0x26f0();}export function joinBaseAndPath(_0x5922e1,_0x1e6ee7){const _0x41a27b=_0x54e8;if(!_0x5922e1)return undefined;if(!_0x1e6ee7)return _0x5922e1;const _0x29f9f0=_0x5922e1['endsWith']('/')?_0x5922e1[_0x41a27b(0x16a)](0x0,-0x1):_0x5922e1,_0x2973b8=_0x1e6ee7[_0x41a27b(0x164)]('/')?_0x1e6ee7:'/'+_0x1e6ee7;return _0x29f9f0+_0x2973b8;}export function resolveProfileUrl(_0x37ae7e){const _0x432cd7=_0x54e8,_0xc1ef4e={'mqkHs':function(_0x3e147d,_0x17b53d){return _0x3e147d(_0x17b53d);}},_0x449a4a=_0xc1ef4e[_0x432cd7(0x169)](resolveBaseUrl,_0x37ae7e),_0x342991=_0xc1ef4e['mqkHs'](resolveStartPath,_0x37ae7e);return{'baseUrl':_0x449a4a,'startPath':_0x342991,'url':joinBaseAndPath(_0x449a4a,_0x342991)};}export function readUrlEnvVars(_0x2e7ff6=process['env']){const _0x3c0119=_0x54e8;return{'envBaseUrl':_0x2e7ff6[_0x3c0119(0x171)],'envStartPath':_0x2e7ff6[_0x3c0119(0x160)]};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x45ce8c,_0x33676f){const _0x24e835=_0x3363,_0x4d87bc=_0x45ce8c();while(!![]){try{const _0x176dbb=parseInt(_0x24e835(0x123))/0x1+parseInt(_0x24e835(0x12a))/0x2+parseInt(_0x24e835(0x127))/0x3*(-parseInt(_0x24e835(0x12c))/0x4)+parseInt(_0x24e835(0x11f))/0x5*(-parseInt(_0x24e835(0x129))/0x6)+parseInt(_0x24e835(0x126))/0x7+-parseInt(_0x24e835(0x121))/0x8+-parseInt(_0x24e835(0x120))/0x9*(-parseInt(_0x24e835(0x125))/0xa);if(_0x176dbb===_0x33676f)break;else _0x4d87bc['push'](_0x4d87bc['shift']());}catch(_0x33d18c){_0x4d87bc['push'](_0x4d87bc['shift']());}}}(_0x2aff,0x25906));function _0x3363(_0x40d56d,_0x39819d){_0x40d56d=_0x40d56d-0x11f;const _0x2afff7=_0x2aff();let _0x3363b0=_0x2afff7[_0x40d56d];return _0x3363b0;}const DEFAULT_MAX_RETRIES=0x3,DEFAULT_BASE_DELAY_MS=0x1f4;function _0x2aff(){const _0x4df938=['1113344kxgKsa','xwBTt','272806MLLafV','maxRetries','30TYLYUZ','414757AFMvai','111XnawNf','ZuBEq','153966CKgKNC','55828GyKrSt','label','5224eiqeYs','baseDelayMs','10EGcGvf','98109Zvuyef'];_0x2aff=function(){return _0x4df938;};return _0x2aff();}export async function withRetry(_0x42b561,_0x188e47){const _0xfec875=_0x3363,_0x193114={'GGOLp':function(_0x41aaf2){return _0x41aaf2();},'FoWLN':function(_0x147dc6,_0x50d87b){return _0x147dc6 instanceof _0x50d87b;},'xwBTt':function(_0x141404,_0x3ca7f9){return _0x141404<_0x3ca7f9;},'dEDha':function(_0x48179c,_0x2ca2b7){return _0x48179c*_0x2ca2b7;},'ZuBEq':function(_0x1be482,_0x54f7e1){return _0x1be482+_0x54f7e1;}},_0x598ef1=_0x188e47?.[_0xfec875(0x124)]??DEFAULT_MAX_RETRIES,_0x1c8a9f=_0x188e47?.[_0xfec875(0x12d)]??DEFAULT_BASE_DELAY_MS;let _0x4d2066;for(let _0x8c5ca0=0x0;_0x8c5ca0<=_0x598ef1;_0x8c5ca0++){try{return await _0x193114['GGOLp'](_0x42b561);}catch(_0x27257b){_0x4d2066=_0x193114['FoWLN'](_0x27257b,Error)?_0x27257b:new Error(String(_0x27257b));if(_0x193114[_0xfec875(0x122)](_0x8c5ca0,_0x598ef1)){const _0x5273d6=_0x193114['dEDha'](_0x1c8a9f,Math['pow'](0x2,_0x8c5ca0));_0x188e47?.[_0xfec875(0x12b)]&&console['error'](_0x188e47[_0xfec875(0x12b)]+'\x20failed\x20(attempt\x20'+_0x193114[_0xfec875(0x128)](_0x8c5ca0,0x1)+'/'+_0x193114['ZuBEq'](_0x598ef1,0x1)+'),\x20retrying\x20in\x20'+_0x5273d6+'ms...'),await new Promise(_0x4e35ef=>setTimeout(_0x4e35ef,_0x5273d6));}}}throw _0x4d2066;}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const _0x582ff1=_0x1586;(function(_0x24333c,_0x57c671){const _0x58a672=_0x1586,_0x4df608=_0x24333c();while(!![]){try{const _0x1fbda0=-parseInt(_0x58a672(0x90))/0x1*(-parseInt(_0x58a672(0x88))/0x2)+-parseInt(_0x58a672(0xa5))/0x3*(parseInt(_0x58a672(0x73))/0x4)+-parseInt(_0x58a672(0x87))/0x5*(parseInt(_0x58a672(0x98))/0x6)+parseInt(_0x58a672(0x7b))/0x7*(-parseInt(_0x58a672(0xa0))/0x8)+-parseInt(_0x58a672(0x95))/0x9*(parseInt(_0x58a672(0x7d))/0xa)+parseInt(_0x58a672(0x7e))/0xb+parseInt(_0x58a672(0xaa))/0xc;if(_0x1fbda0===_0x57c671)break;else _0x4df608['push'](_0x4df608['shift']());}catch(_0x2d179c){_0x4df608['push'](_0x4df608['shift']());}}}(_0x3308,0xb4e64));import*as _0x32d4d2 from'fs';import*as _0x16497f from'path';import*as _0x48cda2 from'os';function _0x1586(_0xc8c32e,_0x2fe24b){_0xc8c32e=_0xc8c32e-0x6f;const _0x3308b8=_0x3308();let _0x1586b1=_0x3308b8[_0xc8c32e];return _0x1586b1;}function _0x3308(){const _0x30b62e=['wrZLQ','lastEnabledSessionClearedAt','zSldp','enabled','1119moXTdH','master','readFileSync','Xvwid','mqtJI','45207120EgjnxR','prompted','pipe','ZzgWx','mRQbo','dirname','11084YjTHvk','utf-8','parse','branches','RlmBK','qEhPi','main','JYTez','28JxPKOz','homedir','4478990IVfNmX','12458435pREFIX','currentBranch','now','mkdirSync','stringify','sessions','BoKyM','wQbLw','existsSync','5CvoWDD','376490kAKoJv','featureId','tZdAO','wiUaY','IZmSy','lastStopReminderAt','FFruW','xxccN','3kQEEWH','WnWcA','LqbBE','writeFileSync','join','18GKEbXZ','HEAD','registeredAt','8176722JBMukh','JMXvT','upjVO','QSUog','clear','gVRaG','rnyRZ','txllG','2862896VgbXUA'];_0x3308=function(){return _0x30b62e;};return _0x3308();}import{execSync}from'child_process';const CACHE_FILE=_0x16497f[_0x582ff1(0x94)](_0x48cda2[_0x582ff1(0x7c)](),'.claude','.ranger_cache.json');function createEmptyCache(){return{'version':0x3,'sessions':{},'branches':{}};}function loadCache(){const _0x55d9b3=_0x582ff1;try{if(_0x32d4d2[_0x55d9b3(0x86)](CACHE_FILE)){const _0x16c992=JSON[_0x55d9b3(0x75)](_0x32d4d2[_0x55d9b3(0xa7)](CACHE_FILE,'utf-8'));return{'version':0x3,'sessions':_0x16c992[_0x55d9b3(0x83)]||{},'branches':_0x16c992['branches']||{},'lastEnabledSessionClearedAt':_0x16c992[_0x55d9b3(0xa2)]};}}catch{}return createEmptyCache();}function saveCache(_0x42425c){const _0x5602d7=_0x582ff1;try{const _0x4f9b85=_0x16497f[_0x5602d7(0x72)](CACHE_FILE);!_0x32d4d2['existsSync'](_0x4f9b85)&&_0x32d4d2[_0x5602d7(0x81)](_0x4f9b85,{'recursive':!![]}),_0x32d4d2[_0x5602d7(0x93)](CACHE_FILE,JSON[_0x5602d7(0x82)](_0x42425c,null,0x2));}catch{}}export function getCurrentBranch(){const _0x107c11=_0x582ff1,_0x564c66={'wrZLQ':function(_0x51612f,_0x45ef49,_0x17ce9e){return _0x51612f(_0x45ef49,_0x17ce9e);},'Xvwid':_0x107c11(0x74),'PHjzt':_0x107c11(0x6f),'LqbBE':function(_0x259000,_0x6a6a7f){return _0x259000===_0x6a6a7f;}};try{const _0x574332=_0x564c66[_0x107c11(0xa1)](execSync,'git\x20rev-parse\x20--abbrev-ref\x20HEAD',{'encoding':_0x564c66[_0x107c11(0xa8)],'stdio':[_0x564c66['PHjzt'],'pipe','pipe']})['trim']();if(!_0x574332||_0x564c66[_0x107c11(0x92)](_0x574332,_0x107c11(0x96)))return null;return _0x574332;}catch{return null;}}export function enableBranch(_0x3d8bb2){const _0x888178=_0x582ff1,_0x41bf4e={'wQbLw':function(_0xfbe02a,_0x2587b5){return _0xfbe02a(_0x2587b5);}},_0x1f5f3f=loadCache();_0x1f5f3f[_0x888178(0x76)][_0x3d8bb2]=!![],_0x41bf4e[_0x888178(0x85)](saveCache,_0x1f5f3f);}export function disableBranch(_0x2c7d23){const _0x6d6b61=_0x582ff1,_0x362ffc={'tZdAO':function(_0x235c3f){return _0x235c3f();}},_0x4472d0=_0x362ffc[_0x6d6b61(0x8a)](loadCache);delete _0x4472d0[_0x6d6b61(0x76)][_0x2c7d23],saveCache(_0x4472d0);}export function isBranchEnabled(_0x14284c){const _0x5105c3=_0x582ff1,_0x35c6b7=loadCache();return _0x35c6b7[_0x5105c3(0x76)][_0x14284c]===!![];}function getOrCreateSession(_0x2f76e8,_0x2c232c){const _0xfa0e28=_0x582ff1;return!_0x2f76e8[_0xfa0e28(0x83)][_0x2c232c]&&(_0x2f76e8['sessions'][_0x2c232c]={}),_0x2f76e8['sessions'][_0x2c232c];}export function enableSession(_0x1f1316){const _0x242d85=_0x582ff1,_0x131839={'UDVZQ':function(_0x2625d2,_0x594bc3){return _0x2625d2!==_0x594bc3;},'gVRaG':_0x242d85(0x79),'gdePp':'master','rnyRZ':function(_0xa7e7dc,_0xba66f9){return _0xa7e7dc(_0xba66f9);}},_0x5130f7=loadCache(),_0x355c0c=getOrCreateSession(_0x5130f7,_0x1f1316);_0x355c0c['enabled']=!![];const _0x348fa9=getCurrentBranch();_0x348fa9&&_0x131839['UDVZQ'](_0x348fa9,_0x131839[_0x242d85(0x9d)])&&_0x131839['UDVZQ'](_0x348fa9,_0x131839['gdePp'])&&(_0x5130f7[_0x242d85(0x76)][_0x348fa9]=!![],_0x355c0c['currentBranch']=_0x348fa9),_0x131839[_0x242d85(0x9e)](saveCache,_0x5130f7);}export function isSessionEnabled(_0x34434d){const _0x75b4c=_0x582ff1,_0x4730d1={'ZzgWx':function(_0x3935f9,_0x34f8b7){return _0x3935f9===_0x34f8b7;},'WnWcA':function(_0x17d520,_0x17154d){return _0x17d520||_0x17154d;}},_0x1af731=loadCache(),_0xdc59a3=getCurrentBranch();if(!_0xdc59a3||_0x4730d1[_0x75b4c(0x70)](_0xdc59a3,_0x75b4c(0x79))||_0x4730d1[_0x75b4c(0x70)](_0xdc59a3,_0x75b4c(0xa6)))return _0x1af731['sessions'][_0x34434d]?.['enabled']===!![];const _0x275504=_0x1af731['branches'][_0xdc59a3]===!![],_0x581678=_0x1af731[_0x75b4c(0x83)][_0x34434d]?.[_0x75b4c(0xa4)]===!![];return _0x4730d1[_0x75b4c(0x91)](_0x275504,_0x581678);}export function disableSession(_0x4a46cc){const _0xb049bc=_0x582ff1,_0x416a47={'RymEA':function(_0x2c08f2,_0x1afe5f){return _0x2c08f2(_0x1afe5f);}},_0x1a1bfa=loadCache(),_0x746684=getOrCreateSession(_0x1a1bfa,_0x4a46cc);_0x746684[_0xb049bc(0xa4)]=![],_0x416a47['RymEA'](saveCache,_0x1a1bfa);}export function updateBranchTracking(_0x5c11a5){const _0x2b84b7=_0x582ff1,_0x50fe37={'nnAhv':function(_0x2363d8){return _0x2363d8();},'qEhPi':function(_0x26a538,_0x141894){return _0x26a538===_0x141894;},'JMXvT':function(_0x430b66,_0xa9e0e5){return _0x430b66===_0xa9e0e5;}},_0x215d3b=_0x50fe37['nnAhv'](loadCache),_0x994a36=_0x215d3b[_0x2b84b7(0x83)][_0x5c11a5];if(!_0x994a36?.['enabled'])return;const _0x244dcb=getCurrentBranch();if(!_0x244dcb||_0x50fe37[_0x2b84b7(0x78)](_0x244dcb,'main')||_0x50fe37[_0x2b84b7(0x99)](_0x244dcb,_0x2b84b7(0xa6)))return;_0x994a36[_0x2b84b7(0x7f)]!==_0x244dcb&&(_0x215d3b['branches'][_0x244dcb]=!![],_0x994a36[_0x2b84b7(0x7f)]=_0x244dcb,saveCache(_0x215d3b));}export function initBranchTracking(_0x59be4e){const _0x2f129e=_0x582ff1,_0x2d1f4a={'upjVO':function(_0x52244a){return _0x52244a();},'mqtJI':function(_0x5b7f23,_0x239c62){return _0x5b7f23===_0x239c62;},'sXMDB':_0x2f129e(0x79),'gmUDp':_0x2f129e(0xa6),'xxccN':function(_0x5b0e1f,_0x2c77c5){return _0x5b0e1f===_0x2c77c5;}},_0x4fafb7=_0x2d1f4a[_0x2f129e(0x9a)](loadCache),_0x5a6055=getCurrentBranch();if(!_0x5a6055||_0x2d1f4a['mqtJI'](_0x5a6055,_0x2d1f4a['sXMDB'])||_0x2d1f4a[_0x2f129e(0xa9)](_0x5a6055,_0x2d1f4a['gmUDp']))return;if(_0x2d1f4a[_0x2f129e(0x8f)](_0x4fafb7[_0x2f129e(0x76)][_0x5a6055],!![])){const _0xf7b37b=getOrCreateSession(_0x4fafb7,_0x59be4e);_0xf7b37b[_0x2f129e(0xa4)]=!![],_0xf7b37b[_0x2f129e(0x7f)]=_0x5a6055,saveCache(_0x4fafb7);}}const CLEAR_AUTO_ENABLE_WINDOW_MS=0x1388;export function recordEnabledSessionCleared(_0x2df59c){const _0x202e5c=_0x582ff1,_0x3bcf02={'zANhT':function(_0x49ac54){return _0x49ac54();}},_0x22bcc7=_0x3bcf02['zANhT'](loadCache),_0x1cd4d4=_0x22bcc7[_0x202e5c(0x83)][_0x2df59c];_0x1cd4d4?.['enabled']&&(_0x22bcc7['lastEnabledSessionClearedAt']=Date['now'](),saveCache(_0x22bcc7));}export function shouldAutoEnableAfterClear(_0xf40649){const _0x14b44e=_0x582ff1,_0x4fc3f4={'xMUif':_0x14b44e(0x9c),'JYTez':function(_0x3a14f1){return _0x3a14f1();},'wiUaY':function(_0x51635c,_0x4dc4e7){return _0x51635c-_0x4dc4e7;},'kKbAK':function(_0x2d1987,_0x408e5b){return _0x2d1987<=_0x408e5b;}};if(_0xf40649!==_0x4fc3f4['xMUif'])return![];const _0x44b82b=_0x4fc3f4[_0x14b44e(0x7a)](loadCache),_0x471f45=_0x44b82b['lastEnabledSessionClearedAt'];if(!_0x471f45)return![];const _0x4eff40=_0x4fc3f4[_0x14b44e(0x8b)](Date[_0x14b44e(0x80)](),_0x471f45);return _0x4fc3f4['kKbAK'](_0x4eff40,CLEAR_AUTO_ENABLE_WINDOW_MS);}export function autoEnableAfterClear(_0x35c2ec){const _0x179b57=_0x582ff1,_0x183230={'GXcHe':function(_0x2e3e2b){return _0x2e3e2b();},'FFruW':function(_0x1f3902,_0x9fd5a8){return _0x1f3902!==_0x9fd5a8;},'celeO':'main','txllG':'master','AJqqZ':function(_0x1f1418,_0xb73a54){return _0x1f1418(_0xb73a54);}},_0x32b8da=loadCache(),_0x1c38d9=getOrCreateSession(_0x32b8da,_0x35c2ec);_0x1c38d9['enabled']=!![];const _0x246c5c=_0x183230['GXcHe'](getCurrentBranch);_0x246c5c&&_0x183230[_0x179b57(0x8e)](_0x246c5c,_0x183230['celeO'])&&_0x246c5c!==_0x183230[_0x179b57(0x9f)]&&(_0x1c38d9[_0x179b57(0x7f)]=_0x246c5c),delete _0x32b8da['lastEnabledSessionClearedAt'],_0x183230['AJqqZ'](saveCache,_0x32b8da);}export function registerSession(_0x29e987,_0x5a36c7){const _0x1fea3b=_0x582ff1,_0x866d80={'XMfES':function(_0x5e85b8){return _0x5e85b8();},'RlmBK':function(_0x479de5,_0x121dc0,_0x41aece){return _0x479de5(_0x121dc0,_0x41aece);},'YBZlh':function(_0x2097c3,_0x139535){return _0x2097c3(_0x139535);}},_0xc3389a=_0x866d80['XMfES'](loadCache),_0x37081c=_0x866d80[_0x1fea3b(0x77)](getOrCreateSession,_0xc3389a,_0x29e987);_0x37081c[_0x1fea3b(0x89)]=_0x5a36c7,_0x37081c[_0x1fea3b(0x97)]=new Date()['toISOString'](),_0x866d80['YBZlh'](saveCache,_0xc3389a);}export function getSessionEntry(_0x19a7ab){const _0x5db3b7=_0x582ff1,_0x12c138=loadCache(),_0x2848d8=_0x12c138['sessions'][_0x19a7ab];if(_0x2848d8?.['featureId']&&_0x2848d8?.[_0x5db3b7(0x97)])return{'featureId':_0x2848d8['featureId'],'registeredAt':_0x2848d8['registeredAt']};return null;}export function unregisterSession(_0xf620f8){const _0x5e008e=_0x582ff1,_0x11c36f={'BoKyM':function(_0x46374e,_0x24f888){return _0x46374e(_0x24f888);}},_0x270f5d=loadCache(),_0x45f129=_0x270f5d[_0x5e008e(0x83)][_0xf620f8];_0x45f129&&(delete _0x45f129[_0x5e008e(0x89)],delete _0x45f129['registeredAt'],_0x11c36f[_0x5e008e(0x84)](saveCache,_0x270f5d));}const PLAN_REMINDER_INTERVAL_MS=0x5*0x3c*0x3e8,STOP_REMINDER_INTERVAL_MS=0x5*0x3c*0x3e8;export function shouldShowPlanReminder(_0x110a4f){const _0x19b258=_0x582ff1,_0x9cdf11={'QSUog':function(_0x490542){return _0x490542();},'yIbBN':function(_0x301d34,_0x17cd29){return _0x301d34>=_0x17cd29;}},_0x4f39bb=_0x9cdf11[_0x19b258(0x9b)](loadCache),_0x1219b8=getOrCreateSession(_0x4f39bb,_0x110a4f),_0x4a3b02=_0x1219b8['lastPlanReminderAt']||0x0,_0x4626dd=Date[_0x19b258(0x80)]();if(_0x9cdf11['yIbBN'](_0x4626dd-_0x4a3b02,PLAN_REMINDER_INTERVAL_MS))return _0x1219b8['lastPlanReminderAt']=_0x4626dd,saveCache(_0x4f39bb),!![];return![];}export function shouldShowStopReminder(_0x228ba7){const _0x3dfaa2=_0x582ff1,_0x5ce397={'UucKS':function(_0x4abb13){return _0x4abb13();},'IZmSy':function(_0x35ceee,_0x33bd04,_0x3f5feb){return _0x35ceee(_0x33bd04,_0x3f5feb);},'zSldp':function(_0x33fe18,_0x3e4296){return _0x33fe18>=_0x3e4296;}},_0x998501=_0x5ce397['UucKS'](loadCache),_0x1e3a5f=_0x5ce397[_0x3dfaa2(0x8c)](getOrCreateSession,_0x998501,_0x228ba7),_0x4d066e=_0x1e3a5f[_0x3dfaa2(0x8d)]||0x0,_0x677157=Date['now']();if(_0x5ce397[_0x3dfaa2(0xa3)](_0x677157-_0x4d066e,STOP_REMINDER_INTERVAL_MS))return _0x1e3a5f['lastStopReminderAt']=_0x677157,saveCache(_0x998501),!![];return![];}export function hasSessionBeenPrompted(_0x5e5b3b){const _0x2458b6=_0x582ff1,_0x382888=loadCache();return _0x382888[_0x2458b6(0x83)][_0x5e5b3b]?.['prompted']===!![];}export function markSessionPrompted(_0x1865da){const _0x5e61ba=_0x582ff1,_0x50f9ef={'mRQbo':function(_0x289eb7){return _0x289eb7();},'whIBn':function(_0x211e32,_0x4ab414){return _0x211e32(_0x4ab414);}},_0x5d4827=_0x50f9ef[_0x5e61ba(0x71)](loadCache),_0x1f8aee=getOrCreateSession(_0x5d4827,_0x1865da);_0x1f8aee[_0x5e61ba(0xab)]=!![],_0x50f9ef['whIBn'](saveCache,_0x5d4827);}export function getCacheFile(){return CACHE_FILE;}
|
|
1
|
+
const _0x110832=_0x1ea6;(function(_0x3c86cb,_0x43a7e1){const _0x1271ff=_0x1ea6,_0x48c290=_0x3c86cb();while(!![]){try{const _0x3c825a=-parseInt(_0x1271ff(0xb0))/0x1+-parseInt(_0x1271ff(0xa1))/0x2+parseInt(_0x1271ff(0xab))/0x3*(-parseInt(_0x1271ff(0xa6))/0x4)+-parseInt(_0x1271ff(0x8e))/0x5*(-parseInt(_0x1271ff(0xac))/0x6)+parseInt(_0x1271ff(0xa2))/0x7+-parseInt(_0x1271ff(0x9a))/0x8+parseInt(_0x1271ff(0x89))/0x9*(parseInt(_0x1271ff(0xa3))/0xa);if(_0x3c825a===_0x43a7e1)break;else _0x48c290['push'](_0x48c290['shift']());}catch(_0x21ddfe){_0x48c290['push'](_0x48c290['shift']());}}}(_0x59c6,0x3877b));import*as _0x5d5801 from'fs';import*as _0xdedeec from'path';import*as _0x2464b5 from'os';import{execSync}from'child_process';const CACHE_FILE=_0xdedeec['join'](_0x2464b5[_0x110832(0x9d)](),'.claude',_0x110832(0x97));function createEmptyCache(){return{'version':0x3,'sessions':{},'branches':{}};}function loadCache(){const _0x1227d5=_0x110832,_0x3296b1={'GQfvR':_0x1227d5(0xae)};try{if(_0x5d5801[_0x1227d5(0xad)](CACHE_FILE)){const _0x3eec86=JSON['parse'](_0x5d5801[_0x1227d5(0xb8)](CACHE_FILE,_0x3296b1[_0x1227d5(0x9f)]));return{'version':0x3,'sessions':_0x3eec86['sessions']||{},'branches':_0x3eec86[_0x1227d5(0xb9)]||{},'lastEnabledSessionClearedAt':_0x3eec86[_0x1227d5(0xb6)]};}}catch{}return createEmptyCache();}function saveCache(_0x289893){const _0x3454b2=_0x110832;try{const _0xab186a=_0xdedeec[_0x3454b2(0xb1)](CACHE_FILE);!_0x5d5801[_0x3454b2(0xad)](_0xab186a)&&_0x5d5801['mkdirSync'](_0xab186a,{'recursive':!![]}),_0x5d5801[_0x3454b2(0xb4)](CACHE_FILE,JSON[_0x3454b2(0x8c)](_0x289893,null,0x2));}catch{}}function _0x59c6(){const _0xcd8d22=['lastEnabledSessionClearedAt','Tpmwl','readFileSync','branches','377361OGmUTZ','featureId','sessions','stringify','nthbf','90hBCrRG','registeredAt','TMTzT','ivZkE','prompted','git\x20rev-parse\x20--abbrev-ref\x20HEAD','urZlI','yvlFo','SFRVx','.ranger_cache.json','pipe','now','1951192EmUREU','WjtSO','master','homedir','main','GQfvR','HGCIB','35046wooxtb','2990015RlsniQ','130hWCsqE','enabled','ZoQLZ','104Ebsmcb','bygNl','NZoYo','mIUAj','RJWoY','48819gXjQCF','106674pmbIyC','existsSync','utf-8','NRpcK','376433UxxcQY','dirname','currentBranch','lastStopReminderAt','writeFileSync','lastPlanReminderAt'];_0x59c6=function(){return _0xcd8d22;};return _0x59c6();}export function getCurrentBranch(){const _0xa41374=_0x110832,_0x2879ad={'urZlI':function(_0x14c6d8,_0x2c5539,_0x545711){return _0x14c6d8(_0x2c5539,_0x545711);},'ivZkE':'utf-8','fsfIL':_0xa41374(0x98),'TMTzT':function(_0x32ebb8,_0x4c2e10){return _0x32ebb8===_0x4c2e10;}};try{const _0x1b2e68=_0x2879ad[_0xa41374(0x94)](execSync,_0xa41374(0x93),{'encoding':_0x2879ad[_0xa41374(0x91)],'stdio':[_0x2879ad['fsfIL'],_0xa41374(0x98),_0xa41374(0x98)]})['trim']();if(!_0x1b2e68||_0x2879ad[_0xa41374(0x90)](_0x1b2e68,'HEAD'))return null;return _0x1b2e68;}catch{return null;}}export function enableBranch(_0x2370d1){const _0xdeba1=_0x110832,_0xb96911={'nthbf':function(_0x16a947,_0x24b135){return _0x16a947(_0x24b135);}},_0x346c45=loadCache();_0x346c45[_0xdeba1(0xb9)][_0x2370d1]=!![],_0xb96911[_0xdeba1(0x8d)](saveCache,_0x346c45);}export function disableBranch(_0x100fe6){const _0x279870=_0x110832,_0x27b116={'ZoQLZ':function(_0x11e970){return _0x11e970();}},_0x55f9ea=_0x27b116[_0x279870(0xa5)](loadCache);delete _0x55f9ea[_0x279870(0xb9)][_0x100fe6],saveCache(_0x55f9ea);}export function isBranchEnabled(_0x38f673){const _0x16f208=_0x110832,_0xa1dd3f={'mIUAj':function(_0x3a25d1,_0x2e120e){return _0x3a25d1===_0x2e120e;}},_0x2283c0=loadCache();return _0xa1dd3f[_0x16f208(0xa9)](_0x2283c0['branches'][_0x38f673],!![]);}function getOrCreateSession(_0x40125b,_0x2c72c7){const _0x5091a1=_0x110832;return!_0x40125b[_0x5091a1(0x8b)][_0x2c72c7]&&(_0x40125b[_0x5091a1(0x8b)][_0x2c72c7]={}),_0x40125b['sessions'][_0x2c72c7];}export function enableSession(_0xf64e87){const _0x5d9a7e=_0x110832,_0x23be53={'NZoYo':function(_0x58fc07){return _0x58fc07();},'jxdXW':function(_0x2c4ac8,_0x1cb234){return _0x2c4ac8!==_0x1cb234;},'iLlxM':'main','QqnQs':function(_0x184a65,_0x221cfb){return _0x184a65!==_0x221cfb;},'HOONa':function(_0x4fa549,_0x2102e8){return _0x4fa549(_0x2102e8);}},_0x493a46=loadCache(),_0x268af=getOrCreateSession(_0x493a46,_0xf64e87);_0x268af[_0x5d9a7e(0xa4)]=!![];const _0x5395d1=_0x23be53[_0x5d9a7e(0xa8)](getCurrentBranch);_0x5395d1&&_0x23be53['jxdXW'](_0x5395d1,_0x23be53['iLlxM'])&&_0x23be53['QqnQs'](_0x5395d1,'master')&&(_0x493a46[_0x5d9a7e(0xb9)][_0x5395d1]=!![],_0x268af[_0x5d9a7e(0xb2)]=_0x5395d1),_0x23be53['HOONa'](saveCache,_0x493a46);}export function isSessionEnabled(_0x5d029e){const _0x4f7d24=_0x110832,_0x2abc75={'onrMY':function(_0x3bcea1){return _0x3bcea1();},'arszJ':function(_0x4b650a){return _0x4b650a();},'RJWoY':function(_0x59f8e9,_0x338ea3){return _0x59f8e9===_0x338ea3;},'CJQOn':'main','pswby':function(_0x284803,_0x56101d){return _0x284803===_0x56101d;}},_0x230d5a=_0x2abc75['onrMY'](loadCache),_0x5d2fc0=_0x2abc75['arszJ'](getCurrentBranch);if(!_0x5d2fc0||_0x2abc75[_0x4f7d24(0xaa)](_0x5d2fc0,_0x2abc75['CJQOn'])||_0x5d2fc0==='master')return _0x2abc75[_0x4f7d24(0xaa)](_0x230d5a['sessions'][_0x5d029e]?.['enabled'],!![]);const _0x175672=_0x230d5a['branches'][_0x5d2fc0]===!![],_0xbf1fbd=_0x2abc75['pswby'](_0x230d5a[_0x4f7d24(0x8b)][_0x5d029e]?.[_0x4f7d24(0xa4)],!![]);return _0x175672||_0xbf1fbd;}export function disableSession(_0x519c81){const _0x2520e5=_0x110832,_0x434785={'nKBIr':function(_0x7394d9){return _0x7394d9();},'ARXyP':function(_0x1c4741,_0x44290d,_0x5cbbd6){return _0x1c4741(_0x44290d,_0x5cbbd6);}},_0x4b24f7=_0x434785['nKBIr'](loadCache),_0x11f4a7=_0x434785['ARXyP'](getOrCreateSession,_0x4b24f7,_0x519c81);_0x11f4a7[_0x2520e5(0xa4)]=![],saveCache(_0x4b24f7);}export function updateBranchTracking(_0x53a6f4){const _0x12d8f6=_0x110832,_0x338904={'QBCpW':function(_0x2efbb4,_0x163fbf){return _0x2efbb4===_0x163fbf;},'ltjGB':_0x12d8f6(0x9e),'gukBt':function(_0x440050,_0x12c2d2){return _0x440050===_0x12c2d2;},'NRpcK':_0x12d8f6(0x9c),'aadGr':function(_0x200754,_0x326910){return _0x200754!==_0x326910;}},_0x180399=loadCache(),_0x54309b=_0x180399['sessions'][_0x53a6f4];if(!_0x54309b?.[_0x12d8f6(0xa4)])return;const _0x3dfb05=getCurrentBranch();if(!_0x3dfb05||_0x338904['QBCpW'](_0x3dfb05,_0x338904['ltjGB'])||_0x338904['gukBt'](_0x3dfb05,_0x338904[_0x12d8f6(0xaf)]))return;_0x338904['aadGr'](_0x54309b[_0x12d8f6(0xb2)],_0x3dfb05)&&(_0x180399[_0x12d8f6(0xb9)][_0x3dfb05]=!![],_0x54309b['currentBranch']=_0x3dfb05,saveCache(_0x180399));}export function initBranchTracking(_0x51c589){const _0xa591e3=_0x110832,_0x5cad50={'tZVzU':function(_0x4de213,_0x446512){return _0x4de213===_0x446512;},'HGCIB':_0xa591e3(0x9c),'gIkas':function(_0x1b0b32,_0x25e6e5,_0x3dee08){return _0x1b0b32(_0x25e6e5,_0x3dee08);},'PctbB':function(_0x49b372,_0x4425eb){return _0x49b372(_0x4425eb);}},_0x2de2cb=loadCache(),_0x26d236=getCurrentBranch();if(!_0x26d236||_0x5cad50['tZVzU'](_0x26d236,_0xa591e3(0x9e))||_0x26d236===_0x5cad50[_0xa591e3(0xa0)])return;if(_0x2de2cb['branches'][_0x26d236]===!![]){const _0x54ead0=_0x5cad50['gIkas'](getOrCreateSession,_0x2de2cb,_0x51c589);_0x54ead0[_0xa591e3(0xa4)]=!![],_0x54ead0[_0xa591e3(0xb2)]=_0x26d236,_0x5cad50['PctbB'](saveCache,_0x2de2cb);}}const CLEAR_AUTO_ENABLE_WINDOW_MS=0x1388;export function recordEnabledSessionCleared(_0x341fbc){const _0x443a11=_0x110832,_0x8a4c26={'TUqsN':function(_0x9061e1){return _0x9061e1();},'bygNl':function(_0x1af364,_0x27aa33){return _0x1af364(_0x27aa33);}},_0x1ffeaf=_0x8a4c26['TUqsN'](loadCache),_0x5bef8a=_0x1ffeaf[_0x443a11(0x8b)][_0x341fbc];_0x5bef8a?.['enabled']&&(_0x1ffeaf['lastEnabledSessionClearedAt']=Date['now'](),_0x8a4c26[_0x443a11(0xa7)](saveCache,_0x1ffeaf));}export function shouldAutoEnableAfterClear(_0x3aeb49){const _0x23ff4e={'IGIAr':function(_0x46cd58,_0x1c7aae){return _0x46cd58!==_0x1c7aae;}};if(_0x23ff4e['IGIAr'](_0x3aeb49,'clear'))return![];const _0x76e22d=loadCache(),_0x39b158=_0x76e22d['lastEnabledSessionClearedAt'];if(!_0x39b158)return![];const _0x5d218c=Date['now']()-_0x39b158;return _0x5d218c<=CLEAR_AUTO_ENABLE_WINDOW_MS;}export function autoEnableAfterClear(_0x5ef485){const _0x11e4d1=_0x110832,_0x4af117={'kiLcg':function(_0x262560){return _0x262560();},'QAAWi':'master'},_0x157f82=loadCache(),_0x53a8b0=getOrCreateSession(_0x157f82,_0x5ef485);_0x53a8b0[_0x11e4d1(0xa4)]=!![];const _0x2ac438=_0x4af117['kiLcg'](getCurrentBranch);_0x2ac438&&_0x2ac438!==_0x11e4d1(0x9e)&&_0x2ac438!==_0x4af117['QAAWi']&&(_0x53a8b0[_0x11e4d1(0xb2)]=_0x2ac438),delete _0x157f82[_0x11e4d1(0xb6)],saveCache(_0x157f82);}export function registerSession(_0xd587a3,_0xc9543b){const _0x87d8d6=_0x110832,_0x28667e={'uEXrY':function(_0xa055e4,_0x5bce51,_0x2c49c2){return _0xa055e4(_0x5bce51,_0x2c49c2);}},_0x58188f=loadCache(),_0x10624c=_0x28667e['uEXrY'](getOrCreateSession,_0x58188f,_0xd587a3);_0x10624c['featureId']=_0xc9543b,_0x10624c[_0x87d8d6(0x8f)]=new Date()['toISOString'](),saveCache(_0x58188f);}export function getSessionEntry(_0x47dbd9){const _0x351a75=_0x110832,_0x5aafa9=loadCache(),_0x5cc557=_0x5aafa9[_0x351a75(0x8b)][_0x47dbd9];if(_0x5cc557?.['featureId']&&_0x5cc557?.[_0x351a75(0x8f)])return{'featureId':_0x5cc557[_0x351a75(0x8a)],'registeredAt':_0x5cc557[_0x351a75(0x8f)]};return null;}export function unregisterSession(_0x309a51){const _0x4061fa=_0x110832,_0x2f8963=loadCache(),_0x55fa88=_0x2f8963[_0x4061fa(0x8b)][_0x309a51];_0x55fa88&&(delete _0x55fa88[_0x4061fa(0x8a)],delete _0x55fa88['registeredAt'],saveCache(_0x2f8963));}const PLAN_REMINDER_INTERVAL_MS=0x5*0x3c*0x3e8,STOP_REMINDER_INTERVAL_MS=0x5*0x3c*0x3e8;export function shouldShowPlanReminder(_0x28af69){const _0x375dcb=_0x110832,_0x256121={'SFRVx':function(_0x2fcaf4,_0x580777){return _0x2fcaf4(_0x580777);}},_0x14a869=loadCache(),_0x45a4d5=getOrCreateSession(_0x14a869,_0x28af69),_0x2d2ed8=_0x45a4d5[_0x375dcb(0xb5)]||0x0,_0x3699cc=Date[_0x375dcb(0x99)]();if(_0x3699cc-_0x2d2ed8>=PLAN_REMINDER_INTERVAL_MS)return _0x45a4d5[_0x375dcb(0xb5)]=_0x3699cc,_0x256121[_0x375dcb(0x96)](saveCache,_0x14a869),!![];return![];}export function shouldShowStopReminder(_0x140205){const _0x51a244=_0x110832,_0x4e55a4={'WjtSO':function(_0x5cd8fe,_0x1d59e6,_0x3d3c42){return _0x5cd8fe(_0x1d59e6,_0x3d3c42);}},_0x51c24a=loadCache(),_0x357df8=_0x4e55a4[_0x51a244(0x9b)](getOrCreateSession,_0x51c24a,_0x140205),_0x51b626=_0x357df8[_0x51a244(0xb3)]||0x0,_0xa31f81=Date['now']();if(_0xa31f81-_0x51b626>=STOP_REMINDER_INTERVAL_MS)return _0x357df8['lastStopReminderAt']=_0xa31f81,saveCache(_0x51c24a),!![];return![];}function _0x1ea6(_0x2664f7,_0x4d9cc7){_0x2664f7=_0x2664f7-0x89;const _0x59c6d1=_0x59c6();let _0x1ea6b4=_0x59c6d1[_0x2664f7];return _0x1ea6b4;}export function hasSessionBeenPrompted(_0x1c7fe3){const _0x19ea8b=_0x110832,_0x4d0d6a={'Tpmwl':function(_0x99a20){return _0x99a20();},'yvlFo':function(_0x1aae36,_0x17fca8){return _0x1aae36===_0x17fca8;}},_0x37aed6=_0x4d0d6a[_0x19ea8b(0xb7)](loadCache);return _0x4d0d6a[_0x19ea8b(0x95)](_0x37aed6['sessions'][_0x1c7fe3]?.[_0x19ea8b(0x92)],!![]);}export function markSessionPrompted(_0x5e32ad){const _0x450c86=_0x110832,_0x15495e={'DrEES':function(_0x21216a,_0x42595b,_0x30d5b2){return _0x21216a(_0x42595b,_0x30d5b2);},'TlaMz':function(_0x525932,_0x2f76fa){return _0x525932(_0x2f76fa);}},_0x15c2f5=loadCache(),_0x4a4410=_0x15495e['DrEES'](getOrCreateSession,_0x15c2f5,_0x5e32ad);_0x4a4410[_0x450c86(0x92)]=!![],_0x15495e['TlaMz'](saveCache,_0x15c2f5);}export function getCacheFile(){return CACHE_FILE;}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
function _0x4a59(_0x1b8738,_0x505dca){_0x1b8738=_0x1b8738-0x93;const _0x308202=_0x3082();let _0x4a5909=_0x308202[_0x1b8738];return _0x4a5909;}const _0xde5ba5=_0x4a59;(function(_0x679405,_0x5b5026){const _0x3829ac=_0x4a59,_0x58c794=_0x679405();while(!![]){try{const _0x42277c=parseInt(_0x3829ac(0x115))/0x1+-parseInt(_0x3829ac(0xcf))/0x2+parseInt(_0x3829ac(0xcc))/0x3+parseInt(_0x3829ac(0xd9))/0x4*(parseInt(_0x3829ac(0xf9))/0x5)+parseInt(_0x3829ac(0xfa))/0x6+-parseInt(_0x3829ac(0xf3))/0x7*(-parseInt(_0x3829ac(0xcd))/0x8)+-parseInt(_0x3829ac(0xd6))/0x9*(parseInt(_0x3829ac(0x97))/0xa);if(_0x42277c===_0x5b5026)break;else _0x58c794['push'](_0x58c794['shift']());}catch(_0x1e4b1c){_0x58c794['push'](_0x58c794['shift']());}}}(_0x3082,0x3940e));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(_0x9bc691,_0x5b8a2b){const _0x3bb001=_0x4a59,_0x2c93f1={'iEzbX':function(_0x3486c8,_0x11b660,_0x1b4f55,_0x3587be){return _0x3486c8(_0x11b660,_0x1b4f55,_0x3587be);},'UygMX':_0x3bb001(0x9a),'IKjNJ':function(_0x1d5892,_0x2dd875,_0x3f2584){return _0x1d5892(_0x2dd875,_0x3f2584);},'MOfEI':function(_0x419c2d,_0x4c6843){return _0x419c2d(_0x4c6843);},'cWjdq':function(_0x48fe97,_0x6db609){return _0x48fe97!==_0x6db609;}},_0x205917=join(_0x5b8a2b,'ci',_0x9bc691),_0x15a137=_0x2c93f1[_0x3bb001(0xec)](join,_0x5b8a2b,_0x3bb001(0x9a),_0x9bc691),_0x265bf6=join(_0x5b8a2b,_0x9bc691),_0x3c0502=join(_0x5b8a2b,_0x2c93f1['UygMX']),_0x348f92=_0x2c93f1[_0x3bb001(0xa1)](join,_0x5b8a2b,'ci');if(_0x2c93f1[_0x3bb001(0xc9)](existsSync,_0x205917))return _0x205917;if(existsSync(_0x15a137))return _0x15a137;if(_0x2c93f1[_0x3bb001(0xc9)](existsSync,_0x265bf6)&&(_0x265bf6!==_0x3c0502&&_0x2c93f1['cWjdq'](_0x265bf6,_0x348f92)?!![]:hasLegacyProfileFiles(_0x265bf6)))return _0x265bf6;return null;}export function getEnvDir(_0x3dc637,_0x2ec9af={}){const _0x2110eb=_0x4a59,_0xb7c7c={'bNhsn':function(_0x19f8c2){return _0x19f8c2();},'RgwXW':function(_0x5ded6d,_0x2a2d9d){return _0x5ded6d(_0x2a2d9d);},'idjGg':function(_0x4dc57d,_0x546b35,_0x4c1753){return _0x4dc57d(_0x546b35,_0x4c1753);},'SoipM':function(_0x450d82,_0x329c15,_0x17ffd4){return _0x450d82(_0x329c15,_0x17ffd4);},'sfwjy':'local'},_0x2d4d67=_0xb7c7c[_0x2110eb(0xf2)](getRangerDir),_0x4c80fd=findEnvInRoot(_0x3dc637,_0x2d4d67);if(_0x4c80fd){if(_0x2ec9af[_0x2110eb(0xff)]&&_0xb7c7c[_0x2110eb(0xc0)](isLegacyEnvPath,_0x4c80fd))throw legacyWriteError(_0x3dc637,_0x4c80fd);return _0x4c80fd;}const _0x8af3bd=_0xb7c7c['bNhsn'](getRangerHomeDir);if(_0x8af3bd!==_0x2d4d67){const _0x321118=_0xb7c7c['idjGg'](findEnvInRoot,_0x3dc637,_0x8af3bd);if(_0x321118){if(_0x2ec9af[_0x2110eb(0xff)]&&_0xb7c7c['RgwXW'](isLegacyEnvPath,_0x321118))throw _0xb7c7c['SoipM'](legacyWriteError,_0x3dc637,_0x321118);return _0x321118;}}const _0x2fb6d5=join(_0x8af3bd,_0xb7c7c[_0x2110eb(0xce)],_0x3dc637);if(_0x2ec9af['forWrite'])throw legacyWriteError(_0x3dc637,_0x2fb6d5);return _0x2fb6d5;}function isLegacyEnvPath(_0x39f8a3){const _0x4f4234=_0x4a59,_0x196421={'eHlIm':function(_0x499984,_0x9bb99e){return _0x499984+_0x9bb99e;},'xyPfU':function(_0x33aa90,_0x5d71d0){return _0x33aa90===_0x5d71d0;}},_0x14a886=getRangerDir(),_0x410cd9=getRangerHomeDir();for(const _0x49f9fe of new Set([_0x14a886,_0x410cd9])){const _0x270071=_0x49f9fe['endsWith']('/')?_0x49f9fe:_0x196421[_0x4f4234(0xa7)](_0x49f9fe,'/');if(_0x196421[_0x4f4234(0xac)](_0x39f8a3,_0x49f9fe)||_0x39f8a3['startsWith'](_0x270071))return!![];}return![];}function legacyWriteError(_0x10ea12,_0x31b638){const _0x12f3e3=_0x4a59,_0x2f7295={'fBVYm':function(_0x3470b4,_0x409288){return _0x3470b4+_0x409288;},'VZmnD':function(_0x3f270b,_0x3ea5f9){return _0x3f270b+_0x3ea5f9;},'fqgcp':function(_0x31273f,_0x3ff6dc){return _0x31273f+_0x3ff6dc;}};return new Error(_0x2f7295[_0x12f3e3(0xdd)](_0x2f7295[_0x12f3e3(0xb1)](_0x2f7295[_0x12f3e3(0xd8)](_0x12f3e3(0xba)+_0x10ea12+'\x22\x20to\x20legacy\x20path\x20'+_0x31b638+'.\x0a',_0x12f3e3(0x98)),_0x12f3e3(0xd1)),_0x12f3e3(0xbf)));}export function findExistingEnv(_0x5e1ede,_0x494b99){const _0x3966d5=_0x4a59,_0x5652fa={'hkEtA':function(_0x177be1){return _0x177be1();},'xHZvz':'local','JfDUj':_0x3966d5(0xe0),'JogbY':function(_0xb19c9e,_0x2e28e9,_0x52e708){return _0xb19c9e(_0x2e28e9,_0x52e708);},'AGBNN':function(_0x4bba65,_0x2e699c,_0xf17552,_0x5736a7){return _0x4bba65(_0x2e699c,_0xf17552,_0x5736a7);},'yZXjX':function(_0x564a0a,_0x1f59d2){return _0x564a0a(_0x1f59d2);}},_0x5b471d=_0x494b99?.['rangerDir'],_0x3bb302=_0x5b471d?[_0x5b471d]:[_0x5652fa['hkEtA'](getRangerDir),_0x5652fa['hkEtA'](getRangerHomeDir)][_0x3966d5(0x107)]((_0x3698b2,_0x4cf7be,_0x19e6e4)=>_0x19e6e4[_0x3966d5(0xb5)](_0x3698b2)===_0x4cf7be),_0x40c421=_0x494b99?.[_0x3966d5(0x9c)]??['ci',_0x5652fa['xHZvz'],_0x5652fa[_0x3966d5(0xc7)]];for(const _0x41674b of _0x3bb302){const _0xa216d2=join(_0x41674b,_0x5652fa[_0x3966d5(0xb2)]),_0x462eb5=_0x5652fa['JogbY'](join,_0x41674b,'ci'),_0x364340=[{'location':'ci','path':_0x5652fa['AGBNN'](join,_0x41674b,'ci',_0x5e1ede)},{'location':'local','path':_0x5652fa[_0x3966d5(0x106)](join,_0x41674b,'local',_0x5e1ede)},{'location':_0x5652fa['JfDUj'],'path':join(_0x41674b,_0x5e1ede)}];for(const _0x2d1695 of _0x364340){if(_0x40c421['includes'](_0x2d1695[_0x3966d5(0xa0)])&&existsSync(_0x2d1695[_0x3966d5(0xf1)])){if(_0x2d1695[_0x3966d5(0xa0)]===_0x5652fa[_0x3966d5(0xc7)]&&(_0x2d1695['path']===_0xa216d2||_0x2d1695[_0x3966d5(0xf1)]===_0x462eb5)&&!_0x5652fa['yZXjX'](hasLegacyProfileFiles,_0x2d1695['path']))continue;return{'path':_0x2d1695['path'],'location':_0x2d1695[_0x3966d5(0xa0)]};}}}return null;}function hasLegacyProfileFiles(_0x211c36){const _0x45643f=_0x4a59,_0x4b3ec8={'GddcU':function(_0x552f8c,_0x413069){return _0x552f8c(_0x413069);},'ZzXMA':'auth.json'};return existsSync(join(_0x211c36,_0x45643f(0xe9)))||_0x4b3ec8[_0x45643f(0xcb)](existsSync,join(_0x211c36,_0x4b3ec8['ZzXMA']))||existsSync(join(_0x211c36,'auth.json.enc'));}export function isEnvCi(_0x283a58){const _0x21966a=_0x4a59,_0x52a768={'nJnYs':function(_0x413deb,_0x255202){return _0x413deb(_0x255202);},'pKrIn':function(_0x4d9c68){return _0x4d9c68();}};if(_0x52a768[_0x21966a(0xca)](existsSync,join(_0x52a768[_0x21966a(0xe5)](getRangerDir),'ci',_0x283a58)))return!![];const _0x344ddf=getRangerHomeDir();if(_0x344ddf!==getRangerDir()&&existsSync(join(_0x344ddf,'ci',_0x283a58)))return!![];return![];}export async function cleanupTempFiles(_0x4569b1){const _0x41b8f5=_0x4a59,_0x1f4ee2=[_0x4569b1['tempAuthPath'],_0x4569b1[_0x41b8f5(0xf5)]][_0x41b8f5(0x107)](Boolean);await Promise['all'](_0x1f4ee2['map'](_0x5a0b2d=>unlink(_0x5a0b2d)['catch'](_0x16acee=>{const _0x379791=_0x41b8f5;_0x16acee['code']!==_0x379791(0xbb)&&console[_0x379791(0xa9)]('Failed\x20to\x20clean\x20up\x20temp\x20file\x20'+_0x5a0b2d+':',_0x16acee['message']);})));}export function getSettingsPath(_0x5a5450){const _0x1449df=_0x4a59,_0x6f2dda={'KDBJG':function(_0xd36a09,_0x5d1f09,_0x49d800){return _0xd36a09(_0x5d1f09,_0x49d800);},'BRVaC':function(_0x1fc767,_0x5daaf8){return _0x1fc767(_0x5daaf8);}};return _0x6f2dda['KDBJG'](join,_0x6f2dda[_0x1449df(0xbd)](getEnvDir,_0x5a5450),'settings.json');}export async function loadSettings(_0x5bc8db){const _0x624004=_0x4a59,_0x58cd6d={'BlHQL':function(_0x123f04,_0x2a2312){return _0x123f04(_0x2a2312);}},_0x5bd53e=_0x58cd6d['BlHQL'](getSettingsPath,_0x5bc8db);if(!existsSync(_0x5bd53e))return{};try{const _0x146fa9=await readFile(_0x5bd53e,_0x624004(0xc6));return JSON[_0x624004(0xa4)](_0x146fa9);}catch{return{};}}function _0x3082(){const _0x2cde09=['warn','clipboard-write','djXUu','xyPfU','AuGng','playwright-cli','--no-sandbox','pVkoy','VZmnD','xHZvz','pdf','storageStatePath','indexOf','setupHeader','extraHTTPHeaders','storageState','MpwDG','Refusing\x20to\x20write\x20profile\x20\x22','ENOENT','file','BRVaC','nova-user-data','See\x20https://docs.ranger.net/main/concepts/profiles\x20for\x20setup\x20options.','RgwXW','replace','install','getuid','cjqoJ','isArray','utf-8','JfDUj','chromium','MOfEI','nJnYs','GddcU','435984TtApya','1688BgrNVc','sfwjy','775702rIFjDT','stagehand','\x20\x20ranger\x20profile\x20add\x20<name>\x0a','ranger-config','YdFSt','TJXwi','\x20is\x20not\x20set','936ZhpkyR','mGCsH','fqgcp','4AcfdRk','vUagh','dBldS','entries','fBVYm','userAgent','header','legacy','auth.json','OWgKL','--allow-insecure-localhost','TDtPa','pKrIn','none','ELajm','args','settings.json','UYMYa','split','iEzbX','contextOptions','auth.json.enc','sessions','kYbhv','path','bNhsn','9345plrbUJ','rczTl','configPath','catch','UDjyU','boolean','760510EHQAtR','987492UyDIIB','headers','now','--disable-setuid-sandbox','TIMeV','forWrite','keys','oDeiJ','string','-cli','object','qIhoJ','AGBNN','filter','Environment\x20variable\x20','UrQpv','browser','executablePath','push','cNyvX','repeat','ysAfL','TVBGu','.json','map','includes','length','337720SWhnvU','LPLnO','join','core','yfFPB','-rangerwright.json','xSJBb','Gjczi','44140YvYCUF','That\x20directory\x20is\x20read-only\x20now.\x20To\x20set\x20up\x20a\x20fresh\x20profile,\x20run:\x0a','pRllx','local','allowInsecureLocalhost','locations','clipboard-read','zZLEr','TGcKl','location','IKjNJ','hgVwj','cdpEndpoint','parse','safeMode','LpyYc','eHlIm','JSNeS'];_0x3082=function(){return _0x2cde09;};return _0x3082();}export async function saveSettings(_0x7e0037,_0x25c31d){const _0x19b6ec=_0x4a59,_0x4042c2={'yfFPB':function(_0x328cbd,_0x39346d){return _0x328cbd(_0x39346d);},'XCgHe':function(_0x40c0a5,_0x307ecb){return _0x40c0a5(_0x307ecb);},'FStqy':function(_0x24f562,_0x3139fc,_0x5e71e){return _0x24f562(_0x3139fc,_0x5e71e);}},_0x4530c6=_0x4042c2[_0x19b6ec(0x93)](getSettingsPath,_0x7e0037),_0x1a64de=dirname(_0x4530c6);!_0x4042c2['XCgHe'](existsSync,_0x1a64de)&&await _0x4042c2['FStqy'](mkdir,_0x1a64de,{'recursive':!![]}),await writeFile(_0x4530c6,JSON['stringify'](_0x25c31d,null,0x2));}export function resolveEnvVars(_0x1d1928){const _0x506cc7=_0x4a59,_0x27eb6a={'ysAfL':'string','aijDz':function(_0x2b0177,_0xc52da0){return _0x2b0177===_0xc52da0;},'pRhuC':'object'};if(typeof _0x1d1928===_0x27eb6a[_0x506cc7(0x10f)])return _0x1d1928[_0x506cc7(0xc1)](/\$\{(\w+)\}/g,(_0x545061,_0x5c66b1)=>{const _0x206889=_0x506cc7,_0x313775=process['env'][_0x5c66b1];if(_0x313775===undefined)throw new Error(_0x206889(0x108)+_0x5c66b1+_0x206889(0xd5));return _0x313775;});if(Array[_0x506cc7(0xc5)](_0x1d1928))return _0x1d1928[_0x506cc7(0x112)](resolveEnvVars);if(_0x1d1928&&_0x27eb6a['aijDz'](typeof _0x1d1928,_0x27eb6a['pRhuC']))return Object['fromEntries'](Object[_0x506cc7(0xdc)](_0x1d1928)['map'](([_0x151f8d,_0x490a18])=>[_0x151f8d,resolveEnvVars(_0x490a18)]));return _0x1d1928;}const isRecord=_0x1701d7=>typeof _0x1701d7===_0xde5ba5(0x104)&&_0x1701d7!==null&&!Array[_0xde5ba5(0xc5)](_0x1701d7),asRecord=_0x5da3db=>isRecord(_0x5da3db)?_0x5da3db:undefined,mergeHeaders=(_0x1fed5f,_0x6e5fb8)=>{const _0x3d17c9=_0xde5ba5,_0x7cb561={'UrQpv':function(_0x39dd7d,_0x125f01){return _0x39dd7d??_0x125f01;}},_0x1245d7={..._0x1fed5f??{},..._0x7cb561[_0x3d17c9(0x109)](_0x6e5fb8,{})};return Object[_0x3d17c9(0x100)](_0x1245d7)[_0x3d17c9(0x114)]?_0x1245d7:undefined;},SAFE_MODE_ARGS=['--disable-features=WebBluetooth'],ALLOW_LOCALHOST_ARGS=['--disable-web-security','--allow-running-insecure-content','--unsafely-treat-insecure-origin-as-secure=http://localhost',_0xde5ba5(0xe3)];export function buildBrowserOptionsFromSettings(_0x496b79,_0x5dad54={}){const _0x437993=_0xde5ba5,_0x3ed7cc={'UDjyU':function(_0x5f4486,_0x48f37){return _0x5f4486===_0x48f37;},'qdvCd':function(_0x448044,_0x2c173b){return _0x448044(_0x2c173b);}},_0x1a638f=asRecord(_0x496b79[_0x437993(0x10a)]),_0x3a9280={...asRecord(_0x1a638f?.['launchOptions'])??{}};typeof _0x5dad54['headless']===_0x437993(0xf8)&&(_0x3a9280['headless']=_0x5dad54['headless']);if(_0x496b79[_0x437993(0xa5)]){const _0x1e1854=_0x3a9280['args']??[],_0x13abda=SAFE_MODE_ARGS['filter'](_0x56f25e=>!_0x1e1854[_0x437993(0x113)](_0x56f25e));_0x3a9280['args']=[..._0x1e1854,..._0x13abda];}if(_0x496b79[_0x437993(0x9b)]){const _0x25f62e=_0x3a9280['args']??[],_0x2e7e28=ALLOW_LOCALHOST_ARGS[_0x437993(0x107)](_0x51e9c1=>!_0x25f62e['includes'](_0x51e9c1));_0x3a9280[_0x437993(0xe8)]=[..._0x25f62e,..._0x2e7e28];}const _0x158ec8={...asRecord(_0x1a638f?.['contextOptions'])??{}};_0x158ec8['ignoreHTTPSErrors']=!![];_0x3ed7cc[_0x437993(0xf7)](typeof _0x496b79['userAgent'],'string')&&(_0x158ec8['userAgent']=_0x496b79[_0x437993(0xde)]);const _0x2064d0=mergeHeaders(asRecord(_0x158ec8['extraHTTPHeaders']),_0x3ed7cc['qdvCd'](asRecord,_0x496b79['headers']));return _0x2064d0?_0x158ec8['extraHTTPHeaders']=_0x2064d0:delete _0x158ec8['extraHTTPHeaders'],_0x5dad54['storageStatePath']&&(_0x158ec8[_0x437993(0xb8)]=_0x5dad54[_0x437993(0xb4)]),{'launchOptions':_0x3a9280,'contextOptions':_0x158ec8};}export async function resolveProfileStorageState(_0x1820fd){const _0x191315={'fNDGQ':function(_0x178c8f,_0x42fb38){return _0x178c8f(_0x42fb38);}};return _0x191315['fNDGQ'](resolveLocalAuthPath,getEnvDir(_0x1820fd));}async function resolveLocalAuthPath(_0x410cf6){const _0x297afe=_0xde5ba5,_0x19c1ec={'ccGjU':function(_0x3abcfa,_0x292ec5,_0x3866d8){return _0x3abcfa(_0x292ec5,_0x3866d8);},'AuGng':function(_0x33bd7a,_0x26a245){return _0x33bd7a(_0x26a245);},'TGcKl':function(_0x2e4f0d,_0x109e85,_0x4b4ebf){return _0x2e4f0d(_0x109e85,_0x4b4ebf);},'azrRC':function(_0x4ef593,_0x18d55d,_0x24aa79){return _0x4ef593(_0x18d55d,_0x24aa79);}},_0x1fbd8c=_0x19c1ec['ccGjU'](join,_0x410cf6,_0x297afe(0xee)),_0x5bcbc0=join(_0x410cf6,_0x297afe(0xe1));if(_0x19c1ec['AuGng'](existsSync,_0x1fbd8c))try{const _0x6aa9bd=await getToken();if(!_0x6aa9bd)throw new Error('No\x20API\x20token\x20found.\x20Run:\x20ranger\x20setup\x20[token]');const _0x51361f=await _0x19c1ec[_0x297afe(0xad)](readFile,_0x1fbd8c),_0x5e3772=_0x19c1ec[_0x297afe(0x9f)](decrypt,_0x51361f,_0x6aa9bd),_0x2f83da=_0x19c1ec['azrRC'](join,tmpdir(),'ranger-auth-'+Date[_0x297afe(0xfc)]()+_0x297afe(0x111));return await writeFile(_0x2f83da,_0x5e3772),{'storageStatePath':_0x2f83da,'tempAuthPath':_0x2f83da};}catch(_0x5c644a){const _0x19dfc5=_0x5c644a instanceof Error?_0x5c644a['message']:String(_0x5c644a);throw new Error('Failed\x20to\x20decrypt\x20auth\x20state:\x20'+_0x19dfc5);}if(existsSync(_0x5bcbc0))return{'storageStatePath':_0x5bcbc0};return{};}export async function buildPlaywrightConfig(_0x2cae39,_0x4c7219,_0x3a3267,_0x4a3d37,_0x5c248e){const _0x5b8e29=_0xde5ba5,_0x212f6b={'SFuej':function(_0x2fb233,_0x1c1975,_0x337726,_0x205c57,_0x33d8d8,_0x51f84a,_0x27fe8f){return _0x2fb233(_0x1c1975,_0x337726,_0x205c57,_0x33d8d8,_0x51f84a,_0x27fe8f);},'MpwDG':'stagehand','vUagh':function(_0x384705,_0x2a932d){return _0x384705(_0x2a932d);}};if(_0x5c248e)return _0x212f6b['SFuej'](buildPlaywrightConfigCore,_0x2cae39,_0x5c248e,_0x4c7219,_0x3a3267,_0x4a3d37,_0x212f6b[_0x5b8e29(0xb9)]);const {storageStatePath:_0x145473,tempAuthPath:_0x177814}=await _0x212f6b['vUagh'](resolveLocalAuthPath,getEnvDir(_0x4c7219));try{const _0x1f29bb=await _0x212f6b['SFuej'](buildPlaywrightConfigCore,_0x2cae39,_0x145473,_0x4c7219,_0x3a3267,_0x4a3d37,_0x5b8e29(0xd0));return{..._0x1f29bb,'tempAuthPath':_0x177814};}catch(_0x2397cb){_0x177814&&await _0x212f6b[_0x5b8e29(0xda)](unlink,_0x177814)['catch'](()=>{});throw _0x2397cb;}}export async function buildPlaywrightConfigCore(_0x32be43,_0x15cee0,_0x1c0e5a,_0x14b1ef,_0x359ac9,_0x49198a=_0xde5ba5(0xd0)){const _0x3eab1d=_0xde5ba5,_0x53ef14={'pRllx':'--no-sandbox','cNyvX':_0x3eab1d(0x9d),'oDeiJ':'chromium','iaQou':_0x3eab1d(0xe6),'rczTl':_0x3eab1d(0x118),'UYMYa':_0x3eab1d(0xb3),'qIhoJ':function(_0x2d1a62,_0x1f6253){return _0x2d1a62===_0x1f6253;},'kYbhv':_0x3eab1d(0xd2),'wCEsa':_0x3eab1d(0xae),'LPLnO':_0x3eab1d(0x103),'SyHqm':function(_0x1561d5,_0x43a94b,_0x2cb5c0){return _0x1561d5(_0x43a94b,_0x2cb5c0);}},_0x4b211e=_0x14b1ef||randomUUID(),_0x4a19f0=join(getRangerDir(),'sessions',_0x4b211e),_0x26508b=Boolean(_0x32be43['cdpEndpoint']),_0x3761f2=_0x26508b?{'browserName':_0x53ef14[_0x3eab1d(0x101)],'cdpEndpoint':_0x32be43[_0x3eab1d(0xa3)]}:((()=>{const _0xf62177=_0x3eab1d,{launchOptions:_0x50e04a,contextOptions:_0x208902}=buildBrowserOptionsFromSettings(_0x32be43,{'headless':_0x359ac9?![]:_0x32be43['headless']??!![],'storageStatePath':_0x15cee0});if(process['getuid']?.()===0x0){const _0x1c13c4=[_0x53ef14[_0xf62177(0x99)],_0xf62177(0xfd)],_0x3aea94=_0x50e04a['args']??[],_0x455430=_0x1c13c4[_0xf62177(0x107)](_0x50cfd7=>!_0x3aea94[_0xf62177(0x113)](_0x50cfd7));_0x50e04a['args']=[..._0x3aea94,..._0x455430];}return{'isolated':!![],'browserName':_0xf62177(0xc8),'launchOptions':_0x50e04a,'contextOptions':{..._0x208902,'permissions':[_0x53ef14[_0xf62177(0x10d)],'clipboard-write'],'viewport':{'width':0x500,'height':0x2d0}}};})()),_0x3a16e2=_0x49198a==='playwright-cli'?{'browser':_0x3761f2,'saveVideo':{'width':0x500,'height':0x2d0},'outputDir':_0x4a19f0,'outputMode':_0x3eab1d(0xbc),'codegen':_0x53ef14['iaQou']}:{'name':_0x1c0e5a,'browser':_0x3761f2,'capabilities':[_0x53ef14[_0x3eab1d(0xf4)],'tabs',_0x3eab1d(0xc2),_0x53ef14[_0x3eab1d(0xea)],'vision'],'imageResponses':'allow','saveTrace':!![],'saveVideo':{'width':0x500,'height':0x2d0},'outputDir':_0x4a19f0};if(!_0x26508b){const _0x4b3439=_0x3a16e2[_0x3eab1d(0x10a)],_0x544444=_0x4b3439[_0x3eab1d(0xed)];if(_0x544444[_0x3eab1d(0xde)]===undefined)delete _0x544444['userAgent'];if(_0x53ef14[_0x3eab1d(0x105)](_0x544444[_0x3eab1d(0xb8)],undefined))delete _0x544444['storageState'];}const _0x556ecd=join(tmpdir(),_0x53ef14[_0x3eab1d(0xf0)]);!existsSync(_0x556ecd)&&await mkdir(_0x556ecd,{'recursive':!![]});const _0x1e0b5a=_0x49198a===_0x53ef14['wCEsa']?_0x53ef14[_0x3eab1d(0x116)]:'',_0xfe9f09=_0x53ef14['SyHqm'](join,_0x556ecd,_0x1c0e5a+'-'+Date[_0x3eab1d(0xfc)]()+_0x1e0b5a+'.json');return await writeFile(_0xfe9f09,JSON['stringify'](_0x3a16e2,null,0x2)),{'configPath':_0xfe9f09,'storageStatePath':_0x15cee0};}export async function buildPlaywrightCliConfig(_0x150d8d,_0x3f8dbf,_0x43d8aa,_0x54528c,_0x1e4820){const _0x5c2e1d=_0xde5ba5,_0xf41039={'Midcz':function(_0x4a3ff2,_0x36ae2e,_0x2395a5,_0x4c9b86,_0x1086ef,_0x288945,_0x5b7cf9){return _0x4a3ff2(_0x36ae2e,_0x2395a5,_0x4c9b86,_0x1086ef,_0x288945,_0x5b7cf9);},'mGCsH':'playwright-cli'};if(_0x1e4820)return _0xf41039['Midcz'](buildPlaywrightConfigCore,_0x150d8d,_0x1e4820,_0x3f8dbf,_0x43d8aa,_0x54528c,_0xf41039[_0x5c2e1d(0xd7)]);const {storageStatePath:_0x3c90e4,tempAuthPath:_0x5e7a07}=await resolveLocalAuthPath(getEnvDir(_0x3f8dbf));try{const _0x24ba90=await _0xf41039['Midcz'](buildPlaywrightConfigCore,_0x150d8d,_0x3c90e4,_0x3f8dbf,_0x43d8aa,_0x54528c,'playwright-cli');return{..._0x24ba90,'tempAuthPath':_0x5e7a07};}catch(_0x5a2a9d){_0x5e7a07&&await unlink(_0x5e7a07)[_0x5c2e1d(0xf6)](()=>{});throw _0x5a2a9d;}}export async function buildRangerwrightCliConfig(_0x16e33b,_0x44b95a,_0x147432,_0x50171d,_0x2baed4){const _0xb9bace=_0xde5ba5,_0x30f7c3={'TJXwi':function(_0x19fad1,_0x33b75d,_0x1b508d){return _0x19fad1(_0x33b75d,_0x1b508d);},'HzOXz':function(_0x4343b3,_0x523026){return _0x4343b3===_0x523026;},'cjqoJ':_0xb9bace(0xaf),'ibVed':'--disable-setuid-sandbox','TIMeV':_0xb9bace(0xc8),'IxUqy':_0xb9bace(0x9d),'hgVwj':_0xb9bace(0xaa),'OWgKL':function(_0x388773,_0x3cba54){return _0x388773(_0x3cba54);},'ELajm':function(_0x569064,_0x27dfaf,_0x109209){return _0x569064(_0x27dfaf,_0x109209);}},{storageStatePath:_0x38fd36,tempAuthPath:_0xf90767}=_0x2baed4?{'storageStatePath':_0x2baed4,'tempAuthPath':undefined}:await resolveLocalAuthPath(_0x30f7c3['OWgKL'](getEnvDir,_0x44b95a)),_0xba6d8c=_0x147432||randomUUID(),_0x2ca35a=join(getRangerDir(),_0xb9bace(0xef),_0xba6d8c),_0x44656a=Boolean(_0x16e33b['cdpEndpoint']),_0x59498a=_0x44656a?{'browserName':_0xb9bace(0xc8),'cdpEndpoint':_0x16e33b['cdpEndpoint']}:((()=>{const _0x18ef58=_0xb9bace,{launchOptions:_0x18782a,contextOptions:_0x56df03}=_0x30f7c3['TJXwi'](buildBrowserOptionsFromSettings,_0x16e33b,{'headless':_0x50171d?![]:_0x16e33b['headless']??!![],'storageStatePath':_0x38fd36});if(_0x30f7c3['HzOXz'](process[_0x18ef58(0xc3)]?.(),0x0)){const _0x14e14a=[_0x30f7c3[_0x18ef58(0xc4)],_0x30f7c3['ibVed']],_0x32c280=_0x18782a['args']??[],_0x4087c3=_0x14e14a[_0x18ef58(0x107)](_0x3709fd=>!_0x32c280['includes'](_0x3709fd));_0x18782a[_0x18ef58(0xe8)]=[..._0x32c280,..._0x4087c3];}return{'browserName':_0x30f7c3[_0x18ef58(0xfe)],'launchOptions':_0x18782a,'contextOptions':{..._0x56df03,'permissions':[_0x30f7c3['IxUqy'],_0x30f7c3[_0x18ef58(0xa2)]],'viewport':{'width':0x500,'height':0x2d0}}};})());if(!_0x44656a){const _0xcc029f=_0x59498a[_0xb9bace(0xed)];if(_0xcc029f){if(_0xcc029f[_0xb9bace(0xde)]===undefined)delete _0xcc029f['userAgent'];if(_0xcc029f[_0xb9bace(0xb8)]===undefined)delete _0xcc029f['storageState'];}}const _0x273019={'browser':_0x59498a,'outputDir':_0x2ca35a,'saveTrace':!![],'saveVideo':{'width':0x500,'height':0x2d0},'settle':{'navigationLoadTimeoutMs':0x7530,'networkSettleTimeoutMs':0x1388,'networkIdleWindowMs':0x1f4,'postActionAnimationFrameCount':0x2}};let _0x3cee1b;try{const _0x32cbf9=_0x30f7c3[_0xb9bace(0xd4)](join,tmpdir(),'ranger-config');!_0x30f7c3[_0xb9bace(0xe2)](existsSync,_0x32cbf9)&&await _0x30f7c3['ELajm'](mkdir,_0x32cbf9,{'recursive':!![]}),_0x3cee1b=join(_0x32cbf9,_0x44b95a+'-'+Date[_0xb9bace(0xfc)]()+_0xb9bace(0x94)),await _0x30f7c3[_0xb9bace(0xe7)](writeFile,_0x3cee1b,JSON['stringify'](_0x273019,null,0x2));}catch(_0x26ca0f){_0xf90767&&await unlink(_0xf90767)[_0xb9bace(0xf6)](()=>{});throw _0x26ca0f;}return{'configPath':_0x3cee1b,'storageStatePath':_0x38fd36,'tempAuthPath':_0xf90767,'outputDir':_0x2ca35a};}export async function buildNovaActCliConfig(_0x53876f,_0x4beadb,_0x6ea91,_0x14890a,_0x209e1f){const _0x267cf3=_0xde5ba5,_0x42e1e4={'TDtPa':function(_0x886479,_0x49e652,_0x3cf16b,_0x5c6b75){return _0x886479(_0x49e652,_0x3cf16b,_0x5c6b75);},'jRUoB':function(_0x2f36cd){return _0x2f36cd();},'dTYVh':'sessions','Gearm':_0x267cf3(0xbe),'mmbzt':function(_0x18ca57,_0x3a21f7,_0x1c57e4){return _0x18ca57(_0x3a21f7,_0x1c57e4);},'tiwyi':'Default','Jvdzk':function(_0x3d6dfb,_0x1bcc5d,_0x53f276){return _0x3d6dfb(_0x1bcc5d,_0x53f276);},'zZLEr':function(_0x492342,_0x515147){return _0x492342===_0x515147;},'svqLr':function(_0x4843d7,_0x5014d4){return _0x4843d7===_0x5014d4;},'ymYlH':_0x267cf3(0x102),'YBjcV':function(_0xfe827d,_0x2693e2){return _0xfe827d(_0x2693e2);},'SWUeh':function(_0x4e6c73,_0x5c623e){return _0x4e6c73(_0x5c623e);},'TVBGu':function(_0x3dfeb8,_0x4c65b2){return _0x3dfeb8(_0x4c65b2);}},{storageStatePath:_0x343ddf,tempAuthPath:_0x523d35}=_0x209e1f?{'storageStatePath':_0x209e1f,'tempAuthPath':undefined}:await resolveLocalAuthPath(getEnvDir(_0x4beadb)),_0x467e5a=_0x6ea91||randomUUID(),_0x3d821e=_0x42e1e4[_0x267cf3(0xe4)](join,_0x42e1e4['jRUoB'](getRangerDir),_0x42e1e4['dTYVh'],_0x467e5a),_0x2c9905=join(_0x3d821e,_0x42e1e4['Gearm']),_0x4b489a=_0x343ddf?_0x42e1e4['mmbzt'](join,_0x2c9905,_0x42e1e4['tiwyi']):undefined,{launchOptions:_0x212f37,contextOptions:_0x3ac303}=_0x42e1e4['Jvdzk'](buildBrowserOptionsFromSettings,_0x53876f,{'headless':_0x14890a?![]:_0x53876f['headless']??!![],'storageStatePath':_0x343ddf});if(_0x42e1e4[_0x267cf3(0x9e)](process[_0x267cf3(0xc3)]?.(),0x0)){const _0x3dddee=[_0x267cf3(0xaf),'--disable-setuid-sandbox'],_0xde22a0=_0x212f37['args']??[],_0x5155fa=_0x3dddee[_0x267cf3(0x107)](_0x4cf96b=>!_0xde22a0['includes'](_0x4cf96b));_0x212f37['args']=[..._0xde22a0,..._0x5155fa];}const _0x2f706e=_0x42e1e4['svqLr'](typeof _0x212f37[_0x267cf3(0x10b)],_0x42e1e4['ymYlH'])?_0x212f37[_0x267cf3(0x10b)]:_0x343ddf?chromium[_0x267cf3(0x10b)]():undefined;return{'storageStatePath':_0x343ddf,'tempAuthPath':_0x523d35,'baseUrl':_0x53876f['baseUrl'],'headless':Boolean(_0x212f37['headless']),'userDataDir':_0x2c9905,'browserProfilePath':_0x4b489a,'executablePath':_0x2f706e,'launchArgs':Array['isArray'](_0x212f37[_0x267cf3(0xe8)])?_0x212f37[_0x267cf3(0xe8)]['filter'](_0x544cdf=>typeof _0x544cdf===_0x267cf3(0x102)):[],'userAgent':typeof _0x3ac303[_0x267cf3(0xde)]===_0x267cf3(0x102)?_0x3ac303['userAgent']:undefined,'extraHTTPHeaders':_0x3ac303[_0x267cf3(0xb7)],'allowInsecureLocalhost':_0x42e1e4['YBjcV'](Boolean,_0x53876f[_0x267cf3(0x9b)]),'safeMode':_0x42e1e4['SWUeh'](Boolean,_0x53876f[_0x267cf3(0xa5)]),'cdpEndpoint':_0x53876f[_0x267cf3(0xa3)],'isCdpMode':_0x42e1e4[_0x267cf3(0x110)](Boolean,_0x53876f[_0x267cf3(0xa3)])};}export function getNestedValue(_0x4f33f8,_0x4ce92b){const _0xaf9f48=_0xde5ba5,_0x531245={'Gjczi':function(_0x53cc28,_0x316c7f){return _0x53cc28(_0x316c7f);},'jXdro':function(_0x30ce9c,_0x31ffac){return _0x30ce9c===_0x31ffac;},'jLGAU':_0xaf9f48(0x104)},_0x20bab8=_0x531245[_0xaf9f48(0x96)](parseKeyPath,_0x4ce92b);let _0x11a21f=_0x4f33f8;for(const _0x3e5dd6 of _0x20bab8){if(_0x531245['jXdro'](_0x11a21f,null)||_0x11a21f===undefined||typeof _0x11a21f!==_0x531245['jLGAU'])return undefined;_0x11a21f=_0x11a21f[_0x3e5dd6];}return _0x11a21f;}export function setNestedValue(_0x3d43b2,_0x24db3f,_0x1c3de8){const _0xa9fcf6=_0xde5ba5,_0x34c81c={'pVkoy':function(_0x445d2a,_0x2ffe0b){return _0x445d2a<_0x2ffe0b;},'xSJBb':'object'},_0x35bc99=parseKeyPath(_0x24db3f);let _0x42c201=_0x3d43b2;for(let _0x3852ac=0x0;_0x34c81c[_0xa9fcf6(0xb0)](_0x3852ac,_0x35bc99[_0xa9fcf6(0x114)]-0x1);_0x3852ac++){const _0x326bfa=_0x35bc99[_0x3852ac];(!(_0x326bfa in _0x42c201)||typeof _0x42c201[_0x326bfa]!==_0x34c81c[_0xa9fcf6(0x95)])&&(_0x42c201[_0x326bfa]={}),_0x42c201=_0x42c201[_0x326bfa];}_0x42c201[_0x35bc99[_0x35bc99[_0xa9fcf6(0x114)]-0x1]]=_0x1c3de8;}export function deleteNestedValue(_0x330b60,_0x3b81d2){const _0x1b2887=_0xde5ba5,_0x34bfb0={'sCEwS':function(_0x20bbc4,_0x37ceac){return _0x20bbc4(_0x37ceac);},'qTgto':function(_0x484124,_0x229ed5){return _0x484124<_0x229ed5;},'LpyYc':function(_0xe996b8,_0xa22be9){return _0xe996b8!==_0xa22be9;},'vplWG':'object','JSNeS':function(_0x58919c,_0x2cd809){return _0x58919c===_0x2cd809;}},_0x3fe7e9=_0x34bfb0['sCEwS'](parseKeyPath,_0x3b81d2);let _0x126f67=_0x330b60;for(let _0x431a7f=0x0;_0x34bfb0['qTgto'](_0x431a7f,_0x3fe7e9['length']-0x1);_0x431a7f++){if(_0x126f67===null||_0x126f67===undefined||_0x34bfb0[_0x1b2887(0xa6)](typeof _0x126f67,_0x34bfb0['vplWG']))return![];_0x126f67=_0x126f67[_0x3fe7e9[_0x431a7f]];}if(_0x126f67===null||_0x34bfb0[_0x1b2887(0xa8)](_0x126f67,undefined)||_0x34bfb0[_0x1b2887(0xa6)](typeof _0x126f67,'object'))return![];const _0x2f3a04=_0x3fe7e9[_0x3fe7e9[_0x1b2887(0x114)]-0x1];if(_0x2f3a04 in _0x126f67)return delete _0x126f67[_0x2f3a04],!![];return![];}function parseKeyPath(_0x592732){const _0x194605=_0xde5ba5,_0x5b9428={'YdFSt':_0x194605(0xdf),'tUvyb':_0x194605(0xfb),'djXUu':_0x194605(0xb6)},_0x529078=_0x592732[_0x194605(0xeb)]('.');return _0x529078[0x0]===_0x5b9428[_0x194605(0xd3)]&&(_0x529078[0x0]=_0x5b9428['tUvyb']),_0x529078[0x0]===_0x5b9428[_0x194605(0xab)]&&(_0x529078[0x0]='setupHeaders'),_0x529078;}export function formatSettings(_0x5d3059,_0x24f9c2=0x0){const _0x2e64af=_0xde5ba5,_0x860f30={'dBldS':function(_0x4f49c0,_0x52d1e6){return _0x4f49c0!==_0x52d1e6;}},_0x288cb1=[],_0x29d5a8='\x20\x20'[_0x2e64af(0x10e)](_0x24f9c2);for(const [_0x39efcc,_0x1673c0]of Object['entries'](_0x5d3059)){if(_0x1673c0===undefined)continue;if(typeof _0x1673c0===_0x2e64af(0x104)&&_0x860f30[_0x2e64af(0xdb)](_0x1673c0,null)){_0x288cb1[_0x2e64af(0x10c)](''+_0x29d5a8+_0x39efcc+':');for(const [_0x5b41ab,_0x391b58]of Object[_0x2e64af(0xdc)](_0x1673c0)){_0x288cb1['push'](_0x29d5a8+'\x20\x20'+_0x5b41ab+':\x20'+_0x391b58);}}else _0x288cb1['push'](''+_0x29d5a8+_0x39efcc+':\x20'+_0x1673c0);}return _0x288cb1[_0x2e64af(0x117)]('\x0a');}
|
|
1
|
+
const _0x5ba534=_0x16a2;(function(_0xfcdcfe,_0x1b273a){const _0x5635f7=_0x16a2,_0x3b6b9f=_0xfcdcfe();while(!![]){try{const _0x3d5b43=-parseInt(_0x5635f7(0x1d6))/0x1*(parseInt(_0x5635f7(0x1a8))/0x2)+parseInt(_0x5635f7(0x224))/0x3+parseInt(_0x5635f7(0x1e8))/0x4*(-parseInt(_0x5635f7(0x1d0))/0x5)+-parseInt(_0x5635f7(0x1a0))/0x6*(parseInt(_0x5635f7(0x20b))/0x7)+parseInt(_0x5635f7(0x1aa))/0x8+parseInt(_0x5635f7(0x1cf))/0x9+parseInt(_0x5635f7(0x21a))/0xa*(parseInt(_0x5635f7(0x1dd))/0xb);if(_0x3d5b43===_0x1b273a)break;else _0x3b6b9f['push'](_0x3b6b9f['shift']());}catch(_0x3d3c9e){_0x3b6b9f['push'](_0x3b6b9f['shift']());}}}(_0xb7ac,0x1a515));function _0xb7ac(){const _0x40818f=['DrYrC','args','replace','VRlNB','rEtXT','egvDw','push','message','nova-user-data','AKMiz','JiPGA','startsWith','PhWKU','storageStatePath','bPuMD','XARym','iKAbO','uMrgC','filter','--disable-web-security','30317MWmpjz','headers','DyLmr','configPath','rangerDir','--no-sandbox','pHGns','string','ATeNn','auth.json.enc','GLbDR','object','dvixL','TrhMc','wsonb','5410RsWNZX','bsoPf','\x20\x20ranger\x20profile\x20add\x20<name>\x0a','yuoHe','--disable-setuid-sandbox','TGViL','unXHB','stringify','entries','catch','27504wkdruA','mUTbM','keys','-cli','That\x20directory\x20is\x20read-only\x20now.\x20To\x20set\x20up\x20a\x20fresh\x20profile,\x20run:\x0a','baseUrl','local','246RjGWwP','utf-8','isArray','split','indexOf','iIVit','ECJZJ','fSdhH','11006PnNTED','dasbn','394600cKqngW','header','.json','code','browser','executablePath','headless','IytKg','No\x20API\x20token\x20found.\x20Run:\x20ranger\x20setup\x20[token]','iYJgR','chromium','warn','TpQvx','LfbXf','fromEntries','sessions','ranger-config','CBqsn','gaDGE','env','FFWLr','kUjht','jwHoi','xomUn','extraHTTPHeaders','ydvSg','length','TKLXC','includes','wnMqS','join','pdf','clipboard-write','forWrite','UElUy','Rkbsn','wkanS','1328886HLSQOH','930485fLtNOd','rSAyf','lfHCm','path','rzZyr','rXwGf','15WxxdPJ','XgyUQ','contextOptions','cdpEndpoint','PNPpO','QDmTO','storageState','7073blfWhe','Failed\x20to\x20clean\x20up\x20temp\x20file\x20','gJRIZ','Environment\x20variable\x20','YTAPt','now','map','NNlPp','location','bBYlT','userAgent','4AJRsaM','getuid','HLiBQ','YrVIm','uPERj','fLGxw','settings.json','FeBTH','all','SOjNR','CXSnC','stagehand','playwright-cli','--unsafely-treat-insecure-origin-as-secure=http://localhost','yxJdl'];_0xb7ac=function(){return _0x40818f;};return _0xb7ac();}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';function _0x16a2(_0x3f38e5,_0x42dd5c){_0x3f38e5=_0x3f38e5-0x19c;const _0xb7ac09=_0xb7ac();let _0x16a217=_0xb7ac09[_0x3f38e5];return _0x16a217;}import{decrypt}from'./crypto.js';import{getToken}from'./keychain.js';import{getRangerDir,getRangerHomeDir}from'./rangerRoot.js';function findEnvInRoot(_0x3d2aba,_0x377f6c){const _0x200257=_0x16a2,_0xfc68={'LfbXf':'local','NNlPp':function(_0x584537,_0x597133,_0xec5b1b){return _0x584537(_0x597133,_0xec5b1b);},'uBLbp':function(_0x38d07e,_0x27c790,_0x3ab6c4){return _0x38d07e(_0x27c790,_0x3ab6c4);},'gaDGE':function(_0x2250ff,_0x4df4d0){return _0x2250ff(_0x4df4d0);},'DjfXJ':function(_0x294cc6,_0x215475){return _0x294cc6!==_0x215475;}},_0x579ee6=join(_0x377f6c,'ci',_0x3d2aba),_0x4c7ce3=join(_0x377f6c,_0xfc68[_0x200257(0x1b7)],_0x3d2aba),_0x917869=_0xfc68[_0x200257(0x1e4)](join,_0x377f6c,_0x3d2aba),_0x57e0cd=_0xfc68['uBLbp'](join,_0x377f6c,_0xfc68['LfbXf']),_0x262d29=join(_0x377f6c,'ci');if(existsSync(_0x579ee6))return _0x579ee6;if(_0xfc68[_0x200257(0x1bc)](existsSync,_0x4c7ce3))return _0x4c7ce3;if(existsSync(_0x917869)&&(_0xfc68['DjfXJ'](_0x917869,_0x57e0cd)&&_0x917869!==_0x262d29?!![]:hasLegacyProfileFiles(_0x917869)))return _0x917869;return null;}export function getEnvDir(_0x2ad850,_0xbbef7={}){const _0x5759d8=_0x16a2,_0xaca5cd={'wsonb':function(_0x3ef01e){return _0x3ef01e();},'fLGxw':function(_0x59ccfa,_0x472749,_0x98fa9d){return _0x59ccfa(_0x472749,_0x98fa9d);},'ZfXjJ':function(_0x587338,_0x474b3e){return _0x587338!==_0x474b3e;}},_0x22fc5e=_0xaca5cd['wsonb'](getRangerDir),_0x4cd1ca=findEnvInRoot(_0x2ad850,_0x22fc5e);if(_0x4cd1ca){if(_0xbbef7['forWrite']&&isLegacyEnvPath(_0x4cd1ca))throw _0xaca5cd[_0x5759d8(0x1ed)](legacyWriteError,_0x2ad850,_0x4cd1ca);return _0x4cd1ca;}const _0x49ba64=_0xaca5cd[_0x5759d8(0x219)](getRangerHomeDir);if(_0xaca5cd['ZfXjJ'](_0x49ba64,_0x22fc5e)){const _0x323fc1=_0xaca5cd['fLGxw'](findEnvInRoot,_0x2ad850,_0x49ba64);if(_0x323fc1){if(_0xbbef7[_0x5759d8(0x1cb)]&&isLegacyEnvPath(_0x323fc1))throw legacyWriteError(_0x2ad850,_0x323fc1);return _0x323fc1;}}const _0x5995e3=join(_0x49ba64,'local',_0x2ad850);if(_0xbbef7[_0x5759d8(0x1cb)])throw legacyWriteError(_0x2ad850,_0x5995e3);return _0x5995e3;}function isLegacyEnvPath(_0x67a4ea){const _0x59339b=_0x16a2,_0x473c4c={'VRlNB':function(_0x4c7440){return _0x4c7440();},'gszfO':function(_0xe7ce3d,_0x221943){return _0xe7ce3d+_0x221943;},'MNyZi':function(_0x40d56e,_0x4eef24){return _0x40d56e===_0x4eef24;}},_0x4d9a8a=getRangerDir(),_0x1c5de4=_0x473c4c[_0x59339b(0x1fa)](getRangerHomeDir);for(const _0x1ad2ce of new Set([_0x4d9a8a,_0x1c5de4])){const _0x2d7e90=_0x1ad2ce['endsWith']('/')?_0x1ad2ce:_0x473c4c['gszfO'](_0x1ad2ce,'/');if(_0x473c4c['MNyZi'](_0x67a4ea,_0x1ad2ce)||_0x67a4ea[_0x59339b(0x202)](_0x2d7e90))return!![];}return![];}function legacyWriteError(_0x49c335,_0x1efd8b){const _0x387deb=_0x16a2,_0x47ec41={'unXHB':function(_0x2deaff,_0x500afd){return _0x2deaff+_0x500afd;}};return new Error(_0x47ec41[_0x387deb(0x220)](_0x47ec41['unXHB']('Refusing\x20to\x20write\x20profile\x20\x22'+_0x49c335+'\x22\x20to\x20legacy\x20path\x20'+_0x1efd8b+'.\x0a',_0x387deb(0x19d))+_0x387deb(0x21c),'See\x20https://docs.ranger.net/main/concepts/profiles\x20for\x20setup\x20options.'));}export function findExistingEnv(_0x5fca86,_0x536f24){const _0x31678c=_0x16a2,_0x4f6021={'OIohj':'local','yXPIj':function(_0x420b90,_0x3fdef1,_0x34675a){return _0x420b90(_0x3fdef1,_0x34675a);},'SOjNR':function(_0x490b32,_0x405f55,_0x5b1dc7){return _0x490b32(_0x405f55,_0x5b1dc7);},'FeBTH':function(_0x1b6ce5,_0x362f62,_0x3fcb72,_0x3d2843){return _0x1b6ce5(_0x362f62,_0x3fcb72,_0x3d2843);},'caqNt':function(_0x32c127,_0x2bebc7){return _0x32c127(_0x2bebc7);},'JiPGA':'legacy'},_0x23af93=_0x536f24?.[_0x31678c(0x20f)],_0xf5c9c5=_0x23af93?[_0x23af93]:[getRangerDir(),getRangerHomeDir()][_0x31678c(0x209)]((_0x4e30f9,_0x12bf50,_0x1c16d0)=>_0x1c16d0[_0x31678c(0x1a4)](_0x4e30f9)===_0x12bf50),_0xb47b3a=_0x536f24?.['locations']??['ci',_0x4f6021['OIohj'],'legacy'];for(const _0x48a424 of _0xf5c9c5){const _0x9d7a1a=_0x4f6021['yXPIj'](join,_0x48a424,_0x31678c(0x19f)),_0x1362bc=_0x4f6021['SOjNR'](join,_0x48a424,'ci'),_0xd959c5=[{'location':'ci','path':join(_0x48a424,'ci',_0x5fca86)},{'location':_0x31678c(0x19f),'path':_0x4f6021[_0x31678c(0x1ef)](join,_0x48a424,_0x31678c(0x19f),_0x5fca86)},{'location':'legacy','path':_0x4f6021[_0x31678c(0x1f1)](join,_0x48a424,_0x5fca86)}];for(const _0x21947a of _0xd959c5){if(_0xb47b3a[_0x31678c(0x1c6)](_0x21947a[_0x31678c(0x1e5)])&&_0x4f6021['caqNt'](existsSync,_0x21947a[_0x31678c(0x1d3)])){if(_0x21947a[_0x31678c(0x1e5)]===_0x4f6021[_0x31678c(0x201)]&&(_0x21947a[_0x31678c(0x1d3)]===_0x9d7a1a||_0x21947a['path']===_0x1362bc)&&!hasLegacyProfileFiles(_0x21947a['path']))continue;return{'path':_0x21947a['path'],'location':_0x21947a[_0x31678c(0x1e5)]};}}}return null;}function hasLegacyProfileFiles(_0x180ad9){const _0x5e814=_0x16a2,_0x2ee72={'egvDw':function(_0x3af639,_0x146c7c){return _0x3af639(_0x146c7c);},'XARym':_0x5e814(0x214)};return _0x2ee72[_0x5e814(0x1fc)](existsSync,join(_0x180ad9,_0x5e814(0x1ee)))||_0x2ee72[_0x5e814(0x1fc)](existsSync,join(_0x180ad9,'auth.json'))||existsSync(join(_0x180ad9,_0x2ee72[_0x5e814(0x206)]));}export function isEnvCi(_0x3446f3){const _0x33f293=_0x16a2,_0xb063e6={'mUTbM':function(_0x10ce95,_0x499203){return _0x10ce95(_0x499203);},'pHGns':function(_0x14509f,_0x1be5ec,_0x53403b,_0x24e7d5){return _0x14509f(_0x1be5ec,_0x53403b,_0x24e7d5);},'hpjWT':function(_0xef7f94,_0xf47a7){return _0xef7f94!==_0xf47a7;}};if(_0xb063e6[_0x33f293(0x225)](existsSync,_0xb063e6[_0x33f293(0x211)](join,getRangerDir(),'ci',_0x3446f3)))return!![];const _0x4ba227=getRangerHomeDir();if(_0xb063e6['hpjWT'](_0x4ba227,getRangerDir())&&_0xb063e6[_0x33f293(0x225)](existsSync,join(_0x4ba227,'ci',_0x3446f3)))return!![];return![];}export async function cleanupTempFiles(_0xf91fbb){const _0x427fab=_0x16a2,_0x47feab={'XgyUQ':function(_0x19d925,_0x42933d){return _0x19d925!==_0x42933d;}},_0x25979a=[_0xf91fbb['tempAuthPath'],_0xf91fbb[_0x427fab(0x20e)]][_0x427fab(0x209)](Boolean);await Promise[_0x427fab(0x1f0)](_0x25979a['map'](_0x522eff=>unlink(_0x522eff)['catch'](_0x3085f0=>{const _0x53220a=_0x427fab;_0x47feab[_0x53220a(0x1d7)](_0x3085f0[_0x53220a(0x1ad)],'ENOENT')&&console[_0x53220a(0x1b5)](_0x53220a(0x1de)+_0x522eff+':',_0x3085f0[_0x53220a(0x1fe)]);})));}export function getSettingsPath(_0x3a1d4e){const _0xca7ac0=_0x16a2,_0x4c2c77={'CBklg':function(_0x10ee24,_0x11d753,_0x4b0bca){return _0x10ee24(_0x11d753,_0x4b0bca);},'sRbmS':function(_0x1e8c04,_0x1a372b){return _0x1e8c04(_0x1a372b);},'XfrPB':_0xca7ac0(0x1ee)};return _0x4c2c77['CBklg'](join,_0x4c2c77['sRbmS'](getEnvDir,_0x3a1d4e),_0x4c2c77['XfrPB']);}export async function loadSettings(_0x102d7a){const _0x41ef6e=_0x16a2,_0x1d1dff={'gFPgU':function(_0x4dfa52,_0x3618a8){return _0x4dfa52(_0x3618a8);}},_0x3dce7f=getSettingsPath(_0x102d7a);if(!_0x1d1dff['gFPgU'](existsSync,_0x3dce7f))return{};try{const _0x4bc62d=await readFile(_0x3dce7f,_0x41ef6e(0x1a1));return JSON['parse'](_0x4bc62d);}catch{return{};}}export async function saveSettings(_0x29b2b5,_0x4617af){const _0x11bc72=_0x16a2,_0x3d62fb=getSettingsPath(_0x29b2b5),_0x52cf1a=dirname(_0x3d62fb);!existsSync(_0x52cf1a)&&await mkdir(_0x52cf1a,{'recursive':!![]}),await writeFile(_0x3d62fb,JSON[_0x11bc72(0x221)](_0x4617af,null,0x2));}export function resolveEnvVars(_0x36994d){const _0x355096=_0x16a2,_0x4ba76d={'GSMdC':function(_0x3dd5d9,_0x410c8c){return _0x3dd5d9===_0x410c8c;},'Rkbsn':'string','fSdhH':_0x355096(0x216)};if(_0x4ba76d['GSMdC'](typeof _0x36994d,_0x4ba76d[_0x355096(0x1cd)]))return _0x36994d[_0x355096(0x1f9)](/\$\{(\w+)\}/g,(_0x5c5efe,_0x121718)=>{const _0x2b6a0a=_0x355096,_0x1d5e24=process[_0x2b6a0a(0x1bd)][_0x121718];if(_0x4ba76d['GSMdC'](_0x1d5e24,undefined))throw new Error(_0x2b6a0a(0x1e0)+_0x121718+'\x20is\x20not\x20set');return _0x1d5e24;});if(Array[_0x355096(0x1a2)](_0x36994d))return _0x36994d['map'](resolveEnvVars);if(_0x36994d&&typeof _0x36994d===_0x4ba76d[_0x355096(0x1a7)])return Object[_0x355096(0x1b8)](Object['entries'](_0x36994d)[_0x355096(0x1e3)](([_0x40e70a,_0xdc5d3])=>[_0x40e70a,resolveEnvVars(_0xdc5d3)]));return _0x36994d;}const isRecord=_0xa7cdd7=>typeof _0xa7cdd7===_0x5ba534(0x216)&&_0xa7cdd7!==null&&!Array[_0x5ba534(0x1a2)](_0xa7cdd7),asRecord=_0x10e8b9=>isRecord(_0x10e8b9)?_0x10e8b9:undefined,mergeHeaders=(_0x2b0eda,_0x5365c5)=>{const _0x2129b5=_0x5ba534,_0x3bb892={'ErwAy':function(_0x3a3dae,_0x53fe07){return _0x3a3dae??_0x53fe07;}},_0xffc5fc={..._0x2b0eda??{},..._0x3bb892['ErwAy'](_0x5365c5,{})};return Object[_0x2129b5(0x226)](_0xffc5fc)[_0x2129b5(0x1c4)]?_0xffc5fc:undefined;},SAFE_MODE_ARGS=['--disable-features=WebBluetooth'],ALLOW_LOCALHOST_ARGS=[_0x5ba534(0x20a),'--allow-running-insecure-content',_0x5ba534(0x1f5),'--allow-insecure-localhost'];export function buildBrowserOptionsFromSettings(_0x1b4bee,_0x17c076={}){const _0x16fda4=_0x5ba534,_0x2ada35={'bPuMD':function(_0x1a017b,_0x408333){return _0x1a017b(_0x408333);},'lQPpm':function(_0x267a8e,_0x5c5b9e){return _0x267a8e===_0x5c5b9e;},'AWbBR':function(_0x40865a,_0x2f42d0,_0x500da2){return _0x40865a(_0x2f42d0,_0x500da2);},'wnMqS':function(_0x33dc58,_0x204e25){return _0x33dc58(_0x204e25);}},_0x2af8ee=asRecord(_0x1b4bee['browser']),_0x2f187f={...asRecord(_0x2af8ee?.['launchOptions'])??{}};typeof _0x17c076[_0x16fda4(0x1b0)]==='boolean'&&(_0x2f187f[_0x16fda4(0x1b0)]=_0x17c076['headless']);if(_0x1b4bee['safeMode']){const _0x426b8b=_0x2f187f[_0x16fda4(0x1f8)]??[],_0x528835=SAFE_MODE_ARGS[_0x16fda4(0x209)](_0x3097a4=>!_0x426b8b['includes'](_0x3097a4));_0x2f187f['args']=[..._0x426b8b,..._0x528835];}if(_0x1b4bee['allowInsecureLocalhost']){const _0x5e7a9f=_0x2f187f[_0x16fda4(0x1f8)]??[],_0x40b67a=ALLOW_LOCALHOST_ARGS['filter'](_0x1773c7=>!_0x5e7a9f['includes'](_0x1773c7));_0x2f187f[_0x16fda4(0x1f8)]=[..._0x5e7a9f,..._0x40b67a];}const _0x4296bf={..._0x2ada35[_0x16fda4(0x205)](asRecord,_0x2af8ee?.['contextOptions'])??{}};_0x4296bf['ignoreHTTPSErrors']=!![];_0x2ada35['lQPpm'](typeof _0x1b4bee['userAgent'],_0x16fda4(0x212))&&(_0x4296bf['userAgent']=_0x1b4bee[_0x16fda4(0x1e7)]);const _0x24e4fb=_0x2ada35['AWbBR'](mergeHeaders,asRecord(_0x4296bf['extraHTTPHeaders']),_0x2ada35[_0x16fda4(0x1c7)](asRecord,_0x1b4bee['headers']));return _0x24e4fb?_0x4296bf[_0x16fda4(0x1c2)]=_0x24e4fb:delete _0x4296bf['extraHTTPHeaders'],_0x17c076[_0x16fda4(0x204)]&&(_0x4296bf[_0x16fda4(0x1dc)]=_0x17c076['storageStatePath']),{'launchOptions':_0x2f187f,'contextOptions':_0x4296bf};}export async function resolveProfileStorageState(_0x4e8390){const _0x323a07={'GYmxU':function(_0x424d03,_0x45c7a3){return _0x424d03(_0x45c7a3);}};return resolveLocalAuthPath(_0x323a07['GYmxU'](getEnvDir,_0x4e8390));}async function resolveLocalAuthPath(_0x45db7e){const _0x486d4d=_0x5ba534,_0x8120ae={'xomUn':'auth.json.enc','TKLXC':function(_0x5ee309,_0x133320,_0x56ea90){return _0x5ee309(_0x133320,_0x56ea90);},'IytKg':function(_0x421a8e,_0x4a45d3){return _0x421a8e(_0x4a45d3);},'rzZyr':function(_0x39b9cf,_0x584fcf,_0x38cfea){return _0x39b9cf(_0x584fcf,_0x38cfea);},'rSAyf':function(_0x2e6eb8){return _0x2e6eb8();}},_0x2141e8=join(_0x45db7e,_0x8120ae[_0x486d4d(0x1c1)]),_0xfa5a6=_0x8120ae[_0x486d4d(0x1c5)](join,_0x45db7e,'auth.json');if(existsSync(_0x2141e8))try{const _0x2fb165=await getToken();if(!_0x2fb165)throw new Error(_0x486d4d(0x1b2));const _0x529942=await _0x8120ae[_0x486d4d(0x1b1)](readFile,_0x2141e8),_0x1f720b=_0x8120ae[_0x486d4d(0x1d4)](decrypt,_0x529942,_0x2fb165),_0x1b21a7=_0x8120ae[_0x486d4d(0x1d4)](join,_0x8120ae[_0x486d4d(0x1d1)](tmpdir),'ranger-auth-'+Date['now']()+'.json');return await writeFile(_0x1b21a7,_0x1f720b),{'storageStatePath':_0x1b21a7,'tempAuthPath':_0x1b21a7};}catch(_0x1c1fe2){const _0x36bae4=_0x1c1fe2 instanceof Error?_0x1c1fe2[_0x486d4d(0x1fe)]:_0x8120ae['IytKg'](String,_0x1c1fe2);throw new Error('Failed\x20to\x20decrypt\x20auth\x20state:\x20'+_0x36bae4);}if(existsSync(_0xfa5a6))return{'storageStatePath':_0xfa5a6};return{};}export async function buildPlaywrightConfig(_0x2b13fe,_0x872d26,_0x3ef6d9,_0x1017e7,_0x4b3f7e){const _0x2fe937=_0x5ba534;if(_0x4b3f7e)return buildPlaywrightConfigCore(_0x2b13fe,_0x4b3f7e,_0x872d26,_0x3ef6d9,_0x1017e7,_0x2fe937(0x1f3));const {storageStatePath:_0x2821d2,tempAuthPath:_0x455da1}=await resolveLocalAuthPath(getEnvDir(_0x872d26));try{const _0x24ec45=await buildPlaywrightConfigCore(_0x2b13fe,_0x2821d2,_0x872d26,_0x3ef6d9,_0x1017e7,_0x2fe937(0x1f3));return{..._0x24ec45,'tempAuthPath':_0x455da1};}catch(_0x20a266){_0x455da1&&await unlink(_0x455da1)['catch'](()=>{});throw _0x20a266;}}export async function buildPlaywrightConfigCore(_0x1aabf4,_0x4bc02e,_0x325b61,_0x22d7d4,_0x1616ef,_0x5ac1a6='stagehand'){const _0x2641f7=_0x5ba534,_0x564971={'CXSnC':_0x2641f7(0x210),'fxJsU':'clipboard-read','FFWLr':_0x2641f7(0x1ca),'rEtXT':function(_0x1cfb00){return _0x1cfb00();},'iYJgR':function(_0x2ea0ff,_0x5b6614,_0x1aa85e,_0x10361a){return _0x2ea0ff(_0x5b6614,_0x1aa85e,_0x10361a);},'bPxtr':'sessions','lfHCm':'chromium','ECJZJ':function(_0x3d0ee6,_0x6e2b54){return _0x3d0ee6===_0x6e2b54;},'wkanS':'none','PhWKU':'core','kUjht':'install','zzOqn':_0x2641f7(0x1c9),'jwHoi':function(_0x3ef7e7,_0x25f5b6){return _0x3ef7e7===_0x25f5b6;},'KAaAp':function(_0x30eaff,_0xd1d5c0){return _0x30eaff===_0xd1d5c0;},'PlaSb':function(_0x384e10,_0x4560ad){return _0x384e10===_0x4560ad;},'bsoPf':_0x2641f7(0x1f4),'lfQOJ':_0x2641f7(0x19c),'oVmIU':function(_0x1d5808,_0x5b79b4,_0x16ea62){return _0x1d5808(_0x5b79b4,_0x16ea62);}},_0x1aaddc=_0x22d7d4||_0x564971['rEtXT'](randomUUID),_0x4107bb=_0x564971[_0x2641f7(0x1b3)](join,_0x564971[_0x2641f7(0x1fb)](getRangerDir),_0x564971['bPxtr'],_0x1aaddc),_0x4ce2da=Boolean(_0x1aabf4[_0x2641f7(0x1d9)]),_0x1b038e=_0x4ce2da?{'browserName':_0x564971[_0x2641f7(0x1d2)],'cdpEndpoint':_0x1aabf4[_0x2641f7(0x1d9)]}:((()=>{const _0x28062f=_0x2641f7,{launchOptions:_0x4f4e6d,contextOptions:_0x58b581}=buildBrowserOptionsFromSettings(_0x1aabf4,{'headless':_0x1616ef?![]:_0x1aabf4[_0x28062f(0x1b0)]??!![],'storageStatePath':_0x4bc02e});if(process['getuid']?.()===0x0){const _0x407d59=[_0x564971[_0x28062f(0x1f2)],'--disable-setuid-sandbox'],_0x3ea835=_0x4f4e6d[_0x28062f(0x1f8)]??[],_0x287b16=_0x407d59['filter'](_0x350d37=>!_0x3ea835[_0x28062f(0x1c6)](_0x350d37));_0x4f4e6d['args']=[..._0x3ea835,..._0x287b16];}return{'isolated':!![],'browserName':_0x28062f(0x1b4),'launchOptions':_0x4f4e6d,'contextOptions':{..._0x58b581,'permissions':[_0x564971['fxJsU'],_0x564971[_0x28062f(0x1be)]],'viewport':{'width':0x500,'height':0x2d0}}};})()),_0x3b1465=_0x564971[_0x2641f7(0x1a6)](_0x5ac1a6,'playwright-cli')?{'browser':_0x1b038e,'saveVideo':{'width':0x500,'height':0x2d0},'outputDir':_0x4107bb,'outputMode':'file','codegen':_0x564971[_0x2641f7(0x1ce)]}:{'name':_0x325b61,'browser':_0x1b038e,'capabilities':[_0x564971[_0x2641f7(0x203)],'tabs',_0x564971[_0x2641f7(0x1bf)],_0x564971['zzOqn'],'vision'],'imageResponses':'allow','saveTrace':!![],'saveVideo':{'width':0x500,'height':0x2d0},'outputDir':_0x4107bb};if(!_0x4ce2da){const _0x21e7e5=_0x3b1465[_0x2641f7(0x1ae)],_0x3417b3=_0x21e7e5[_0x2641f7(0x1d8)];if(_0x564971[_0x2641f7(0x1c0)](_0x3417b3['userAgent'],undefined))delete _0x3417b3[_0x2641f7(0x1e7)];if(_0x564971['KAaAp'](_0x3417b3[_0x2641f7(0x1dc)],undefined))delete _0x3417b3[_0x2641f7(0x1dc)];}const _0x53ca1a=join(tmpdir(),'ranger-config');!existsSync(_0x53ca1a)&&await mkdir(_0x53ca1a,{'recursive':!![]});const _0x187899=_0x564971['PlaSb'](_0x5ac1a6,_0x564971[_0x2641f7(0x21b)])?_0x564971['lfQOJ']:'',_0xd6729f=_0x564971['oVmIU'](join,_0x53ca1a,_0x325b61+'-'+Date[_0x2641f7(0x1e2)]()+_0x187899+_0x2641f7(0x1ac));return await writeFile(_0xd6729f,JSON[_0x2641f7(0x221)](_0x3b1465,null,0x2)),{'configPath':_0xd6729f,'storageStatePath':_0x4bc02e};}export async function buildPlaywrightCliConfig(_0x8a396d,_0x594794,_0x1650de,_0x34dfae,_0xbf96a8){const _0x908f59=_0x5ba534,_0x3e8021={'jBFdf':function(_0x39d2c0,_0x4e3756){return _0x39d2c0(_0x4e3756);},'jNNYl':'playwright-cli'};if(_0xbf96a8)return buildPlaywrightConfigCore(_0x8a396d,_0xbf96a8,_0x594794,_0x1650de,_0x34dfae,'playwright-cli');const {storageStatePath:_0x2fb76a,tempAuthPath:_0x57257a}=await _0x3e8021['jBFdf'](resolveLocalAuthPath,getEnvDir(_0x594794));try{const _0x3dfd91=await buildPlaywrightConfigCore(_0x8a396d,_0x2fb76a,_0x594794,_0x1650de,_0x34dfae,_0x3e8021['jNNYl']);return{..._0x3dfd91,'tempAuthPath':_0x57257a};}catch(_0x4153e3){_0x57257a&&await unlink(_0x57257a)[_0x908f59(0x223)](()=>{});throw _0x4153e3;}}export async function buildRangerwrightCliConfig(_0x3f4897,_0x4a446c,_0x3af317,_0x3a4bfa,_0x2cb521){const _0x574d34=_0x5ba534,_0x5b5352={'gJRIZ':function(_0x5aa858,_0x50b750){return _0x5aa858===_0x50b750;},'TrZJz':'chromium','bBYlT':'clipboard-read','AKMiz':'clipboard-write','dvixL':function(_0x42fcb5,_0x257038){return _0x42fcb5(_0x257038);},'xpNHM':function(_0x10801f){return _0x10801f();},'QDmTO':_0x574d34(0x1b9),'ydvSg':function(_0x5a7324,_0x14cd9c,_0x5de481){return _0x5a7324(_0x14cd9c,_0x5de481);}},{storageStatePath:_0x23edf8,tempAuthPath:_0x15bec6}=_0x2cb521?{'storageStatePath':_0x2cb521,'tempAuthPath':undefined}:await _0x5b5352[_0x574d34(0x217)](resolveLocalAuthPath,getEnvDir(_0x4a446c)),_0x1e12b0=_0x3af317||randomUUID(),_0x1c9584=join(_0x5b5352['xpNHM'](getRangerDir),_0x5b5352[_0x574d34(0x1db)],_0x1e12b0),_0x786903=_0x5b5352['dvixL'](Boolean,_0x3f4897['cdpEndpoint']),_0x4ad7d2=_0x786903?{'browserName':'chromium','cdpEndpoint':_0x3f4897['cdpEndpoint']}:((()=>{const _0x24f1cd=_0x574d34,{launchOptions:_0x15f707,contextOptions:_0x4ae1e2}=buildBrowserOptionsFromSettings(_0x3f4897,{'headless':_0x3a4bfa?![]:_0x3f4897[_0x24f1cd(0x1b0)]??!![],'storageStatePath':_0x23edf8});if(_0x5b5352['gJRIZ'](process[_0x24f1cd(0x1e9)]?.(),0x0)){const _0x35d9be=[_0x24f1cd(0x210),_0x24f1cd(0x21e)],_0x307f8f=_0x15f707[_0x24f1cd(0x1f8)]??[],_0x2eaf25=_0x35d9be['filter'](_0x2c4d60=>!_0x307f8f['includes'](_0x2c4d60));_0x15f707['args']=[..._0x307f8f,..._0x2eaf25];}return{'browserName':_0x5b5352['TrZJz'],'launchOptions':_0x15f707,'contextOptions':{..._0x4ae1e2,'permissions':[_0x5b5352[_0x24f1cd(0x1e6)],_0x5b5352[_0x24f1cd(0x200)]],'viewport':{'width':0x500,'height':0x2d0}}};})());if(!_0x786903){const _0x10a6d3=_0x4ad7d2[_0x574d34(0x1d8)];if(_0x10a6d3){if(_0x5b5352[_0x574d34(0x1df)](_0x10a6d3[_0x574d34(0x1e7)],undefined))delete _0x10a6d3[_0x574d34(0x1e7)];if(_0x10a6d3['storageState']===undefined)delete _0x10a6d3['storageState'];}}const _0x207a1c={'browser':_0x4ad7d2,'outputDir':_0x1c9584,'saveTrace':!![],'saveVideo':{'width':0x500,'height':0x2d0},'settle':{'navigationLoadTimeoutMs':0x7530,'networkSettleTimeoutMs':0x1388,'networkIdleWindowMs':0x1f4,'postActionAnimationFrameCount':0x2}};let _0x1ed4e3;try{const _0x187f8d=_0x5b5352['ydvSg'](join,tmpdir(),_0x574d34(0x1ba));!existsSync(_0x187f8d)&&await mkdir(_0x187f8d,{'recursive':!![]}),_0x1ed4e3=_0x5b5352[_0x574d34(0x1c3)](join,_0x187f8d,_0x4a446c+'-'+Date[_0x574d34(0x1e2)]()+'-rangerwright.json'),await writeFile(_0x1ed4e3,JSON[_0x574d34(0x221)](_0x207a1c,null,0x2));}catch(_0x505795){_0x15bec6&&await _0x5b5352['dvixL'](unlink,_0x15bec6)['catch'](()=>{});throw _0x505795;}return{'configPath':_0x1ed4e3,'storageStatePath':_0x23edf8,'tempAuthPath':_0x15bec6,'outputDir':_0x1c9584};}export async function buildNovaActCliConfig(_0x1e7865,_0xe777a,_0x3040b4,_0x5416dd,_0x2ad7b4){const _0x3c2ef9=_0x5ba534,_0x32f164={'iKAbO':function(_0x58205c,_0x43fbd6){return _0x58205c(_0x43fbd6);},'tbcla':function(_0x121564){return _0x121564();},'nLfAu':function(_0x2108b4,_0x4505f4,_0xbcf7bb,_0x35d2d6){return _0x2108b4(_0x4505f4,_0xbcf7bb,_0x35d2d6);},'ouvVl':function(_0xbee0ee){return _0xbee0ee();},'HLiBQ':'sessions','GGprP':function(_0x8d0d4e,_0x1e1fbf,_0x485371){return _0x8d0d4e(_0x1e1fbf,_0x485371);},'uPERj':_0x3c2ef9(0x210),'dasbn':function(_0x2bedab,_0x3bdffc){return _0x2bedab===_0x3bdffc;},'kZxUJ':_0x3c2ef9(0x212),'rXwGf':function(_0xb3e286,_0x156c28){return _0xb3e286(_0x156c28);}},{storageStatePath:_0x4e6a08,tempAuthPath:_0x587a38}=_0x2ad7b4?{'storageStatePath':_0x2ad7b4,'tempAuthPath':undefined}:await _0x32f164['iKAbO'](resolveLocalAuthPath,getEnvDir(_0xe777a)),_0x571e42=_0x3040b4||_0x32f164['tbcla'](randomUUID),_0x4e39c1=_0x32f164['nLfAu'](join,_0x32f164['ouvVl'](getRangerDir),_0x32f164[_0x3c2ef9(0x1ea)],_0x571e42),_0x3816a9=_0x32f164['GGprP'](join,_0x4e39c1,_0x3c2ef9(0x1ff)),_0x3d1e5e=_0x4e6a08?_0x32f164['GGprP'](join,_0x3816a9,'Default'):undefined,{launchOptions:_0x291684,contextOptions:_0x2759a7}=buildBrowserOptionsFromSettings(_0x1e7865,{'headless':_0x5416dd?![]:_0x1e7865['headless']??!![],'storageStatePath':_0x4e6a08});if(process[_0x3c2ef9(0x1e9)]?.()===0x0){const _0x37ad6b=[_0x32f164[_0x3c2ef9(0x1ec)],_0x3c2ef9(0x21e)],_0x3d51f8=_0x291684['args']??[],_0x83a252=_0x37ad6b[_0x3c2ef9(0x209)](_0x2be613=>!_0x3d51f8['includes'](_0x2be613));_0x291684[_0x3c2ef9(0x1f8)]=[..._0x3d51f8,..._0x83a252];}const _0x35fac9=_0x32f164[_0x3c2ef9(0x1a9)](typeof _0x291684[_0x3c2ef9(0x1af)],_0x3c2ef9(0x212))?_0x291684['executablePath']:_0x4e6a08?chromium[_0x3c2ef9(0x1af)]():undefined;return{'storageStatePath':_0x4e6a08,'tempAuthPath':_0x587a38,'baseUrl':_0x1e7865[_0x3c2ef9(0x19e)],'headless':_0x32f164[_0x3c2ef9(0x207)](Boolean,_0x291684['headless']),'userDataDir':_0x3816a9,'browserProfilePath':_0x3d1e5e,'executablePath':_0x35fac9,'launchArgs':Array['isArray'](_0x291684[_0x3c2ef9(0x1f8)])?_0x291684['args']['filter'](_0x4facd4=>typeof _0x4facd4==='string'):[],'userAgent':_0x32f164['dasbn'](typeof _0x2759a7[_0x3c2ef9(0x1e7)],_0x32f164['kZxUJ'])?_0x2759a7['userAgent']:undefined,'extraHTTPHeaders':_0x2759a7['extraHTTPHeaders'],'allowInsecureLocalhost':_0x32f164[_0x3c2ef9(0x207)](Boolean,_0x1e7865['allowInsecureLocalhost']),'safeMode':Boolean(_0x1e7865['safeMode']),'cdpEndpoint':_0x1e7865['cdpEndpoint'],'isCdpMode':_0x32f164[_0x3c2ef9(0x1d5)](Boolean,_0x1e7865['cdpEndpoint'])};}export function getNestedValue(_0x5c4680,_0x16f651){const _0x50b47b=_0x5ba534,_0x1be891={'TrhMc':function(_0x150ecd,_0x2a3678){return _0x150ecd===_0x2a3678;},'KBsyb':function(_0x5252ff,_0x54d356){return _0x5252ff===_0x54d356;},'ATeNn':function(_0x4047d4,_0x33eb5d){return _0x4047d4!==_0x33eb5d;}},_0x429f3e=parseKeyPath(_0x16f651);let _0x1f6ea0=_0x5c4680;for(const _0x3e17b0 of _0x429f3e){if(_0x1be891[_0x50b47b(0x218)](_0x1f6ea0,null)||_0x1be891['KBsyb'](_0x1f6ea0,undefined)||_0x1be891[_0x50b47b(0x213)](typeof _0x1f6ea0,_0x50b47b(0x216)))return undefined;_0x1f6ea0=_0x1f6ea0[_0x3e17b0];}return _0x1f6ea0;}export function setNestedValue(_0xb578d3,_0x516143,_0x5a32c2){const _0x51962a=_0x5ba534,_0x2fe69e={'TpQvx':function(_0x12df30,_0x238fe9){return _0x12df30<_0x238fe9;},'uMrgC':function(_0x208461,_0x458ab7){return _0x208461-_0x458ab7;},'YTAPt':function(_0xafca1,_0x54bb8b){return _0xafca1 in _0x54bb8b;},'yuoHe':function(_0x323318,_0x529418){return _0x323318!==_0x529418;}},_0x12ea0d=parseKeyPath(_0x516143);let _0x4aa56a=_0xb578d3;for(let _0x544331=0x0;_0x2fe69e[_0x51962a(0x1b6)](_0x544331,_0x2fe69e['uMrgC'](_0x12ea0d[_0x51962a(0x1c4)],0x1));_0x544331++){const _0x237569=_0x12ea0d[_0x544331];(!_0x2fe69e[_0x51962a(0x1e1)](_0x237569,_0x4aa56a)||_0x2fe69e[_0x51962a(0x21d)](typeof _0x4aa56a[_0x237569],'object'))&&(_0x4aa56a[_0x237569]={}),_0x4aa56a=_0x4aa56a[_0x237569];}_0x4aa56a[_0x12ea0d[_0x2fe69e[_0x51962a(0x208)](_0x12ea0d['length'],0x1)]]=_0x5a32c2;}export function deleteNestedValue(_0x41bc5f,_0x39c355){const _0x31d7ed=_0x5ba534,_0x3d89af={'PNPpO':function(_0x426121,_0x98a684){return _0x426121(_0x98a684);},'YrVIm':function(_0x335c55,_0x577127){return _0x335c55<_0x577127;},'CBqsn':function(_0x90cd3f,_0x2f4a04){return _0x90cd3f===_0x2f4a04;},'jrPCt':function(_0x415191,_0x1b0161){return _0x415191!==_0x1b0161;},'TGViL':function(_0x438ce1,_0x234307){return _0x438ce1===_0x234307;},'aEXTK':function(_0x3eb8e8,_0x28ae7b){return _0x3eb8e8!==_0x28ae7b;},'wKUQA':'object','iIVit':function(_0xceab08,_0x2d78e8){return _0xceab08-_0x2d78e8;},'cdamP':function(_0x2f3da3,_0x266c48){return _0x2f3da3 in _0x266c48;}},_0x2becbf=_0x3d89af[_0x31d7ed(0x1da)](parseKeyPath,_0x39c355);let _0x253eed=_0x41bc5f;for(let _0x19c5c7=0x0;_0x3d89af[_0x31d7ed(0x1eb)](_0x19c5c7,_0x2becbf[_0x31d7ed(0x1c4)]-0x1);_0x19c5c7++){if(_0x3d89af['CBqsn'](_0x253eed,null)||_0x253eed===undefined||_0x3d89af['jrPCt'](typeof _0x253eed,_0x31d7ed(0x216)))return![];_0x253eed=_0x253eed[_0x2becbf[_0x19c5c7]];}if(_0x3d89af[_0x31d7ed(0x1bb)](_0x253eed,null)||_0x3d89af[_0x31d7ed(0x21f)](_0x253eed,undefined)||_0x3d89af['aEXTK'](typeof _0x253eed,_0x3d89af['wKUQA']))return![];const _0x2a9b29=_0x2becbf[_0x3d89af[_0x31d7ed(0x1a5)](_0x2becbf[_0x31d7ed(0x1c4)],0x1)];if(_0x3d89af['cdamP'](_0x2a9b29,_0x253eed))return delete _0x253eed[_0x2a9b29],!![];return![];}function parseKeyPath(_0x4ea11a){const _0x128a6b=_0x5ba534,_0x4f9569={'rvbLC':_0x128a6b(0x1ab),'DrYrC':_0x128a6b(0x20c),'SbXPk':function(_0x4e0f46,_0x266ff){return _0x4e0f46===_0x266ff;},'UElUy':'setupHeaders'},_0x408b47=_0x4ea11a[_0x128a6b(0x1a3)]('.');return _0x408b47[0x0]===_0x4f9569['rvbLC']&&(_0x408b47[0x0]=_0x4f9569[_0x128a6b(0x1f7)]),_0x4f9569['SbXPk'](_0x408b47[0x0],'setupHeader')&&(_0x408b47[0x0]=_0x4f9569[_0x128a6b(0x1cc)]),_0x408b47;}export function formatSettings(_0x2bcbca,_0x52f047=0x0){const _0x2af5bd=_0x5ba534,_0x3aad90={'DyLmr':function(_0x48831f,_0x46b6ad){return _0x48831f===_0x46b6ad;},'yxJdl':function(_0x169510,_0x55d2a5){return _0x169510===_0x55d2a5;},'GLbDR':function(_0x474baa,_0x36a73f){return _0x474baa!==_0x36a73f;}},_0x2f72e9=[],_0x4ebf9c='\x20\x20'['repeat'](_0x52f047);for(const [_0x25b010,_0xae9edd]of Object[_0x2af5bd(0x222)](_0x2bcbca)){if(_0x3aad90[_0x2af5bd(0x20d)](_0xae9edd,undefined))continue;if(_0x3aad90[_0x2af5bd(0x1f6)](typeof _0xae9edd,_0x2af5bd(0x216))&&_0x3aad90[_0x2af5bd(0x215)](_0xae9edd,null)){_0x2f72e9['push'](''+_0x4ebf9c+_0x25b010+':');for(const [_0x48513a,_0x16a149]of Object['entries'](_0xae9edd)){_0x2f72e9[_0x2af5bd(0x1fd)](_0x4ebf9c+'\x20\x20'+_0x48513a+':\x20'+_0x16a149);}}else _0x2f72e9['push'](''+_0x4ebf9c+_0x25b010+':\x20'+_0xae9edd);}return _0x2f72e9[_0x2af5bd(0x1c8)]('\x0a');}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x3ec507,_0x11ac56){const _0x5025dd=_0x5c41,_0x3ed3b4=_0x3ec507();while(!![]){try{const _0x23ecc3=parseInt(_0x5025dd(0x14c))/0x1+-parseInt(_0x5025dd(0x147))/0x2*(-parseInt(_0x5025dd(0x148))/0x3)+parseInt(_0x5025dd(0x14b))/0x4+parseInt(_0x5025dd(0x14a))/0x5+parseInt(_0x5025dd(0x146))/0x6*(-parseInt(_0x5025dd(0x144))/0x7)+parseInt(_0x5025dd(0x14d))/0x8+parseInt(_0x5025dd(0x149))/0x9*(-parseInt(_0x5025dd(0x14e))/0xa);if(_0x23ecc3===_0x11ac56)break;else _0x3ed3b4['push'](_0x3ed3b4['shift']());}catch(_0x53ccae){_0x3ed3b4['push'](_0x3ed3b4['shift']());}}}(_0x1af8,0xdc0e4));import{readFileSync}from'fs';function _0x5c41(_0x29fb6e,_0x398b00){_0x29fb6e=_0x29fb6e-0x143;const _0x1af840=_0x1af8();let _0x5c412a=_0x1af840[_0x29fb6e];return _0x5c412a;}import{dirname,join}from'path';import{fileURLToPath}from'url';const __filename=fileURLToPath(import.meta.url),__dirname=dirname(__filename);export function readSkillContent(_0x218a21){const _0x152d3a=_0x5c41,_0x40a4f3={'zAEeU':'utf-8'},_0x456d24=join(__dirname,'..','..',_0x152d3a(0x145)),_0x28c3e8=join(_0x456d24,_0x218a21);try{return readFileSync(_0x28c3e8,_0x40a4f3[_0x152d3a(0x143)]);}catch{return'';}}function _0x1af8(){const _0x45791b=['1595349GskoWh','11640064qfgoHp','42068530vZZBQg','dGqfi','zAEeU','91GstsGh','skills','335802oJjmgU','58gODWfp','148863TAFLtj','9pXUUyk','451735LyYiTl','5024236aOiZIx'];_0x1af8=function(){return _0x45791b;};return _0x1af8();}export function getRangerSkillContent(){const _0x3c66d6=_0x5c41,_0x23b99a={'dGqfi':function(_0x3475c7,_0x20d9e3){return _0x3475c7(_0x20d9e3);}};return _0x23b99a[_0x3c66d6(0x14f)](readSkillContent,'ranger/SKILL.md');}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const _0x3a6fe9=_0x2e0a;(function(_0x466c74,_0x3c863d){const _0xe57342=_0x2e0a,_0x2f3dd9=_0x466c74();while(!![]){try{const _0x30297c=parseInt(_0xe57342(0x85))/0x1+-parseInt(_0xe57342(0x82))/0x2*(parseInt(_0xe57342(0x89))/0x3)+parseInt(_0xe57342(0x8e))/0x4*(parseInt(_0xe57342(0x80))/0x5)+parseInt(_0xe57342(0x71))/0x6+-parseInt(_0xe57342(0x84))/0x7*(-parseInt(_0xe57342(0x6d))/0x8)+parseInt(_0xe57342(0x7a))/0x9*(-parseInt(_0xe57342(0x78))/0xa)+parseInt(_0xe57342(0x75))/0xb;if(_0x30297c===_0x3c863d)break;else _0x2f3dd9['push'](_0x2f3dd9['shift']());}catch(_0x40725d){_0x2f3dd9['push'](_0x2f3dd9['shift']());}}}(_0x3603,0x28441));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';import{getOpencodeSkillsDir}from'./opencodeConfig.js';function _0x3603(){const _0x13f0f9=['2908499TZIran','endsWith','feature-tracker','46990hkuxiP','utf-8','630QXTKjS','xxuzY','claude','\x20\x20Files:\x20','CvOPp','.md','540390fPRmdl','yDxbp','36964TibdPb','jqAid','35UWXyal','28744mFBIvQ','e2e-test-recommender','\x20\x20Installed\x20skill:\x20','darpG','45CfWOOu','Invalid\x20skill\x20frontmatter','SKILL.md','match','warn','8SbONEz','dpJbl','\x20\x20Removed\x20deprecated\x20skill:\x20','join','qutEF','XGBfv','opencode','102136IZlXdy','log','JzfIr','CjKyF','1187670uWsRJd','push','trim','ocOaO'];_0x3603=function(){return _0x13f0f9;};return _0x3603();}const __filename=fileURLToPath(import.meta.url),__dirname=dirname(__filename);export const RANGER_MANAGED_SKILLS=['ranger'];export const DEPRECATED_SKILLS=[_0x3a6fe9(0x86),'bug-bash',_0x3a6fe9(0x77)];export async function installSkill(_0x18f129,_0x333880={}){const _0x518968=_0x3a6fe9,_0x3ff7ce={'XGBfv':_0x518968(0x7c),'qutEF':function(_0xcff96e){return _0xcff96e();},'jqAid':function(_0x21c821,_0x479755,_0xce16b8){return _0x21c821(_0x479755,_0xce16b8);},'IFBSQ':function(_0x8b9d8d,_0x4d5f53){return _0x8b9d8d(_0x4d5f53);},'yDxbp':function(_0x14ad7c,_0x2a2b0a){return _0x14ad7c(_0x2a2b0a);},'CvOPp':_0x518968(0x8b),'darpG':function(_0x7fd82,_0xfe20ce){return _0x7fd82&&_0xfe20ce;},'fItwr':function(_0x5724d0,_0x170e55){return _0x5724d0===_0x170e55;},'WZnnh':_0x518968(0x6c),'uWnJj':function(_0xa3d7a4,_0x8c08d0,_0x8fc729){return _0xa3d7a4(_0x8c08d0,_0x8fc729);},'WXbll':function(_0x5d12d7,_0x5778ed,_0x4b5c56){return _0x5d12d7(_0x5778ed,_0x4b5c56);},'uRWXl':function(_0x3d1c65,_0x986f79){return _0x3d1c65(_0x986f79);},'AOVyW':function(_0x1e78a7,_0x51b415,_0x24b1b1){return _0x1e78a7(_0x51b415,_0x24b1b1);},'JzfIr':_0x518968(0x79),'CgSMC':function(_0x31c5cc,_0x5e5b09,_0x2eaa84){return _0x31c5cc(_0x5e5b09,_0x2eaa84);},'kJVXI':function(_0x4cc321,_0x707955,_0x4f8528,_0x1b85a8){return _0x4cc321(_0x707955,_0x4f8528,_0x1b85a8);},'CjKyF':function(_0xc372af,_0x43ee7d){return _0xc372af>_0x43ee7d;}},{level:level='project',cliVersion:_0x2f59fe,platform:platform=_0x3ff7ce[_0x518968(0x6b)]}=_0x333880,_0x525b9b=_0x3ff7ce[_0x518968(0x6a)](getSourceSkillsDir),_0x56d077=join(_0x525b9b,_0x18f129),_0x19177a=_0x3ff7ce['jqAid'](join,_0x525b9b,_0x18f129+'.md'),_0x468581=_0x3ff7ce['IFBSQ'](existsSync,_0x56d077)&&_0x3ff7ce['yDxbp'](statSync,_0x56d077)['isDirectory']()&&existsSync(join(_0x56d077,_0x3ff7ce[_0x518968(0x7e)])),_0x35e3f4=_0x3ff7ce['yDxbp'](existsSync,_0x19177a);if(_0x3ff7ce[_0x518968(0x88)](!_0x468581,!_0x35e3f4))return console[_0x518968(0x8d)]('\x20\x20Skill\x20not\x20found:\x20'+_0x18f129),![];const _0x8242f1=_0x3ff7ce['fItwr'](platform,_0x3ff7ce['WZnnh'])?getOpencodeSkillsDir(level):getSkillsDir(level),_0x535685=_0x3ff7ce['uWnJj'](join,_0x8242f1,_0x18f129);await _0x3ff7ce['WXbll'](mkdir,_0x535685,{'recursive':!![]});let _0x2f3290,_0x4cf5b7=[];if(_0x468581){const _0x6d6ed6=await _0x3ff7ce['uRWXl'](readdir,_0x56d077),_0x3116d4=_0x6d6ed6['filter'](_0x4b2ee0=>_0x4b2ee0[_0x518968(0x76)](_0x518968(0x7f)));for(const _0x38f9da of _0x3116d4){const _0x1cf37b=join(_0x56d077,_0x38f9da),_0x3f76c2=_0x3ff7ce[_0x518968(0x83)](join,_0x535685,_0x38f9da);await _0x3ff7ce['AOVyW'](copyFile,_0x1cf37b,_0x3f76c2),_0x4cf5b7[_0x518968(0x72)](_0x38f9da);}_0x2f3290=await readFile(join(_0x56d077,_0x3ff7ce['CvOPp']),_0x3ff7ce[_0x518968(0x6f)]);}else{_0x2f3290=await _0x3ff7ce['CgSMC'](readFile,_0x19177a,'utf-8');const _0x209b61=join(_0x535685,'SKILL.md');await _0x3ff7ce['kJVXI'](writeFile,_0x209b61,_0x2f3290,_0x3ff7ce['JzfIr']),_0x4cf5b7['push']('SKILL.md');}const {name:_0x4e4bec}=_0x3ff7ce[_0x518968(0x81)](parseFrontmatter,_0x2f3290);return console[_0x518968(0x6e)](_0x518968(0x87)+_0x4e4bec),console[_0x518968(0x6e)]('\x20\x20Location:\x20'+_0x535685),_0x3ff7ce[_0x518968(0x70)](_0x4cf5b7['length'],0x1)&&console[_0x518968(0x6e)](_0x518968(0x7d)+_0x4cf5b7[_0x518968(0x69)](',\x20')),logLocalAgentInstallation(_0x18f129,{'skillDisplayName':_0x4e4bec,'installLevel':level},_0x2f59fe)['catch'](()=>{}),!![];}function getSourceSkillsDir(){const _0x352ec7=_0x3a6fe9,_0x5d28e9={'xxuzY':function(_0x3d4c88,_0x45801f,_0x5d7ad2,_0x3af4d5,_0x2fcfb8){return _0x3d4c88(_0x45801f,_0x5d7ad2,_0x3af4d5,_0x2fcfb8);},'cjckP':'skills','dpJbl':function(_0x4547ab,_0x1cea5a,_0x33a9e6,_0x290894,_0x1a0277,_0x2ab3a8){return _0x4547ab(_0x1cea5a,_0x33a9e6,_0x290894,_0x1a0277,_0x2ab3a8);},'ocOaO':function(_0x480854,_0x4e189f){return _0x480854(_0x4e189f);}},_0x128d89=[_0x5d28e9[_0x352ec7(0x7b)](join,__dirname,'..','..',_0x5d28e9['cjckP']),_0x5d28e9[_0x352ec7(0x8f)](join,__dirname,'..','..','..','skills')];for(const _0xecda23 of _0x128d89){if(_0x5d28e9[_0x352ec7(0x74)](existsSync,_0xecda23))return _0xecda23;}return _0x128d89[0x0];}function parseFrontmatter(_0x396f9c){const _0x2c5c04=_0x3a6fe9,_0x1c8042={'mNsfP':_0x2c5c04(0x8a)},_0x4ebcef=_0x396f9c[_0x2c5c04(0x8c)](/^---\n([\s\S]+?)\n---/);if(!_0x4ebcef)throw new Error(_0x1c8042['mNsfP']);const _0x8f97f4=_0x4ebcef[0x1],_0x5efc63=_0x8f97f4['match'](/name:\s*(.+)/),_0x444193=_0x8f97f4['match'](/description:\s*"?(.+?)"?\n/);return{'name':_0x5efc63?.[0x1][_0x2c5c04(0x73)]()||'','description':_0x444193?.[0x1][_0x2c5c04(0x73)]()||''};}function _0x2e0a(_0x230dea,_0x3955b7){_0x230dea=_0x230dea-0x68;const _0x36033d=_0x3603();let _0x2e0a74=_0x36033d[_0x230dea];return _0x2e0a74;}export async function removeSkill(_0x44989c,_0x1f45b7){const _0x4c1b7b=_0x3a6fe9,_0x414110={'dQFew':function(_0x1f8d8d,_0x447569,_0xc61fd5){return _0x1f8d8d(_0x447569,_0xc61fd5);}},_0x54acbf=getSkillsDir(_0x1f45b7),_0xc036b0=join(_0x54acbf,_0x44989c);if(!existsSync(_0xc036b0))return![];try{return await _0x414110['dQFew'](rm,_0xc036b0,{'recursive':!![]}),console['log'](_0x4c1b7b(0x68)+_0x44989c),!![];}catch{return console['warn']('\x20\x20Failed\x20to\x20remove\x20deprecated\x20skill:\x20'+_0x44989c),![];}}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const _0x1f87f1=_0x837e;(function(_0x461197,_0x5efd85){const _0x29a3ae=_0x837e,_0x1ce926=_0x461197();while(!![]){try{const _0x147851=-parseInt(_0x29a3ae(0x16c))/0x1*(parseInt(_0x29a3ae(0x177))/0x2)+parseInt(_0x29a3ae(0x15d))/0x3+parseInt(_0x29a3ae(0x148))/0x4+parseInt(_0x29a3ae(0x15e))/0x5*(-parseInt(_0x29a3ae(0x147))/0x6)+-parseInt(_0x29a3ae(0x155))/0x7*(parseInt(_0x29a3ae(0x163))/0x8)+parseInt(_0x29a3ae(0x17a))/0x9+parseInt(_0x29a3ae(0x16f))/0xa;if(_0x147851===_0x5efd85)break;else _0x1ce926['push'](_0x1ce926['shift']());}catch(_0x213629){_0x1ce926['push'](_0x1ce926['shift']());}}}(_0x3834,0xddd67));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 _0x837e(_0x5dc7bd,_0x19146d){_0x5dc7bd=_0x5dc7bd-0x13e;const _0x3834d5=_0x3834();let _0x837eec=_0x3834d5[_0x5dc7bd];return _0x837eec;}function readVint(_0x4d786d,_0x1a440f){const _0xe6128d=_0x837e,_0x5dd44d={'lKrms':function(_0x4f4f7d,_0x2ab503){return _0x4f4f7d+_0x2ab503;},'pAgHT':function(_0x35009e,_0x520fca){return _0x35009e&_0x520fca;},'XazYF':function(_0x1e2b69,_0x441a4a){return _0x1e2b69<_0x441a4a;},'LLySb':function(_0x57592d,_0x25ed0d){return _0x57592d*_0x25ed0d;}};if(_0x1a440f>=_0x4d786d['length'])return[0x0,0x0];const _0x1ea846=_0x4d786d[_0x1a440f];let _0xb3ac62=0x1,_0x594277=0x80;while(_0xb3ac62<=0x8&&!(_0x1ea846&_0x594277)){_0xb3ac62++,_0x594277>>=0x1;}if(_0x5dd44d['lKrms'](_0x1a440f,_0xb3ac62)>_0x4d786d[_0xe6128d(0x157)])return[0x0,0x0];let _0x218494=_0x5dd44d['pAgHT'](_0x1ea846,_0x594277-0x1);for(let _0x307e55=0x1;_0x5dd44d[_0xe6128d(0x161)](_0x307e55,_0xb3ac62);_0x307e55++){_0x218494=_0x5dd44d[_0xe6128d(0x15a)](_0x5dd44d[_0xe6128d(0x164)](_0x218494,0x100),_0x4d786d[_0x1a440f+_0x307e55]);}return[_0x218494,_0xb3ac62];}function readId(_0x40037f,_0x1baf45){const _0x1b4823=_0x837e,_0x2ebb8d={'eDshJ':function(_0x1464c4,_0x5cb835){return _0x1464c4>=_0x5cb835;},'BCSKZ':function(_0x641666,_0x3638f6){return _0x641666<_0x3638f6;},'GerMB':function(_0x21ab3f,_0x16ed75){return _0x21ab3f*_0x16ed75;},'wCBzh':function(_0x5548af,_0x529ad6){return _0x5548af+_0x529ad6;}};if(_0x2ebb8d['eDshJ'](_0x1baf45,_0x40037f[_0x1b4823(0x157)]))return[0x0,0x0];const _0x43fe3e=_0x40037f[_0x1baf45];let _0x39f65b;if(_0x2ebb8d[_0x1b4823(0x17b)](_0x43fe3e,0x80))_0x39f65b=0x1;else{if(_0x2ebb8d['eDshJ'](_0x43fe3e,0x40))_0x39f65b=0x2;else{if(_0x43fe3e>=0x20)_0x39f65b=0x3;else{if(_0x2ebb8d[_0x1b4823(0x17b)](_0x43fe3e,0x10))_0x39f65b=0x4;else return[_0x43fe3e,0x1];}}}if(_0x1baf45+_0x39f65b>_0x40037f['length'])return[0x0,0x0];let _0x146d10=0x0;for(let _0x3f2eff=0x0;_0x2ebb8d[_0x1b4823(0x143)](_0x3f2eff,_0x39f65b);_0x3f2eff++){_0x146d10=_0x2ebb8d['GerMB'](_0x146d10,0x100)+_0x40037f[_0x2ebb8d['wCBzh'](_0x1baf45,_0x3f2eff)];}return[_0x146d10,_0x39f65b];}function readUint(_0x4499d4,_0x23d639,_0x2b1c0f){const _0x268019=_0x837e,_0x53fdc4={'ucJxu':function(_0x1a998c,_0x926a79){return _0x1a998c<_0x926a79;},'AAMkR':function(_0x19dd61,_0x9647e0){return _0x19dd61+_0x9647e0;}};let _0x1b1c4f=0x0;for(let _0x193537=0x0;_0x53fdc4[_0x268019(0x170)](_0x193537,_0x2b1c0f);_0x193537++){_0x1b1c4f=_0x1b1c4f*0x100+_0x4499d4[_0x53fdc4['AAMkR'](_0x23d639,_0x193537)];}return _0x1b1c4f;}function isUnknownSize(_0xc98a68,_0x293ace){const _0x1df769=_0x837e,_0x50ed0c={'vwrYc':function(_0x471254,_0x17125e){return _0x471254-_0x17125e;},'vXozN':function(_0x4d7b8d,_0x43b6a7){return _0x4d7b8d*_0x43b6a7;}};return _0xc98a68===_0x50ed0c['vwrYc'](Math['pow'](0x2,_0x50ed0c[_0x1df769(0x144)](0x7,_0x293ace)),0x1);}function writeVint(_0x528659,_0x4473a5){const _0x491a7b=_0x837e,_0x2c8079={'gircP':function(_0x10fced,_0x5386c2){return _0x10fced*_0x5386c2;},'GOUNU':function(_0x531be5,_0x4a76f8){return _0x531be5>=_0x4a76f8;},'IzVFJ':function(_0x39f7d5,_0x37dc1e){return _0x39f7d5/_0x37dc1e;}};let _0x3bcdd5=_0x4473a5||0x1;while(Math['pow'](0x2,_0x2c8079[_0x491a7b(0x16a)](0x7,_0x3bcdd5))-0x2<_0x528659)_0x3bcdd5++;const _0x4e7b5e=Buffer['alloc'](_0x3bcdd5);for(let _0x587f54=_0x3bcdd5-0x1;_0x2c8079['GOUNU'](_0x587f54,0x0);_0x587f54--){_0x4e7b5e[_0x587f54]=_0x528659&0xff,_0x528659=Math[_0x491a7b(0x167)](_0x2c8079['IzVFJ'](_0x528659,0x100));}return _0x4e7b5e[0x0]|=0x1<<0x8-_0x3bcdd5,_0x4e7b5e;}function writeUint(_0x55ba10,_0x3b6e3d){const _0x3fd722=_0x837e,_0x1bafa7={'lzMVZ':function(_0x487de9,_0x1d8d60){return _0x487de9-_0x1d8d60;},'ocRSQ':function(_0x4dfa9d,_0x34ade4){return _0x4dfa9d/_0x34ade4;}},_0x21394a=Buffer['alloc'](_0x3b6e3d);for(let _0x2be3fa=_0x1bafa7['lzMVZ'](_0x3b6e3d,0x1);_0x2be3fa>=0x0;_0x2be3fa--){_0x21394a[_0x2be3fa]=_0x55ba10&0xff,_0x55ba10=Math['floor'](_0x1bafa7[_0x3fd722(0x15b)](_0x55ba10,0x100));}return _0x21394a;}function writeUnknownSizeVint(_0x37a3de){const _0x5332d6=_0x837e,_0x3e41c2=Buffer[_0x5332d6(0x14f)](_0x37a3de,0xff);return _0x3e41c2[0x0]=0xff>>_0x37a3de-0x1,_0x3e41c2;}function uintSize(_0x2189e1){const _0x181e82=_0x837e,_0x142356={'EGAkY':function(_0xd6b481,_0xb97287){return _0xd6b481>_0xb97287;},'raTNQ':function(_0x54d232,_0x25640d){return _0x54d232/_0x25640d;}};if(_0x2189e1===0x0)return 0x1;let _0x4f1c6e=0x0,_0x20ade6=_0x2189e1;while(_0x142356[_0x181e82(0x14a)](_0x20ade6,0x0)){_0x4f1c6e++,_0x20ade6=Math[_0x181e82(0x167)](_0x142356[_0x181e82(0x142)](_0x20ade6,0x100));}return _0x4f1c6e;}function findTimestampScale(_0x4c1943,_0x557eb9){const _0x2fa96a=_0x837e,_0x3c0756={'LyIgA':function(_0x1f0a8a,_0x3799c0){return _0x1f0a8a+_0x3799c0;},'cXgru':function(_0x34bba3,_0x2533aa){return _0x34bba3<_0x2533aa;},'cKroA':function(_0x516e92,_0x37fff1,_0x7511d8){return _0x516e92(_0x37fff1,_0x7511d8);},'XhXJQ':function(_0x30054c,_0x459c80){return _0x30054c===_0x459c80;},'sAskN':function(_0x3a1326,_0x30c8d3,_0x257666,_0x23462c){return _0x3a1326(_0x30c8d3,_0x257666,_0x23462c);},'QBLjl':function(_0x53e22b,_0x3822c7){return _0x53e22b+_0x3822c7;},'PPbtl':function(_0xc6c56,_0x1af977){return _0xc6c56+_0x1af977;}};let _0x27d87e=_0x557eb9;const _0x2fe674=Math['min'](_0x4c1943['length'],_0x3c0756['LyIgA'](_0x557eb9,0x2710));while(_0x27d87e<_0x2fe674){const [_0x51eadf,_0x3cf5b8]=readId(_0x4c1943,_0x27d87e),[_0x2e2e98,_0x3a344d]=readVint(_0x4c1943,_0x3c0756[_0x2fa96a(0x14c)](_0x27d87e,_0x3cf5b8));if(_0x51eadf===ID_INFO){let _0x2364fa=_0x3c0756['LyIgA'](_0x27d87e,_0x3cf5b8)+_0x3a344d;const _0x147aac=_0x3c0756[_0x2fa96a(0x14c)](_0x2364fa,_0x2e2e98);while(_0x3c0756['cXgru'](_0x2364fa,_0x147aac)){const [_0x422f2a,_0x591cb7]=_0x3c0756[_0x2fa96a(0x176)](readId,_0x4c1943,_0x2364fa),[_0x428835,_0x225d5b]=readVint(_0x4c1943,_0x2364fa+_0x591cb7);if(_0x3c0756['XhXJQ'](_0x422f2a,ID_TIMESTAMP_SCALE))return _0x3c0756['sAskN'](readUint,_0x4c1943,_0x3c0756[_0x2fa96a(0x172)](_0x2364fa,_0x591cb7)+_0x225d5b,_0x428835);_0x2364fa+=_0x3c0756['PPbtl'](_0x591cb7+_0x225d5b,_0x428835);}break;}if(_0x51eadf===ID_CLUSTER)break;if(isUnknownSize(_0x2e2e98,_0x3a344d))break;_0x27d87e+=_0x3cf5b8+_0x3a344d+_0x2e2e98;}return 0xf4240;}function findFirstClusterOffset(_0x2d9381,_0xcaf28d){const _0x265f16=_0x837e,_0x3a7c57={'YlcTH':function(_0x50812c,_0x2340dc,_0x518499){return _0x50812c(_0x2340dc,_0x518499);},'Dgwom':function(_0x41f7e7,_0x42fd3c){return _0x41f7e7===_0x42fd3c;},'amLad':function(_0x5b1de8,_0x3c0164,_0x517e61){return _0x5b1de8(_0x3c0164,_0x517e61);},'HsuKx':function(_0x77c750,_0x551f80){return _0x77c750+_0x551f80;}};let _0x300d5f=_0xcaf28d;while(_0x300d5f<_0x2d9381['length']){const [_0x5c966e,_0x4a57e2]=_0x3a7c57['YlcTH'](readId,_0x2d9381,_0x300d5f);if(_0x3a7c57['Dgwom'](_0x5c966e,ID_CLUSTER))return _0x300d5f;const [_0x55c7e3,_0x2678a1]=_0x3a7c57['amLad'](readVint,_0x2d9381,_0x3a7c57['HsuKx'](_0x300d5f,_0x4a57e2));if(_0x3a7c57[_0x265f16(0x14d)](isUnknownSize,_0x55c7e3,_0x2678a1))return _0x300d5f;_0x300d5f+=_0x3a7c57[_0x265f16(0x150)](_0x4a57e2+_0x2678a1,_0x55c7e3);}return _0x2d9381['length'];}function findClusterEnd(_0x10f573,_0x30d5a4,_0x1418a0,_0x55d6f0){const _0x40b3a5=_0x837e,_0x338048={'AfAlY':function(_0x440d7a,_0x2962c3){return _0x440d7a-_0x2962c3;},'NIUim':function(_0x402183,_0x68824d,_0x5c885f){return _0x402183(_0x68824d,_0x5c885f);},'oQDuL':function(_0x1b0680,_0x35f8a6){return _0x1b0680+_0x35f8a6;},'rdStk':function(_0x2a48a3,_0x5dbadd){return _0x2a48a3+_0x5dbadd;}};if(!isUnknownSize(_0x1418a0,_0x55d6f0))return _0x30d5a4+_0x1418a0;const _0x302972=new Set([ID_CLUSTER,0x1c53bb6b,0x1254c367]);let _0x267340=_0x30d5a4;while(_0x267340<_0x338048[_0x40b3a5(0x159)](_0x10f573['length'],0x4)){const [_0x19c387,_0x32d566]=_0x338048['NIUim'](readId,_0x10f573,_0x267340);if(_0x302972[_0x40b3a5(0x171)](_0x19c387))return _0x267340;const [_0x256f7b,_0xb446a6]=readVint(_0x10f573,_0x338048['oQDuL'](_0x267340,_0x32d566));if(isUnknownSize(_0x256f7b,_0xb446a6))return _0x10f573[_0x40b3a5(0x157)];_0x267340+=_0x338048['rdStk'](_0x32d566,_0xb446a6)+_0x256f7b;}return _0x10f573['length'];}function extractClusters(_0x5ef27f,_0x3e4931){const _0x8d5fe6=_0x837e,_0x1c2ae9={'pgpPH':function(_0x68e4d,_0x4d3ae3){return _0x68e4d===_0x4d3ae3;},'qiiTj':function(_0x2908e3,_0x2bbdcd,_0x35f139){return _0x2908e3(_0x2bbdcd,_0x35f139);},'YLsow':function(_0x3de985,_0x20466e){return _0x3de985!==_0x20466e;},'NmUIV':function(_0x377da3,_0x278b54,_0x473876){return _0x377da3(_0x278b54,_0x473876);},'jJkha':function(_0x3326c7,_0x5afcf4){return _0x3326c7+_0x5afcf4;},'nwMVa':function(_0x13a420,_0x6b12fa){return _0x13a420<_0x6b12fa;},'eXHsm':function(_0xf78c45,_0x181092){return _0xf78c45+_0x181092;},'axiFy':function(_0x299be8,_0x5a1a60){return _0x299be8===_0x5a1a60;},'FlOIj':function(_0x12fea3,_0x18f1da){return _0x12fea3+_0x18f1da;},'EkLQt':function(_0x5708c8,_0x2798ad){return _0x5708c8+_0x2798ad;},'Naorx':function(_0x5e44e6,_0x1fd832){return _0x5e44e6+_0x1fd832;},'kxrKd':function(_0x3e01ff,_0x45fed1){return _0x3e01ff===_0x45fed1;},'diQOZ':function(_0xde7a19,_0x2f13e6,_0xee297e){return _0xde7a19(_0x2f13e6,_0xee297e);},'VwsKO':function(_0xa2e092,_0x4a47cf){return _0xa2e092<_0x4a47cf;},'RHgup':function(_0xf96750,_0x1999ee,_0x1b0cdf){return _0xf96750(_0x1999ee,_0x1b0cdf);},'udzBH':function(_0x2320a2,_0x498fc7){return _0x2320a2>=_0x498fc7;},'MuxKP':function(_0x2bc241,_0x1eb962){return _0x2bc241+_0x1eb962;},'XaZpQ':function(_0x41694c,_0x5641e2){return _0x41694c>_0x5641e2;},'sPGGH':function(_0x248150,_0x31edc4,_0x12dcaa){return _0x248150(_0x31edc4,_0x12dcaa);}},_0x3581e0=[],_0x28c942=Buffer['from']([0x1f,0x43,0xb6,0x75]);let _0x1a88ea=0x0;while(_0x1a88ea<_0x5ef27f['length']){const _0xcdc01c=_0x5ef27f['indexOf'](_0x28c942,_0x1a88ea);if(_0x1c2ae9['pgpPH'](_0xcdc01c,-0x1))break;const [_0x1d7772,_0x4437b5]=_0x1c2ae9['qiiTj'](readId,_0x5ef27f,_0xcdc01c);if(_0x1c2ae9['YLsow'](_0x1d7772,ID_CLUSTER)){_0x1a88ea=_0xcdc01c+0x1;continue;}const [_0x5ef887,_0x36ab5d]=_0x1c2ae9['NmUIV'](readVint,_0x5ef27f,_0x1c2ae9[_0x8d5fe6(0x153)](_0xcdc01c,_0x4437b5)),_0x19accf=_0x1c2ae9[_0x8d5fe6(0x153)](_0xcdc01c+_0x4437b5,_0x36ab5d),_0x532829=findClusterEnd(_0x5ef27f,_0x19accf,_0x5ef887,_0x36ab5d);let _0x105c15=_0x19accf,_0x232197=0x0,_0x48d24d=0x2,_0x299cfb=![],_0x48218e=Buffer['alloc'](0x0),_0x30fb52=Buffer['alloc'](0x0);while(_0x1c2ae9['nwMVa'](_0x105c15,_0x532829)){const [_0x4eb615,_0x329e33]=readId(_0x5ef27f,_0x105c15),[_0x4a7012,_0x2627da]=_0x1c2ae9['qiiTj'](readVint,_0x5ef27f,_0x1c2ae9[_0x8d5fe6(0x162)](_0x105c15,_0x329e33));if(_0x1c2ae9['axiFy'](_0x4eb615,ID_TIMESTAMP)){_0x232197=readUint(_0x5ef27f,_0x1c2ae9['FlOIj'](_0x105c15,_0x329e33)+_0x2627da,_0x4a7012),_0x48d24d=_0x4a7012,_0x299cfb=!![],_0x48218e=_0x5ef27f[_0x8d5fe6(0x156)](_0x19accf,_0x105c15);const _0x1f5a74=_0x1c2ae9['EkLQt'](_0x1c2ae9[_0x8d5fe6(0x17c)](_0x105c15+_0x329e33,_0x2627da),_0x4a7012);_0x30fb52=_0x5ef27f['slice'](_0x1f5a74,_0x532829);break;}if(_0x1c2ae9[_0x8d5fe6(0x13f)](_0x4eb615,ID_CLUSTER))break;if(_0x1c2ae9['diQOZ'](isUnknownSize,_0x4a7012,_0x2627da))break;_0x105c15+=_0x1c2ae9['Naorx'](_0x1c2ae9[_0x8d5fe6(0x153)](_0x329e33,_0x2627da),_0x4a7012);}!_0x299cfb&&(_0x30fb52=_0x5ef27f['slice'](_0x19accf,_0x532829));let _0x8a52b7=_0x232197;_0x105c15=_0x19accf;while(_0x1c2ae9['VwsKO'](_0x105c15,_0x532829)){const [_0x339a7a,_0x2d97a7]=readId(_0x5ef27f,_0x105c15),[_0x29a4ee,_0x24f054]=_0x1c2ae9[_0x8d5fe6(0x141)](readVint,_0x5ef27f,_0x105c15+_0x2d97a7);if(_0x1c2ae9['kxrKd'](_0x339a7a,ID_SIMPLE_BLOCK)&&_0x1c2ae9['udzBH'](_0x29a4ee,0x4)){const _0x304299=_0x1c2ae9[_0x8d5fe6(0x13e)](_0x105c15,_0x2d97a7)+_0x24f054,[,_0x334d0e]=readVint(_0x5ef27f,_0x304299),_0x4fe087=_0x5ef27f[_0x8d5fe6(0x16e)](_0x304299+_0x334d0e),_0x2ae870=_0x232197+_0x4fe087;if(_0x1c2ae9[_0x8d5fe6(0x17f)](_0x2ae870,_0x8a52b7))_0x8a52b7=_0x2ae870;}if(_0x1c2ae9[_0x8d5fe6(0x17e)](_0x339a7a,ID_CLUSTER))break;if(_0x1c2ae9['sPGGH'](isUnknownSize,_0x29a4ee,_0x24f054))break;_0x105c15+=_0x1c2ae9[_0x8d5fe6(0x17c)](_0x2d97a7,_0x24f054)+_0x29a4ee;}_0x3581e0[_0x8d5fe6(0x173)]({'timestamp':_0x232197,'maxTicks':_0x8a52b7,'bodyBeforeTimestamp':_0x48218e,'bodyAfterTimestamp':_0x30fb52,'timestampElementSize':_0x48d24d}),_0x1a88ea=_0x532829;}return _0x3581e0;}function parseWebm(_0x2b7289){const _0x24584b=_0x837e,_0x4d00e6={'wuguh':function(_0x513f5b,_0x340950,_0x5ef7ac){return _0x513f5b(_0x340950,_0x5ef7ac);},'Sdzca':function(_0x2ead38,_0x48d457){return _0x2ead38+_0x48d457;},'tMKxw':function(_0x36c874,_0x25e77b){return _0x36c874>_0x25e77b;}};let _0x40b724=0x0;const [,_0x629926]=readId(_0x2b7289,_0x40b724),[_0x379263,_0x4e2bbf]=readVint(_0x2b7289,_0x40b724+_0x629926);_0x40b724+=_0x629926+_0x4e2bbf+_0x379263;const [_0x1b039a,_0x51e03c]=_0x4d00e6[_0x24584b(0x158)](readId,_0x2b7289,_0x40b724);if(_0x1b039a!==ID_SEGMENT)return null;const [,_0x145526]=_0x4d00e6[_0x24584b(0x158)](readVint,_0x2b7289,_0x4d00e6['Sdzca'](_0x40b724,_0x51e03c)),_0x5ca21e=_0x40b724+_0x51e03c+_0x145526,_0x332992=findTimestampScale(_0x2b7289,_0x5ca21e),_0x438249=findFirstClusterOffset(_0x2b7289,_0x5ca21e),_0xa2cb70=_0x2b7289[_0x24584b(0x156)](0x0,_0x438249),_0x3675f0=_0x4d00e6['wuguh'](extractClusters,_0x2b7289,_0x332992);let _0x4a5c3a=0x0;for(const _0x207539 of _0x3675f0){if(_0x4d00e6['tMKxw'](_0x207539['maxTicks'],_0x4a5c3a))_0x4a5c3a=_0x207539['maxTicks'];}return{'header':_0xa2cb70,'clusters':_0x3675f0,'timestampScale':_0x332992,'maxTimestampTicks':_0x4a5c3a};}function buildCluster(_0x138573,_0x1e04fd,_0x56dbb4){const _0x1b8803=_0x837e,_0x4d081a=Buffer['from']([0x1f,0x43,0xb6,0x75]),_0x5a92f1=Math['max'](0x4,uintSize(_0x138573)),_0x47feeb=Buffer['concat']([Buffer[_0x1b8803(0x14e)]([ID_TIMESTAMP]),writeVint(_0x5a92f1),writeUint(_0x138573,_0x5a92f1)]),_0x18fc81=Buffer['concat']([_0x1e04fd,_0x47feeb,_0x56dbb4]),_0x236bb8=writeVint(_0x18fc81[_0x1b8803(0x157)]);return Buffer[_0x1b8803(0x15c)]([_0x4d081a,_0x236bb8,_0x18fc81]);}const ID_DURATION=0x4489;function _0x3834(){const _0x14b857=['lKrms','ocRSQ','concat','2359524UGhUvZ','590btYDAf','log','clusters','XazYF','eXHsm','5224NbHqPB','LLySb','copy','lUYZs','floor','error','argv','gircP','stitchWebmFiles.ts','804157wpjESM','min','readInt16BE','7162350bbSedD','ucJxu','has','QBLjl','push','uqrnV','Stitching\x20failed\x20or\x20only\x20one\x20input\x20file.','cKroA','2rlcNWe','JFJzn','header','1222506wISIJk','eDshJ','Naorx','\x20files\x20->\x20','pgpPH','XaZpQ','zPsRO','MuxKP','kxrKd','YtiRM','RHgup','raTNQ','BCSKZ','vXozN','endsWith','vyOAD','4266pdpYtd','5848664lHUDzJ','fTfim','EGAkY','KnPUY','LyIgA','amLad','from','alloc','HsuKx','WaiMr','czQvc','jJkha','bodyAfterTimestamp','13979RxyGHw','slice','length','wuguh','AfAlY'];_0x3834=function(){return _0x14b857;};return _0x3834();}function rebuildHeaderWithoutDuration(_0x58f718){const _0x2b54f5=_0x837e,_0x5e7796={'uqrnV':function(_0x311724,_0x56e7c0,_0x291ce9){return _0x311724(_0x56e7c0,_0x291ce9);},'lUYZs':function(_0x9b5e48,_0x4bfa7d){return _0x9b5e48+_0x4bfa7d;},'zPsRO':function(_0x424c30,_0xf73a07,_0x5c876d){return _0x424c30(_0xf73a07,_0x5c876d);},'WaiMr':function(_0x32bf0a,_0x44b684){return _0x32bf0a<_0x44b684;},'wXlGj':function(_0x55fcca,_0x57b54b,_0x17693b){return _0x55fcca(_0x57b54b,_0x17693b);},'CVgTO':function(_0x41124c,_0x46ee4c,_0x3472f4){return _0x41124c(_0x46ee4c,_0x3472f4);},'czQvc':function(_0x439eb5,_0xd9d90c,_0x8c7a28){return _0x439eb5(_0xd9d90c,_0x8c7a28);},'vyOAD':function(_0x3395b5,_0x54eefb){return _0x3395b5+_0x54eefb;}},_0xda9db1=Buffer['from'](_0x58f718);let _0x27fbc5=0x0;const [,_0x22a858]=readId(_0xda9db1,_0x27fbc5),[_0x1ad6fe,_0x5df183]=_0x5e7796[_0x2b54f5(0x174)](readVint,_0xda9db1,_0x27fbc5+_0x22a858),_0x58dbe3=_0x5e7796['lUYZs'](_0x5e7796[_0x2b54f5(0x166)](_0x27fbc5,_0x22a858)+_0x5df183,_0x1ad6fe),[,_0x47be70]=_0x5e7796['zPsRO'](readId,_0xda9db1,_0x58dbe3),[,_0x4809fa]=_0x5e7796[_0x2b54f5(0x180)](readVint,_0xda9db1,_0x5e7796[_0x2b54f5(0x166)](_0x58dbe3,_0x47be70)),_0x2f1d5a=_0x58dbe3+_0x47be70+_0x4809fa,_0x33205c=writeUnknownSizeVint(_0x4809fa);_0x33205c[_0x2b54f5(0x165)](_0xda9db1,_0x5e7796[_0x2b54f5(0x166)](_0x58dbe3,_0x47be70));let _0x35d90d=_0x2f1d5a;const _0x33fc4b=Math[_0x2b54f5(0x16d)](_0xda9db1['length'],_0x5e7796['lUYZs'](_0x2f1d5a,0x2710));while(_0x5e7796[_0x2b54f5(0x151)](_0x35d90d,_0x33fc4b)){const [_0x4e60f4,_0x594aa7]=_0x5e7796['wXlGj'](readId,_0xda9db1,_0x35d90d),[_0x3ff0b4,_0x5cffc5]=_0x5e7796['CVgTO'](readVint,_0xda9db1,_0x35d90d+_0x594aa7);if(_0x4e60f4===ID_CLUSTER)break;if(_0x5e7796[_0x2b54f5(0x152)](isUnknownSize,_0x3ff0b4,_0x5cffc5))break;if(_0x4e60f4===ID_INFO){const _0x57e817=_0x5e7796[_0x2b54f5(0x166)](_0x35d90d+_0x594aa7,_0x5cffc5),_0xbe695d=_0x57e817+_0x3ff0b4,_0x9359a9=[];let _0x2024cb=_0x57e817;while(_0x2024cb<_0xbe695d){const [_0x14584e,_0x1a17f3]=readId(_0xda9db1,_0x2024cb),[_0x30c3db,_0x28f30c]=readVint(_0xda9db1,_0x5e7796[_0x2b54f5(0x146)](_0x2024cb,_0x1a17f3)),_0x4e2f48=_0x1a17f3+_0x28f30c+_0x30c3db;_0x14584e!==ID_DURATION&&_0x9359a9[_0x2b54f5(0x173)](_0xda9db1['slice'](_0x2024cb,_0x5e7796[_0x2b54f5(0x146)](_0x2024cb,_0x4e2f48))),_0x2024cb+=_0x4e2f48;}const _0x154230=Buffer['concat'](_0x9359a9),_0x5beacb=Buffer['concat']([_0xda9db1[_0x2b54f5(0x156)](_0x35d90d,_0x35d90d+_0x594aa7),writeVint(_0x154230['length'],_0x5cffc5)]);return Buffer[_0x2b54f5(0x15c)]([_0xda9db1['slice'](0x0,_0x35d90d),_0x5beacb,_0x154230,_0xda9db1['slice'](_0xbe695d)]);}_0x35d90d+=_0x594aa7+_0x5cffc5+_0x3ff0b4;}return _0xda9db1;}export function stitchWebmFiles(_0x4bf8fe,_0xbdc058){const _0x4b5217=_0x837e,_0x20c1e9={'gGTxF':function(_0x286c05,_0x1e1bfa){return _0x286c05(_0x1e1bfa);},'fTfim':function(_0x405621,_0x46a58a){return _0x405621(_0x46a58a);},'YtiRM':function(_0xe7bef4,_0x2b5dd1){return _0xe7bef4<_0x2b5dd1;},'KnPUY':function(_0x5e5e03,_0x1c3f85,_0x7f9aff,_0x265d6b){return _0x5e5e03(_0x1c3f85,_0x7f9aff,_0x265d6b);},'JFJzn':function(_0x23e900,_0x4d175c){return _0x23e900+_0x4d175c;},'DKzuL':function(_0x5cedd3,_0x5e0e63,_0x2999ee){return _0x5cedd3(_0x5e0e63,_0x2999ee);}};if(_0x4bf8fe['length']<=0x1)return![];const _0x42f6eb=[];for(const _0xb9fc0e of _0x4bf8fe){const _0x37b718=readFileSync(_0xb9fc0e),_0x397835=_0x20c1e9['gGTxF'](parseWebm,_0x37b718);if(!_0x397835||_0x397835[_0x4b5217(0x160)]['length']===0x0)return![];_0x42f6eb[_0x4b5217(0x173)](_0x397835);}const _0x438a6b=_0x42f6eb[0x0],_0x28490a=_0x20c1e9[_0x4b5217(0x149)](rebuildHeaderWithoutDuration,_0x438a6b[_0x4b5217(0x179)]),_0x312dce=[_0x28490a];let _0x3b7cc5=0x0;for(let _0x537503=0x0;_0x20c1e9[_0x4b5217(0x140)](_0x537503,_0x42f6eb['length']);_0x537503++){const _0x1237c9=_0x42f6eb[_0x537503];for(const _0x4794df of _0x1237c9[_0x4b5217(0x160)]){const _0x425a50=_0x4794df['timestamp']+_0x3b7cc5;_0x312dce['push'](_0x20c1e9[_0x4b5217(0x14b)](buildCluster,_0x425a50,_0x4794df['bodyBeforeTimestamp'],_0x4794df[_0x4b5217(0x154)]));}const _0x291983=0x1e;_0x3b7cc5+=_0x20c1e9[_0x4b5217(0x178)](_0x1237c9['maxTimestampTicks'],_0x291983);}return _0x20c1e9['DKzuL'](writeFileSync,_0xbdc058,Buffer['concat'](_0x312dce)),!![];}if(process['argv'][0x1]?.[_0x1f87f1(0x145)](_0x1f87f1(0x16b))||process[_0x1f87f1(0x169)][0x1]?.['endsWith']('stitchWebmFiles.js')){const args=process[_0x1f87f1(0x169)][_0x1f87f1(0x156)](0x2);args['length']<0x3&&(console[_0x1f87f1(0x168)]('Usage:\x20stitchWebmFiles\x20<input1.webm>\x20<input2.webm>\x20[...]\x20<output.webm>'),process['exit'](0x1));const output=args[args[_0x1f87f1(0x157)]-0x1],inputs=args['slice'](0x0,-0x1),ok=stitchWebmFiles(inputs,output);ok?console['log']('Stitched\x20'+inputs['length']+_0x1f87f1(0x17d)+output):console[_0x1f87f1(0x15f)](_0x1f87f1(0x175));}
|
|
1
|
+
const _0x2518e6=_0x10c7;(function(_0x3d093a,_0x244ecb){const _0x242d8e=_0x10c7,_0x37c294=_0x3d093a();while(!![]){try{const _0x32d4a9=-parseInt(_0x242d8e(0xf6))/0x1*(-parseInt(_0x242d8e(0xbc))/0x2)+-parseInt(_0x242d8e(0xc7))/0x3*(parseInt(_0x242d8e(0xda))/0x4)+parseInt(_0x242d8e(0xdc))/0x5*(-parseInt(_0x242d8e(0xbf))/0x6)+parseInt(_0x242d8e(0xf5))/0x7*(-parseInt(_0x242d8e(0xef))/0x8)+parseInt(_0x242d8e(0xd0))/0x9*(-parseInt(_0x242d8e(0xd8))/0xa)+-parseInt(_0x242d8e(0xc6))/0xb*(-parseInt(_0x242d8e(0xe2))/0xc)+parseInt(_0x242d8e(0xbe))/0xd;if(_0x32d4a9===_0x244ecb)break;else _0x37c294['push'](_0x37c294['shift']());}catch(_0x52f40a){_0x37c294['push'](_0x37c294['shift']());}}}(_0x37b1,0xcbdd6));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(_0x6832b9,_0x184dcf){const _0x4aac6e=_0x10c7,_0x14a33d={'JDSvr':function(_0x10e548,_0x285f3d){return _0x10e548>=_0x285f3d;},'XzxyY':function(_0x2a4ad4,_0x369f25){return _0x2a4ad4&_0x369f25;},'wsoVf':function(_0x2a2f52,_0x763f37){return _0x2a2f52-_0x763f37;},'uQFCV':function(_0x5742cb,_0x5ca962){return _0x5742cb*_0x5ca962;}};if(_0x14a33d['JDSvr'](_0x184dcf,_0x6832b9[_0x4aac6e(0xee)]))return[0x0,0x0];const _0x585276=_0x6832b9[_0x184dcf];let _0x5e79db=0x1,_0x48a2bf=0x80;while(_0x5e79db<=0x8&&!_0x14a33d['XzxyY'](_0x585276,_0x48a2bf)){_0x5e79db++,_0x48a2bf>>=0x1;}if(_0x184dcf+_0x5e79db>_0x6832b9[_0x4aac6e(0xee)])return[0x0,0x0];let _0x2f3e8b=_0x585276&_0x14a33d[_0x4aac6e(0xc3)](_0x48a2bf,0x1);for(let _0x4d00b1=0x1;_0x4d00b1<_0x5e79db;_0x4d00b1++){_0x2f3e8b=_0x14a33d['uQFCV'](_0x2f3e8b,0x100)+_0x6832b9[_0x184dcf+_0x4d00b1];}return[_0x2f3e8b,_0x5e79db];}function readId(_0x519209,_0x247496){const _0x279eb5=_0x10c7,_0x57f236={'JbAxC':function(_0x152093,_0x32c58f){return _0x152093>=_0x32c58f;},'tDhWD':function(_0x2fab14,_0x80c980){return _0x2fab14>=_0x80c980;},'LFagx':function(_0x576234,_0x1754e9){return _0x576234+_0x1754e9;},'XpOjd':function(_0x16343c,_0x2b3392){return _0x16343c<_0x2b3392;}};if(_0x57f236[_0x279eb5(0xfe)](_0x247496,_0x519209[_0x279eb5(0xee)]))return[0x0,0x0];const _0x31b4c9=_0x519209[_0x247496];let _0x7a2ff7;if(_0x31b4c9>=0x80)_0x7a2ff7=0x1;else{if(_0x57f236['JbAxC'](_0x31b4c9,0x40))_0x7a2ff7=0x2;else{if(_0x31b4c9>=0x20)_0x7a2ff7=0x3;else{if(_0x57f236[_0x279eb5(0xd3)](_0x31b4c9,0x10))_0x7a2ff7=0x4;else return[_0x31b4c9,0x1];}}}if(_0x57f236['LFagx'](_0x247496,_0x7a2ff7)>_0x519209['length'])return[0x0,0x0];let _0x3f13e6=0x0;for(let _0x2771bd=0x0;_0x57f236[_0x279eb5(0xc0)](_0x2771bd,_0x7a2ff7);_0x2771bd++){_0x3f13e6=_0x3f13e6*0x100+_0x519209[_0x247496+_0x2771bd];}return[_0x3f13e6,_0x7a2ff7];}function readUint(_0x9b202b,_0x3d4ffe,_0x3abf92){const _0x16cd22={'OtZrP':function(_0x5c0085,_0x2d3c58){return _0x5c0085+_0x2d3c58;},'zMUxN':function(_0x40747f,_0xc98f93){return _0x40747f+_0xc98f93;}};let _0x4f14fe=0x0;for(let _0x1efe9b=0x0;_0x1efe9b<_0x3abf92;_0x1efe9b++){_0x4f14fe=_0x16cd22['OtZrP'](_0x4f14fe*0x100,_0x9b202b[_0x16cd22['zMUxN'](_0x3d4ffe,_0x1efe9b)]);}return _0x4f14fe;}function isUnknownSize(_0x5e9db3,_0x2d24a2){const _0x35c89e=_0x10c7,_0x3f00d1={'SqRnp':function(_0x21a7c4,_0xe877e9){return _0x21a7c4===_0xe877e9;},'kMODT':function(_0x230d15,_0x543837){return _0x230d15-_0x543837;}};return _0x3f00d1['SqRnp'](_0x5e9db3,_0x3f00d1[_0x35c89e(0xe0)](Math[_0x35c89e(0xe9)](0x2,0x7*_0x2d24a2),0x1));}function _0x37b1(){const _0x2118e5=['sQHGp','ycvAs','QYCVR','from','fNxgX','max','mHmfA','min','31966rlhghR','vsZVM','27496794MzMCWW','114KNYRjL','XpOjd','yqGeo','floor','wsoVf','FzjmC','has','6882689UbzvxP','1581GYBwtu','YDFum','Igtjf','bNCbq','OLFyl','\x20files\x20->\x20','XOapx','log','sRNjZ','9OHqjTo','stitchWebmFiles.js','ceQEg','tDhWD','ZoCVo','stitchWebmFiles.ts','argv','slice','3903880kxNvhp','endsWith','5132sOekLl','zidKS','363395ehMYYF','YqKva','XhbMa','QGJna','kMODT','POMQB','12HtAcZF','fZOWO','EgJVK','fgaak','qfYce','WLhOC','concat','pow','aNBiz','bodyAfterTimestamp','qTEfC','SQmCO','length','344aHsUUu','push','Stitched\x20','amnES','WFSNP','Usage:\x20stitchWebmFiles\x20<input1.webm>\x20<input2.webm>\x20[...]\x20<output.webm>','153804BdYIFS','93ZtkfER','Stitching\x20failed\x20or\x20only\x20one\x20input\x20file.','alloc','oENUh','IxBxG','readInt16BE','maxTicks','JJkrC','JbAxC'];_0x37b1=function(){return _0x2118e5;};return _0x37b1();}function writeVint(_0x2ebc37,_0x1abef9){const _0x1ffb7b=_0x10c7,_0x19ca0c={'FzjmC':function(_0x11dbb4,_0x3062d5){return _0x11dbb4*_0x3062d5;},'YqKva':function(_0x2b8c2e,_0x2d11bc){return _0x2b8c2e&_0x2d11bc;},'eszbf':function(_0x3afefd,_0x409843){return _0x3afefd-_0x409843;}};let _0x152b30=_0x1abef9||0x1;while(Math[_0x1ffb7b(0xe9)](0x2,_0x19ca0c[_0x1ffb7b(0xc4)](0x7,_0x152b30))-0x2<_0x2ebc37)_0x152b30++;const _0xe5adbf=Buffer[_0x1ffb7b(0xf8)](_0x152b30);for(let _0x18986e=_0x152b30-0x1;_0x18986e>=0x0;_0x18986e--){_0xe5adbf[_0x18986e]=_0x19ca0c[_0x1ffb7b(0xdd)](_0x2ebc37,0xff),_0x2ebc37=Math['floor'](_0x2ebc37/0x100);}return _0xe5adbf[0x0]|=0x1<<_0x19ca0c['eszbf'](0x8,_0x152b30),_0xe5adbf;}function writeUint(_0x522512,_0x1489f0){const _0x3c172e=_0x10c7,_0x186867={'FwCeS':function(_0x5db706,_0x4e61e2){return _0x5db706>=_0x4e61e2;},'qfYce':function(_0x44f276,_0x222fd7){return _0x44f276&_0x222fd7;}},_0x16dd17=Buffer['alloc'](_0x1489f0);for(let _0x6c4daf=_0x1489f0-0x1;_0x186867['FwCeS'](_0x6c4daf,0x0);_0x6c4daf--){_0x16dd17[_0x6c4daf]=_0x186867[_0x3c172e(0xe6)](_0x522512,0xff),_0x522512=Math[_0x3c172e(0xc2)](_0x522512/0x100);}return _0x16dd17;}function writeUnknownSizeVint(_0xc0d92d){const _0x2801cb=_0x10c7,_0x481d53={'fkCjS':function(_0x1f5ebf,_0x57d4ff){return _0x1f5ebf-_0x57d4ff;}},_0x14c0bb=Buffer[_0x2801cb(0xf8)](_0xc0d92d,0xff);return _0x14c0bb[0x0]=0xff>>_0x481d53['fkCjS'](_0xc0d92d,0x1),_0x14c0bb;}function uintSize(_0x2cb1e9){const _0x40a871=_0x10c7,_0x4d9f0a={'IojVi':function(_0x3a6dd9,_0x4f7658){return _0x3a6dd9>_0x4f7658;},'RADCH':function(_0x140799,_0x24b416){return _0x140799/_0x24b416;}};if(_0x2cb1e9===0x0)return 0x1;let _0x2c0675=0x0,_0x11fdce=_0x2cb1e9;while(_0x4d9f0a['IojVi'](_0x11fdce,0x0)){_0x2c0675++,_0x11fdce=Math[_0x40a871(0xc2)](_0x4d9f0a['RADCH'](_0x11fdce,0x100));}return _0x2c0675;}function findTimestampScale(_0x176cd9,_0xe3d1b2){const _0xe0309e=_0x10c7,_0x14a947={'SQmCO':function(_0x563ab9,_0x9762d){return _0x563ab9<_0x9762d;},'sQHGp':function(_0x539516,_0x208fe9,_0x47a5d0){return _0x539516(_0x208fe9,_0x47a5d0);},'qTEfC':function(_0x55514a,_0x38540f){return _0x55514a+_0x38540f;},'amnES':function(_0x27abe2,_0xf24eee){return _0x27abe2+_0xf24eee;},'jsCgC':function(_0x110a81,_0x7bd16c){return _0x110a81===_0x7bd16c;},'bzulG':function(_0x4f847e,_0x1b18ee,_0x4464f3,_0x32b680){return _0x4f847e(_0x1b18ee,_0x4464f3,_0x32b680);},'MiZyF':function(_0x1843db,_0x5d1962){return _0x1843db+_0x5d1962;},'fNxgX':function(_0x24b7d5,_0x3c0e01){return _0x24b7d5===_0x3c0e01;}};let _0x3515b2=_0xe3d1b2;const _0x20719e=Math[_0xe0309e(0xbb)](_0x176cd9[_0xe0309e(0xee)],_0xe3d1b2+0x2710);while(_0x14a947[_0xe0309e(0xed)](_0x3515b2,_0x20719e)){const [_0x527f3a,_0x2f7c3c]=readId(_0x176cd9,_0x3515b2),[_0x2ebdbd,_0x2a4baa]=_0x14a947['sQHGp'](readVint,_0x176cd9,_0x3515b2+_0x2f7c3c);if(_0x527f3a===ID_INFO){let _0x45f6b4=_0x14a947['qTEfC'](_0x14a947[_0xe0309e(0xf2)](_0x3515b2,_0x2f7c3c),_0x2a4baa);const _0x1f8532=_0x45f6b4+_0x2ebdbd;while(_0x45f6b4<_0x1f8532){const [_0x547710,_0xc84345]=readId(_0x176cd9,_0x45f6b4),[_0x1bb2bc,_0x2eb640]=_0x14a947[_0xe0309e(0xb4)](readVint,_0x176cd9,_0x45f6b4+_0xc84345);if(_0x14a947['jsCgC'](_0x547710,ID_TIMESTAMP_SCALE))return _0x14a947['bzulG'](readUint,_0x176cd9,_0x14a947['MiZyF'](_0x14a947[_0xe0309e(0xec)](_0x45f6b4,_0xc84345),_0x2eb640),_0x1bb2bc);_0x45f6b4+=_0x14a947['amnES'](_0xc84345+_0x2eb640,_0x1bb2bc);}break;}if(_0x14a947[_0xe0309e(0xb8)](_0x527f3a,ID_CLUSTER))break;if(_0x14a947['sQHGp'](isUnknownSize,_0x2ebdbd,_0x2a4baa))break;_0x3515b2+=_0x14a947['amnES'](_0x2f7c3c,_0x2a4baa)+_0x2ebdbd;}return 0xf4240;}function _0x10c7(_0x2b7128,_0x4f8d36){_0x2b7128=_0x2b7128-0xb4;const _0x37b1c8=_0x37b1();let _0x10c7e4=_0x37b1c8[_0x2b7128];return _0x10c7e4;}function findFirstClusterOffset(_0x4e92df,_0x9eeb07){const _0x456bf8=_0x10c7,_0x4bf2b5={'oENUh':function(_0x50f235,_0x357447,_0x34c16e){return _0x50f235(_0x357447,_0x34c16e);},'MqLSk':function(_0x1a2a66,_0x285acc){return _0x1a2a66===_0x285acc;},'YDFum':function(_0x4fc34e,_0x232433,_0x3370bc){return _0x4fc34e(_0x232433,_0x3370bc);},'mHmfA':function(_0x5bd3e6,_0x5becef){return _0x5bd3e6+_0x5becef;},'ZNqFP':function(_0x2c5646,_0x3c9a8e,_0x569dbf){return _0x2c5646(_0x3c9a8e,_0x569dbf);},'VCsdt':function(_0x4793e6,_0x109448){return _0x4793e6+_0x109448;}};let _0x4eb97a=_0x9eeb07;while(_0x4eb97a<_0x4e92df['length']){const [_0x1ceb5e,_0x4d5f36]=_0x4bf2b5[_0x456bf8(0xf9)](readId,_0x4e92df,_0x4eb97a);if(_0x4bf2b5['MqLSk'](_0x1ceb5e,ID_CLUSTER))return _0x4eb97a;const [_0x1a8fb0,_0x581e7d]=_0x4bf2b5[_0x456bf8(0xc8)](readVint,_0x4e92df,_0x4bf2b5[_0x456bf8(0xba)](_0x4eb97a,_0x4d5f36));if(_0x4bf2b5['ZNqFP'](isUnknownSize,_0x1a8fb0,_0x581e7d))return _0x4eb97a;_0x4eb97a+=_0x4bf2b5['VCsdt'](_0x4d5f36+_0x581e7d,_0x1a8fb0);}return _0x4e92df[_0x456bf8(0xee)];}function findClusterEnd(_0x1aed29,_0x2b1343,_0x209eaa,_0x1ec806){const _0x34e2cf=_0x10c7,_0x3b8668={'ZoCVo':function(_0xd00c3a,_0x239e76,_0x4f733d){return _0xd00c3a(_0x239e76,_0x4f733d);},'sRNjZ':function(_0x4024d6,_0x540c6b){return _0x4024d6+_0x540c6b;},'zidKS':function(_0x4cd41c,_0x55d626){return _0x4cd41c-_0x55d626;}};if(!_0x3b8668[_0x34e2cf(0xd4)](isUnknownSize,_0x209eaa,_0x1ec806))return _0x3b8668['sRNjZ'](_0x2b1343,_0x209eaa);const _0x2c84b0=new Set([ID_CLUSTER,0x1c53bb6b,0x1254c367]);let _0x27c7cb=_0x2b1343;while(_0x27c7cb<_0x3b8668[_0x34e2cf(0xdb)](_0x1aed29['length'],0x4)){const [_0x3c1943,_0x51172b]=readId(_0x1aed29,_0x27c7cb);if(_0x2c84b0[_0x34e2cf(0xc5)](_0x3c1943))return _0x27c7cb;const [_0xbc9cfb,_0x214140]=readVint(_0x1aed29,_0x3b8668[_0x34e2cf(0xcf)](_0x27c7cb,_0x51172b));if(isUnknownSize(_0xbc9cfb,_0x214140))return _0x1aed29[_0x34e2cf(0xee)];_0x27c7cb+=_0x3b8668[_0x34e2cf(0xcf)](_0x51172b+_0x214140,_0xbc9cfb);}return _0x1aed29[_0x34e2cf(0xee)];}function extractClusters(_0x5c3fa3,_0x149c21){const _0xb1b7c4=_0x10c7,_0x2e6816={'WLhOC':function(_0x3ac03b,_0x9931ca,_0x52ed16){return _0x3ac03b(_0x9931ca,_0x52ed16);},'OLFyl':function(_0xc323ee,_0x1d5be8){return _0xc323ee+_0x1d5be8;},'QYCVR':function(_0x459b3e,_0x43f311){return _0x459b3e<_0x43f311;},'Rrmgu':function(_0x3e83d0,_0x39b0aa){return _0x3e83d0===_0x39b0aa;},'jQQwi':function(_0x5e5e98,_0x580b25){return _0x5e5e98===_0x580b25;},'wPDOq':function(_0x54a165,_0x4fd109,_0x3a025c){return _0x54a165(_0x4fd109,_0x3a025c);},'brYno':function(_0x481f47,_0x383705){return _0x481f47+_0x383705;},'WFSNP':function(_0x5d0606,_0x1d2b49){return _0x5d0606>=_0x1d2b49;},'Igtjf':function(_0x581163,_0x2a4487){return _0x581163+_0x2a4487;},'ojTBS':function(_0x268358,_0x2daaed){return _0x268358+_0x2daaed;},'vsZVM':function(_0x32e29a,_0x3d6715){return _0x32e29a+_0x3d6715;},'bNCbq':function(_0x3c783c,_0x19e2d8){return _0x3c783c>_0x19e2d8;}},_0x292dba=[],_0x889650=Buffer[_0xb1b7c4(0xb7)]([0x1f,0x43,0xb6,0x75]);let _0x306ad3=0x0;while(_0x306ad3<_0x5c3fa3['length']){const _0x2b96fd=_0x5c3fa3['indexOf'](_0x889650,_0x306ad3);if(_0x2b96fd===-0x1)break;const [_0x4e8bb3,_0x9b305a]=_0x2e6816['WLhOC'](readId,_0x5c3fa3,_0x2b96fd);if(_0x4e8bb3!==ID_CLUSTER){_0x306ad3=_0x2e6816[_0xb1b7c4(0xcb)](_0x2b96fd,0x1);continue;}const [_0x4ca68b,_0x233bf5]=readVint(_0x5c3fa3,_0x2e6816[_0xb1b7c4(0xcb)](_0x2b96fd,_0x9b305a)),_0x3675ce=_0x2e6816['OLFyl'](_0x2e6816[_0xb1b7c4(0xcb)](_0x2b96fd,_0x9b305a),_0x233bf5),_0x284459=findClusterEnd(_0x5c3fa3,_0x3675ce,_0x4ca68b,_0x233bf5);let _0x1417b1=_0x3675ce,_0x3f33fa=0x0,_0x33ca08=0x2,_0x34733e=![],_0x2b72ce=Buffer[_0xb1b7c4(0xf8)](0x0),_0x21191d=Buffer['alloc'](0x0);while(_0x2e6816[_0xb1b7c4(0xb6)](_0x1417b1,_0x284459)){const [_0x13b7f4,_0x68753c]=_0x2e6816[_0xb1b7c4(0xe7)](readId,_0x5c3fa3,_0x1417b1),[_0x558f1b,_0x4bd5ed]=readVint(_0x5c3fa3,_0x1417b1+_0x68753c);if(_0x2e6816['Rrmgu'](_0x13b7f4,ID_TIMESTAMP)){_0x3f33fa=readUint(_0x5c3fa3,_0x2e6816[_0xb1b7c4(0xcb)](_0x1417b1+_0x68753c,_0x4bd5ed),_0x558f1b),_0x33ca08=_0x558f1b,_0x34733e=!![],_0x2b72ce=_0x5c3fa3['slice'](_0x3675ce,_0x1417b1);const _0x5a6769=_0x1417b1+_0x68753c+_0x4bd5ed+_0x558f1b;_0x21191d=_0x5c3fa3['slice'](_0x5a6769,_0x284459);break;}if(_0x2e6816['jQQwi'](_0x13b7f4,ID_CLUSTER))break;if(_0x2e6816['wPDOq'](isUnknownSize,_0x558f1b,_0x4bd5ed))break;_0x1417b1+=_0x68753c+_0x4bd5ed+_0x558f1b;}!_0x34733e&&(_0x21191d=_0x5c3fa3['slice'](_0x3675ce,_0x284459));let _0x5de14b=_0x3f33fa;_0x1417b1=_0x3675ce;while(_0x2e6816['QYCVR'](_0x1417b1,_0x284459)){const [_0x312604,_0x3e7f96]=_0x2e6816[_0xb1b7c4(0xe7)](readId,_0x5c3fa3,_0x1417b1),[_0xbe3efa,_0x2d55de]=readVint(_0x5c3fa3,_0x2e6816['brYno'](_0x1417b1,_0x3e7f96));if(_0x312604===ID_SIMPLE_BLOCK&&_0x2e6816[_0xb1b7c4(0xf3)](_0xbe3efa,0x4)){const _0x4174bf=_0x2e6816['Igtjf'](_0x2e6816['ojTBS'](_0x1417b1,_0x3e7f96),_0x2d55de),[,_0x37682f]=readVint(_0x5c3fa3,_0x4174bf),_0x3b7558=_0x5c3fa3[_0xb1b7c4(0xfb)](_0x2e6816['ojTBS'](_0x4174bf,_0x37682f)),_0x4cecf6=_0x2e6816[_0xb1b7c4(0xbd)](_0x3f33fa,_0x3b7558);if(_0x2e6816[_0xb1b7c4(0xca)](_0x4cecf6,_0x5de14b))_0x5de14b=_0x4cecf6;}if(_0x312604===ID_CLUSTER)break;if(isUnknownSize(_0xbe3efa,_0x2d55de))break;_0x1417b1+=_0x2e6816[_0xb1b7c4(0xc9)](_0x3e7f96+_0x2d55de,_0xbe3efa);}_0x292dba['push']({'timestamp':_0x3f33fa,'maxTicks':_0x5de14b,'bodyBeforeTimestamp':_0x2b72ce,'bodyAfterTimestamp':_0x21191d,'timestampElementSize':_0x33ca08}),_0x306ad3=_0x284459;}return _0x292dba;}function parseWebm(_0x11e4b5){const _0x2c9bea=_0x10c7,_0x3e4422={'JJkrC':function(_0x1f8fec,_0xb39c05,_0x3f7f99){return _0x1f8fec(_0xb39c05,_0x3f7f99);},'wmjki':function(_0x175b7d,_0x15e6bb){return _0x175b7d+_0x15e6bb;},'opXpd':function(_0x423772,_0x1281b5){return _0x423772+_0x1281b5;},'fZOWO':function(_0x14421a,_0x279ce4){return _0x14421a+_0x279ce4;},'XOapx':function(_0x143f7f,_0x5705f5,_0x1da7c3){return _0x143f7f(_0x5705f5,_0x1da7c3);},'aNBiz':function(_0x18dd34,_0xd0348a){return _0x18dd34+_0xd0348a;},'sVXEe':function(_0x556cbc,_0x4f72fa,_0xfabf4){return _0x556cbc(_0x4f72fa,_0xfabf4);},'ETuOu':function(_0x479bde,_0x5e6a79,_0x462d97){return _0x479bde(_0x5e6a79,_0x462d97);}};let _0x34ec4f=0x0;const [,_0x41c3b0]=_0x3e4422[_0x2c9bea(0xfd)](readId,_0x11e4b5,_0x34ec4f),[_0x8a2f04,_0x50658b]=_0x3e4422['JJkrC'](readVint,_0x11e4b5,_0x3e4422['wmjki'](_0x34ec4f,_0x41c3b0));_0x34ec4f+=_0x3e4422['opXpd'](_0x3e4422[_0x2c9bea(0xe3)](_0x41c3b0,_0x50658b),_0x8a2f04);const [_0x4440eb,_0x4937ea]=_0x3e4422[_0x2c9bea(0xcd)](readId,_0x11e4b5,_0x34ec4f);if(_0x4440eb!==ID_SEGMENT)return null;const [,_0x447eec]=_0x3e4422['JJkrC'](readVint,_0x11e4b5,_0x34ec4f+_0x4937ea),_0x1d7bd6=_0x3e4422[_0x2c9bea(0xea)](_0x34ec4f,_0x4937ea)+_0x447eec,_0x40409b=findTimestampScale(_0x11e4b5,_0x1d7bd6),_0x382d49=_0x3e4422['sVXEe'](findFirstClusterOffset,_0x11e4b5,_0x1d7bd6),_0x13ec64=_0x11e4b5['slice'](0x0,_0x382d49),_0x3be36f=_0x3e4422['ETuOu'](extractClusters,_0x11e4b5,_0x40409b);let _0x335f49=0x0;for(const _0x2b5f01 of _0x3be36f){if(_0x2b5f01[_0x2c9bea(0xfc)]>_0x335f49)_0x335f49=_0x2b5f01[_0x2c9bea(0xfc)];}return{'header':_0x13ec64,'clusters':_0x3be36f,'timestampScale':_0x40409b,'maxTimestampTicks':_0x335f49};}function buildCluster(_0x159f6d,_0x3bf811,_0x2a8f40){const _0x47f00e=_0x10c7,_0x215f5c={'XhbMa':function(_0x4759ab,_0x5b78be,_0x374f98){return _0x4759ab(_0x5b78be,_0x374f98);},'wPdCw':function(_0x502052,_0x3f1e29){return _0x502052(_0x3f1e29);}},_0x4a54a3=Buffer['from']([0x1f,0x43,0xb6,0x75]),_0x3b4f0d=Math[_0x47f00e(0xb9)](0x4,uintSize(_0x159f6d)),_0x2e1718=Buffer[_0x47f00e(0xe8)]([Buffer['from']([ID_TIMESTAMP]),writeVint(_0x3b4f0d),_0x215f5c[_0x47f00e(0xde)](writeUint,_0x159f6d,_0x3b4f0d)]),_0x52c812=Buffer['concat']([_0x3bf811,_0x2e1718,_0x2a8f40]),_0x4ea584=_0x215f5c['wPdCw'](writeVint,_0x52c812['length']);return Buffer[_0x47f00e(0xe8)]([_0x4a54a3,_0x4ea584,_0x52c812]);}const ID_DURATION=0x4489;function rebuildHeaderWithoutDuration(_0x2279c4){const _0x3cf20d=_0x10c7,_0x3d5b76={'ceQEg':function(_0x537641,_0x34e1a8,_0x425bd0){return _0x537641(_0x34e1a8,_0x425bd0);},'ycvAs':function(_0xb30b9e,_0x458549){return _0xb30b9e+_0x458549;},'POMQB':function(_0x51831c,_0x2eafef){return _0x51831c+_0x2eafef;},'iaKNN':function(_0xc2494a,_0x4f4a94){return _0xc2494a+_0x4f4a94;},'MKxpW':function(_0x58c025,_0x5a0da1){return _0x58c025(_0x5a0da1);},'URhiJ':function(_0x423980,_0x19e15f){return _0x423980+_0x19e15f;},'yqGeo':function(_0x3e60cd,_0x135e3a){return _0x3e60cd===_0x135e3a;},'fgaak':function(_0x3cf9a7,_0x26e5d1,_0x3006c8){return _0x3cf9a7(_0x26e5d1,_0x3006c8);},'QGJna':function(_0x3a56a4,_0x44b130){return _0x3a56a4+_0x44b130;},'DBZro':function(_0x1a161d,_0x3d060c){return _0x1a161d+_0x3d060c;}},_0x48bba7=Buffer[_0x3cf20d(0xb7)](_0x2279c4);let _0x35bca8=0x0;const [,_0x2aa527]=_0x3d5b76[_0x3cf20d(0xd2)](readId,_0x48bba7,_0x35bca8),[_0x31f5fc,_0x416d97]=readVint(_0x48bba7,_0x35bca8+_0x2aa527),_0xce58ef=_0x3d5b76[_0x3cf20d(0xb5)](_0x3d5b76['ycvAs'](_0x35bca8,_0x2aa527)+_0x416d97,_0x31f5fc),[,_0x4e1d10]=_0x3d5b76['ceQEg'](readId,_0x48bba7,_0xce58ef),[,_0x5d75dd]=readVint(_0x48bba7,_0x3d5b76[_0x3cf20d(0xe1)](_0xce58ef,_0x4e1d10)),_0x3a087c=_0x3d5b76['iaKNN'](_0xce58ef+_0x4e1d10,_0x5d75dd),_0x27b9f4=_0x3d5b76['MKxpW'](writeUnknownSizeVint,_0x5d75dd);_0x27b9f4['copy'](_0x48bba7,_0x3d5b76['POMQB'](_0xce58ef,_0x4e1d10));let _0x123b8e=_0x3a087c;const _0x333606=Math['min'](_0x48bba7[_0x3cf20d(0xee)],_0x3d5b76['URhiJ'](_0x3a087c,0x2710));while(_0x123b8e<_0x333606){const [_0x10cabc,_0x289911]=readId(_0x48bba7,_0x123b8e),[_0x12499d,_0x8a82f3]=readVint(_0x48bba7,_0x123b8e+_0x289911);if(_0x3d5b76[_0x3cf20d(0xc1)](_0x10cabc,ID_CLUSTER))break;if(_0x3d5b76['fgaak'](isUnknownSize,_0x12499d,_0x8a82f3))break;if(_0x10cabc===ID_INFO){const _0x2893e0=_0x3d5b76[_0x3cf20d(0xb5)](_0x123b8e+_0x289911,_0x8a82f3),_0x4d5336=_0x3d5b76[_0x3cf20d(0xe1)](_0x2893e0,_0x12499d),_0x152ec4=[];let _0x5b3c7e=_0x2893e0;while(_0x5b3c7e<_0x4d5336){const [_0x1d4261,_0x573680]=_0x3d5b76[_0x3cf20d(0xd2)](readId,_0x48bba7,_0x5b3c7e),[_0x2b8261,_0x368b8f]=readVint(_0x48bba7,_0x5b3c7e+_0x573680),_0x3c08a7=_0x3d5b76[_0x3cf20d(0xdf)](_0x573680,_0x368b8f)+_0x2b8261;_0x1d4261!==ID_DURATION&&_0x152ec4['push'](_0x48bba7[_0x3cf20d(0xd7)](_0x5b3c7e,_0x5b3c7e+_0x3c08a7)),_0x5b3c7e+=_0x3c08a7;}const _0x52711b=Buffer[_0x3cf20d(0xe8)](_0x152ec4),_0x2cb0b0=Buffer['concat']([_0x48bba7['slice'](_0x123b8e,_0x123b8e+_0x289911),_0x3d5b76[_0x3cf20d(0xe5)](writeVint,_0x52711b['length'],_0x8a82f3)]);return Buffer[_0x3cf20d(0xe8)]([_0x48bba7['slice'](0x0,_0x123b8e),_0x2cb0b0,_0x52711b,_0x48bba7[_0x3cf20d(0xd7)](_0x4d5336)]);}_0x123b8e+=_0x3d5b76['DBZro'](_0x289911+_0x8a82f3,_0x12499d);}return _0x48bba7;}export function stitchWebmFiles(_0x473e93,_0x5ee460){const _0x48eebc=_0x10c7,_0x2c82cc={'IxBxG':function(_0x3bc874,_0x46b886){return _0x3bc874(_0x46b886);},'EgJVK':function(_0x144838,_0x1a469b){return _0x144838(_0x1a469b);},'LtYIQ':function(_0x3daaa2,_0x1b3d97){return _0x3daaa2===_0x1b3d97;},'WakVk':function(_0x4e1aa5,_0x2ef005){return _0x4e1aa5<_0x2ef005;},'lRAPx':function(_0x332154,_0x186ffa){return _0x332154+_0x186ffa;},'ENnxC':function(_0x291e7a,_0x4cec0f,_0x194e7f){return _0x291e7a(_0x4cec0f,_0x194e7f);}};if(_0x473e93['length']<=0x1)return![];const _0x53f496=[];for(const _0x40a8b9 of _0x473e93){const _0x36d886=_0x2c82cc[_0x48eebc(0xfa)](readFileSync,_0x40a8b9),_0x388531=_0x2c82cc['EgJVK'](parseWebm,_0x36d886);if(!_0x388531||_0x2c82cc['LtYIQ'](_0x388531['clusters']['length'],0x0))return![];_0x53f496['push'](_0x388531);}const _0x4ff3e7=_0x53f496[0x0],_0x413f7e=_0x2c82cc[_0x48eebc(0xe4)](rebuildHeaderWithoutDuration,_0x4ff3e7['header']),_0xdc62c8=[_0x413f7e];let _0x251763=0x0;for(let _0x146913=0x0;_0x2c82cc['WakVk'](_0x146913,_0x53f496[_0x48eebc(0xee)]);_0x146913++){const _0x22cd68=_0x53f496[_0x146913];for(const _0x18fec2 of _0x22cd68['clusters']){const _0x1a7b97=_0x2c82cc['lRAPx'](_0x18fec2['timestamp'],_0x251763);_0xdc62c8[_0x48eebc(0xf0)](buildCluster(_0x1a7b97,_0x18fec2['bodyBeforeTimestamp'],_0x18fec2[_0x48eebc(0xeb)]));}const _0x236f92=0x1e;_0x251763+=_0x2c82cc['lRAPx'](_0x22cd68['maxTimestampTicks'],_0x236f92);}return _0x2c82cc['ENnxC'](writeFileSync,_0x5ee460,Buffer[_0x48eebc(0xe8)](_0xdc62c8)),!![];}if(process['argv'][0x1]?.['endsWith'](_0x2518e6(0xd5))||process[_0x2518e6(0xd6)][0x1]?.[_0x2518e6(0xd9)](_0x2518e6(0xd1))){const args=process[_0x2518e6(0xd6)]['slice'](0x2);args[_0x2518e6(0xee)]<0x3&&(console['error'](_0x2518e6(0xf4)),process['exit'](0x1));const output=args[args['length']-0x1],inputs=args[_0x2518e6(0xd7)](0x0,-0x1),ok=stitchWebmFiles(inputs,output);ok?console[_0x2518e6(0xce)](_0x2518e6(0xf1)+inputs[_0x2518e6(0xee)]+_0x2518e6(0xcc)+output):console['log'](_0x2518e6(0xf7));}
|