@ranger-testing/ranger-cli 2.5.4-alpha.a70fc60-4 → 2.5.4-alpha.bc88254-5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (79) hide show
  1. package/build/cli.js +1 -1
  2. package/build/commands/addEnv.js +1 -1
  3. package/build/commands/authEncrypt.js +1 -1
  4. package/build/commands/clean.js +1 -1
  5. package/build/commands/config.js +1 -1
  6. package/build/commands/env.js +1 -1
  7. package/build/commands/feature.js +1 -1
  8. package/build/commands/hook.js +1 -1
  9. package/build/commands/hooks/autoPrompt.js +1 -1
  10. package/build/commands/hooks/disable.js +1 -1
  11. package/build/commands/hooks/enable.js +1 -1
  12. package/build/commands/hooks/exitPlanMode.js +1 -1
  13. package/build/commands/hooks/index.js +1 -1
  14. package/build/commands/hooks/output.js +1 -1
  15. package/build/commands/hooks/planReminder.js +1 -1
  16. package/build/commands/hooks/planStart.js +1 -1
  17. package/build/commands/hooks/postEdit.js +1 -1
  18. package/build/commands/hooks/preCompact.js +1 -1
  19. package/build/commands/hooks/sessionEnd.js +1 -1
  20. package/build/commands/hooks/sessionStart.js +1 -1
  21. package/build/commands/hooks/stopHook.js +1 -1
  22. package/build/commands/index.js +1 -1
  23. package/build/commands/login.js +1 -1
  24. package/build/commands/mcpBootstrap.js +1 -1
  25. package/build/commands/migrateProfile.js +1 -1
  26. package/build/commands/setup/claude.js +1 -1
  27. package/build/commands/setup/opencode.js +1 -1
  28. package/build/commands/setupCi.js +1 -1
  29. package/build/commands/skillup.js +1 -1
  30. package/build/commands/start.js +1 -1
  31. package/build/commands/status.js +1 -1
  32. package/build/commands/update.js +1 -1
  33. package/build/commands/updateEnv.js +1 -1
  34. package/build/commands/useEnv.js +1 -1
  35. package/build/commands/utils/activeProfile.js +1 -1
  36. package/build/commands/utils/agentEnv.js +1 -1
  37. package/build/commands/utils/browserSessionsApi.js +1 -1
  38. package/build/commands/utils/claudeConfig.js +1 -1
  39. package/build/commands/utils/claudeOverrideSettings.js +1 -1
  40. package/build/commands/utils/claudePlugin.js +1 -1
  41. package/build/commands/utils/cloudProfile.js +1 -1
  42. package/build/commands/utils/cloudProfileSession.js +1 -1
  43. package/build/commands/utils/crypto.js +1 -1
  44. package/build/commands/utils/desirePathLog.js +1 -1
  45. package/build/commands/utils/deviceAuth.js +1 -1
  46. package/build/commands/utils/environment.js +1 -1
  47. package/build/commands/utils/featureApi.js +1 -1
  48. package/build/commands/utils/fixWebmDuration.js +1 -1
  49. package/build/commands/utils/gitTracked.js +1 -1
  50. package/build/commands/utils/keychain.js +1 -1
  51. package/build/commands/utils/localAgentInstallationsApi.js +1 -1
  52. package/build/commands/utils/matchAuthEnvironment.js +1 -1
  53. package/build/commands/utils/mcpImageBase64.js +1 -1
  54. package/build/commands/utils/model.js +1 -1
  55. package/build/commands/utils/opencodeConfig.js +1 -1
  56. package/build/commands/utils/playwrightCli.js +1 -1
  57. package/build/commands/utils/profileMessages.js +1 -1
  58. package/build/commands/utils/profileSetupBanner.js +1 -1
  59. package/build/commands/utils/projectsConfig.js +1 -1
  60. package/build/commands/utils/rangerConfig.js +1 -1
  61. package/build/commands/utils/rangerRoot.js +1 -1
  62. package/build/commands/utils/resolveProfileContext.js +1 -1
  63. package/build/commands/utils/resolveProfileUrl.js +1 -1
  64. package/build/commands/utils/retry.js +1 -1
  65. package/build/commands/utils/sessionCache.js +1 -1
  66. package/build/commands/utils/settings.js +1 -1
  67. package/build/commands/utils/skillContent.js +1 -1
  68. package/build/commands/utils/skills.js +1 -1
  69. package/build/commands/utils/stitchWebmFiles.js +1 -1
  70. package/build/commands/utils/telemetry.js +1 -1
  71. package/build/commands/utils/tokenRefresh.js +1 -1
  72. package/build/commands/utils/traceSnapshotMapper.js +1 -1
  73. package/build/commands/utils/userApi.js +1 -1
  74. package/build/commands/utils/version.js +1 -1
  75. package/build/commands/verifyFeature.js +1 -1
  76. package/build/commands/verifyFeatureCli.js +1 -1
  77. package/build/skills/ranger/SKILL.md +4 -3
  78. package/build/skills/ranger/verify.md +15 -3
  79. package/package.json +1 -1
@@ -1 +1 @@
1
- (function(_0x56f158,_0x189f31){const _0x25980b=_0x45b7,_0x1b3967=_0x56f158();while(!![]){try{const _0x10d60b=-parseInt(_0x25980b(0x90))/0x1*(parseInt(_0x25980b(0xa1))/0x2)+-parseInt(_0x25980b(0x92))/0x3+-parseInt(_0x25980b(0x9f))/0x4+parseInt(_0x25980b(0x93))/0x5*(parseInt(_0x25980b(0x9c))/0x6)+parseInt(_0x25980b(0xa0))/0x7*(-parseInt(_0x25980b(0x9e))/0x8)+-parseInt(_0x25980b(0x8b))/0x9*(-parseInt(_0x25980b(0x8e))/0xa)+parseInt(_0x25980b(0x95))/0xb*(parseInt(_0x25980b(0x8a))/0xc);if(_0x10d60b===_0x189f31)break;else _0x1b3967['push'](_0x1b3967['shift']());}catch(_0x3699d1){_0x1b3967['push'](_0x1b3967['shift']());}}}(_0x2444,0xf420c));function firstDefined(..._0x1d2131){const _0x333c0f=_0x45b7,_0x5d1445={'hYxOg':function(_0x29f9a5,_0x2ff9f2){return _0x29f9a5!==_0x2ff9f2;}};for(const _0x57e1fe of _0x1d2131){if(_0x57e1fe!==undefined&&_0x57e1fe!==null&&_0x5d1445[_0x333c0f(0x9d)](_0x57e1fe,''))return _0x57e1fe;}return undefined;}function normalizeAuthEnvironmentDomain(_0x5e1f25){if(!_0x5e1f25)return undefined;if(/^[a-z][a-z0-9+.-]*:\/\//i['test'](_0x5e1f25))return _0x5e1f25;return'https://'+_0x5e1f25;}function _0x2444(){const _0x4dc027=['string','5438847EsnJQp','1127755hgcnUN','slice','11RhNnNY','xGlqA','KxyoD','envBaseUrl','localSettingsBaseUrl','startPath','cloudSettings','18VOawmN','hYxOg','1437496PcfnAq','6054632VFGBfb','35Eeiptu','172374ZOQThx','projectOverrides','59869416cpTPDt','27hqzpoJ','UtKPi','startsWith','1978210zgCyGr','RANGER_START_PATH','12tOSQZi'];_0x2444=function(){return _0x4dc027;};return _0x2444();}export function resolveBaseUrl(_0x507ec6){const _0x4b4ddd=_0x45b7,_0x459a2e={'wuYBr':function(_0x30a7fa,_0x55e85a,_0x4d8657,_0x5c0c6c,_0x86d6dd,_0x2dd15a,_0x366925){return _0x30a7fa(_0x55e85a,_0x4d8657,_0x5c0c6c,_0x86d6dd,_0x2dd15a,_0x366925);},'UtKPi':'string'},_0x2d91d4=_0x507ec6['projectOverrides']?.['baseUrl'];return _0x459a2e['wuYBr'](firstDefined,_0x507ec6['flagBaseUrl'],_0x507ec6[_0x4b4ddd(0x98)],_0x507ec6[_0x4b4ddd(0x99)],typeof _0x2d91d4===_0x459a2e[_0x4b4ddd(0x8c)]?_0x2d91d4:undefined,_0x507ec6[_0x4b4ddd(0x9b)]?.['baseUrl'],normalizeAuthEnvironmentDomain(_0x507ec6['authEnvironmentDomain']));}export function resolveStartPath(_0x5f2928){const _0x3a56e7=_0x45b7,_0x223737=_0x5f2928[_0x3a56e7(0x89)]?.[_0x3a56e7(0x9a)];return firstDefined(_0x5f2928['flagStartPath'],_0x5f2928['envStartPath'],typeof _0x223737===_0x3a56e7(0x91)?_0x223737:undefined,_0x5f2928[_0x3a56e7(0x9b)]?.[_0x3a56e7(0x9a)]);}export function joinBaseAndPath(_0x19e89f,_0x3809c7){const _0x16234f=_0x45b7,_0x1a0dc9={'xGlqA':function(_0x1d8a6d,_0x74e690){return _0x1d8a6d+_0x74e690;},'KxyoD':function(_0x1c98e4,_0x1080d4){return _0x1c98e4+_0x1080d4;}};if(!_0x19e89f)return undefined;if(!_0x3809c7)return _0x19e89f;const _0x27b749=_0x19e89f['endsWith']('/')?_0x19e89f[_0x16234f(0x94)](0x0,-0x1):_0x19e89f,_0x16b6a0=_0x3809c7[_0x16234f(0x8d)]('/')?_0x3809c7:_0x1a0dc9[_0x16234f(0x96)]('/',_0x3809c7);return _0x1a0dc9[_0x16234f(0x97)](_0x27b749,_0x16b6a0);}function _0x45b7(_0x3d7c1d,_0xdcfd55){_0x3d7c1d=_0x3d7c1d-0x89;const _0x2444c6=_0x2444();let _0x45b71b=_0x2444c6[_0x3d7c1d];return _0x45b71b;}export function resolveProfileUrl(_0x227467){const _0x593d1a=resolveBaseUrl(_0x227467),_0xa90daa=resolveStartPath(_0x227467);return{'baseUrl':_0x593d1a,'startPath':_0xa90daa,'url':joinBaseAndPath(_0x593d1a,_0xa90daa)};}export function readUrlEnvVars(_0xdfc388=process['env']){const _0x24550f=_0x45b7;return{'envBaseUrl':_0xdfc388['RANGER_BASE_URL'],'envStartPath':_0xdfc388[_0x24550f(0x8f)]};}
1
+ const _0x27b674=_0x343f;function _0x343f(_0x5c910e,_0x5be18d){_0x5c910e=_0x5c910e-0xcc;const _0x52c5d1=_0x52c5();let _0x343f87=_0x52c5d1[_0x5c910e];return _0x343f87;}(function(_0x4ad446,_0x4fcca6){const _0x5ce56f=_0x343f,_0x4f13a3=_0x4ad446();while(!![]){try{const _0x3b9a16=-parseInt(_0x5ce56f(0xe3))/0x1+-parseInt(_0x5ce56f(0xdb))/0x2+parseInt(_0x5ce56f(0xde))/0x3+-parseInt(_0x5ce56f(0xd6))/0x4*(parseInt(_0x5ce56f(0xdf))/0x5)+parseInt(_0x5ce56f(0xdc))/0x6*(-parseInt(_0x5ce56f(0xd5))/0x7)+parseInt(_0x5ce56f(0xcd))/0x8*(parseInt(_0x5ce56f(0xe0))/0x9)+-parseInt(_0x5ce56f(0xd7))/0xa*(-parseInt(_0x5ce56f(0xcc))/0xb);if(_0x3b9a16===_0x4fcca6)break;else _0x4f13a3['push'](_0x4f13a3['shift']());}catch(_0x285060){_0x4f13a3['push'](_0x4f13a3['shift']());}}}(_0x52c5,0x2f420));function firstDefined(..._0x4741a3){const _0x47474f={'fEFxJ':function(_0xafeac6,_0x4d10b5){return _0xafeac6!==_0x4d10b5;},'lqbtJ':function(_0x8705a0,_0x5f13c2){return _0x8705a0!==_0x5f13c2;}};for(const _0x4c253b of _0x4741a3){if(_0x47474f['fEFxJ'](_0x4c253b,undefined)&&_0x47474f['lqbtJ'](_0x4c253b,null)&&_0x4c253b!=='')return _0x4c253b;}return undefined;}function normalizeAuthEnvironmentDomain(_0x23f9be){const _0x279315=_0x343f;if(!_0x23f9be)return undefined;if(/^[a-z][a-z0-9+.-]*:\/\//i[_0x279315(0xda)](_0x23f9be))return _0x23f9be;return'https://'+_0x23f9be;}export function resolveBaseUrl(_0x77f40d){const _0x32bb1c=_0x343f,_0x4cac83={'YRTdt':function(_0x1c3050,_0x16da0c){return _0x1c3050===_0x16da0c;},'cXPdZ':'string'},_0x2b0b2=_0x77f40d['projectOverrides']?.[_0x32bb1c(0xe4)],_0x3c5eba=_0x2b0b2!==null;return firstDefined(_0x77f40d[_0x32bb1c(0xd1)],_0x77f40d[_0x32bb1c(0xe2)],_0x77f40d[_0x32bb1c(0xd0)],_0x4cac83[_0x32bb1c(0xcf)](typeof _0x2b0b2,_0x4cac83['cXPdZ'])?_0x2b0b2:undefined,_0x3c5eba?_0x77f40d[_0x32bb1c(0xe1)]?.['baseUrl']:undefined,_0x3c5eba?normalizeAuthEnvironmentDomain(_0x77f40d['authEnvironmentDomain']):undefined);}export function resolveStartPath(_0x3c749a){const _0x197af5=_0x343f,_0x365e5c={'ewcVN':function(_0x1817ff,_0x41fb34){return _0x1817ff!==_0x41fb34;},'SALqh':function(_0x13bac7,_0x26160c,_0xd44ca7,_0xbaa51f,_0x1556e8){return _0x13bac7(_0x26160c,_0xd44ca7,_0xbaa51f,_0x1556e8);}},_0x35e6bb=_0x3c749a[_0x197af5(0xdd)]?.['startPath'],_0x13abf4=_0x365e5c['ewcVN'](_0x35e6bb,null);return _0x365e5c[_0x197af5(0xd4)](firstDefined,_0x3c749a[_0x197af5(0xd9)],_0x3c749a['envStartPath'],typeof _0x35e6bb==='string'?_0x35e6bb:undefined,_0x13abf4?_0x3c749a['cloudSettings']?.['startPath']:undefined);}export function joinBaseAndPath(_0x23c331,_0x13dfb4){const _0x5ad494=_0x343f;if(!_0x23c331)return undefined;if(!_0x13dfb4)return _0x23c331;const _0x1868e5=_0x23c331['endsWith']('/')?_0x23c331[_0x5ad494(0xd2)](0x0,-0x1):_0x23c331,_0x42663b=_0x13dfb4[_0x5ad494(0xce)]('/')?_0x13dfb4:'/'+_0x13dfb4;return _0x1868e5+_0x42663b;}export function resolveProfileUrl(_0x55841f){const _0x5f102d={'qRGcR':function(_0x3ed4a5,_0x304598){return _0x3ed4a5(_0x304598);}},_0x9acf08=_0x5f102d['qRGcR'](resolveBaseUrl,_0x55841f),_0x30f794=resolveStartPath(_0x55841f);return{'baseUrl':_0x9acf08,'startPath':_0x30f794,'url':joinBaseAndPath(_0x9acf08,_0x30f794)};}function _0x52c5(){const _0x2dcacd=['startsWith','YRTdt','localSettingsBaseUrl','flagBaseUrl','slice','env','SALqh','110082SjrXYa','1884bokJed','103080EIPnqc','RANGER_START_PATH','flagStartPath','test','378554aJqngz','36oVXRBV','projectOverrides','546381lShqBo','2335eYuzpN','10998UiDsrW','cloudSettings','envBaseUrl','67879busWNx','baseUrl','253EmNMzP','2264WcLEOY'];_0x52c5=function(){return _0x2dcacd;};return _0x52c5();}export function readUrlEnvVars(_0x2ca1d5=process[_0x27b674(0xd3)]){const _0x4bffc1=_0x27b674;return{'envBaseUrl':_0x2ca1d5['RANGER_BASE_URL'],'envStartPath':_0x2ca1d5[_0x4bffc1(0xd8)]};}
@@ -1 +1 @@
1
- (function(_0x21fe29,_0x10e599){const _0x24bd4c=_0x1f18,_0x3157bf=_0x21fe29();while(!![]){try{const _0x45c535=parseInt(_0x24bd4c(0x1b8))/0x1*(parseInt(_0x24bd4c(0x1ba))/0x2)+parseInt(_0x24bd4c(0x1bd))/0x3+parseInt(_0x24bd4c(0x1b6))/0x4+-parseInt(_0x24bd4c(0x1b7))/0x5+parseInt(_0x24bd4c(0x1b3))/0x6*(parseInt(_0x24bd4c(0x1b4))/0x7)+-parseInt(_0x24bd4c(0x1b1))/0x8*(-parseInt(_0x24bd4c(0x1af))/0x9)+-parseInt(_0x24bd4c(0x1ad))/0xa*(parseInt(_0x24bd4c(0x1bb))/0xb);if(_0x45c535===_0x10e599)break;else _0x3157bf['push'](_0x3157bf['shift']());}catch(_0x338ebb){_0x3157bf['push'](_0x3157bf['shift']());}}}(_0x431f,0x75d86));function _0x431f(){const _0x1fad23=['5577366mjmuWL','7hdjybt','TcHjh','2073428MaBpHF','2756795zySuZR','3KOEeQH','label','59914KnvqtM','8190809wmboHq','OBTNA','396006bgkDpE','baseDelayMs','20LgBqZQ','ms...','6750sJpalY','maxRetries','9104mrXWvH','\x20failed\x20(attempt\x20'];_0x431f=function(){return _0x1fad23;};return _0x431f();}const DEFAULT_MAX_RETRIES=0x3,DEFAULT_BASE_DELAY_MS=0x1f4;function _0x1f18(_0x50b05e,_0x28c6b0){_0x50b05e=_0x50b05e-0x1ad;const _0x431f91=_0x431f();let _0x1f18e5=_0x431f91[_0x50b05e];return _0x1f18e5;}export async function withRetry(_0x453206,_0x878ce8){const _0x1d8f34=_0x1f18,_0x58939a={'OBTNA':function(_0x2209af,_0x52c141){return _0x2209af<=_0x52c141;},'TcHjh':function(_0x1497c4,_0xa47254){return _0x1497c4 instanceof _0xa47254;},'urPPE':function(_0x201cc7,_0x1aebe6){return _0x201cc7<_0x1aebe6;},'xZdCq':function(_0x38177a,_0x3e2e38){return _0x38177a+_0x3e2e38;}},_0x484a0b=_0x878ce8?.[_0x1d8f34(0x1b0)]??DEFAULT_MAX_RETRIES,_0x4c3e9d=_0x878ce8?.[_0x1d8f34(0x1be)]??DEFAULT_BASE_DELAY_MS;let _0x5d6d69;for(let _0x3024f6=0x0;_0x58939a[_0x1d8f34(0x1bc)](_0x3024f6,_0x484a0b);_0x3024f6++){try{return await _0x453206();}catch(_0x115ad1){_0x5d6d69=_0x58939a[_0x1d8f34(0x1b5)](_0x115ad1,Error)?_0x115ad1:new Error(String(_0x115ad1));if(_0x58939a['urPPE'](_0x3024f6,_0x484a0b)){const _0x1a3b4a=_0x4c3e9d*Math['pow'](0x2,_0x3024f6);_0x878ce8?.['label']&&console['error'](_0x878ce8[_0x1d8f34(0x1b9)]+_0x1d8f34(0x1b2)+_0x58939a['xZdCq'](_0x3024f6,0x1)+'/'+(_0x484a0b+0x1)+'),\x20retrying\x20in\x20'+_0x1a3b4a+_0x1d8f34(0x1ae)),await new Promise(_0x50e60c=>setTimeout(_0x50e60c,_0x1a3b4a));}}}throw _0x5d6d69;}
1
+ (function(_0x2d28d3,_0x3a6050){const _0x1cacda=_0x16d9,_0x46df32=_0x2d28d3();while(!![]){try{const _0xf54728=-parseInt(_0x1cacda(0xb4))/0x1+-parseInt(_0x1cacda(0xbf))/0x2+parseInt(_0x1cacda(0xb6))/0x3*(parseInt(_0x1cacda(0xbb))/0x4)+parseInt(_0x1cacda(0xbc))/0x5*(parseInt(_0x1cacda(0xbe))/0x6)+-parseInt(_0x1cacda(0xbd))/0x7+-parseInt(_0x1cacda(0xb5))/0x8*(-parseInt(_0x1cacda(0xb3))/0x9)+parseInt(_0x1cacda(0xb9))/0xa;if(_0xf54728===_0x3a6050)break;else _0x46df32['push'](_0x46df32['shift']());}catch(_0x5cb6b7){_0x46df32['push'](_0x46df32['shift']());}}}(_0x248b,0xc5c74));const DEFAULT_MAX_RETRIES=0x3,DEFAULT_BASE_DELAY_MS=0x1f4;function _0x16d9(_0x2c7f16,_0x5d9d13){_0x2c7f16=_0x2c7f16-0xb3;const _0x248b72=_0x248b();let _0x16d923=_0x248b72[_0x2c7f16];return _0x16d923;}function _0x248b(){const _0x503a42=['1613744UukPlO','16lNGsAS','5043ynEDJy','label','maxRetries','7707090WAHGHU','ms...','764iveeIG','1325DKHmhk','6322575ZfFDiK','25722TCBzqo','232952UJaUEY','\x20failed\x20(attempt\x20','5470695pTpPen'];_0x248b=function(){return _0x503a42;};return _0x248b();}export async function withRetry(_0x496b15,_0x1246ea){const _0x50cb91=_0x16d9,_0x1b5613={'VniOK':function(_0x1e5458,_0x1118f3){return _0x1e5458(_0x1118f3);},'Bjcrq':function(_0x320593,_0xd93e77){return _0x320593+_0xd93e77;},'ELixk':function(_0x5b0f0a,_0x59d558){return _0x5b0f0a+_0x59d558;}},_0x3ac86c=_0x1246ea?.[_0x50cb91(0xb8)]??DEFAULT_MAX_RETRIES,_0x3cfb1f=_0x1246ea?.['baseDelayMs']??DEFAULT_BASE_DELAY_MS;let _0x32850d;for(let _0x3e833f=0x0;_0x3e833f<=_0x3ac86c;_0x3e833f++){try{return await _0x496b15();}catch(_0x1351eb){_0x32850d=_0x1351eb instanceof Error?_0x1351eb:new Error(_0x1b5613['VniOK'](String,_0x1351eb));if(_0x3e833f<_0x3ac86c){const _0x9eac03=_0x3cfb1f*Math['pow'](0x2,_0x3e833f);_0x1246ea?.[_0x50cb91(0xb7)]&&console['error'](_0x1246ea[_0x50cb91(0xb7)]+_0x50cb91(0xc0)+_0x1b5613['Bjcrq'](_0x3e833f,0x1)+'/'+_0x1b5613['ELixk'](_0x3ac86c,0x1)+'),\x20retrying\x20in\x20'+_0x9eac03+_0x50cb91(0xba)),await new Promise(_0x65aef5=>setTimeout(_0x65aef5,_0x9eac03));}}}throw _0x32850d;}
@@ -1 +1 @@
1
- const _0xe64401=_0x6942;(function(_0x293251,_0x2aee33){const _0x37a1e8=_0x6942,_0x8e8f80=_0x293251();while(!![]){try{const _0x4deb69=parseInt(_0x37a1e8(0xc9))/0x1+parseInt(_0x37a1e8(0xc4))/0x2+parseInt(_0x37a1e8(0x9b))/0x3+-parseInt(_0x37a1e8(0xa1))/0x4*(-parseInt(_0x37a1e8(0xaa))/0x5)+parseInt(_0x37a1e8(0xa9))/0x6*(parseInt(_0x37a1e8(0xbd))/0x7)+parseInt(_0x37a1e8(0xb3))/0x8+-parseInt(_0x37a1e8(0x9a))/0x9;if(_0x4deb69===_0x2aee33)break;else _0x8e8f80['push'](_0x8e8f80['shift']());}catch(_0x4363ca){_0x8e8f80['push'](_0x8e8f80['shift']());}}}(_0x47a8,0x34f87));import*as _0x5d2aa5 from'fs';import*as _0x384bb5 from'path';import*as _0x22a86d from'os';import{execSync}from'child_process';const CACHE_FILE=_0x384bb5[_0xe64401(0xaf)](_0x22a86d['homedir'](),'.claude','.ranger_cache.json');function createEmptyCache(){return{'version':0x3,'sessions':{},'branches':{}};}function loadCache(){const _0x4244d5=_0xe64401,_0x472e64={'bMLgG':function(_0x425b68){return _0x425b68();}};try{if(_0x5d2aa5['existsSync'](CACHE_FILE)){const _0x5e7f5d=JSON[_0x4244d5(0xbf)](_0x5d2aa5['readFileSync'](CACHE_FILE,_0x4244d5(0xb9)));return{'version':0x3,'sessions':_0x5e7f5d[_0x4244d5(0x98)]||{},'branches':_0x5e7f5d['branches']||{},'lastEnabledSessionClearedAt':_0x5e7f5d['lastEnabledSessionClearedAt']};}}catch{}return _0x472e64['bMLgG'](createEmptyCache);}function saveCache(_0x276e41){const _0x19bac6=_0xe64401;try{const _0x27392a=_0x384bb5[_0x19bac6(0xc8)](CACHE_FILE);!_0x5d2aa5[_0x19bac6(0x9c)](_0x27392a)&&_0x5d2aa5['mkdirSync'](_0x27392a,{'recursive':!![]}),_0x5d2aa5[_0x19bac6(0xc5)](CACHE_FILE,JSON[_0x19bac6(0xa6)](_0x276e41,null,0x2));}catch{}}export function getCurrentBranch(){const _0x3eb0b3=_0xe64401,_0x3216cc={'fjTsD':'git\x20rev-parse\x20--abbrev-ref\x20HEAD','eEWuV':_0x3eb0b3(0xb9),'PhVBR':'pipe'};try{const _0x1f85f4=execSync(_0x3216cc[_0x3eb0b3(0xb5)],{'encoding':_0x3216cc['eEWuV'],'stdio':[_0x3216cc[_0x3eb0b3(0xb7)],_0x3216cc[_0x3eb0b3(0xb7)],_0x3eb0b3(0xb6)]})[_0x3eb0b3(0xac)]();if(!_0x1f85f4||_0x1f85f4==='HEAD')return null;return _0x1f85f4;}catch{return null;}}export function enableBranch(_0x5aece7){const _0xf04021=loadCache();_0xf04021['branches'][_0x5aece7]=!![],saveCache(_0xf04021);}export function disableBranch(_0x24f9ba){const _0xdae885=_0xe64401,_0x27b259=loadCache();delete _0x27b259[_0xdae885(0xa3)][_0x24f9ba],saveCache(_0x27b259);}export function isBranchEnabled(_0xbc2ae){const _0x293af8=_0xe64401,_0x114e68={'LbaOo':function(_0x2996b3){return _0x2996b3();}},_0x4634a1=_0x114e68['LbaOo'](loadCache);return _0x4634a1[_0x293af8(0xa3)][_0xbc2ae]===!![];}function getOrCreateSession(_0x565b96,_0x407060){return!_0x565b96['sessions'][_0x407060]&&(_0x565b96['sessions'][_0x407060]={}),_0x565b96['sessions'][_0x407060];}export function enableSession(_0x5444b7){const _0x4e911e=_0xe64401,_0x56ff5e={'mpMak':function(_0xed335f){return _0xed335f();},'KpJwd':function(_0x14ef29,_0x296745){return _0x14ef29!==_0x296745;},'ifhvM':'main','oqEGy':function(_0x459390,_0x5486e7){return _0x459390(_0x5486e7);}},_0x204b57=_0x56ff5e['mpMak'](loadCache),_0x31c430=getOrCreateSession(_0x204b57,_0x5444b7);_0x31c430['enabled']=!![];const _0x35d13f=getCurrentBranch();_0x35d13f&&_0x56ff5e[_0x4e911e(0xc6)](_0x35d13f,_0x56ff5e[_0x4e911e(0xc0)])&&_0x35d13f!==_0x4e911e(0xb8)&&(_0x204b57[_0x4e911e(0xa3)][_0x35d13f]=!![],_0x31c430['currentBranch']=_0x35d13f),_0x56ff5e['oqEGy'](saveCache,_0x204b57);}export function isSessionEnabled(_0x56a67f){const _0xb3fd5b=_0xe64401,_0x2536d6={'gaiCX':function(_0x18ac99){return _0x18ac99();},'RXEgp':function(_0x22a780,_0x56c414){return _0x22a780===_0x56c414;},'ymajo':function(_0x4da143,_0x2db52a){return _0x4da143===_0x2db52a;},'JnCCa':function(_0x1afa41,_0x35b15e){return _0x1afa41===_0x35b15e;},'RfEFr':function(_0x340741,_0x5be512){return _0x340741||_0x5be512;}},_0x53b10e=loadCache(),_0x2ea36f=_0x2536d6[_0xb3fd5b(0xb0)](getCurrentBranch);if(!_0x2ea36f||_0x2536d6['RXEgp'](_0x2ea36f,'main')||_0x2536d6[_0xb3fd5b(0xca)](_0x2ea36f,'master'))return _0x53b10e[_0xb3fd5b(0x98)][_0x56a67f]?.[_0xb3fd5b(0x95)]===!![];const _0x582ddb=_0x2536d6['RXEgp'](_0x53b10e[_0xb3fd5b(0xa3)][_0x2ea36f],!![]),_0x427fe6=_0x2536d6[_0xb3fd5b(0x9e)](_0x53b10e[_0xb3fd5b(0x98)][_0x56a67f]?.[_0xb3fd5b(0x95)],!![]);return _0x2536d6[_0xb3fd5b(0xc3)](_0x582ddb,_0x427fe6);}export function disableSession(_0x17c3ce){const _0x30aad2=_0xe64401,_0x1cb6e2={'SCuRg':function(_0x2be6a3){return _0x2be6a3();},'ZVXtp':function(_0x5cc558,_0x2ac0f1,_0x2699db){return _0x5cc558(_0x2ac0f1,_0x2699db);},'jkYkT':function(_0x4f75be,_0x53bcc1){return _0x4f75be(_0x53bcc1);}},_0x45b361=_0x1cb6e2[_0x30aad2(0xa7)](loadCache),_0x51339b=_0x1cb6e2[_0x30aad2(0xa4)](getOrCreateSession,_0x45b361,_0x17c3ce);_0x51339b['enabled']=![],_0x1cb6e2[_0x30aad2(0xba)](saveCache,_0x45b361);}export function updateBranchTracking(_0x55db73){const _0x10aafd=_0xe64401,_0x405ac7={'AqQnM':function(_0x2863ec){return _0x2863ec();},'MPPXc':function(_0x4bd2c5,_0x31839e){return _0x4bd2c5===_0x31839e;},'wqtfU':_0x10aafd(0xbb),'GAGPr':'master','iHKNy':function(_0x5a715c,_0x94d6ed){return _0x5a715c!==_0x94d6ed;},'xkHcv':function(_0x41c3b1,_0x2392db){return _0x41c3b1(_0x2392db);}},_0x4b9f27=loadCache(),_0x5de611=_0x4b9f27[_0x10aafd(0x98)][_0x55db73];if(!_0x5de611?.['enabled'])return;const _0x53aa9b=_0x405ac7['AqQnM'](getCurrentBranch);if(!_0x53aa9b||_0x405ac7['MPPXc'](_0x53aa9b,_0x405ac7[_0x10aafd(0xa5)])||_0x53aa9b===_0x405ac7[_0x10aafd(0xbc)])return;_0x405ac7['iHKNy'](_0x5de611[_0x10aafd(0x9f)],_0x53aa9b)&&(_0x4b9f27['branches'][_0x53aa9b]=!![],_0x5de611[_0x10aafd(0x9f)]=_0x53aa9b,_0x405ac7[_0x10aafd(0x9d)](saveCache,_0x4b9f27));}export function initBranchTracking(_0x2e3bd5){const _0x1a6dd7=_0xe64401,_0x41c25e={'EsrPY':function(_0x446c2a){return _0x446c2a();},'jNlTj':function(_0x5675f5,_0x4e138d){return _0x5675f5===_0x4e138d;},'SmBGm':_0x1a6dd7(0xb8),'TeiJx':function(_0x171eb6,_0x42b53c,_0x1d48dd){return _0x171eb6(_0x42b53c,_0x1d48dd);}},_0x12e2cb=_0x41c25e['EsrPY'](loadCache),_0x46b045=getCurrentBranch();if(!_0x46b045||_0x41c25e['jNlTj'](_0x46b045,_0x1a6dd7(0xbb))||_0x46b045===_0x41c25e['SmBGm'])return;if(_0x12e2cb['branches'][_0x46b045]===!![]){const _0x38ba76=_0x41c25e['TeiJx'](getOrCreateSession,_0x12e2cb,_0x2e3bd5);_0x38ba76[_0x1a6dd7(0x95)]=!![],_0x38ba76[_0x1a6dd7(0x9f)]=_0x46b045,saveCache(_0x12e2cb);}}const CLEAR_AUTO_ENABLE_WINDOW_MS=0x1388;function _0x6942(_0x55ad94,_0x49e518){_0x55ad94=_0x55ad94-0x94;const _0x47a8d9=_0x47a8();let _0x6942f2=_0x47a8d9[_0x55ad94];return _0x6942f2;}export function recordEnabledSessionCleared(_0x105cac){const _0x2de0b3=loadCache(),_0x2adafd=_0x2de0b3['sessions'][_0x105cac];_0x2adafd?.['enabled']&&(_0x2de0b3['lastEnabledSessionClearedAt']=Date['now'](),saveCache(_0x2de0b3));}export function shouldAutoEnableAfterClear(_0x12e723){const _0x97237=_0xe64401,_0x44a20d={'dDlKi':_0x97237(0xae),'CErfo':function(_0x4f8907,_0x1c55fe){return _0x4f8907-_0x1c55fe;},'ZKXwX':function(_0x38dfd1,_0x143564){return _0x38dfd1<=_0x143564;}};if(_0x12e723!==_0x44a20d[_0x97237(0x99)])return![];const _0x4b63d6=loadCache(),_0x424629=_0x4b63d6[_0x97237(0xad)];if(!_0x424629)return![];const _0x49f91f=_0x44a20d[_0x97237(0xb1)](Date['now'](),_0x424629);return _0x44a20d['ZKXwX'](_0x49f91f,CLEAR_AUTO_ENABLE_WINDOW_MS);}export function autoEnableAfterClear(_0x2b972f){const _0x262732=_0xe64401,_0x352ab3={'NolXU':function(_0x42263d){return _0x42263d();},'Nxogm':function(_0x305c00,_0x2adae7,_0x929db){return _0x305c00(_0x2adae7,_0x929db);},'KnbYL':function(_0x5774f4,_0x4e603e){return _0x5774f4!==_0x4e603e;},'BsvvF':_0x262732(0xbb),'mxNqx':function(_0x23f48f,_0x3b01a1){return _0x23f48f(_0x3b01a1);}},_0x4a37d7=_0x352ab3[_0x262732(0xc7)](loadCache),_0x50c0af=_0x352ab3['Nxogm'](getOrCreateSession,_0x4a37d7,_0x2b972f);_0x50c0af[_0x262732(0x95)]=!![];const _0x20330b=getCurrentBranch();_0x20330b&&_0x352ab3[_0x262732(0x94)](_0x20330b,_0x352ab3['BsvvF'])&&_0x352ab3[_0x262732(0x94)](_0x20330b,_0x262732(0xb8))&&(_0x50c0af['currentBranch']=_0x20330b),delete _0x4a37d7['lastEnabledSessionClearedAt'],_0x352ab3['mxNqx'](saveCache,_0x4a37d7);}export function registerSession(_0x36023c,_0x15b163){const _0x3a4680=_0xe64401,_0x1f10cd=loadCache(),_0x49fb13=getOrCreateSession(_0x1f10cd,_0x36023c);_0x49fb13[_0x3a4680(0xb4)]=_0x15b163,_0x49fb13['registeredAt']=new Date()['toISOString'](),saveCache(_0x1f10cd);}export function getSessionEntry(_0x198c06){const _0x3a6cc9=_0xe64401,_0x144293=loadCache(),_0x3bf88b=_0x144293['sessions'][_0x198c06];if(_0x3bf88b?.[_0x3a6cc9(0xb4)]&&_0x3bf88b?.['registeredAt'])return{'featureId':_0x3bf88b[_0x3a6cc9(0xb4)],'registeredAt':_0x3bf88b['registeredAt']};return null;}export function unregisterSession(_0x3ee27b){const _0x9c374a=_0xe64401,_0x2a5d94={'VtLrC':function(_0x268840){return _0x268840();}},_0x506060=_0x2a5d94['VtLrC'](loadCache),_0x57648d=_0x506060['sessions'][_0x3ee27b];_0x57648d&&(delete _0x57648d['featureId'],delete _0x57648d[_0x9c374a(0x97)],saveCache(_0x506060));}const PLAN_REMINDER_INTERVAL_MS=0x5*0x3c*0x3e8,STOP_REMINDER_INTERVAL_MS=0x5*0x3c*0x3e8;export function shouldShowPlanReminder(_0x2de1ee){const _0x39568b=_0xe64401,_0x104552={'dDbmL':function(_0x31f864,_0x574bb8,_0x456192){return _0x31f864(_0x574bb8,_0x456192);},'iiMUL':function(_0x4577c4,_0x15f7a4){return _0x4577c4>=_0x15f7a4;},'QeBOB':function(_0x22b7d1,_0x4caa25){return _0x22b7d1-_0x4caa25;}},_0x485fab=loadCache(),_0xd848d1=_0x104552['dDbmL'](getOrCreateSession,_0x485fab,_0x2de1ee),_0x30da86=_0xd848d1['lastPlanReminderAt']||0x0,_0x4b1bdd=Date[_0x39568b(0xa8)]();if(_0x104552[_0x39568b(0xbe)](_0x104552[_0x39568b(0xa2)](_0x4b1bdd,_0x30da86),PLAN_REMINDER_INTERVAL_MS))return _0xd848d1['lastPlanReminderAt']=_0x4b1bdd,saveCache(_0x485fab),!![];return![];}export function shouldShowStopReminder(_0x112ddd){const _0x4fc693=_0xe64401,_0x2912ea={'HCknw':function(_0x473cdb){return _0x473cdb();},'rfDLA':function(_0x34db2e,_0xfab8ca,_0x48718b){return _0x34db2e(_0xfab8ca,_0x48718b);},'JCCuV':function(_0x1f86b9,_0x50ca34){return _0x1f86b9>=_0x50ca34;},'JKvCf':function(_0x21dbca,_0x222941){return _0x21dbca-_0x222941;}},_0x87de2e=_0x2912ea[_0x4fc693(0x96)](loadCache),_0x246fec=_0x2912ea[_0x4fc693(0xb2)](getOrCreateSession,_0x87de2e,_0x112ddd),_0x521f9c=_0x246fec[_0x4fc693(0xc2)]||0x0,_0x91389e=Date[_0x4fc693(0xa8)]();if(_0x2912ea[_0x4fc693(0xab)](_0x2912ea['JKvCf'](_0x91389e,_0x521f9c),STOP_REMINDER_INTERVAL_MS))return _0x246fec[_0x4fc693(0xc2)]=_0x91389e,saveCache(_0x87de2e),!![];return![];}function _0x47a8(){const _0x30ab18=['SCuRg','now','105654yUVMcf','1270ONtsnI','JCCuV','trim','lastEnabledSessionClearedAt','clear','join','gaiCX','CErfo','rfDLA','1965792nZOrNV','featureId','fjTsD','pipe','PhVBR','master','utf-8','jkYkT','main','GAGPr','28tsTXPy','iiMUL','parse','ifhvM','cOJBT','lastStopReminderAt','RfEFr','482584LajpKf','writeFileSync','KpJwd','NolXU','dirname','73278JarbnR','ymajo','KnbYL','enabled','HCknw','registeredAt','sessions','dDlKi','8122482JJUDKu','1224651eRllNB','existsSync','xkHcv','JnCCa','currentBranch','prompted','1268OvFtNY','QeBOB','branches','ZVXtp','wqtfU','stringify'];_0x47a8=function(){return _0x30ab18;};return _0x47a8();}export function hasSessionBeenPrompted(_0x592e24){const _0x4b30a7=_0xe64401,_0x593273={'UXpQh':function(_0x52d144,_0x594bfa){return _0x52d144===_0x594bfa;}},_0x5e3ffc=loadCache();return _0x593273['UXpQh'](_0x5e3ffc[_0x4b30a7(0x98)][_0x592e24]?.['prompted'],!![]);}export function markSessionPrompted(_0x3b5625){const _0x5c6312=_0xe64401,_0x4ff664={'cOJBT':function(_0x4d4a47){return _0x4d4a47();},'vuDXM':function(_0x175b1e,_0x504d67,_0x1cccd5){return _0x175b1e(_0x504d67,_0x1cccd5);}},_0x224ba9=_0x4ff664[_0x5c6312(0xc1)](loadCache),_0x304c4d=_0x4ff664['vuDXM'](getOrCreateSession,_0x224ba9,_0x3b5625);_0x304c4d[_0x5c6312(0xa0)]=!![],saveCache(_0x224ba9);}export function getCacheFile(){return CACHE_FILE;}
1
+ const _0x23cda7=_0x427a;(function(_0x287629,_0x44ea1f){const _0x30439e=_0x427a,_0x4ea2ab=_0x287629();while(!![]){try{const _0x8db4a1=-parseInt(_0x30439e(0x188))/0x1+-parseInt(_0x30439e(0x17a))/0x2+-parseInt(_0x30439e(0x185))/0x3*(-parseInt(_0x30439e(0x17f))/0x4)+parseInt(_0x30439e(0x178))/0x5+parseInt(_0x30439e(0x195))/0x6+parseInt(_0x30439e(0x192))/0x7*(parseInt(_0x30439e(0x18c))/0x8)+-parseInt(_0x30439e(0x18f))/0x9;if(_0x8db4a1===_0x44ea1f)break;else _0x4ea2ab['push'](_0x4ea2ab['shift']());}catch(_0x8f5580){_0x4ea2ab['push'](_0x4ea2ab['shift']());}}}(_0x5766,0xabd09));import*as _0x32e5b3 from'fs';import*as _0x546e27 from'path';import*as _0x52e0d7 from'os';import{execSync}from'child_process';const CACHE_FILE=_0x546e27['join'](_0x52e0d7[_0x23cda7(0x179)](),_0x23cda7(0x19c),'.ranger_cache.json');function createEmptyCache(){return{'version':0x3,'sessions':{},'branches':{}};}function loadCache(){const _0x5c4919=_0x23cda7;try{if(_0x32e5b3['existsSync'](CACHE_FILE)){const _0x17c771=JSON['parse'](_0x32e5b3[_0x5c4919(0x187)](CACHE_FILE,_0x5c4919(0x19b)));return{'version':0x3,'sessions':_0x17c771[_0x5c4919(0x1a6)]||{},'branches':_0x17c771['branches']||{},'lastEnabledSessionClearedAt':_0x17c771[_0x5c4919(0x181)]};}}catch{}return createEmptyCache();}function saveCache(_0x337fe4){const _0x578c97=_0x23cda7;try{const _0x2eda7f=_0x546e27[_0x578c97(0x191)](CACHE_FILE);!_0x32e5b3['existsSync'](_0x2eda7f)&&_0x32e5b3[_0x578c97(0x18e)](_0x2eda7f,{'recursive':!![]}),_0x32e5b3[_0x578c97(0x17e)](CACHE_FILE,JSON[_0x578c97(0x19d)](_0x337fe4,null,0x2));}catch{}}export function getCurrentBranch(){const _0x1e2fd1=_0x23cda7,_0x4ef43d={'KezLg':'pipe','eXKuu':function(_0x3e46ea,_0x3d483a){return _0x3e46ea===_0x3d483a;}};try{const _0x241bd0=execSync('git\x20rev-parse\x20--abbrev-ref\x20HEAD',{'encoding':_0x1e2fd1(0x19b),'stdio':[_0x4ef43d['KezLg'],_0x4ef43d['KezLg'],_0x4ef43d[_0x1e2fd1(0x182)]]})['trim']();if(!_0x241bd0||_0x4ef43d['eXKuu'](_0x241bd0,_0x1e2fd1(0x17c)))return null;return _0x241bd0;}catch{return null;}}export function enableBranch(_0x12481a){const _0x594b65=_0x23cda7,_0x41610a={'eArFb':function(_0x572d69){return _0x572d69();},'iHpET':function(_0x556ed3,_0x28674a){return _0x556ed3(_0x28674a);}},_0x5b3eab=_0x41610a[_0x594b65(0x19e)](loadCache);_0x5b3eab[_0x594b65(0x199)][_0x12481a]=!![],_0x41610a['iHpET'](saveCache,_0x5b3eab);}export function disableBranch(_0x4af39d){const _0x171dd2=loadCache();delete _0x171dd2['branches'][_0x4af39d],saveCache(_0x171dd2);}export function isBranchEnabled(_0x4fcd3b){const _0x158073=_0x23cda7,_0x26cd43=loadCache();return _0x26cd43[_0x158073(0x199)][_0x4fcd3b]===!![];}function getOrCreateSession(_0x3b8108,_0x1092a4){const _0x316760=_0x23cda7;return!_0x3b8108[_0x316760(0x1a6)][_0x1092a4]&&(_0x3b8108[_0x316760(0x1a6)][_0x1092a4]={}),_0x3b8108['sessions'][_0x1092a4];}export function enableSession(_0xbc6208){const _0x10535c=_0x23cda7,_0x2c798b={'QQFgW':function(_0x5994e9,_0x23b324,_0x3517ee){return _0x5994e9(_0x23b324,_0x3517ee);},'OLqAs':function(_0xec91dd){return _0xec91dd();},'ZKUTk':'main','kZFbV':function(_0x47161f,_0x4f5528){return _0x47161f(_0x4f5528);}},_0x119163=loadCache(),_0xce8ad9=_0x2c798b['QQFgW'](getOrCreateSession,_0x119163,_0xbc6208);_0xce8ad9['enabled']=!![];const _0x4f2478=_0x2c798b['OLqAs'](getCurrentBranch);_0x4f2478&&_0x4f2478!==_0x2c798b['ZKUTk']&&_0x4f2478!=='master'&&(_0x119163[_0x10535c(0x199)][_0x4f2478]=!![],_0xce8ad9[_0x10535c(0x17d)]=_0x4f2478),_0x2c798b['kZFbV'](saveCache,_0x119163);}export function isSessionEnabled(_0x1eea56){const _0x4d56ec=_0x23cda7,_0x16a810={'BOibC':_0x4d56ec(0x190),'bjAlb':function(_0x54303d,_0x41d9d4){return _0x54303d===_0x41d9d4;},'nCXii':function(_0x5f22d1,_0x3348ea){return _0x5f22d1===_0x3348ea;},'unEVk':function(_0x41ef5f,_0x3de362){return _0x41ef5f||_0x3de362;}},_0x47be06=loadCache(),_0x36dc8d=getCurrentBranch();if(!_0x36dc8d||_0x36dc8d===_0x16a810['BOibC']||_0x36dc8d===_0x4d56ec(0x180))return _0x47be06['sessions'][_0x1eea56]?.['enabled']===!![];const _0x9fc808=_0x16a810['bjAlb'](_0x47be06['branches'][_0x36dc8d],!![]),_0x5ef877=_0x16a810[_0x4d56ec(0x1a3)](_0x47be06[_0x4d56ec(0x1a6)][_0x1eea56]?.[_0x4d56ec(0x1a0)],!![]);return _0x16a810['unEVk'](_0x9fc808,_0x5ef877);}export function disableSession(_0x49f905){const _0x58e795=_0x23cda7,_0x6f1c8a={'JkUuN':function(_0x516044){return _0x516044();},'ZjUHY':function(_0x289858,_0x292d15){return _0x289858(_0x292d15);}},_0x55abe3=_0x6f1c8a[_0x58e795(0x186)](loadCache),_0x2fd956=getOrCreateSession(_0x55abe3,_0x49f905);_0x2fd956[_0x58e795(0x1a0)]=![],_0x6f1c8a['ZjUHY'](saveCache,_0x55abe3);}export function updateBranchTracking(_0x2a6b3c){const _0x1a59cb=_0x23cda7,_0x1776fc={'lwPkJ':function(_0x1096ba){return _0x1096ba();},'hThNs':function(_0x56e5b1,_0x461b9a){return _0x56e5b1===_0x461b9a;},'GqrdE':function(_0x443026,_0x39ec6c){return _0x443026===_0x39ec6c;},'xkVsv':function(_0x44d832,_0xb54ec1){return _0x44d832!==_0xb54ec1;},'ouvUA':function(_0x1dd8b3,_0x48b282){return _0x1dd8b3(_0x48b282);}},_0x2c6ec=loadCache(),_0x3afe65=_0x2c6ec['sessions'][_0x2a6b3c];if(!_0x3afe65?.['enabled'])return;const _0x46684b=_0x1776fc['lwPkJ'](getCurrentBranch);if(!_0x46684b||_0x1776fc[_0x1a59cb(0x194)](_0x46684b,_0x1a59cb(0x190))||_0x1776fc['GqrdE'](_0x46684b,_0x1a59cb(0x180)))return;_0x1776fc[_0x1a59cb(0x18d)](_0x3afe65['currentBranch'],_0x46684b)&&(_0x2c6ec['branches'][_0x46684b]=!![],_0x3afe65[_0x1a59cb(0x17d)]=_0x46684b,_0x1776fc['ouvUA'](saveCache,_0x2c6ec));}export function initBranchTracking(_0x2471e6){const _0x101948=_0x23cda7,_0x578228={'UNlNJ':function(_0x27ca52){return _0x27ca52();},'Rbkyp':function(_0x1705f4,_0x22e15e){return _0x1705f4(_0x22e15e);}},_0x4f5b66=_0x578228['UNlNJ'](loadCache),_0x338476=getCurrentBranch();if(!_0x338476||_0x338476===_0x101948(0x190)||_0x338476==='master')return;if(_0x4f5b66['branches'][_0x338476]===!![]){const _0x38d36d=getOrCreateSession(_0x4f5b66,_0x2471e6);_0x38d36d[_0x101948(0x1a0)]=!![],_0x38d36d[_0x101948(0x17d)]=_0x338476,_0x578228[_0x101948(0x184)](saveCache,_0x4f5b66);}}const CLEAR_AUTO_ENABLE_WINDOW_MS=0x1388;function _0x5766(){const _0x17fc1=['stringify','eArFb','lastStopReminderAt','enabled','toISOString','lastPlanReminderAt','nCXii','NCzOB','prompted','sessions','2009670kufUxG','homedir','1621668pOCmxn','now','HEAD','currentBranch','writeFileSync','4RdTtoK','master','lastEnabledSessionClearedAt','KezLg','zOnPE','Rbkyp','2699931KFHUww','JkUuN','readFileSync','626836RRpNzh','clear','HRxJC','registeredAt','16eevLqG','xkVsv','mkdirSync','9033426tnqkMY','main','dirname','4349667GABCOq','YpjBp','hThNs','3602784MOKZeK','featureId','wNxNr','vVEgE','branches','kgpFN','utf-8','.claude'];_0x5766=function(){return _0x17fc1;};return _0x5766();}export function recordEnabledSessionCleared(_0x2a7ef5){const _0xd845c8=_0x23cda7,_0x38e905=loadCache(),_0x4bbee5=_0x38e905['sessions'][_0x2a7ef5];_0x4bbee5?.['enabled']&&(_0x38e905['lastEnabledSessionClearedAt']=Date[_0xd845c8(0x17b)](),saveCache(_0x38e905));}export function shouldAutoEnableAfterClear(_0x1dbca3){const _0xff2fc9=_0x23cda7,_0x77a733={'YpjBp':function(_0x493ec2){return _0x493ec2();}};if(_0x1dbca3!==_0xff2fc9(0x189))return![];const _0x43b7fc=_0x77a733[_0xff2fc9(0x193)](loadCache),_0x150946=_0x43b7fc[_0xff2fc9(0x181)];if(!_0x150946)return![];const _0x3067c2=Date[_0xff2fc9(0x17b)]()-_0x150946;return _0x3067c2<=CLEAR_AUTO_ENABLE_WINDOW_MS;}export function autoEnableAfterClear(_0x238138){const _0x589ac2=_0x23cda7,_0x4457db={'kgpFN':function(_0xfaea76){return _0xfaea76();},'DlCHG':'main','AJLmw':'master','NCzOB':function(_0x4b0907,_0xc3063e){return _0x4b0907(_0xc3063e);}},_0x230f40=loadCache(),_0x198ce2=getOrCreateSession(_0x230f40,_0x238138);_0x198ce2[_0x589ac2(0x1a0)]=!![];const _0x1279e6=_0x4457db[_0x589ac2(0x19a)](getCurrentBranch);_0x1279e6&&_0x1279e6!==_0x4457db['DlCHG']&&_0x1279e6!==_0x4457db['AJLmw']&&(_0x198ce2[_0x589ac2(0x17d)]=_0x1279e6),delete _0x230f40[_0x589ac2(0x181)],_0x4457db[_0x589ac2(0x1a4)](saveCache,_0x230f40);}export function registerSession(_0x21a1a5,_0x16d499){const _0x485b04=_0x23cda7,_0x2ecf6c=loadCache(),_0xa6e28b=getOrCreateSession(_0x2ecf6c,_0x21a1a5);_0xa6e28b[_0x485b04(0x196)]=_0x16d499,_0xa6e28b['registeredAt']=new Date()[_0x485b04(0x1a1)](),saveCache(_0x2ecf6c);}export function getSessionEntry(_0x510ad5){const _0x3d613d=_0x23cda7,_0x2e2415=loadCache(),_0x5ba56c=_0x2e2415['sessions'][_0x510ad5];if(_0x5ba56c?.[_0x3d613d(0x196)]&&_0x5ba56c?.[_0x3d613d(0x18b)])return{'featureId':_0x5ba56c[_0x3d613d(0x196)],'registeredAt':_0x5ba56c['registeredAt']};return null;}export function unregisterSession(_0x1868d9){const _0x528129=_0x23cda7,_0x43b74a={'vVEgE':function(_0x46d77c){return _0x46d77c();}},_0x5d245b=_0x43b74a[_0x528129(0x198)](loadCache),_0xba6cbd=_0x5d245b['sessions'][_0x1868d9];_0xba6cbd&&(delete _0xba6cbd[_0x528129(0x196)],delete _0xba6cbd['registeredAt'],saveCache(_0x5d245b));}function _0x427a(_0x52b828,_0x4b18a3){_0x52b828=_0x52b828-0x178;const _0x576624=_0x5766();let _0x427aea=_0x576624[_0x52b828];return _0x427aea;}const PLAN_REMINDER_INTERVAL_MS=0x5*0x3c*0x3e8,STOP_REMINDER_INTERVAL_MS=0x5*0x3c*0x3e8;export function shouldShowPlanReminder(_0x4a640b){const _0x3ebbc0=_0x23cda7,_0x4bf16a={'HRxJC':function(_0x3dcb8f,_0x26420a,_0x195e78){return _0x3dcb8f(_0x26420a,_0x195e78);},'qiMwk':function(_0x909604,_0x5f0320){return _0x909604>=_0x5f0320;}},_0x1873e8=loadCache(),_0x570952=_0x4bf16a[_0x3ebbc0(0x18a)](getOrCreateSession,_0x1873e8,_0x4a640b),_0x20ace5=_0x570952[_0x3ebbc0(0x1a2)]||0x0,_0x57272e=Date[_0x3ebbc0(0x17b)]();if(_0x4bf16a['qiMwk'](_0x57272e-_0x20ace5,PLAN_REMINDER_INTERVAL_MS))return _0x570952[_0x3ebbc0(0x1a2)]=_0x57272e,saveCache(_0x1873e8),!![];return![];}export function shouldShowStopReminder(_0x2c8c94){const _0x3754ec=_0x23cda7,_0x27abcc={'lCEPV':function(_0xf9ecab,_0x3e3c57){return _0xf9ecab-_0x3e3c57;},'BNSsW':function(_0x58d3d8,_0x4df07c){return _0x58d3d8(_0x4df07c);}},_0x27df33=loadCache(),_0x5abf3a=getOrCreateSession(_0x27df33,_0x2c8c94),_0x2c8ad8=_0x5abf3a[_0x3754ec(0x19f)]||0x0,_0x5da18a=Date[_0x3754ec(0x17b)]();if(_0x27abcc['lCEPV'](_0x5da18a,_0x2c8ad8)>=STOP_REMINDER_INTERVAL_MS)return _0x5abf3a[_0x3754ec(0x19f)]=_0x5da18a,_0x27abcc['BNSsW'](saveCache,_0x27df33),!![];return![];}export function hasSessionBeenPrompted(_0x2f2232){const _0x3cead2=_0x23cda7,_0x342405={'zOnPE':function(_0x127624){return _0x127624();}},_0xd2756d=_0x342405[_0x3cead2(0x183)](loadCache);return _0xd2756d[_0x3cead2(0x1a6)][_0x2f2232]?.[_0x3cead2(0x1a5)]===!![];}export function markSessionPrompted(_0x33c1f7){const _0xb57a60=_0x23cda7,_0x55d3e1={'wNxNr':function(_0x158671,_0x391a12,_0x128b80){return _0x158671(_0x391a12,_0x128b80);},'viYmJ':function(_0x2537d8,_0x39b859){return _0x2537d8(_0x39b859);}},_0x5ad486=loadCache(),_0x230fec=_0x55d3e1[_0xb57a60(0x197)](getOrCreateSession,_0x5ad486,_0x33c1f7);_0x230fec[_0xb57a60(0x1a5)]=!![],_0x55d3e1['viYmJ'](saveCache,_0x5ad486);}export function getCacheFile(){return CACHE_FILE;}
@@ -1 +1 @@
1
- const _0x1f68ed=_0x9bd2;(function(_0x5d8121,_0x162887){const _0x5040cc=_0x9bd2,_0x3b420c=_0x5d8121();while(!![]){try{const _0x25e747=parseInt(_0x5040cc(0x10e))/0x1*(-parseInt(_0x5040cc(0x122))/0x2)+parseInt(_0x5040cc(0xc6))/0x3*(-parseInt(_0x5040cc(0xd7))/0x4)+-parseInt(_0x5040cc(0xe6))/0x5+parseInt(_0x5040cc(0xd5))/0x6+parseInt(_0x5040cc(0xd4))/0x7*(-parseInt(_0x5040cc(0xeb))/0x8)+parseInt(_0x5040cc(0xf3))/0x9*(parseInt(_0x5040cc(0x111))/0xa)+parseInt(_0x5040cc(0x10b))/0xb;if(_0x25e747===_0x162887)break;else _0x3b420c['push'](_0x3b420c['shift']());}catch(_0x7d8a69){_0x3b420c['push'](_0x3b420c['shift']());}}}(_0x127e,0x6c9e9));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{decrypt}from'./crypto.js';import{getToken}from'./keychain.js';import{getRangerDir,getRangerHomeDir}from'./rangerRoot.js';function findEnvInRoot(_0x18af57,_0xb1ce30){const _0x5009e8=_0x9bd2,_0x3e25b5={'XmkEf':function(_0xaf411,_0x164af1,_0x211bfb,_0x1cd366){return _0xaf411(_0x164af1,_0x211bfb,_0x1cd366);},'NGPXb':function(_0xf5ce0e,_0x32940d,_0x35d0fe){return _0xf5ce0e(_0x32940d,_0x35d0fe);},'vCUyZ':'local','AERDo':function(_0xe4efd,_0x38f3ba,_0x35afcd){return _0xe4efd(_0x38f3ba,_0x35afcd);},'FoJKP':function(_0x2841fa,_0x267d4b){return _0x2841fa(_0x267d4b);},'TocNR':function(_0x1b268c,_0x2c7a02){return _0x1b268c(_0x2c7a02);},'RDLoo':function(_0x3c4498,_0x304270){return _0x3c4498!==_0x304270;},'zBnOQ':function(_0x4ccc9b,_0x20ee1f){return _0x4ccc9b!==_0x20ee1f;}},_0x489a0f=_0x3e25b5['XmkEf'](join,_0xb1ce30,'ci',_0x18af57),_0x33a665=_0x3e25b5[_0x5009e8(0xcc)](join,_0xb1ce30,'local',_0x18af57),_0x5b0b63=_0x3e25b5['NGPXb'](join,_0xb1ce30,_0x18af57),_0x558204=join(_0xb1ce30,_0x3e25b5['vCUyZ']),_0x5a7244=_0x3e25b5['AERDo'](join,_0xb1ce30,'ci');if(_0x3e25b5[_0x5009e8(0x128)](existsSync,_0x489a0f))return _0x489a0f;if(_0x3e25b5[_0x5009e8(0x128)](existsSync,_0x33a665))return _0x33a665;if(_0x3e25b5[_0x5009e8(0xe8)](existsSync,_0x5b0b63)&&(_0x3e25b5['RDLoo'](_0x5b0b63,_0x558204)&&_0x3e25b5[_0x5009e8(0xfd)](_0x5b0b63,_0x5a7244)?!![]:hasLegacyProfileFiles(_0x5b0b63)))return _0x5b0b63;return null;}export function getEnvDir(_0x568806){const _0x3a8328=_0x9bd2,_0x3b8668={'hUhBu':function(_0x36b531){return _0x36b531();}},_0x51e631=_0x3b8668[_0x3a8328(0xca)](getRangerDir),_0x28ced9=findEnvInRoot(_0x568806,_0x51e631);if(_0x28ced9)return _0x28ced9;const _0x4fc75d=_0x3b8668[_0x3a8328(0xca)](getRangerHomeDir);if(_0x4fc75d!==_0x51e631){const _0xbcc776=findEnvInRoot(_0x568806,_0x4fc75d);if(_0xbcc776)return _0xbcc776;}return join(_0x51e631,'local',_0x568806);}function _0x127e(){const _0x590b2d=['location','allowInsecureLocalhost','--disable-features=WebBluetooth','UVdcV','chromium','20858893alRnbL','zoQiG','join','3jCUFiK','install','JypxI','10dnCknN','--allow-insecure-localhost','DtmyV','ranger-auth-','vSJXs','No\x20API\x20token\x20found.\x20Run:\x20ranger\x20setup\x20[token]','isArray','fromEntries','PhhLO','jmsIF','parse','vwJVq','clipboard-write','HFhsj','iATMC','local','hvycM','575518EiwKIb','NUETt','fZSKC','includes','IKZJC','launchOptions','FoJKP','DSVZe','headless','qbuHv','setupHeaders','entries','header','xYBxc','235551WAHDRo','boolean','HzBPB','keys','hUhBu','rangerDir','XmkEf','BAXTO','UkBgv','browser','vision','ZEvZu','stringify','length','161wlCjiw','3711912fyXuGl','zhbiQ','16DZqKPS','qZAkJ','tabs','storageStatePath','now','extraHTTPHeaders','Gjikh','getuid','contextOptions','--disable-web-security','args','.json','settings.json','push','legacy','2054335ZLLzBX','repeat','TocNR','Qwsqm','storageState','273704yopeUG','replace','playwright-cli','core','cOpkB','lUCIZ','--no-sandbox','sessions','2745909hFxxjT','QHoej','dHhgP','\x20is\x20not\x20set','all','userAgent','auth.json','TLCzD','map','filter','zBnOQ','object','tempAuthPath','aIicT','MMmWb','PReWV','path','string','juEsP'];_0x127e=function(){return _0x590b2d;};return _0x127e();}export function findExistingEnv(_0x4402ae,_0x58be99){const _0x253d94=_0x9bd2,_0xd2531c={'aIicT':function(_0x127ae6){return _0x127ae6();},'WXQYu':_0x253d94(0x120),'uSEyx':function(_0x1d638a,_0x5b9ba0,_0x29f197){return _0x1d638a(_0x5b9ba0,_0x29f197);},'vSJXs':function(_0x300ac2,_0x518184,_0x5066c8,_0x42ee34){return _0x300ac2(_0x518184,_0x5066c8,_0x42ee34);},'Qwsqm':function(_0x4f057a,_0x55c341){return _0x4f057a(_0x55c341);},'fZSKC':function(_0x316db5,_0x119201){return _0x316db5===_0x119201;},'DSVZe':'legacy'},_0xa23e87=_0x58be99?.[_0x253d94(0xcb)],_0xb31c63=_0xa23e87?[_0xa23e87]:[getRangerDir(),_0xd2531c[_0x253d94(0x100)](getRangerHomeDir)][_0x253d94(0xfc)]((_0x57400f,_0x504062,_0x1dabf5)=>_0x1dabf5['indexOf'](_0x57400f)===_0x504062),_0x9e1969=_0x58be99?.['locations']??['ci',_0xd2531c['WXQYu'],'legacy'];for(const _0x204bfb of _0xb31c63){const _0x50e6e8=join(_0x204bfb,'local'),_0x2ed21b=_0xd2531c['uSEyx'](join,_0x204bfb,'ci'),_0x30a29e=[{'location':'ci','path':_0xd2531c[_0x253d94(0x115)](join,_0x204bfb,'ci',_0x4402ae)},{'location':_0x253d94(0x120),'path':join(_0x204bfb,_0xd2531c['WXQYu'],_0x4402ae)},{'location':_0x253d94(0xe5),'path':join(_0x204bfb,_0x4402ae)}];for(const _0x1dfc7a of _0x30a29e){if(_0x9e1969['includes'](_0x1dfc7a[_0x253d94(0x106)])&&_0xd2531c[_0x253d94(0xe9)](existsSync,_0x1dfc7a[_0x253d94(0x103)])){if(_0xd2531c['fZSKC'](_0x1dfc7a['location'],_0xd2531c[_0x253d94(0xbf)])&&(_0x1dfc7a[_0x253d94(0x103)]===_0x50e6e8||_0xd2531c[_0x253d94(0x124)](_0x1dfc7a[_0x253d94(0x103)],_0x2ed21b))&&!hasLegacyProfileFiles(_0x1dfc7a['path']))continue;return{'path':_0x1dfc7a['path'],'location':_0x1dfc7a['location']};}}}return null;}function hasLegacyProfileFiles(_0x114b04){const _0x6af39a=_0x9bd2,_0x2a5a07={'IKZJC':function(_0x2cfcfb,_0x2dba09,_0x28163e){return _0x2cfcfb(_0x2dba09,_0x28163e);},'fOuVR':'auth.json'};return existsSync(_0x2a5a07[_0x6af39a(0x126)](join,_0x114b04,_0x6af39a(0xe3)))||existsSync(_0x2a5a07[_0x6af39a(0x126)](join,_0x114b04,_0x2a5a07['fOuVR']))||existsSync(_0x2a5a07['IKZJC'](join,_0x114b04,'auth.json.enc'));}export function isEnvCi(_0x18e9d3){const _0x4dbbb5=_0x9bd2,_0x240217={'cQcGQ':function(_0x527769,_0x296680){return _0x527769(_0x296680);},'sVggk':function(_0x29b212,_0x18b615,_0x225e65,_0x307d95){return _0x29b212(_0x18b615,_0x225e65,_0x307d95);},'PhhLO':function(_0x495661){return _0x495661();}};return _0x240217['cQcGQ'](existsSync,_0x240217['sVggk'](join,_0x240217[_0x4dbbb5(0x119)](getRangerDir),'ci',_0x18e9d3));}export async function cleanupTempFiles(_0x44a6ee){const _0x3dae77=_0x9bd2,_0x326f85={'DlHaB':function(_0x3b4b82,_0x243b9b){return _0x3b4b82!==_0x243b9b;},'gtcaY':'ENOENT'},_0x69574e=[_0x44a6ee[_0x3dae77(0xff)],_0x44a6ee['configPath']]['filter'](Boolean);await Promise[_0x3dae77(0xf7)](_0x69574e['map'](_0x3dd628=>unlink(_0x3dd628)['catch'](_0x25bf30=>{_0x326f85['DlHaB'](_0x25bf30['code'],_0x326f85['gtcaY'])&&console['warn']('Failed\x20to\x20clean\x20up\x20temp\x20file\x20'+_0x3dd628+':',_0x25bf30['message']);})));}export function getSettingsPath(_0x383279){const _0x551720=_0x9bd2,_0x74b8e8={'damDm':function(_0x1613e6,_0x20b461,_0x577826){return _0x1613e6(_0x20b461,_0x577826);},'eLXqX':function(_0x2585bf,_0x54bdca){return _0x2585bf(_0x54bdca);},'igKYe':_0x551720(0xe3)};return _0x74b8e8['damDm'](join,_0x74b8e8['eLXqX'](getEnvDir,_0x383279),_0x74b8e8['igKYe']);}export async function loadSettings(_0x12ab60){const _0x223e9a=_0x9bd2,_0x4b8355={'jmsIF':function(_0x42ae,_0x14b83b){return _0x42ae(_0x14b83b);},'DtmyV':function(_0x1cdb61,_0x484b73,_0x575f92){return _0x1cdb61(_0x484b73,_0x575f92);}},_0x1fccba=getSettingsPath(_0x12ab60);if(!_0x4b8355[_0x223e9a(0x11a)](existsSync,_0x1fccba))return{};try{const _0x178295=await _0x4b8355[_0x223e9a(0x113)](readFile,_0x1fccba,'utf-8');return JSON[_0x223e9a(0x11b)](_0x178295);}catch{return{};}}export async function saveSettings(_0x40ea40,_0x381ef8){const _0x56f9a9=_0x9bd2,_0x42e6cb={'hvycM':function(_0x3eb2f4,_0x1862a7){return _0x3eb2f4(_0x1862a7);},'dHhgP':function(_0x433412,_0x2a1f26){return _0x433412(_0x2a1f26);},'iEHnG':function(_0x45739a,_0x5de50e,_0x38e458){return _0x45739a(_0x5de50e,_0x38e458);}},_0x57ee94=_0x42e6cb[_0x56f9a9(0x121)](getSettingsPath,_0x40ea40),_0x20c87a=_0x42e6cb['hvycM'](dirname,_0x57ee94);!_0x42e6cb[_0x56f9a9(0xf5)](existsSync,_0x20c87a)&&await _0x42e6cb['iEHnG'](mkdir,_0x20c87a,{'recursive':!![]}),await writeFile(_0x57ee94,JSON[_0x56f9a9(0xd2)](_0x381ef8,null,0x2));}export function resolveEnvVars(_0x4e9958){const _0x43052e=_0x9bd2,_0x2b93e1={'vKSgj':function(_0x10c4eb,_0x32a5c6){return _0x10c4eb===_0x32a5c6;},'hMfMX':_0x43052e(0x104),'zhbiQ':'object'};if(typeof _0x4e9958===_0x2b93e1['hMfMX'])return _0x4e9958[_0x43052e(0xec)](/\$\{(\w+)\}/g,(_0x126ecd,_0x2c6165)=>{const _0x349632=_0x43052e,_0x195c85=process['env'][_0x2c6165];if(_0x2b93e1['vKSgj'](_0x195c85,undefined))throw new Error('Environment\x20variable\x20'+_0x2c6165+_0x349632(0xf6));return _0x195c85;});if(Array[_0x43052e(0x117)](_0x4e9958))return _0x4e9958['map'](resolveEnvVars);if(_0x4e9958&&typeof _0x4e9958===_0x2b93e1[_0x43052e(0xd6)])return Object[_0x43052e(0x118)](Object[_0x43052e(0xc3)](_0x4e9958)[_0x43052e(0xfb)](([_0x1b6712,_0x12bbfd])=>[_0x1b6712,resolveEnvVars(_0x12bbfd)]));return _0x4e9958;}const isRecord=_0x523c32=>typeof _0x523c32==='object'&&_0x523c32!==null&&!Array[_0x1f68ed(0x117)](_0x523c32),asRecord=_0x31d35d=>isRecord(_0x31d35d)?_0x31d35d:undefined,mergeHeaders=(_0x308afd,_0x42b0b8)=>{const _0x403aaa=_0x1f68ed,_0x2045ad={'Gjikh':function(_0x484ba4,_0x53e6b5){return _0x484ba4??_0x53e6b5;}},_0x168c7b={..._0x2045ad['Gjikh'](_0x308afd,{}),..._0x2045ad[_0x403aaa(0xdd)](_0x42b0b8,{})};return Object[_0x403aaa(0xc9)](_0x168c7b)['length']?_0x168c7b:undefined;},SAFE_MODE_ARGS=[_0x1f68ed(0x108)],ALLOW_LOCALHOST_ARGS=[_0x1f68ed(0xe0),'--allow-running-insecure-content','--unsafely-treat-insecure-origin-as-secure=http://localhost',_0x1f68ed(0x112)];export function buildBrowserOptionsFromSettings(_0x3d28b,_0x9bda3d={}){const _0x2353b2=_0x1f68ed,_0x18f61a={'xYBxc':function(_0x452fe3,_0x2ead80){return _0x452fe3(_0x2ead80);},'FlOYm':function(_0x3946c0,_0x1792e4){return _0x3946c0===_0x1792e4;},'UkBgv':_0x2353b2(0xc7),'lGOLN':'string','MMmWb':function(_0x59b0df,_0x7ff0db,_0x539835){return _0x59b0df(_0x7ff0db,_0x539835);}},_0x1941e3=asRecord(_0x3d28b[_0x2353b2(0xcf)]),_0x3b4b08={..._0x18f61a[_0x2353b2(0xc5)](asRecord,_0x1941e3?.[_0x2353b2(0x127)])??{}};_0x18f61a['FlOYm'](typeof _0x9bda3d['headless'],_0x18f61a[_0x2353b2(0xce)])&&(_0x3b4b08['headless']=_0x9bda3d['headless']);if(_0x3d28b['safeMode']){const _0xb8f2e9=_0x3b4b08['args']??[],_0x4dfaa0=SAFE_MODE_ARGS[_0x2353b2(0xfc)](_0x2f60da=>!_0xb8f2e9[_0x2353b2(0x125)](_0x2f60da));_0x3b4b08[_0x2353b2(0xe1)]=[..._0xb8f2e9,..._0x4dfaa0];}if(_0x3d28b[_0x2353b2(0x107)]){const _0x5cf5ee=_0x3b4b08['args']??[],_0x2250ba=ALLOW_LOCALHOST_ARGS[_0x2353b2(0xfc)](_0x2cfb7d=>!_0x5cf5ee[_0x2353b2(0x125)](_0x2cfb7d));_0x3b4b08['args']=[..._0x5cf5ee,..._0x2250ba];}const _0x3f9ac3={...asRecord(_0x1941e3?.['contextOptions'])??{}};_0x3f9ac3['ignoreHTTPSErrors']=!![];typeof _0x3d28b[_0x2353b2(0xf8)]===_0x18f61a['lGOLN']&&(_0x3f9ac3['userAgent']=_0x3d28b[_0x2353b2(0xf8)]);const _0x13e94d=_0x18f61a[_0x2353b2(0x101)](mergeHeaders,asRecord(_0x3f9ac3['extraHTTPHeaders']),_0x18f61a['xYBxc'](asRecord,_0x3d28b['headers']));return _0x13e94d?_0x3f9ac3[_0x2353b2(0xdc)]=_0x13e94d:delete _0x3f9ac3[_0x2353b2(0xdc)],_0x9bda3d['storageStatePath']&&(_0x3f9ac3[_0x2353b2(0xea)]=_0x9bda3d[_0x2353b2(0xda)]),{'launchOptions':_0x3b4b08,'contextOptions':_0x3f9ac3};}async function resolveLocalAuthPath(_0x40639f){const _0x164fe2=_0x1f68ed,_0x1efc02={'QHVoi':function(_0x2d6772,_0x12b00c,_0x4bfac3){return _0x2d6772(_0x12b00c,_0x4bfac3);},'zmqjF':'auth.json.enc','JypxI':_0x164fe2(0xf9),'fwEvD':function(_0x2be459,_0x21b21a){return _0x2be459(_0x21b21a);},'ljozB':function(_0x385839,_0x2ac9c9){return _0x385839(_0x2ac9c9);},'kokeC':function(_0x2dd1e9,_0x3cf7e1){return _0x2dd1e9(_0x3cf7e1);},'juEsP':function(_0x3b55b7,_0x6d603c){return _0x3b55b7(_0x6d603c);}},_0x465803=_0x1efc02['QHVoi'](join,_0x40639f,_0x1efc02['zmqjF']),_0x2e530c=join(_0x40639f,_0x1efc02[_0x164fe2(0x110)]);if(_0x1efc02['fwEvD'](existsSync,_0x465803))try{const _0xb81025=await getToken();if(!_0xb81025)throw new Error(_0x164fe2(0x116));const _0x140de5=await _0x1efc02['ljozB'](readFile,_0x465803),_0x2166f6=decrypt(_0x140de5,_0xb81025),_0xbe9929=_0x1efc02['QHVoi'](join,tmpdir(),_0x164fe2(0x114)+Date[_0x164fe2(0xdb)]()+_0x164fe2(0xe2));return await writeFile(_0xbe9929,_0x2166f6),{'storageStatePath':_0xbe9929,'tempAuthPath':_0xbe9929};}catch(_0x502334){const _0x132399=_0x502334 instanceof Error?_0x502334['message']:_0x1efc02['kokeC'](String,_0x502334);throw new Error('Failed\x20to\x20decrypt\x20auth\x20state:\x20'+_0x132399);}if(_0x1efc02[_0x164fe2(0x105)](existsSync,_0x2e530c))return{'storageStatePath':_0x2e530c};return{};}export async function buildPlaywrightConfig(_0x3f230a,_0x3ebc85,_0x2e914f,_0x1dabb3,_0x1d160d){const _0x29628e=_0x1f68ed,_0x251c59={'NUETt':function(_0x289e6e,_0x2411a6,_0x48f0c5,_0x20dd9b,_0x5a5111,_0x1ec49f,_0x3bea70){return _0x289e6e(_0x2411a6,_0x48f0c5,_0x20dd9b,_0x5a5111,_0x1ec49f,_0x3bea70);},'PReWV':function(_0x4acf6e,_0x41927a){return _0x4acf6e(_0x41927a);}};if(_0x1d160d)return _0x251c59[_0x29628e(0x123)](buildPlaywrightConfigCore,_0x3f230a,_0x1d160d,_0x3ebc85,_0x2e914f,_0x1dabb3,'stagehand');const {storageStatePath:_0x239840,tempAuthPath:_0x46c480}=await _0x251c59[_0x29628e(0x102)](resolveLocalAuthPath,getEnvDir(_0x3ebc85)),_0x634a8a=await buildPlaywrightConfigCore(_0x3f230a,_0x239840,_0x3ebc85,_0x2e914f,_0x1dabb3,'stagehand');return{..._0x634a8a,'tempAuthPath':_0x46c480};}export async function buildPlaywrightConfigCore(_0xbf97d8,_0x5e107b,_0x477222,_0x375a98,_0x3066f9,_0x35d107='stagehand'){const _0x17edff=_0x1f68ed,_0x460dea={'lUCIZ':function(_0x150ddc,_0x2a5ffd){return _0x150ddc===_0x2a5ffd;},'NJaGL':'--disable-setuid-sandbox','UVdcV':_0x17edff(0x11d),'HFhsj':function(_0x4a4b73){return _0x4a4b73();},'BVJpY':function(_0x2e247c){return _0x2e247c();},'iATMC':_0x17edff(0xed),'zoQiG':'file','IyRIG':_0x17edff(0xd9),'vwJVq':_0x17edff(0xd0),'XFbOA':function(_0x37a992,_0x151365,_0x692be9){return _0x37a992(_0x151365,_0x692be9);},'mKHvM':'ranger-config','BAXTO':function(_0x53cd3f,_0x37effe,_0x4d1d23){return _0x53cd3f(_0x37effe,_0x4d1d23);},'qbuHv':'-cli'},_0xa06b34=_0x375a98||_0x460dea[_0x17edff(0x11e)](randomUUID),_0x5d68c5=join(_0x460dea['BVJpY'](getRangerDir),_0x17edff(0xf2),_0xa06b34),_0x4e2534=Boolean(_0xbf97d8['cdpEndpoint']),_0x4e82ea=_0x4e2534?{'browserName':_0x17edff(0x10a),'cdpEndpoint':_0xbf97d8['cdpEndpoint']}:((()=>{const _0x5666be=_0x17edff,{launchOptions:_0x50188c,contextOptions:_0x346569}=buildBrowserOptionsFromSettings(_0xbf97d8,{'headless':_0x3066f9?![]:_0xbf97d8[_0x5666be(0xc0)]??!![],'storageStatePath':_0x5e107b});if(_0x460dea[_0x5666be(0xf0)](process[_0x5666be(0xde)]?.(),0x0)){const _0x4a3f71=[_0x5666be(0xf1),_0x460dea['NJaGL']],_0x446bb8=_0x50188c[_0x5666be(0xe1)]??[],_0x23963f=_0x4a3f71[_0x5666be(0xfc)](_0x5d1e85=>!_0x446bb8[_0x5666be(0x125)](_0x5d1e85));_0x50188c[_0x5666be(0xe1)]=[..._0x446bb8,..._0x23963f];}return{'isolated':!![],'browserName':_0x5666be(0x10a),'launchOptions':_0x50188c,'contextOptions':{..._0x346569,'permissions':['clipboard-read',_0x460dea[_0x5666be(0x109)]],'viewport':{'width':0x500,'height':0x2d0}}};})()),_0x1ab22a=_0x35d107===_0x460dea['iATMC']?{'browser':_0x4e82ea,'saveVideo':{'width':0x500,'height':0x2d0},'outputDir':_0x5d68c5,'outputMode':_0x460dea[_0x17edff(0x10c)],'codegen':'none'}:{'name':_0x477222,'browser':_0x4e82ea,'capabilities':[_0x17edff(0xee),_0x460dea['IyRIG'],_0x17edff(0x10f),'pdf',_0x460dea[_0x17edff(0x11c)]],'imageResponses':'allow','saveTrace':!![],'saveVideo':{'width':0x500,'height':0x2d0},'outputDir':_0x5d68c5};if(!_0x4e2534){const _0x335911=_0x1ab22a[_0x17edff(0xcf)],_0x54a52a=_0x335911[_0x17edff(0xdf)];if(_0x54a52a[_0x17edff(0xf8)]===undefined)delete _0x54a52a[_0x17edff(0xf8)];if(_0x54a52a[_0x17edff(0xea)]===undefined)delete _0x54a52a[_0x17edff(0xea)];}const _0x4a53a6=_0x460dea['XFbOA'](join,tmpdir(),_0x460dea['mKHvM']);!existsSync(_0x4a53a6)&&await _0x460dea[_0x17edff(0xcd)](mkdir,_0x4a53a6,{'recursive':!![]});const _0xa71db7=_0x35d107===_0x460dea[_0x17edff(0x11f)]?_0x460dea[_0x17edff(0xc1)]:'',_0xab2eaf=join(_0x4a53a6,_0x477222+'-'+Date['now']()+_0xa71db7+'.json');return await writeFile(_0xab2eaf,JSON['stringify'](_0x1ab22a,null,0x2)),{'configPath':_0xab2eaf};}export async function buildPlaywrightCliConfig(_0x2779ed,_0x7aca59,_0xa3b797,_0x18c039,_0x20b317){const _0x9e6bc3=_0x1f68ed,_0x2109c1={'QHoej':'playwright-cli','TLCzD':function(_0x20da6f,_0x5dbff5){return _0x20da6f(_0x5dbff5);}};if(_0x20b317)return buildPlaywrightConfigCore(_0x2779ed,_0x20b317,_0x7aca59,_0xa3b797,_0x18c039,_0x2109c1['QHoej']);const {storageStatePath:_0x333e06,tempAuthPath:_0x2384c0}=await resolveLocalAuthPath(_0x2109c1[_0x9e6bc3(0xfa)](getEnvDir,_0x7aca59)),_0xfb4291=await buildPlaywrightConfigCore(_0x2779ed,_0x333e06,_0x7aca59,_0xa3b797,_0x18c039,_0x2109c1[_0x9e6bc3(0xf4)]);return{..._0xfb4291,'tempAuthPath':_0x2384c0};}export function getNestedValue(_0x3ee6ec,_0x49bddf){const _0x5e5e67=_0x1f68ed,_0x29588d={'HzBPB':_0x5e5e67(0xfe)},_0x5528f7=parseKeyPath(_0x49bddf);let _0x1b3acd=_0x3ee6ec;for(const _0x483f75 of _0x5528f7){if(_0x1b3acd===null||_0x1b3acd===undefined||typeof _0x1b3acd!==_0x29588d[_0x5e5e67(0xc8)])return undefined;_0x1b3acd=_0x1b3acd[_0x483f75];}return _0x1b3acd;}export function setNestedValue(_0x1d2697,_0x49c557,_0x1e3794){const _0x4da44b=_0x1f68ed,_0x5213d1={'cOpkB':function(_0x473f40,_0x1d68b8){return _0x473f40<_0x1d68b8;},'BCciH':function(_0x211e7d,_0x5d708b){return _0x211e7d-_0x5d708b;},'ZEvZu':function(_0x56ce1c,_0x316dab){return _0x56ce1c-_0x316dab;}},_0x1eaf4a=parseKeyPath(_0x49c557);let _0x4dac57=_0x1d2697;for(let _0x49fbcc=0x0;_0x5213d1[_0x4da44b(0xef)](_0x49fbcc,_0x5213d1['BCciH'](_0x1eaf4a[_0x4da44b(0xd3)],0x1));_0x49fbcc++){const _0x2893df=_0x1eaf4a[_0x49fbcc];(!(_0x2893df in _0x4dac57)||typeof _0x4dac57[_0x2893df]!==_0x4da44b(0xfe))&&(_0x4dac57[_0x2893df]={}),_0x4dac57=_0x4dac57[_0x2893df];}_0x4dac57[_0x1eaf4a[_0x5213d1[_0x4da44b(0xd1)](_0x1eaf4a['length'],0x1)]]=_0x1e3794;}function _0x9bd2(_0x671a29,_0x2cb4d2){_0x671a29=_0x671a29-0xbf;const _0x127ee4=_0x127e();let _0x9bd21d=_0x127ee4[_0x671a29];return _0x9bd21d;}export function deleteNestedValue(_0x48bc22,_0x5592ce){const _0x33dfe0=_0x1f68ed,_0x2a9e92={'hSCkJ':function(_0x5548dd,_0x289e15){return _0x5548dd-_0x289e15;},'qZAkJ':function(_0x3292a4,_0x16053a){return _0x3292a4 in _0x16053a;}},_0x35a41f=parseKeyPath(_0x5592ce);let _0x2902b6=_0x48bc22;for(let _0x1da8c3=0x0;_0x1da8c3<_0x2a9e92['hSCkJ'](_0x35a41f['length'],0x1);_0x1da8c3++){if(_0x2902b6===null||_0x2902b6===undefined||typeof _0x2902b6!==_0x33dfe0(0xfe))return![];_0x2902b6=_0x2902b6[_0x35a41f[_0x1da8c3]];}if(_0x2902b6===null||_0x2902b6===undefined||typeof _0x2902b6!=='object')return![];const _0x37e1c9=_0x35a41f[_0x35a41f['length']-0x1];if(_0x2a9e92[_0x33dfe0(0xd8)](_0x37e1c9,_0x2902b6))return delete _0x2902b6[_0x37e1c9],!![];return![];}function parseKeyPath(_0x56c7e0){const _0x5b079c=_0x1f68ed,_0x531e90={'dyjzD':function(_0x46e63a,_0x4f5e0b){return _0x46e63a===_0x4f5e0b;},'Dnede':_0x5b079c(0xc4),'HEpgy':'headers'},_0x1d5fd2=_0x56c7e0['split']('.');return _0x531e90['dyjzD'](_0x1d5fd2[0x0],_0x531e90['Dnede'])&&(_0x1d5fd2[0x0]=_0x531e90['HEpgy']),_0x1d5fd2[0x0]==='setupHeader'&&(_0x1d5fd2[0x0]=_0x5b079c(0xc2)),_0x1d5fd2;}export function formatSettings(_0x4e14a0,_0x3ec3d7=0x0){const _0x538a3f=_0x1f68ed,_0x30569f={'fkmjf':function(_0x639610,_0x4eccc3){return _0x639610!==_0x4eccc3;}},_0x524004=[],_0x529c78='\x20\x20'[_0x538a3f(0xe7)](_0x3ec3d7);for(const [_0x387496,_0x14c9d1]of Object['entries'](_0x4e14a0)){if(_0x14c9d1===undefined)continue;if(typeof _0x14c9d1===_0x538a3f(0xfe)&&_0x30569f['fkmjf'](_0x14c9d1,null)){_0x524004['push'](''+_0x529c78+_0x387496+':');for(const [_0x42930c,_0x29d857]of Object['entries'](_0x14c9d1)){_0x524004['push'](_0x529c78+'\x20\x20'+_0x42930c+':\x20'+_0x29d857);}}else _0x524004[_0x538a3f(0xe4)](''+_0x529c78+_0x387496+':\x20'+_0x14c9d1);}return _0x524004[_0x538a3f(0x10d)]('\x0a');}
1
+ const _0x237b3b=_0x359b;(function(_0x220c0b,_0x5035ad){const _0x5d427c=_0x359b,_0x248fc0=_0x220c0b();while(!![]){try{const _0x99220d=parseInt(_0x5d427c(0xb1))/0x1+parseInt(_0x5d427c(0xe4))/0x2+-parseInt(_0x5d427c(0xa3))/0x3*(-parseInt(_0x5d427c(0xb4))/0x4)+parseInt(_0x5d427c(0xf3))/0x5*(parseInt(_0x5d427c(0xdb))/0x6)+parseInt(_0x5d427c(0xfc))/0x7*(-parseInt(_0x5d427c(0xec))/0x8)+parseInt(_0x5d427c(0xaa))/0x9+-parseInt(_0x5d427c(0xdc))/0xa;if(_0x99220d===_0x5035ad)break;else _0x248fc0['push'](_0x248fc0['shift']());}catch(_0x13e8ea){_0x248fc0['push'](_0x248fc0['shift']());}}}(_0x5b93,0xa2fb2));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{decrypt}from'./crypto.js';import{getToken}from'./keychain.js';import{getRangerDir,getRangerHomeDir}from'./rangerRoot.js';function findEnvInRoot(_0x128bb1,_0x34bc56){const _0x3d555a=_0x359b,_0x2eebb5={'RGGmX':'local','ozWDT':function(_0x49917e,_0x174807,_0x141bd8){return _0x49917e(_0x174807,_0x141bd8);},'Tplet':function(_0x6fe400,_0x105ec2){return _0x6fe400(_0x105ec2);},'OMvlf':function(_0x44c4d9,_0x2a0e02){return _0x44c4d9!==_0x2a0e02;},'sfNDr':function(_0x2d382c,_0x6fc188){return _0x2d382c!==_0x6fc188;}},_0x2ad1ac=join(_0x34bc56,'ci',_0x128bb1),_0x359a6b=join(_0x34bc56,_0x2eebb5['RGGmX'],_0x128bb1),_0xfcff65=_0x2eebb5['ozWDT'](join,_0x34bc56,_0x128bb1),_0x3db14b=join(_0x34bc56,'local'),_0x266e47=join(_0x34bc56,'ci');if(_0x2eebb5[_0x3d555a(0xa7)](existsSync,_0x2ad1ac))return _0x2ad1ac;if(existsSync(_0x359a6b))return _0x359a6b;if(existsSync(_0xfcff65)&&(_0x2eebb5['OMvlf'](_0xfcff65,_0x3db14b)&&_0x2eebb5[_0x3d555a(0x10b)](_0xfcff65,_0x266e47)?!![]:hasLegacyProfileFiles(_0xfcff65)))return _0xfcff65;return null;}export function getEnvDir(_0x12fb8b){const _0x2ffb00=_0x359b,_0x2990fa={'yjxPc':function(_0x2f5ce9){return _0x2f5ce9();},'ZOnMr':function(_0x231d72){return _0x231d72();},'HDCWU':function(_0x26f256,_0xcd1a88){return _0x26f256!==_0xcd1a88;},'GVkKj':'local'},_0x4eb83c=_0x2990fa[_0x2ffb00(0xf9)](getRangerDir),_0x2b5ee3=findEnvInRoot(_0x12fb8b,_0x4eb83c);if(_0x2b5ee3)return _0x2b5ee3;const _0xd8b5ae=_0x2990fa[_0x2ffb00(0xaf)](getRangerHomeDir);if(_0x2990fa['HDCWU'](_0xd8b5ae,_0x4eb83c)){const _0x2fa2c8=findEnvInRoot(_0x12fb8b,_0xd8b5ae);if(_0x2fa2c8)return _0x2fa2c8;}return join(_0x4eb83c,_0x2990fa['GVkKj'],_0x12fb8b);}export function findExistingEnv(_0x3c00be,_0x1cde76){const _0x1f866d=_0x359b,_0x5a10ee={'qnXNT':_0x1f866d(0xe0),'BJYJZ':function(_0x3c406e,_0x5d8a31,_0x46af1d){return _0x3c406e(_0x5d8a31,_0x46af1d);},'jjRMI':function(_0x5cbefe,_0x364db5,_0x19f4dd,_0x35c4a9){return _0x5cbefe(_0x364db5,_0x19f4dd,_0x35c4a9);},'sqbLZ':_0x1f866d(0x100),'qCwAZ':function(_0xe84b4,_0x506fdb){return _0xe84b4(_0x506fdb);},'uBlzP':function(_0x5dccf9,_0x3634ea){return _0x5dccf9===_0x3634ea;},'bmUlq':function(_0x28e5cf,_0x4b0e75){return _0x28e5cf===_0x4b0e75;}},_0x459cd6=_0x1cde76?.['rangerDir'],_0x4a5f4b=_0x459cd6?[_0x459cd6]:[getRangerDir(),getRangerHomeDir()]['filter']((_0x48cd4c,_0x31a0bb,_0x20eb0c)=>_0x20eb0c[_0x1f866d(0xae)](_0x48cd4c)===_0x31a0bb),_0x3d12d4=_0x1cde76?.[_0x1f866d(0xab)]??['ci',_0x5a10ee['qnXNT'],_0x1f866d(0x100)];for(const _0x4384ae of _0x4a5f4b){const _0x47f6f6=_0x5a10ee[_0x1f866d(0xda)](join,_0x4384ae,_0x1f866d(0xe0)),_0x5233e7=_0x5a10ee['BJYJZ'](join,_0x4384ae,'ci'),_0x3adaa8=[{'location':'ci','path':join(_0x4384ae,'ci',_0x3c00be)},{'location':_0x5a10ee[_0x1f866d(0xa5)],'path':_0x5a10ee['jjRMI'](join,_0x4384ae,_0x5a10ee['qnXNT'],_0x3c00be)},{'location':_0x5a10ee[_0x1f866d(0x111)],'path':join(_0x4384ae,_0x3c00be)}];for(const _0x3f6d86 of _0x3adaa8){if(_0x3d12d4[_0x1f866d(0xef)](_0x3f6d86['location'])&&_0x5a10ee[_0x1f866d(0xd6)](existsSync,_0x3f6d86['path'])){if(_0x3f6d86['location']==='legacy'&&(_0x5a10ee['uBlzP'](_0x3f6d86[_0x1f866d(0xb8)],_0x47f6f6)||_0x5a10ee['bmUlq'](_0x3f6d86['path'],_0x5233e7))&&!hasLegacyProfileFiles(_0x3f6d86['path']))continue;return{'path':_0x3f6d86['path'],'location':_0x3f6d86[_0x1f866d(0xd0)]};}}}return null;}function hasLegacyProfileFiles(_0x100876){const _0x3bd3d1=_0x359b,_0x36d965={'AVeHP':function(_0x211b1e,_0x50dc1){return _0x211b1e(_0x50dc1);},'gnBmS':function(_0x7b84ac,_0x35795f,_0x41fdfe){return _0x7b84ac(_0x35795f,_0x41fdfe);}};return _0x36d965[_0x3bd3d1(0x102)](existsSync,join(_0x100876,_0x3bd3d1(0xce)))||existsSync(_0x36d965[_0x3bd3d1(0xb3)](join,_0x100876,'auth.json'))||_0x36d965[_0x3bd3d1(0x102)](existsSync,join(_0x100876,_0x3bd3d1(0xbb)));}function _0x5b93(){const _0x3ea85b=['pdf','gnBmS','2437216AcTTYN','ZLeGo','EEWLk','GxnKP','path','qxPzG','Geldy','auth.json.enc','BLdMU','VBxri','xWMRV','IQJmG','TmJyx','OLGcK','ranger-auth-','playwright-cli','HACQM','keys','stringify','object','extraHTTPHeaders','--unsafely-treat-insecure-origin-as-secure=http://localhost','IIHgg','-cli','chromium','yQYkE','settings.json','all','location','sessions','QvZSk','setupHeaders','boolean','ENOENT','qCwAZ','parse','string','RhOqq','BJYJZ','1980654dUHhbJ','36192800EoAXmu','QokfK','vJtoL','Slnbg','local','OJtTj','userAgent','storageState','2647840RUlszB','qFQqR','bjRXR','VwVYE','fplEJ','args','install','catch','16xzyCBe','storageStatePath','--disable-features=WebBluetooth','includes','vision','entries','TQeii','15PwDNNZ','split','--disable-setuid-sandbox','clipboard-write','liRpI','npZWO','yjxPc','setupHeader','contextOptions','3130995BiyfFm','headless','browser','length','legacy','ovIsG','AVeHP','filter','auth.json','cdpEndpoint','--no-sandbox','LuhmH','stagehand','puSan','ranger-config','sfNDr','tempAuthPath','push','\x20is\x20not\x20set','env','tabs','sqbLZ','3LYRcut','yQgZd','qnXNT','vvKkF','Tplet','now','utf-8','9080973kCmRyQ','locations','hmOGQ','isArray','indexOf','ZOnMr','BBSnu','1248872HAMkdK'];_0x5b93=function(){return _0x3ea85b;};return _0x5b93();}export function isEnvCi(_0x2f04d7){const _0x29e529=_0x359b,_0x235aaa={'BCBLd':function(_0x51e73f){return _0x51e73f();},'QokfK':function(_0x4a9c6e,_0x391b19){return _0x4a9c6e!==_0x391b19;},'EEWLk':function(_0x5ba09b){return _0x5ba09b();},'ZLeGo':function(_0x5d3a37,_0x1da6bb){return _0x5d3a37(_0x1da6bb);}};if(existsSync(join(getRangerDir(),'ci',_0x2f04d7)))return!![];const _0x3b6089=_0x235aaa['BCBLd'](getRangerHomeDir);if(_0x235aaa[_0x29e529(0xdd)](_0x3b6089,_0x235aaa[_0x29e529(0xb6)](getRangerDir))&&_0x235aaa[_0x29e529(0xb5)](existsSync,join(_0x3b6089,'ci',_0x2f04d7)))return!![];return![];}export async function cleanupTempFiles(_0xfc0012){const _0x258df5=_0x359b,_0x316163=[_0xfc0012[_0x258df5(0x10c)],_0xfc0012['configPath']][_0x258df5(0x103)](Boolean);await Promise[_0x258df5(0xcf)](_0x316163['map'](_0x40155e=>unlink(_0x40155e)[_0x258df5(0xeb)](_0x45fc23=>{const _0x3e16d4=_0x258df5;_0x45fc23['code']!==_0x3e16d4(0xd5)&&console['warn']('Failed\x20to\x20clean\x20up\x20temp\x20file\x20'+_0x40155e+':',_0x45fc23['message']);})));}export function getSettingsPath(_0x190c98){const _0x1de925=_0x359b,_0x3506f7={'HLvnq':function(_0x732472,_0xfdb8d1,_0x162099){return _0x732472(_0xfdb8d1,_0x162099);},'TmJyx':function(_0xede8a0,_0x346a84){return _0xede8a0(_0x346a84);},'GxnKP':'settings.json'};return _0x3506f7['HLvnq'](join,_0x3506f7[_0x1de925(0xc0)](getEnvDir,_0x190c98),_0x3506f7[_0x1de925(0xb7)]);}export async function loadSettings(_0x212ca5){const _0x556457=_0x359b,_0x5b3aef={'BLdMU':function(_0x795b66,_0x7304d0){return _0x795b66(_0x7304d0);},'xWMRV':function(_0x5afd86,_0x1236cc){return _0x5afd86(_0x1236cc);},'FLUiS':function(_0x2bc228,_0x2c9613,_0x4a9bf8){return _0x2bc228(_0x2c9613,_0x4a9bf8);}},_0x4c25d2=_0x5b3aef[_0x556457(0xbc)](getSettingsPath,_0x212ca5);if(!_0x5b3aef[_0x556457(0xbe)](existsSync,_0x4c25d2))return{};try{const _0x5bbe6a=await _0x5b3aef['FLUiS'](readFile,_0x4c25d2,_0x556457(0xa9));return JSON[_0x556457(0xd7)](_0x5bbe6a);}catch{return{};}}export async function saveSettings(_0x5c67f7,_0x45341f){const _0xa16097=_0x359b,_0x4bc9ad={'LNdhD':function(_0x13896d,_0x3744bf){return _0x13896d(_0x3744bf);},'OLGcK':function(_0x535c96,_0x5736a0,_0x1d1401){return _0x535c96(_0x5736a0,_0x1d1401);}},_0x429c8b=_0x4bc9ad['LNdhD'](getSettingsPath,_0x5c67f7),_0x2873de=dirname(_0x429c8b);!_0x4bc9ad['LNdhD'](existsSync,_0x2873de)&&await _0x4bc9ad[_0xa16097(0xc1)](mkdir,_0x2873de,{'recursive':!![]}),await writeFile(_0x429c8b,JSON[_0xa16097(0xc6)](_0x45341f,null,0x2));}export function resolveEnvVars(_0x336c12){const _0x11ea04=_0x359b,_0x2f8838={'Geldy':function(_0x60cd4a,_0x390a3e){return _0x60cd4a===_0x390a3e;}};if(_0x2f8838[_0x11ea04(0xba)](typeof _0x336c12,'string'))return _0x336c12['replace'](/\$\{(\w+)\}/g,(_0x28e815,_0x286cf9)=>{const _0x4b3f7b=_0x11ea04,_0x39d2c1=process[_0x4b3f7b(0x10f)][_0x286cf9];if(_0x39d2c1===undefined)throw new Error('Environment\x20variable\x20'+_0x286cf9+_0x4b3f7b(0x10e));return _0x39d2c1;});if(Array[_0x11ea04(0xad)](_0x336c12))return _0x336c12['map'](resolveEnvVars);if(_0x336c12&&typeof _0x336c12==='object')return Object['fromEntries'](Object[_0x11ea04(0xf1)](_0x336c12)['map'](([_0x383394,_0x547f89])=>[_0x383394,resolveEnvVars(_0x547f89)]));return _0x336c12;}const isRecord=_0x241851=>typeof _0x241851===_0x237b3b(0xc7)&&_0x241851!==null&&!Array[_0x237b3b(0xad)](_0x241851),asRecord=_0x5e7c9a=>isRecord(_0x5e7c9a)?_0x5e7c9a:undefined,mergeHeaders=(_0x1668f3,_0x2bfebf)=>{const _0x326ca1=_0x237b3b,_0x1d2912={'yQgZd':function(_0x238aa4,_0x4f75da){return _0x238aa4??_0x4f75da;}},_0x57135f={..._0x1d2912['yQgZd'](_0x1668f3,{}),..._0x1d2912[_0x326ca1(0xa4)](_0x2bfebf,{})};return Object[_0x326ca1(0xc5)](_0x57135f)['length']?_0x57135f:undefined;},SAFE_MODE_ARGS=[_0x237b3b(0xee)],ALLOW_LOCALHOST_ARGS=['--disable-web-security','--allow-running-insecure-content',_0x237b3b(0xc9),'--allow-insecure-localhost'];export function buildBrowserOptionsFromSettings(_0x191cae,_0xeb2ca7={}){const _0x24535c=_0x237b3b,_0x6d0a5e={'NQzAm':function(_0x4bdb58,_0x2c1f0f){return _0x4bdb58===_0x2c1f0f;},'ojFEU':_0x24535c(0xd4),'fplEJ':function(_0x3fc09d,_0x2551e6){return _0x3fc09d(_0x2551e6);}},_0x2ab3ee=asRecord(_0x191cae[_0x24535c(0xfe)]),_0x298d20={...asRecord(_0x2ab3ee?.['launchOptions'])??{}};_0x6d0a5e['NQzAm'](typeof _0xeb2ca7[_0x24535c(0xfd)],_0x6d0a5e['ojFEU'])&&(_0x298d20[_0x24535c(0xfd)]=_0xeb2ca7[_0x24535c(0xfd)]);if(_0x191cae['safeMode']){const _0x2cf64d=_0x298d20['args']??[],_0x2a3afb=SAFE_MODE_ARGS[_0x24535c(0x103)](_0x5d4b42=>!_0x2cf64d[_0x24535c(0xef)](_0x5d4b42));_0x298d20['args']=[..._0x2cf64d,..._0x2a3afb];}if(_0x191cae['allowInsecureLocalhost']){const _0x4f0683=_0x298d20[_0x24535c(0xe9)]??[],_0x163cc1=ALLOW_LOCALHOST_ARGS[_0x24535c(0x103)](_0x3470cd=>!_0x4f0683['includes'](_0x3470cd));_0x298d20[_0x24535c(0xe9)]=[..._0x4f0683,..._0x163cc1];}const _0x14fe27={..._0x6d0a5e[_0x24535c(0xe8)](asRecord,_0x2ab3ee?.[_0x24535c(0xfb)])??{}};_0x14fe27['ignoreHTTPSErrors']=!![];typeof _0x191cae[_0x24535c(0xe2)]===_0x24535c(0xd8)&&(_0x14fe27['userAgent']=_0x191cae[_0x24535c(0xe2)]);const _0x13ac09=mergeHeaders(asRecord(_0x14fe27['extraHTTPHeaders']),asRecord(_0x191cae['headers']));return _0x13ac09?_0x14fe27[_0x24535c(0xc8)]=_0x13ac09:delete _0x14fe27[_0x24535c(0xc8)],_0xeb2ca7['storageStatePath']&&(_0x14fe27[_0x24535c(0xe3)]=_0xeb2ca7[_0x24535c(0xed)]),{'launchOptions':_0x298d20,'contextOptions':_0x14fe27};}async function resolveLocalAuthPath(_0xc46b6a){const _0x2e9e0e=_0x237b3b,_0x508a={'xiZNg':_0x2e9e0e(0xbb),'TFVoY':_0x2e9e0e(0x104),'OJtTj':function(_0xeed5b7,_0x9fdb21){return _0xeed5b7(_0x9fdb21);},'QvZSk':'No\x20API\x20token\x20found.\x20Run:\x20ranger\x20setup\x20[token]','IQJmG':function(_0x430a07,_0x3ac456,_0x3fd023){return _0x430a07(_0x3ac456,_0x3fd023);},'rInVx':function(_0x21e340){return _0x21e340();},'SQLJn':function(_0x121eac,_0x27c2a9){return _0x121eac instanceof _0x27c2a9;}},_0x55218e=join(_0xc46b6a,_0x508a['xiZNg']),_0x2500c4=join(_0xc46b6a,_0x508a['TFVoY']);if(_0x508a['OJtTj'](existsSync,_0x55218e))try{const _0x254214=await getToken();if(!_0x254214)throw new Error(_0x508a[_0x2e9e0e(0xd2)]);const _0x3d6288=await _0x508a[_0x2e9e0e(0xe1)](readFile,_0x55218e),_0x15ac4f=_0x508a['IQJmG'](decrypt,_0x3d6288,_0x254214),_0x394160=_0x508a[_0x2e9e0e(0xbf)](join,_0x508a['rInVx'](tmpdir),_0x2e9e0e(0xc2)+Date[_0x2e9e0e(0xa8)]()+'.json');return await writeFile(_0x394160,_0x15ac4f),{'storageStatePath':_0x394160,'tempAuthPath':_0x394160};}catch(_0x589a39){const _0x1481f6=_0x508a['SQLJn'](_0x589a39,Error)?_0x589a39['message']:String(_0x589a39);throw new Error('Failed\x20to\x20decrypt\x20auth\x20state:\x20'+_0x1481f6);}if(existsSync(_0x2500c4))return{'storageStatePath':_0x2500c4};return{};}export async function buildPlaywrightConfig(_0x597b5c,_0x4aa5ac,_0x339eb8,_0x860b9f,_0x528400){const _0x2e1758=_0x237b3b,_0x18aedb={'qBlMf':_0x2e1758(0x108)};if(_0x528400)return buildPlaywrightConfigCore(_0x597b5c,_0x528400,_0x4aa5ac,_0x339eb8,_0x860b9f,_0x18aedb['qBlMf']);const {storageStatePath:_0x465f4e,tempAuthPath:_0x35b0a4}=await resolveLocalAuthPath(getEnvDir(_0x4aa5ac));try{const _0x1fe059=await buildPlaywrightConfigCore(_0x597b5c,_0x465f4e,_0x4aa5ac,_0x339eb8,_0x860b9f,'stagehand');return{..._0x1fe059,'tempAuthPath':_0x35b0a4};}catch(_0x5ad3ca){_0x35b0a4&&await unlink(_0x35b0a4)['catch'](()=>{});throw _0x5ad3ca;}}export async function buildPlaywrightConfigCore(_0x5d89eb,_0x1d95cc,_0x1865e5,_0x4117c4,_0x2437b7,_0x1fb4e8='stagehand'){const _0x1e9abf=_0x237b3b,_0x49e78b={'LuhmH':function(_0x571c03,_0x130a90,_0x3c27f2){return _0x571c03(_0x130a90,_0x3c27f2);},'bjRXR':'clipboard-read','taNrO':_0x1e9abf(0xf6),'vvKkF':function(_0x321f87){return _0x321f87();},'xQkXC':function(_0x4c8909,_0x2aa175,_0x13eb77,_0x16eb41){return _0x4c8909(_0x2aa175,_0x13eb77,_0x16eb41);},'HNXhG':function(_0x4f070d,_0x570729){return _0x4f070d(_0x570729);},'BBSnu':'playwright-cli','eJDrB':'none','npZWO':'core','VBxri':_0x1e9abf(0xf0),'bbtlb':function(_0x3b9d2d,_0x49e376){return _0x3b9d2d===_0x49e376;},'pLrSp':function(_0x5dd61f,_0x30e1f2,_0x4942b5){return _0x5dd61f(_0x30e1f2,_0x4942b5);},'hmOGQ':function(_0x4e7113,_0x37597a){return _0x4e7113(_0x37597a);},'IIHgg':function(_0x13b7b6,_0x3cefd7){return _0x13b7b6===_0x3cefd7;}},_0x523de6=_0x4117c4||_0x49e78b[_0x1e9abf(0xa6)](randomUUID),_0x202693=_0x49e78b['xQkXC'](join,getRangerDir(),_0x1e9abf(0xd1),_0x523de6),_0x44b339=_0x49e78b['HNXhG'](Boolean,_0x5d89eb[_0x1e9abf(0x105)]),_0x19d7ef=_0x44b339?{'browserName':_0x1e9abf(0xcc),'cdpEndpoint':_0x5d89eb[_0x1e9abf(0x105)]}:((()=>{const _0x883e58=_0x1e9abf,{launchOptions:_0x2a486d,contextOptions:_0x514ac8}=_0x49e78b[_0x883e58(0x107)](buildBrowserOptionsFromSettings,_0x5d89eb,{'headless':_0x2437b7?![]:_0x5d89eb[_0x883e58(0xfd)]??!![],'storageStatePath':_0x1d95cc});if(process['getuid']?.()===0x0){const _0x2feadd=[_0x883e58(0x106),_0x883e58(0xf5)],_0x25fe90=_0x2a486d[_0x883e58(0xe9)]??[],_0x38614b=_0x2feadd[_0x883e58(0x103)](_0x2ce3bd=>!_0x25fe90['includes'](_0x2ce3bd));_0x2a486d['args']=[..._0x25fe90,..._0x38614b];}return{'isolated':!![],'browserName':_0x883e58(0xcc),'launchOptions':_0x2a486d,'contextOptions':{..._0x514ac8,'permissions':[_0x49e78b[_0x883e58(0xe6)],_0x49e78b['taNrO']],'viewport':{'width':0x500,'height':0x2d0}}};})()),_0x525614=_0x1fb4e8===_0x49e78b[_0x1e9abf(0xb0)]?{'browser':_0x19d7ef,'saveVideo':{'width':0x500,'height':0x2d0},'outputDir':_0x202693,'outputMode':'file','codegen':_0x49e78b['eJDrB']}:{'name':_0x1865e5,'browser':_0x19d7ef,'capabilities':[_0x49e78b[_0x1e9abf(0xf8)],_0x1e9abf(0x110),_0x1e9abf(0xea),_0x1e9abf(0xb2),_0x49e78b[_0x1e9abf(0xbd)]],'imageResponses':'allow','saveTrace':!![],'saveVideo':{'width':0x500,'height':0x2d0},'outputDir':_0x202693};if(!_0x44b339){const _0x31def4=_0x525614[_0x1e9abf(0xfe)],_0x49985f=_0x31def4[_0x1e9abf(0xfb)];if(_0x49985f['userAgent']===undefined)delete _0x49985f[_0x1e9abf(0xe2)];if(_0x49e78b['bbtlb'](_0x49985f['storageState'],undefined))delete _0x49985f[_0x1e9abf(0xe3)];}const _0x3b280a=_0x49e78b['pLrSp'](join,tmpdir(),_0x1e9abf(0x10a));!_0x49e78b[_0x1e9abf(0xac)](existsSync,_0x3b280a)&&await mkdir(_0x3b280a,{'recursive':!![]});const _0x45b993=_0x49e78b[_0x1e9abf(0xca)](_0x1fb4e8,_0x1e9abf(0xc3))?_0x1e9abf(0xcb):'',_0x57de7f=join(_0x3b280a,_0x1865e5+'-'+Date[_0x1e9abf(0xa8)]()+_0x45b993+'.json');return await _0x49e78b['LuhmH'](writeFile,_0x57de7f,JSON['stringify'](_0x525614,null,0x2)),{'configPath':_0x57de7f};}function _0x359b(_0x25ee40,_0x3f7d7c){_0x25ee40=_0x25ee40-0xa3;const _0x5b931a=_0x5b93();let _0x359b0f=_0x5b931a[_0x25ee40];return _0x359b0f;}export async function buildPlaywrightCliConfig(_0x3f4a3,_0x567c83,_0x2b9c10,_0x458682,_0x303cac){const _0x690626=_0x237b3b,_0x4ab754={'vYcwQ':function(_0x359de2,_0x163d33,_0x206e42,_0x2c98ff,_0x3da625,_0x258bd4,_0x56d433){return _0x359de2(_0x163d33,_0x206e42,_0x2c98ff,_0x3da625,_0x258bd4,_0x56d433);},'YJwSv':function(_0x2bf96b,_0x283b55){return _0x2bf96b(_0x283b55);},'yQYkE':function(_0x3868ab,_0x101077,_0x2f40fd,_0xdd83a1,_0x5983ec,_0x5aac46,_0x2a5f42){return _0x3868ab(_0x101077,_0x2f40fd,_0xdd83a1,_0x5983ec,_0x5aac46,_0x2a5f42);}};if(_0x303cac)return _0x4ab754['vYcwQ'](buildPlaywrightConfigCore,_0x3f4a3,_0x303cac,_0x567c83,_0x2b9c10,_0x458682,'playwright-cli');const {storageStatePath:_0x4f220d,tempAuthPath:_0x341cab}=await resolveLocalAuthPath(_0x4ab754['YJwSv'](getEnvDir,_0x567c83));try{const _0x92d901=await _0x4ab754[_0x690626(0xcd)](buildPlaywrightConfigCore,_0x3f4a3,_0x4f220d,_0x567c83,_0x2b9c10,_0x458682,'playwright-cli');return{..._0x92d901,'tempAuthPath':_0x341cab};}catch(_0x3f16fe){_0x341cab&&await unlink(_0x341cab)['catch'](()=>{});throw _0x3f16fe;}}export function getNestedValue(_0xa46035,_0x2f23f0){const _0x1658c1=_0x237b3b,_0x50d9f9={'ovIsG':function(_0x2b1ac7,_0x5e0ef0){return _0x2b1ac7(_0x5e0ef0);},'AVMoE':function(_0x4348a,_0x4e3f8f){return _0x4348a===_0x4e3f8f;},'vJtoL':'object'},_0x298750=_0x50d9f9[_0x1658c1(0x101)](parseKeyPath,_0x2f23f0);let _0x495180=_0xa46035;for(const _0x3a79e9 of _0x298750){if(_0x495180===null||_0x50d9f9['AVMoE'](_0x495180,undefined)||typeof _0x495180!==_0x50d9f9[_0x1658c1(0xde)])return undefined;_0x495180=_0x495180[_0x3a79e9];}return _0x495180;}export function setNestedValue(_0x5b047a,_0x2f650e,_0x135c92){const _0x43e449=_0x237b3b,_0x35a5c9={'VwVYE':function(_0x5b5aa5,_0x52fb8c){return _0x5b5aa5 in _0x52fb8c;},'liRpI':function(_0x51b620,_0x559d49){return _0x51b620!==_0x559d49;},'HACQM':'object','qFQqR':function(_0x4f76fa,_0x367c81){return _0x4f76fa-_0x367c81;}},_0x13b4c0=parseKeyPath(_0x2f650e);let _0x374a66=_0x5b047a;for(let _0x483bfd=0x0;_0x483bfd<_0x13b4c0[_0x43e449(0xff)]-0x1;_0x483bfd++){const _0x1037f4=_0x13b4c0[_0x483bfd];(!_0x35a5c9[_0x43e449(0xe7)](_0x1037f4,_0x374a66)||_0x35a5c9[_0x43e449(0xf7)](typeof _0x374a66[_0x1037f4],_0x35a5c9[_0x43e449(0xc4)]))&&(_0x374a66[_0x1037f4]={}),_0x374a66=_0x374a66[_0x1037f4];}_0x374a66[_0x13b4c0[_0x35a5c9[_0x43e449(0xe5)](_0x13b4c0['length'],0x1)]]=_0x135c92;}export function deleteNestedValue(_0x276400,_0x58266a){const _0x3874f6=_0x237b3b,_0x52ffe7={'RhOqq':function(_0x2a0444,_0x2b52b){return _0x2a0444<_0x2b52b;},'ahCMv':function(_0x395d96,_0x45e02d){return _0x395d96-_0x45e02d;},'AfKeq':function(_0x4845a7,_0x1b1321){return _0x4845a7===_0x1b1321;},'Slnbg':function(_0x1fc31c,_0x3f2920){return _0x1fc31c!==_0x3f2920;},'TQeii':_0x3874f6(0xc7)},_0x4fe450=parseKeyPath(_0x58266a);let _0x163e07=_0x276400;for(let _0x15e152=0x0;_0x52ffe7[_0x3874f6(0xd9)](_0x15e152,_0x52ffe7['ahCMv'](_0x4fe450['length'],0x1));_0x15e152++){if(_0x52ffe7['AfKeq'](_0x163e07,null)||_0x163e07===undefined||_0x52ffe7[_0x3874f6(0xdf)](typeof _0x163e07,_0x52ffe7[_0x3874f6(0xf2)]))return![];_0x163e07=_0x163e07[_0x4fe450[_0x15e152]];}if(_0x163e07===null||_0x52ffe7['AfKeq'](_0x163e07,undefined)||_0x52ffe7['Slnbg'](typeof _0x163e07,'object'))return![];const _0x3b6994=_0x4fe450[_0x4fe450[_0x3874f6(0xff)]-0x1];if(_0x3b6994 in _0x163e07)return delete _0x163e07[_0x3b6994],!![];return![];}function parseKeyPath(_0x2bafb7){const _0x2d0229=_0x237b3b,_0x2f535a={'puSan':function(_0x539fbe,_0x2b0fc1){return _0x539fbe===_0x2b0fc1;},'ztUih':_0x2d0229(0xfa),'qxPzG':_0x2d0229(0xd3)},_0x51a456=_0x2bafb7[_0x2d0229(0xf4)]('.');return _0x51a456[0x0]==='header'&&(_0x51a456[0x0]='headers'),_0x2f535a[_0x2d0229(0x109)](_0x51a456[0x0],_0x2f535a['ztUih'])&&(_0x51a456[0x0]=_0x2f535a[_0x2d0229(0xb9)]),_0x51a456;}export function formatSettings(_0x5eedaf,_0x110cf2=0x0){const _0x3e4bf9=_0x237b3b,_0x5a92c4=[],_0xbbfdf6='\x20\x20'['repeat'](_0x110cf2);for(const [_0x2c186a,_0x56d047]of Object[_0x3e4bf9(0xf1)](_0x5eedaf)){if(_0x56d047===undefined)continue;if(typeof _0x56d047==='object'&&_0x56d047!==null){_0x5a92c4['push'](''+_0xbbfdf6+_0x2c186a+':');for(const [_0x2bf056,_0x5e9cd5]of Object['entries'](_0x56d047)){_0x5a92c4[_0x3e4bf9(0x10d)](_0xbbfdf6+'\x20\x20'+_0x2bf056+':\x20'+_0x5e9cd5);}}else _0x5a92c4['push'](''+_0xbbfdf6+_0x2c186a+':\x20'+_0x56d047);}return _0x5a92c4['join']('\x0a');}
@@ -1 +1 @@
1
- (function(_0x1adfef,_0x123b36){const _0xbe357=_0x3aaa,_0x5e0149=_0x1adfef();while(!![]){try{const _0x5235a6=-parseInt(_0xbe357(0x18b))/0x1+parseInt(_0xbe357(0x18e))/0x2+-parseInt(_0xbe357(0x187))/0x3*(-parseInt(_0xbe357(0x193))/0x4)+parseInt(_0xbe357(0x191))/0x5+parseInt(_0xbe357(0x18f))/0x6+-parseInt(_0xbe357(0x188))/0x7+-parseInt(_0xbe357(0x186))/0x8*(parseInt(_0xbe357(0x189))/0x9);if(_0x5235a6===_0x123b36)break;else _0x5e0149['push'](_0x5e0149['shift']());}catch(_0x2bcfbc){_0x5e0149['push'](_0x5e0149['shift']());}}}(_0x2eb9,0xcb6db));import{readFileSync}from'fs';import{dirname,join}from'path';import{fileURLToPath}from'url';const __filename=fileURLToPath(import.meta.url),__dirname=dirname(__filename);function _0x2eb9(){const _0xf8df22=['dqBTA','ranger/SKILL.md','1357102ZKItzd','2731062oQlHNk','utf-8','5942680TXkdJB','gYkpk','70880ALKPSY','696yHFPoy','153shbbfY','10148789eTLZpU','56862ljaBGt','HxSoG','393248albJVO'];_0x2eb9=function(){return _0xf8df22;};return _0x2eb9();}export function readSkillContent(_0x5e669a){const _0x3c5052=_0x3aaa,_0x2b8969={'drMCH':'skills','gYkpk':function(_0x24a3bd,_0x53df37,_0x490164){return _0x24a3bd(_0x53df37,_0x490164);},'oQZOP':function(_0x22eefe,_0x9de34,_0x360f40){return _0x22eefe(_0x9de34,_0x360f40);},'TMNth':_0x3c5052(0x190)},_0x221e8e=join(__dirname,'..','..',_0x2b8969['drMCH']),_0x2dfd50=_0x2b8969[_0x3c5052(0x192)](join,_0x221e8e,_0x5e669a);try{return _0x2b8969['oQZOP'](readFileSync,_0x2dfd50,_0x2b8969['TMNth']);}catch{return'';}}function _0x3aaa(_0x6a8772,_0x1ccdd5){_0x6a8772=_0x6a8772-0x186;const _0x2eb910=_0x2eb9();let _0x3aaac5=_0x2eb910[_0x6a8772];return _0x3aaac5;}export function getRangerSkillContent(){const _0x393913=_0x3aaa,_0x3dc1b5={'dqBTA':function(_0x4f0b51,_0x450b85){return _0x4f0b51(_0x450b85);},'HxSoG':_0x393913(0x18d)};return _0x3dc1b5[_0x393913(0x18c)](readSkillContent,_0x3dc1b5[_0x393913(0x18a)]);}
1
+ function _0x4999(_0x1253aa,_0x542dbd){_0x1253aa=_0x1253aa-0x12c;const _0x443693=_0x4436();let _0x4999fc=_0x443693[_0x1253aa];return _0x4999fc;}function _0x4436(){const _0x27c121=['tEpsl','1022778lvGSoY','858270piVPGe','1261360KyQWsd','5518464SuLKns','tNOpt','2295310ABtEIE','skills','126504HjOHwF','21hTCawf','286464PQDYyr','900MYBlKP','1mjNkpX'];_0x4436=function(){return _0x27c121;};return _0x4436();}(function(_0x4ba2b2,_0x225525){const _0x532c47=_0x4999,_0x4571b6=_0x4ba2b2();while(!![]){try{const _0x42ac6a=parseInt(_0x532c47(0x135))/0x1*(parseInt(_0x532c47(0x137))/0x2)+parseInt(_0x532c47(0x138))/0x3+parseInt(_0x532c47(0x133))/0x4+parseInt(_0x532c47(0x12f))/0x5+parseInt(_0x532c47(0x12d))/0x6+parseInt(_0x532c47(0x132))/0x7*(-parseInt(_0x532c47(0x12c))/0x8)+parseInt(_0x532c47(0x131))/0x9*(-parseInt(_0x532c47(0x134))/0xa);if(_0x42ac6a===_0x225525)break;else _0x4571b6['push'](_0x4571b6['shift']());}catch(_0x2e0b76){_0x4571b6['push'](_0x4571b6['shift']());}}}(_0x4436,0x7c79b));import{readFileSync}from'fs';import{dirname,join}from'path';import{fileURLToPath}from'url';const __filename=fileURLToPath(import.meta.url),__dirname=dirname(__filename);export function readSkillContent(_0x85ac2d){const _0x273194=_0x4999,_0x43f660={'tNOpt':_0x273194(0x130)},_0x2e8543=join(__dirname,'..','..',_0x43f660[_0x273194(0x12e)]),_0x3d63c6=join(_0x2e8543,_0x85ac2d);try{return readFileSync(_0x3d63c6,'utf-8');}catch{return'';}}export function getRangerSkillContent(){const _0x2eca88=_0x4999,_0x2b15ae={'tEpsl':function(_0x5de12c,_0x47aaf7){return _0x5de12c(_0x47aaf7);},'feFge':'ranger/SKILL.md'};return _0x2b15ae[_0x2eca88(0x136)](readSkillContent,_0x2b15ae['feFge']);}
@@ -1 +1 @@
1
- const _0x592f1d=_0x1c90;(function(_0x551883,_0x8e59ff){const _0x5d8959=_0x1c90,_0x1f7324=_0x551883();while(!![]){try{const _0x2ec678=-parseInt(_0x5d8959(0x11a))/0x1*(parseInt(_0x5d8959(0x131))/0x2)+parseInt(_0x5d8959(0x12d))/0x3*(parseInt(_0x5d8959(0x114))/0x4)+parseInt(_0x5d8959(0x11b))/0x5*(-parseInt(_0x5d8959(0x119))/0x6)+parseInt(_0x5d8959(0x116))/0x7+-parseInt(_0x5d8959(0x11c))/0x8+-parseInt(_0x5d8959(0x134))/0x9+-parseInt(_0x5d8959(0x111))/0xa*(-parseInt(_0x5d8959(0x11d))/0xb);if(_0x2ec678===_0x8e59ff)break;else _0x1f7324['push'](_0x1f7324['shift']());}catch(_0x171492){_0x1f7324['push'](_0x1f7324['shift']());}}}(_0x2624,0xdb081));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';function _0x2624(){const _0x409c52=['\x20\x20Installed\x20skill:\x20','trim','nrfiP','feature-tracker','6tgMKRl','warn','log','\x20\x20Location:\x20','2ILbtWv','claude','IyPlo','1251630bOTrCP','10lIueNA','oPQHN','skills','1768028CYwmOf','\x20\x20Skill\x20not\x20found:\x20','7646982kDmLCA','join','SdNuq','729996qdmeGQ','1423222wUbjjJ','20WMckbD','3456864fONVzw','15419547bxCJnC','length','\x20\x20Files:\x20','push','tPZGA','Jbsvz','akQSw','FTljp','dEKKp','OKmtz','SKILL.md','\x20\x20Removed\x20deprecated\x20skill:\x20'];_0x2624=function(){return _0x409c52;};return _0x2624();}import{getSkillsDir}from'./claudeConfig.js';import{getOpencodeSkillsDir}from'./opencodeConfig.js';const __filename=fileURLToPath(import.meta.url),__dirname=dirname(__filename);function _0x1c90(_0x3ccdf0,_0xf0ef99){_0x3ccdf0=_0x3ccdf0-0x111;const _0x262441=_0x2624();let _0x1c9056=_0x262441[_0x3ccdf0];return _0x1c9056;}export const RANGER_MANAGED_SKILLS=['ranger'];export const DEPRECATED_SKILLS=['e2e-test-recommender','bug-bash',_0x592f1d(0x12c)];export async function installSkill(_0xf1c54,_0x20d86a={}){const _0xc0db6e=_0x592f1d,_0x2e3472={'Nsbep':function(_0x4d1be5){return _0x4d1be5();},'tPZGA':function(_0x96e75c,_0x2ae551,_0x24f9b4){return _0x96e75c(_0x2ae551,_0x24f9b4);},'HQtWD':function(_0x2b3e02,_0x49566b){return _0x2b3e02(_0x49566b);},'GHoOy':function(_0x4fd161,_0xf17158,_0xcac82f){return _0x4fd161(_0xf17158,_0xcac82f);},'SdNuq':'SKILL.md','FTljp':function(_0x159fcf,_0x33417e){return _0x159fcf&&_0x33417e;},'OKmtz':function(_0x177b8a,_0x422cb2){return _0x177b8a===_0x422cb2;},'SWbDP':function(_0x4d5da1,_0x3d9dbd){return _0x4d5da1(_0x3d9dbd);},'IyPlo':function(_0x495f88,_0x2764df){return _0x495f88(_0x2764df);},'Poszb':function(_0x3cb115,_0x58e8e9,_0x3b28c5){return _0x3cb115(_0x58e8e9,_0x3b28c5);},'oPQHN':'utf-8','maWCU':function(_0x7cc018,_0x216366){return _0x7cc018(_0x216366);},'dEKKp':function(_0x1127b8,_0x166b4d,_0x104ed3,_0x12f73a){return _0x1127b8(_0x166b4d,_0x104ed3,_0x12f73a);}},{level:level='project',cliVersion:_0x2c2681,platform:platform=_0xc0db6e(0x132)}=_0x20d86a,_0xce5120=_0x2e3472['Nsbep'](getSourceSkillsDir),_0x17f738=_0x2e3472['tPZGA'](join,_0xce5120,_0xf1c54),_0x4846dd=_0x2e3472[_0xc0db6e(0x121)](join,_0xce5120,_0xf1c54+'.md'),_0x5f4f13=existsSync(_0x17f738)&&_0x2e3472['HQtWD'](statSync,_0x17f738)['isDirectory']()&&existsSync(_0x2e3472['GHoOy'](join,_0x17f738,_0x2e3472[_0xc0db6e(0x118)])),_0x33c01f=existsSync(_0x4846dd);if(_0x2e3472[_0xc0db6e(0x124)](!_0x5f4f13,!_0x33c01f))return console['warn'](_0xc0db6e(0x115)+_0xf1c54),![];const _0x45f9d7=_0x2e3472[_0xc0db6e(0x126)](platform,'opencode')?_0x2e3472['SWbDP'](getOpencodeSkillsDir,level):_0x2e3472[_0xc0db6e(0x133)](getSkillsDir,level),_0x35cdc8=_0x2e3472['tPZGA'](join,_0x45f9d7,_0xf1c54);await mkdir(_0x35cdc8,{'recursive':!![]});let _0x482b81,_0x510e51=[];if(_0x5f4f13){const _0x1097ad=await readdir(_0x17f738),_0x43f4b5=_0x1097ad['filter'](_0x439aeb=>_0x439aeb['endsWith']('.md'));for(const _0x3470a1 of _0x43f4b5){const _0x589b64=join(_0x17f738,_0x3470a1),_0xddf7af=_0x2e3472[_0xc0db6e(0x121)](join,_0x35cdc8,_0x3470a1);await _0x2e3472['Poszb'](copyFile,_0x589b64,_0xddf7af),_0x510e51[_0xc0db6e(0x120)](_0x3470a1);}_0x482b81=await _0x2e3472['Poszb'](readFile,_0x2e3472['tPZGA'](join,_0x17f738,_0x2e3472['SdNuq']),_0x2e3472[_0xc0db6e(0x112)]);}else{_0x482b81=await readFile(_0x4846dd,_0x2e3472['oPQHN']);const _0x7539ad=join(_0x35cdc8,_0xc0db6e(0x127));await writeFile(_0x7539ad,_0x482b81,'utf-8'),_0x510e51['push']('SKILL.md');}const {name:_0x1ebe55}=_0x2e3472['maWCU'](parseFrontmatter,_0x482b81);return console['log'](_0xc0db6e(0x129)+_0x1ebe55),console[_0xc0db6e(0x12f)](_0xc0db6e(0x130)+_0x35cdc8),_0x510e51[_0xc0db6e(0x11e)]>0x1&&console['log'](_0xc0db6e(0x11f)+_0x510e51[_0xc0db6e(0x117)](',\x20')),_0x2e3472[_0xc0db6e(0x125)](logLocalAgentInstallation,_0xf1c54,{'skillDisplayName':_0x1ebe55,'installLevel':level},_0x2c2681)['catch'](()=>{}),!![];}function getSourceSkillsDir(){const _0x149534=_0x592f1d,_0x2338c3={'WqXFe':function(_0x5b940a,_0x49c1bc,_0x1f3ae7,_0x164897,_0x1eb540){return _0x5b940a(_0x49c1bc,_0x1f3ae7,_0x164897,_0x1eb540);},'akQSw':_0x149534(0x113)},_0x5e67c1=[_0x2338c3['WqXFe'](join,__dirname,'..','..',_0x149534(0x113)),join(__dirname,'..','..','..',_0x2338c3[_0x149534(0x123)])];for(const _0x1c2293 of _0x5e67c1){if(existsSync(_0x1c2293))return _0x1c2293;}return _0x5e67c1[0x0];}function parseFrontmatter(_0x450f20){const _0x2621f2=_0x592f1d,_0x321555={'nrfiP':'Invalid\x20skill\x20frontmatter'},_0x266d6d=_0x450f20['match'](/^---\n([\s\S]+?)\n---/);if(!_0x266d6d)throw new Error(_0x321555[_0x2621f2(0x12b)]);const _0x5a2a60=_0x266d6d[0x1],_0x4259ba=_0x5a2a60['match'](/name:\s*(.+)/),_0x3d23d7=_0x5a2a60['match'](/description:\s*"?(.+?)"?\n/);return{'name':_0x4259ba?.[0x1][_0x2621f2(0x12a)]()||'','description':_0x3d23d7?.[0x1]['trim']()||''};}export async function removeSkill(_0x5a407e,_0x213d5a){const _0x267931=_0x592f1d,_0x10f597={'Jbsvz':function(_0x148948,_0x1a6c14){return _0x148948(_0x1a6c14);}},_0x5371fe=getSkillsDir(_0x213d5a),_0x375759=join(_0x5371fe,_0x5a407e);if(!_0x10f597[_0x267931(0x122)](existsSync,_0x375759))return![];try{return await rm(_0x375759,{'recursive':!![]}),console['log'](_0x267931(0x128)+_0x5a407e),!![];}catch{return console[_0x267931(0x12e)]('\x20\x20Failed\x20to\x20remove\x20deprecated\x20skill:\x20'+_0x5a407e),![];}}
1
+ const _0xa9793f=_0xa49d;(function(_0x310998,_0x207aff){const _0x2773bf=_0xa49d,_0x19d367=_0x310998();while(!![]){try{const _0x2e7a91=parseInt(_0x2773bf(0x19b))/0x1+-parseInt(_0x2773bf(0x197))/0x2*(parseInt(_0x2773bf(0x193))/0x3)+parseInt(_0x2773bf(0x1a2))/0x4+parseInt(_0x2773bf(0x188))/0x5*(-parseInt(_0x2773bf(0x183))/0x6)+-parseInt(_0x2773bf(0x184))/0x7+parseInt(_0x2773bf(0x1a7))/0x8*(-parseInt(_0x2773bf(0x19d))/0x9)+-parseInt(_0x2773bf(0x18d))/0xa*(-parseInt(_0x2773bf(0x196))/0xb);if(_0x2e7a91===_0x207aff)break;else _0x19d367['push'](_0x19d367['shift']());}catch(_0x241bd3){_0x19d367['push'](_0x19d367['shift']());}}}(_0x3574,0xd3c26));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';const __filename=fileURLToPath(import.meta.url),__dirname=dirname(__filename);export const RANGER_MANAGED_SKILLS=[_0xa9793f(0x1a6)];export const DEPRECATED_SKILLS=['e2e-test-recommender','bug-bash','feature-tracker'];export async function installSkill(_0x1663ac,_0x34fb28={}){const _0x14746c=_0xa9793f,_0x415205={'PPFFO':_0x14746c(0x191),'jkyYs':function(_0x3dc740){return _0x3dc740();},'lWgFL':function(_0x286496,_0x6077e8){return _0x286496(_0x6077e8);},'klTCz':function(_0x46f3fb,_0x262479,_0xad6237){return _0x46f3fb(_0x262479,_0xad6237);},'UUAEo':function(_0x16c423,_0x120115){return _0x16c423&&_0x120115;},'zHAnP':function(_0x2445f6,_0x28cdb6,_0x33c028){return _0x2445f6(_0x28cdb6,_0x33c028);},'VTtvy':function(_0x5d8ba4,_0xbd6d80,_0x3ccbb4){return _0x5d8ba4(_0xbd6d80,_0x3ccbb4);},'pjtMY':function(_0x5ab277,_0x2fbb41){return _0x5ab277(_0x2fbb41);},'JfiWG':function(_0x18d226,_0x3b62f7,_0x56e798){return _0x18d226(_0x3b62f7,_0x56e798);},'wDiQH':'SKILL.md','YONqn':function(_0x3412d9,_0x51e6d5,_0x49a8fe){return _0x3412d9(_0x51e6d5,_0x49a8fe);},'JxgQp':function(_0x402249,_0x687f24,_0x486a95,_0x4a51c5){return _0x402249(_0x687f24,_0x486a95,_0x4a51c5);},'VJPqr':function(_0x4697e2,_0x340cde){return _0x4697e2(_0x340cde);},'lbOWz':function(_0x4e1d1c,_0x55f710){return _0x4e1d1c>_0x55f710;}},{level:level=_0x415205['PPFFO'],cliVersion:_0x5194be,platform:platform='claude'}=_0x34fb28,_0x2ae7e2=_0x415205['jkyYs'](getSourceSkillsDir),_0x22b5d0=join(_0x2ae7e2,_0x1663ac),_0x3b885a=join(_0x2ae7e2,_0x1663ac+'.md'),_0x556bae=existsSync(_0x22b5d0)&&statSync(_0x22b5d0)['isDirectory']()&&_0x415205['lWgFL'](existsSync,_0x415205[_0x14746c(0x198)](join,_0x22b5d0,'SKILL.md')),_0x597390=_0x415205[_0x14746c(0x19f)](existsSync,_0x3b885a);if(_0x415205[_0x14746c(0x199)](!_0x556bae,!_0x597390))return console['warn']('\x20\x20Skill\x20not\x20found:\x20'+_0x1663ac),![];const _0x482060=platform==='opencode'?getOpencodeSkillsDir(level):_0x415205['lWgFL'](getSkillsDir,level),_0x827ef8=_0x415205['zHAnP'](join,_0x482060,_0x1663ac);await _0x415205[_0x14746c(0x194)](mkdir,_0x827ef8,{'recursive':!![]});let _0x30dad1,_0x4df82f=[];if(_0x556bae){const _0x1a1bfe=await _0x415205[_0x14746c(0x1a3)](readdir,_0x22b5d0),_0x32ed50=_0x1a1bfe[_0x14746c(0x190)](_0x23fb36=>_0x23fb36[_0x14746c(0x186)](_0x14746c(0x18f)));for(const _0x13a2f5 of _0x32ed50){const _0x222efd=_0x415205['klTCz'](join,_0x22b5d0,_0x13a2f5),_0x1acfe9=_0x415205[_0x14746c(0x1a1)](join,_0x827ef8,_0x13a2f5);await _0x415205[_0x14746c(0x18a)](copyFile,_0x222efd,_0x1acfe9),_0x4df82f[_0x14746c(0x19a)](_0x13a2f5);}_0x30dad1=await _0x415205[_0x14746c(0x194)](readFile,join(_0x22b5d0,_0x415205['wDiQH']),'utf-8');}else{_0x30dad1=await _0x415205[_0x14746c(0x18b)](readFile,_0x3b885a,_0x14746c(0x18e));const _0x5352d7=join(_0x827ef8,_0x14746c(0x19e));await _0x415205[_0x14746c(0x1a4)](writeFile,_0x5352d7,_0x30dad1,'utf-8'),_0x4df82f[_0x14746c(0x19a)](_0x14746c(0x19e));}const {name:_0x43b76c}=_0x415205[_0x14746c(0x189)](parseFrontmatter,_0x30dad1);return console['log']('\x20\x20Installed\x20skill:\x20'+_0x43b76c),console['log'](_0x14746c(0x181)+_0x827ef8),_0x415205[_0x14746c(0x187)](_0x4df82f['length'],0x1)&&console['log']('\x20\x20Files:\x20'+_0x4df82f['join'](',\x20')),logLocalAgentInstallation(_0x1663ac,{'skillDisplayName':_0x43b76c,'installLevel':level},_0x5194be)[_0x14746c(0x1a5)](()=>{}),!![];}function _0xa49d(_0x4fa93f,_0x1b30cd){_0x4fa93f=_0x4fa93f-0x180;const _0x357449=_0x3574();let _0xa49dc1=_0x357449[_0x4fa93f];return _0xa49dc1;}function getSourceSkillsDir(){const _0x24bb3f=_0xa9793f,_0x5736e0={'zoSCi':function(_0x1f4b26,_0x454059,_0x4e1828,_0xd2ba32,_0x52ce7b){return _0x1f4b26(_0x454059,_0x4e1828,_0xd2ba32,_0x52ce7b);},'Puwqh':'skills','KhabE':function(_0x14857f,_0x403baf){return _0x14857f(_0x403baf);}},_0x294c0b=[_0x5736e0[_0x24bb3f(0x182)](join,__dirname,'..','..',_0x5736e0['Puwqh']),join(__dirname,'..','..','..',_0x5736e0[_0x24bb3f(0x180)])];for(const _0x39639c of _0x294c0b){if(_0x5736e0['KhabE'](existsSync,_0x39639c))return _0x39639c;}return _0x294c0b[0x0];}function _0x3574(){const _0x43fc59=['ranger','23024udsTiE','Puwqh','\x20\x20Location:\x20','zoSCi','6Smkcga','11471761lSZHjS','match','endsWith','lbOWz','588835OIheHk','VJPqr','zHAnP','YONqn','Invalid\x20skill\x20frontmatter','34061480fNusfJ','utf-8','.md','filter','project','\x20\x20Removed\x20deprecated\x20skill:\x20','3ILVIBR','VTtvy','trim','11LNiKUV','2244602uiUtWF','klTCz','UUAEo','push','1195227aUEZHb','log','4419zzokBb','SKILL.md','lWgFL','warn','JfiWG','2231920NDGGPn','pjtMY','JxgQp','catch'];_0x3574=function(){return _0x43fc59;};return _0x3574();}function parseFrontmatter(_0x4f0c2b){const _0x4456cc=_0xa9793f,_0x48f5bb=_0x4f0c2b['match'](/^---\n([\s\S]+?)\n---/);if(!_0x48f5bb)throw new Error(_0x4456cc(0x18c));const _0x446f23=_0x48f5bb[0x1],_0x32837f=_0x446f23[_0x4456cc(0x185)](/name:\s*(.+)/),_0x28c124=_0x446f23['match'](/description:\s*"?(.+?)"?\n/);return{'name':_0x32837f?.[0x1][_0x4456cc(0x195)]()||'','description':_0x28c124?.[0x1][_0x4456cc(0x195)]()||''};}export async function removeSkill(_0x3af8b3,_0x567f59){const _0x5f41cf=_0xa9793f,_0x5b715a={'APLfg':function(_0x1e227e,_0x3bce74,_0x484161){return _0x1e227e(_0x3bce74,_0x484161);}},_0x336634=getSkillsDir(_0x567f59),_0xfdf81d=_0x5b715a['APLfg'](join,_0x336634,_0x3af8b3);if(!existsSync(_0xfdf81d))return![];try{return await rm(_0xfdf81d,{'recursive':!![]}),console[_0x5f41cf(0x19c)](_0x5f41cf(0x192)+_0x3af8b3),!![];}catch{return console[_0x5f41cf(0x1a0)]('\x20\x20Failed\x20to\x20remove\x20deprecated\x20skill:\x20'+_0x3af8b3),![];}}
@@ -1 +1 @@
1
- const _0x162add=_0xd240;(function(_0x47a6dc,_0xf88daf){const _0x426607=_0xd240,_0x2d9933=_0x47a6dc();while(!![]){try{const _0x4d044b=-parseInt(_0x426607(0x1de))/0x1+-parseInt(_0x426607(0x1f1))/0x2*(parseInt(_0x426607(0x1fb))/0x3)+parseInt(_0x426607(0x1cb))/0x4*(-parseInt(_0x426607(0x1d5))/0x5)+parseInt(_0x426607(0x1c6))/0x6*(parseInt(_0x426607(0x1fe))/0x7)+-parseInt(_0x426607(0x1f2))/0x8*(-parseInt(_0x426607(0x1d1))/0x9)+-parseInt(_0x426607(0x1f5))/0xa+parseInt(_0x426607(0x1cf))/0xb;if(_0x4d044b===_0xf88daf)break;else _0x2d9933['push'](_0x2d9933['shift']());}catch(_0x319345){_0x2d9933['push'](_0x2d9933['shift']());}}}(_0x32df,0x55786));function _0xd240(_0x35d04c,_0x635de4){_0x35d04c=_0x35d04c-0x1c0;const _0x32df05=_0x32df();let _0xd240c1=_0x32df05[_0x35d04c];return _0xd240c1;}import{readFileSync,writeFileSync}from'fs';function _0x32df(){const _0x291b11=['max','9qkURIw','jDEjG','argv','vwdUU','27865AvnbOE','from','uEzTX','\x20files\x20->\x20','header','pow','maxTimestampTicks','lPbbJ','sMQqv','527416KGYngf','log','clusters','nByKm','pJDSC','slice','YAaxl','bodyAfterTimestamp','dDmSR','tkycq','concat','qTGCO','oGHox','kIcqz','fbkMK','CNBaO','floor','endsWith','VpuVh','14VPgmWT','3545264OznIay','xQbre','stitchWebmFiles.js','977800tQNPNY','maxTicks','TPiNB','MZBag','readInt16BE','IGbUK','260610spgfIR','YpOKi','rzdnT','7QQNgRR','indexOf','Stitched\x20','fLCZp','length','OBpdF','aaQyq','exit','GFyIP','bodyBeforeTimestamp','gMLKR','gtwgT','Usage:\x20stitchWebmFiles\x20<input1.webm>\x20<input2.webm>\x20[...]\x20<output.webm>','BTdod','AAhzq','VKCfs','GvfZn','MNaxq','Stitching\x20failed\x20or\x20only\x20one\x20input\x20file.','oRYrC','1008822BsDquu','TiVpQ','etfOJ','kdGrC','zDtIn','496OAtFqG','SxMFc','push','alloc','18294419DEhTDX'];_0x32df=function(){return _0x291b11;};return _0x32df();}const ID_SEGMENT=0x18538067,ID_INFO=0x1549a966,ID_CLUSTER=0x1f43b675,ID_TIMESTAMP=0xe7,ID_TIMESTAMP_SCALE=0x2ad7b1,ID_SIMPLE_BLOCK=0xa3;function readVint(_0x3fbf78,_0x430206){const _0xb42770=_0xd240,_0x32976f={'FxciC':function(_0x15eb5c,_0x46fd9c){return _0x15eb5c&_0x46fd9c;},'luVFM':function(_0x392070,_0x3de667){return _0x392070-_0x3de667;},'aaQyq':function(_0x30b460,_0x1a0ef3){return _0x30b460<_0x1a0ef3;},'ljBgS':function(_0x43d7ef,_0x1a8d85){return _0x43d7ef+_0x1a8d85;},'gWBPX':function(_0x19146c,_0x3b1c5e){return _0x19146c*_0x3b1c5e;}};if(_0x430206>=_0x3fbf78[_0xb42770(0x202)])return[0x0,0x0];const _0x6b798b=_0x3fbf78[_0x430206];let _0x502b39=0x1,_0x1bdf20=0x80;while(_0x502b39<=0x8&&!_0x32976f['FxciC'](_0x6b798b,_0x1bdf20)){_0x502b39++,_0x1bdf20>>=0x1;}if(_0x430206+_0x502b39>_0x3fbf78['length'])return[0x0,0x0];let _0x294926=_0x32976f['FxciC'](_0x6b798b,_0x32976f['luVFM'](_0x1bdf20,0x1));for(let _0x35bc5b=0x1;_0x32976f[_0xb42770(0x204)](_0x35bc5b,_0x502b39);_0x35bc5b++){_0x294926=_0x32976f['ljBgS'](_0x32976f['gWBPX'](_0x294926,0x100),_0x3fbf78[_0x32976f['ljBgS'](_0x430206,_0x35bc5b)]);}return[_0x294926,_0x502b39];}function readId(_0x3798f5,_0x1db96c){const _0x55e6f5=_0xd240,_0xf7524e={'MNaxq':function(_0x1beb45,_0xae0685){return _0x1beb45>=_0xae0685;},'hKZBj':function(_0x2dd7a6,_0x47d844){return _0x2dd7a6>=_0x47d844;},'plYgt':function(_0x2aa4dd,_0x2fa54a){return _0x2aa4dd>_0x2fa54a;},'VpuVh':function(_0x1d9d32,_0x4bb72a){return _0x1d9d32+_0x4bb72a;},'qTGCO':function(_0x41ff32,_0x204e79){return _0x41ff32+_0x204e79;}};if(_0xf7524e['MNaxq'](_0x1db96c,_0x3798f5['length']))return[0x0,0x0];const _0x949af5=_0x3798f5[_0x1db96c];let _0x4c452c;if(_0xf7524e[_0x55e6f5(0x1c3)](_0x949af5,0x80))_0x4c452c=0x1;else{if(_0xf7524e['hKZBj'](_0x949af5,0x40))_0x4c452c=0x2;else{if(_0x949af5>=0x20)_0x4c452c=0x3;else{if(_0x949af5>=0x10)_0x4c452c=0x4;else return[_0x949af5,0x1];}}}if(_0xf7524e['plYgt'](_0x1db96c+_0x4c452c,_0x3798f5[_0x55e6f5(0x202)]))return[0x0,0x0];let _0x227d26=0x0;for(let _0x1d5e9a=0x0;_0x1d5e9a<_0x4c452c;_0x1d5e9a++){_0x227d26=_0xf7524e[_0x55e6f5(0x1f0)](_0x227d26*0x100,_0x3798f5[_0xf7524e[_0x55e6f5(0x1e9)](_0x1db96c,_0x1d5e9a)]);}return[_0x227d26,_0x4c452c];}function readUint(_0x4f1766,_0x327a2f,_0x5eaf99){const _0x5ec647={'tLWZk':function(_0xbcccfe,_0x1fe91c){return _0xbcccfe+_0x1fe91c;}};let _0x2461fe=0x0;for(let _0x4fe0c4=0x0;_0x4fe0c4<_0x5eaf99;_0x4fe0c4++){_0x2461fe=_0x2461fe*0x100+_0x4f1766[_0x5ec647['tLWZk'](_0x327a2f,_0x4fe0c4)];}return _0x2461fe;}function isUnknownSize(_0x15843f,_0x5419e1){const _0x59ff55=_0xd240,_0x498fba={'LmwgN':function(_0x30275f,_0x707606){return _0x30275f===_0x707606;},'TPiNB':function(_0x182bf1,_0x388f1b){return _0x182bf1-_0x388f1b;},'qYxna':function(_0x11bae6,_0x449b36){return _0x11bae6*_0x449b36;}};return _0x498fba['LmwgN'](_0x15843f,_0x498fba[_0x59ff55(0x1f7)](Math[_0x59ff55(0x1da)](0x2,_0x498fba['qYxna'](0x7,_0x5419e1)),0x1));}function writeVint(_0x15e317,_0x19638c){const _0x37cb8d=_0xd240,_0x293923={'FVNsG':function(_0x1645f9,_0x9eece3){return _0x1645f9||_0x9eece3;},'mHKes':function(_0x1cdce5,_0x47d7b3){return _0x1cdce5-_0x47d7b3;},'IyiZa':function(_0x2de618,_0x39ec44){return _0x2de618>=_0x39ec44;},'kIcqz':function(_0x2a58d4,_0x5f1032){return _0x2a58d4/_0x5f1032;},'UNamK':function(_0x3bf096,_0x563d85){return _0x3bf096<<_0x563d85;}};let _0x1fe9be=_0x293923['FVNsG'](_0x19638c,0x1);while(_0x293923['mHKes'](Math[_0x37cb8d(0x1da)](0x2,0x7*_0x1fe9be),0x2)<_0x15e317)_0x1fe9be++;const _0x7bb35f=Buffer['alloc'](_0x1fe9be);for(let _0x6a3d2c=_0x1fe9be-0x1;_0x293923['IyiZa'](_0x6a3d2c,0x0);_0x6a3d2c--){_0x7bb35f[_0x6a3d2c]=_0x15e317&0xff,_0x15e317=Math['floor'](_0x293923[_0x37cb8d(0x1eb)](_0x15e317,0x100));}return _0x7bb35f[0x0]|=_0x293923['UNamK'](0x1,_0x293923['mHKes'](0x8,_0x1fe9be)),_0x7bb35f;}function writeUint(_0xa1edf6,_0x448457){const _0x1ccf9e=_0xd240,_0x5d3333={'dDmSR':function(_0x26d678,_0x579050){return _0x26d678&_0x579050;},'XtJTu':function(_0x15b250,_0x441abb){return _0x15b250/_0x441abb;}},_0x48efa5=Buffer['alloc'](_0x448457);for(let _0x407ffc=_0x448457-0x1;_0x407ffc>=0x0;_0x407ffc--){_0x48efa5[_0x407ffc]=_0x5d3333[_0x1ccf9e(0x1e6)](_0xa1edf6,0xff),_0xa1edf6=Math[_0x1ccf9e(0x1ee)](_0x5d3333['XtJTu'](_0xa1edf6,0x100));}return _0x48efa5;}function writeUnknownSizeVint(_0x35e988){const _0x4f979d={'OyErH':function(_0x193fc9,_0x2fb0a2){return _0x193fc9>>_0x2fb0a2;}},_0x41109d=Buffer['alloc'](_0x35e988,0xff);return _0x41109d[0x0]=_0x4f979d['OyErH'](0xff,_0x35e988-0x1),_0x41109d;}function uintSize(_0x53e37c){const _0x549312=_0xd240;if(_0x53e37c===0x0)return 0x1;let _0x35929a=0x0,_0x4c4d6b=_0x53e37c;while(_0x4c4d6b>0x0){_0x35929a++,_0x4c4d6b=Math[_0x549312(0x1ee)](_0x4c4d6b/0x100);}return _0x35929a;}function findTimestampScale(_0x2256c3,_0x53c575){const _0x31da4c=_0xd240,_0x93f04={'IGbUK':function(_0x1f746f,_0xaadf71){return _0x1f746f+_0xaadf71;},'vwdUU':function(_0xe4a973,_0x477a31){return _0xe4a973<_0x477a31;},'GFyIP':function(_0x3c8d8f,_0x524e93,_0x3d1ec4){return _0x3c8d8f(_0x524e93,_0x3d1ec4);},'jYqbz':function(_0x4c360b,_0x536fe5,_0x2e6fed,_0x41bea2){return _0x4c360b(_0x536fe5,_0x2e6fed,_0x41bea2);},'oRYrC':function(_0x3c62d7,_0x332cbe){return _0x3c62d7+_0x332cbe;},'etfOJ':function(_0x499d5b,_0x55336f){return _0x499d5b+_0x55336f;},'CNBaO':function(_0x464766,_0x44e4cd,_0x37df81){return _0x464766(_0x44e4cd,_0x37df81);}};let _0x379c02=_0x53c575;const _0xc8c16=Math['min'](_0x2256c3['length'],_0x93f04[_0x31da4c(0x1fa)](_0x53c575,0x2710));while(_0x93f04[_0x31da4c(0x1d4)](_0x379c02,_0xc8c16)){const [_0x29f665,_0xa33177]=_0x93f04[_0x31da4c(0x206)](readId,_0x2256c3,_0x379c02),[_0x460655,_0x3c2aeb]=readVint(_0x2256c3,_0x93f04[_0x31da4c(0x1fa)](_0x379c02,_0xa33177));if(_0x29f665===ID_INFO){let _0x2a9f0e=_0x93f04[_0x31da4c(0x1fa)](_0x93f04['IGbUK'](_0x379c02,_0xa33177),_0x3c2aeb);const _0x332cac=_0x93f04[_0x31da4c(0x1fa)](_0x2a9f0e,_0x460655);while(_0x2a9f0e<_0x332cac){const [_0x595b81,_0x5c2397]=readId(_0x2256c3,_0x2a9f0e),[_0x46a074,_0x5f1d2f]=_0x93f04['GFyIP'](readVint,_0x2256c3,_0x2a9f0e+_0x5c2397);if(_0x595b81===ID_TIMESTAMP_SCALE)return _0x93f04['jYqbz'](readUint,_0x2256c3,_0x93f04[_0x31da4c(0x1c5)](_0x93f04[_0x31da4c(0x1fa)](_0x2a9f0e,_0x5c2397),_0x5f1d2f),_0x46a074);_0x2a9f0e+=_0x93f04[_0x31da4c(0x1c8)](_0x5c2397,_0x5f1d2f)+_0x46a074;}break;}if(_0x29f665===ID_CLUSTER)break;if(_0x93f04[_0x31da4c(0x1ed)](isUnknownSize,_0x460655,_0x3c2aeb))break;_0x379c02+=_0x93f04[_0x31da4c(0x1c8)](_0xa33177+_0x3c2aeb,_0x460655);}return 0xf4240;}function findFirstClusterOffset(_0x28c43f,_0x955a63){const _0x9fd6ba=_0xd240,_0x4e588e={'YAaxl':function(_0x41fe8a,_0x3c74d1,_0x25a834){return _0x41fe8a(_0x3c74d1,_0x25a834);},'rzdnT':function(_0x486bf7,_0x5ffa1e){return _0x486bf7===_0x5ffa1e;},'SxMFc':function(_0x151fd5,_0x410f56){return _0x151fd5+_0x410f56;}};let _0x57651f=_0x955a63;while(_0x57651f<_0x28c43f[_0x9fd6ba(0x202)]){const [_0x46447d,_0x1d2970]=_0x4e588e[_0x9fd6ba(0x1e4)](readId,_0x28c43f,_0x57651f);if(_0x4e588e[_0x9fd6ba(0x1fd)](_0x46447d,ID_CLUSTER))return _0x57651f;const [_0x3ab9b0,_0x5a8d2e]=_0x4e588e[_0x9fd6ba(0x1e4)](readVint,_0x28c43f,_0x4e588e[_0x9fd6ba(0x1cc)](_0x57651f,_0x1d2970));if(isUnknownSize(_0x3ab9b0,_0x5a8d2e))return _0x57651f;_0x57651f+=_0x1d2970+_0x5a8d2e+_0x3ab9b0;}return _0x28c43f['length'];}function findClusterEnd(_0x13b52e,_0x514284,_0x109fa8,_0x54fe94){const _0x3673de=_0xd240,_0x38f58d={'VKCfs':function(_0x746607,_0x173192,_0x28ce83){return _0x746607(_0x173192,_0x28ce83);},'YpOKi':function(_0x324454,_0x32105d){return _0x324454<_0x32105d;},'oGHox':function(_0x4affc8,_0x3a7cdc){return _0x4affc8-_0x3a7cdc;},'zDtIn':function(_0x20dabb,_0x5bf22d){return _0x20dabb+_0x5bf22d;},'tkycq':function(_0x390b4a,_0x1c0404,_0x462cac){return _0x390b4a(_0x1c0404,_0x462cac);},'xQbre':function(_0x457e36,_0x32153e){return _0x457e36+_0x32153e;}};if(!_0x38f58d['VKCfs'](isUnknownSize,_0x109fa8,_0x54fe94))return _0x514284+_0x109fa8;const _0xfcc2d9=new Set([ID_CLUSTER,0x1c53bb6b,0x1254c367]);let _0x283177=_0x514284;while(_0x38f58d[_0x3673de(0x1fc)](_0x283177,_0x38f58d[_0x3673de(0x1ea)](_0x13b52e['length'],0x4))){const [_0x80321a,_0x3f7215]=readId(_0x13b52e,_0x283177);if(_0xfcc2d9['has'](_0x80321a))return _0x283177;const [_0x284f23,_0x5e04be]=_0x38f58d[_0x3673de(0x1c1)](readVint,_0x13b52e,_0x38f58d['zDtIn'](_0x283177,_0x3f7215));if(_0x38f58d[_0x3673de(0x1e7)](isUnknownSize,_0x284f23,_0x5e04be))return _0x13b52e[_0x3673de(0x202)];_0x283177+=_0x38f58d[_0x3673de(0x1ca)](_0x38f58d[_0x3673de(0x1f3)](_0x3f7215,_0x5e04be),_0x284f23);}return _0x13b52e[_0x3673de(0x202)];}function extractClusters(_0x608929,_0x2d5a23){const _0x57707c=_0xd240,_0x552e7f={'IUWbJ':function(_0x5f50d0,_0x3e0cff){return _0x5f50d0<_0x3e0cff;},'kdGrC':function(_0x818ac3,_0x126092,_0x36fbc2){return _0x818ac3(_0x126092,_0x36fbc2);},'lPbbJ':function(_0x438210,_0x2fd3bd){return _0x438210!==_0x2fd3bd;},'nByKm':function(_0x5761b9,_0x4f77e8){return _0x5761b9+_0x4f77e8;},'xwrvg':function(_0x4cae32,_0x2fef2a,_0x1c224b,_0x307ec5,_0x1d517f){return _0x4cae32(_0x2fef2a,_0x1c224b,_0x307ec5,_0x1d517f);},'brLJz':function(_0x400d85,_0x53924b){return _0x400d85<_0x53924b;},'gMLKR':function(_0x56f411,_0x5004b5,_0x52231f){return _0x56f411(_0x5004b5,_0x52231f);},'TntcY':function(_0xa4b7be,_0x36a50a){return _0xa4b7be+_0x36a50a;},'OBpdF':function(_0x4e9306,_0x1c6ffb,_0x4df9fb){return _0x4e9306(_0x1c6ffb,_0x4df9fb);},'sPmpJ':function(_0x248215,_0x5ee05f){return _0x248215+_0x5ee05f;},'CywTs':function(_0x3b3653,_0xbb8de4,_0x3209ce){return _0x3b3653(_0xbb8de4,_0x3209ce);},'MZBag':function(_0x268926,_0x9e6702){return _0x268926+_0x9e6702;},'LiQPF':function(_0x1d2b2a,_0x1e167e){return _0x1d2b2a+_0x1e167e;},'TiVpQ':function(_0x1ed22a,_0x594b33){return _0x1ed22a>_0x594b33;}},_0x542965=[],_0x129480=Buffer[_0x57707c(0x1d6)]([0x1f,0x43,0xb6,0x75]);let _0x223b26=0x0;while(_0x552e7f['IUWbJ'](_0x223b26,_0x608929['length'])){const _0x145f41=_0x608929[_0x57707c(0x1ff)](_0x129480,_0x223b26);if(_0x145f41===-0x1)break;const [_0x444bca,_0x418bea]=_0x552e7f[_0x57707c(0x1c9)](readId,_0x608929,_0x145f41);if(_0x552e7f[_0x57707c(0x1dc)](_0x444bca,ID_CLUSTER)){_0x223b26=_0x552e7f['nByKm'](_0x145f41,0x1);continue;}const [_0x3c2c49,_0x23dd54]=readVint(_0x608929,_0x145f41+_0x418bea),_0x242748=_0x145f41+_0x418bea+_0x23dd54,_0x2a975b=_0x552e7f['xwrvg'](findClusterEnd,_0x608929,_0x242748,_0x3c2c49,_0x23dd54);let _0x140c55=_0x242748,_0x330def=0x0,_0x2f8b0d=0x2,_0x1c3007=![],_0x331b99=Buffer['alloc'](0x0),_0x2a0e20=Buffer[_0x57707c(0x1ce)](0x0);while(_0x552e7f['brLJz'](_0x140c55,_0x2a975b)){const [_0x2552f1,_0x1c1fc9]=_0x552e7f[_0x57707c(0x208)](readId,_0x608929,_0x140c55),[_0x2f908e,_0x584f88]=_0x552e7f[_0x57707c(0x208)](readVint,_0x608929,_0x552e7f['nByKm'](_0x140c55,_0x1c1fc9));if(_0x2552f1===ID_TIMESTAMP){_0x330def=readUint(_0x608929,_0x552e7f[_0x57707c(0x1e1)](_0x140c55+_0x1c1fc9,_0x584f88),_0x2f908e),_0x2f8b0d=_0x2f908e,_0x1c3007=!![],_0x331b99=_0x608929[_0x57707c(0x1e3)](_0x242748,_0x140c55);const _0xcdd01b=_0x552e7f['TntcY'](_0x552e7f['TntcY'](_0x140c55,_0x1c1fc9)+_0x584f88,_0x2f908e);_0x2a0e20=_0x608929['slice'](_0xcdd01b,_0x2a975b);break;}if(_0x2552f1===ID_CLUSTER)break;if(_0x552e7f[_0x57707c(0x203)](isUnknownSize,_0x2f908e,_0x584f88))break;_0x140c55+=_0x552e7f[_0x57707c(0x1e1)](_0x552e7f['sPmpJ'](_0x1c1fc9,_0x584f88),_0x2f908e);}!_0x1c3007&&(_0x2a0e20=_0x608929['slice'](_0x242748,_0x2a975b));let _0x13c5ab=_0x330def;_0x140c55=_0x242748;while(_0x140c55<_0x2a975b){const [_0x3a78d1,_0xaae479]=_0x552e7f['CywTs'](readId,_0x608929,_0x140c55),[_0x43d810,_0xa4c3c9]=_0x552e7f[_0x57707c(0x208)](readVint,_0x608929,_0x552e7f['nByKm'](_0x140c55,_0xaae479));if(_0x3a78d1===ID_SIMPLE_BLOCK&&_0x43d810>=0x4){const _0x597e97=_0x552e7f[_0x57707c(0x1f8)](_0x140c55,_0xaae479)+_0xa4c3c9,[,_0x143b06]=_0x552e7f['OBpdF'](readVint,_0x608929,_0x597e97),_0x2b7b28=_0x608929[_0x57707c(0x1f9)](_0x552e7f['LiQPF'](_0x597e97,_0x143b06)),_0x22945e=_0x330def+_0x2b7b28;if(_0x552e7f[_0x57707c(0x1c7)](_0x22945e,_0x13c5ab))_0x13c5ab=_0x22945e;}if(_0x3a78d1===ID_CLUSTER)break;if(_0x552e7f[_0x57707c(0x208)](isUnknownSize,_0x43d810,_0xa4c3c9))break;_0x140c55+=_0xaae479+_0xa4c3c9+_0x43d810;}_0x542965[_0x57707c(0x1cd)]({'timestamp':_0x330def,'maxTicks':_0x13c5ab,'bodyBeforeTimestamp':_0x331b99,'bodyAfterTimestamp':_0x2a0e20,'timestampElementSize':_0x2f8b0d}),_0x223b26=_0x2a975b;}return _0x542965;}function parseWebm(_0x13040c){const _0x30f842=_0xd240,_0x495e85={'GvfZn':function(_0x5d9f67,_0x399300,_0x1e192e){return _0x5d9f67(_0x399300,_0x1e192e);},'sMQqv':function(_0x41cf05,_0x5ba10e){return _0x41cf05+_0x5ba10e;},'Powwn':function(_0x160439,_0x3b814d){return _0x160439+_0x3b814d;},'fbkMK':function(_0x11d0d0,_0x25bd88){return _0x11d0d0!==_0x25bd88;},'gDSMB':function(_0x54c2b2,_0x34c327,_0x5d3e07){return _0x54c2b2(_0x34c327,_0x5d3e07);},'UPvOF':function(_0x5c4cdc,_0x12e5d4,_0x59f1b6){return _0x5c4cdc(_0x12e5d4,_0x59f1b6);}};let _0x332951=0x0;const [,_0x2c9ba5]=readId(_0x13040c,_0x332951),[_0x4cbcca,_0x24bbd6]=_0x495e85[_0x30f842(0x1c2)](readVint,_0x13040c,_0x332951+_0x2c9ba5);_0x332951+=_0x495e85[_0x30f842(0x1dd)](_0x495e85['Powwn'](_0x2c9ba5,_0x24bbd6),_0x4cbcca);const [_0xddda42,_0x12253b]=readId(_0x13040c,_0x332951);if(_0x495e85[_0x30f842(0x1ec)](_0xddda42,ID_SEGMENT))return null;const [,_0x53195f]=_0x495e85['gDSMB'](readVint,_0x13040c,_0x332951+_0x12253b),_0x47e163=_0x332951+_0x12253b+_0x53195f,_0x591408=_0x495e85['UPvOF'](findTimestampScale,_0x13040c,_0x47e163),_0x3d008b=findFirstClusterOffset(_0x13040c,_0x47e163),_0x1f4eab=_0x13040c[_0x30f842(0x1e3)](0x0,_0x3d008b),_0x49e747=_0x495e85['GvfZn'](extractClusters,_0x13040c,_0x591408);let _0x3fd351=0x0;for(const _0x2a411b of _0x49e747){if(_0x2a411b['maxTicks']>_0x3fd351)_0x3fd351=_0x2a411b[_0x30f842(0x1f6)];}return{'header':_0x1f4eab,'clusters':_0x49e747,'timestampScale':_0x591408,'maxTimestampTicks':_0x3fd351};}function buildCluster(_0xc7c3f9,_0x1bf448,_0x400da0){const _0x23a8df=_0xd240,_0x105526={'BTdod':function(_0x55694c,_0x4007d9){return _0x55694c(_0x4007d9);},'itWoB':function(_0x4de6fc,_0x1ee1e2){return _0x4de6fc(_0x1ee1e2);},'LGnca':function(_0x1fdd2c,_0x3435a,_0x595507){return _0x1fdd2c(_0x3435a,_0x595507);},'mysJy':function(_0x406543,_0x4baf65){return _0x406543(_0x4baf65);}},_0x1eb449=Buffer['from']([0x1f,0x43,0xb6,0x75]),_0x29bffa=Math[_0x23a8df(0x1d0)](0x4,_0x105526[_0x23a8df(0x20b)](uintSize,_0xc7c3f9)),_0x85dce0=Buffer[_0x23a8df(0x1e8)]([Buffer['from']([ID_TIMESTAMP]),_0x105526['itWoB'](writeVint,_0x29bffa),_0x105526['LGnca'](writeUint,_0xc7c3f9,_0x29bffa)]),_0x4ca6ed=Buffer[_0x23a8df(0x1e8)]([_0x1bf448,_0x85dce0,_0x400da0]),_0x5c29f1=_0x105526['mysJy'](writeVint,_0x4ca6ed[_0x23a8df(0x202)]);return Buffer['concat']([_0x1eb449,_0x5c29f1,_0x4ca6ed]);}const ID_DURATION=0x4489;function rebuildHeaderWithoutDuration(_0x3af550){const _0x61cd2c=_0xd240,_0x14ab48={'fYbUV':function(_0x466d14,_0x3ab614,_0x539fe2){return _0x466d14(_0x3ab614,_0x539fe2);},'jDEjG':function(_0x4fee76,_0x1a7625){return _0x4fee76+_0x1a7625;},'hcEpt':function(_0xfc2800,_0x3e18d9,_0x55278a){return _0xfc2800(_0x3e18d9,_0x55278a);},'AAhzq':function(_0x46d069,_0x21c9b2){return _0x46d069+_0x21c9b2;},'uEzTX':function(_0x4a7ad3,_0x57d99b){return _0x4a7ad3(_0x57d99b);},'gdBVp':function(_0x216c0d,_0x11f3f8){return _0x216c0d<_0x11f3f8;},'pJDSC':function(_0x1a4e94,_0xfa9078,_0x362f86){return _0x1a4e94(_0xfa9078,_0x362f86);},'VSCYa':function(_0x33e5f1,_0x2660cd){return _0x33e5f1===_0x2660cd;},'thyHp':function(_0xfd2ec9,_0x2fe0c7){return _0xfd2ec9<_0x2fe0c7;},'gtwgT':function(_0x434947,_0x41d7f5){return _0x434947+_0x41d7f5;}},_0x43c57e=Buffer['from'](_0x3af550);let _0x4f017c=0x0;const [,_0x3a9c56]=_0x14ab48['fYbUV'](readId,_0x43c57e,_0x4f017c),[_0x24d6fb,_0x3029ae]=readVint(_0x43c57e,_0x4f017c+_0x3a9c56),_0x1b4db1=_0x14ab48['jDEjG'](_0x14ab48['jDEjG'](_0x4f017c+_0x3a9c56,_0x3029ae),_0x24d6fb),[,_0xc64f4]=_0x14ab48['hcEpt'](readId,_0x43c57e,_0x1b4db1),[,_0x42916f]=_0x14ab48['fYbUV'](readVint,_0x43c57e,_0x1b4db1+_0xc64f4),_0x13f5b4=_0x14ab48['AAhzq'](_0x1b4db1+_0xc64f4,_0x42916f),_0xd9c4cf=_0x14ab48[_0x61cd2c(0x1d7)](writeUnknownSizeVint,_0x42916f);_0xd9c4cf['copy'](_0x43c57e,_0x1b4db1+_0xc64f4);let _0x3f6fe1=_0x13f5b4;const _0x4d2467=Math['min'](_0x43c57e[_0x61cd2c(0x202)],_0x13f5b4+0x2710);while(_0x14ab48['gdBVp'](_0x3f6fe1,_0x4d2467)){const [_0x2e18db,_0x1142a7]=_0x14ab48['hcEpt'](readId,_0x43c57e,_0x3f6fe1),[_0x4718f9,_0x3f530c]=readVint(_0x43c57e,_0x14ab48['AAhzq'](_0x3f6fe1,_0x1142a7));if(_0x2e18db===ID_CLUSTER)break;if(_0x14ab48[_0x61cd2c(0x1e2)](isUnknownSize,_0x4718f9,_0x3f530c))break;if(_0x14ab48['VSCYa'](_0x2e18db,ID_INFO)){const _0x3bb3dd=_0x14ab48['jDEjG'](_0x14ab48[_0x61cd2c(0x1c0)](_0x3f6fe1,_0x1142a7),_0x3f530c),_0x722bd1=_0x14ab48['AAhzq'](_0x3bb3dd,_0x4718f9),_0x3495b9=[];let _0x463ac2=_0x3bb3dd;while(_0x14ab48['thyHp'](_0x463ac2,_0x722bd1)){const [_0x312514,_0x58fd71]=readId(_0x43c57e,_0x463ac2),[_0x393ad3,_0x2e4606]=readVint(_0x43c57e,_0x463ac2+_0x58fd71),_0x8fd38e=_0x14ab48[_0x61cd2c(0x209)](_0x58fd71,_0x2e4606)+_0x393ad3;_0x312514!==ID_DURATION&&_0x3495b9['push'](_0x43c57e['slice'](_0x463ac2,_0x14ab48[_0x61cd2c(0x1d2)](_0x463ac2,_0x8fd38e))),_0x463ac2+=_0x8fd38e;}const _0xf38e52=Buffer[_0x61cd2c(0x1e8)](_0x3495b9),_0xb42212=Buffer[_0x61cd2c(0x1e8)]([_0x43c57e[_0x61cd2c(0x1e3)](_0x3f6fe1,_0x3f6fe1+_0x1142a7),writeVint(_0xf38e52['length'],_0x3f530c)]);return Buffer[_0x61cd2c(0x1e8)]([_0x43c57e['slice'](0x0,_0x3f6fe1),_0xb42212,_0xf38e52,_0x43c57e[_0x61cd2c(0x1e3)](_0x722bd1)]);}_0x3f6fe1+=_0x14ab48['jDEjG'](_0x1142a7,_0x3f530c)+_0x4718f9;}return _0x43c57e;}export function stitchWebmFiles(_0x3ead00,_0x30bd06){const _0x4f55de=_0xd240,_0x2973a9={'pMFta':function(_0x485252,_0x1733ec){return _0x485252(_0x1733ec);},'xEwkk':function(_0x491277,_0x326ffa){return _0x491277+_0x326ffa;},'fLCZp':function(_0x266649,_0x51dfc7,_0x55f5b5,_0xb2f262){return _0x266649(_0x51dfc7,_0x55f5b5,_0xb2f262);}};if(_0x3ead00['length']<=0x1)return![];const _0x470c2c=[];for(const _0x36c0bf of _0x3ead00){const _0x52bd94=_0x2973a9['pMFta'](readFileSync,_0x36c0bf),_0x373355=parseWebm(_0x52bd94);if(!_0x373355||_0x373355[_0x4f55de(0x1e0)]['length']===0x0)return![];_0x470c2c['push'](_0x373355);}const _0x46fe62=_0x470c2c[0x0],_0x34f675=_0x2973a9['pMFta'](rebuildHeaderWithoutDuration,_0x46fe62[_0x4f55de(0x1d9)]),_0x3848c7=[_0x34f675];let _0x358145=0x0;for(let _0x311fcc=0x0;_0x311fcc<_0x470c2c[_0x4f55de(0x202)];_0x311fcc++){const _0x56fe9d=_0x470c2c[_0x311fcc];for(const _0x1b21a7 of _0x56fe9d['clusters']){const _0x58da61=_0x2973a9['xEwkk'](_0x1b21a7['timestamp'],_0x358145);_0x3848c7['push'](_0x2973a9[_0x4f55de(0x201)](buildCluster,_0x58da61,_0x1b21a7[_0x4f55de(0x207)],_0x1b21a7[_0x4f55de(0x1e5)]));}const _0x3d23e9=0x1e;_0x358145+=_0x2973a9['xEwkk'](_0x56fe9d[_0x4f55de(0x1db)],_0x3d23e9);}return writeFileSync(_0x30bd06,Buffer[_0x4f55de(0x1e8)](_0x3848c7)),!![];}if(process['argv'][0x1]?.['endsWith']('stitchWebmFiles.ts')||process[_0x162add(0x1d3)][0x1]?.[_0x162add(0x1ef)](_0x162add(0x1f4))){const args=process['argv']['slice'](0x2);args[_0x162add(0x202)]<0x3&&(console['error'](_0x162add(0x20a)),process[_0x162add(0x205)](0x1));const output=args[args['length']-0x1],inputs=args['slice'](0x0,-0x1),ok=stitchWebmFiles(inputs,output);ok?console[_0x162add(0x1df)](_0x162add(0x200)+inputs['length']+_0x162add(0x1d8)+output):console[_0x162add(0x1df)](_0x162add(0x1c4));}
1
+ const _0x26c6f2=_0x1c92;function _0x1e32(){const _0x331273=['gGQRa','ZLrlw','Stitched\x20','Yyumd','alloc','6tljokM','bodyBeforeTimestamp','TyvNn','clusters','6908643hhqSjs','Kaxir','Usage:\x20stitchWebmFiles\x20<input1.webm>\x20<input2.webm>\x20[...]\x20<output.webm>','CFGfB','MDlUV','timestamp','CVQld','LlzcJ','lGgUS','DQyCR','\x20files\x20->\x20','rzAhQ','log','argv','length','REAPw','VBAQs','IQbFv','TTnHm','880890rlUZLX','4137564bddXjL','PFMDP','OzkFv','oJYeN','yQGBD','QmKyp','70tZmTBA','ecycm','90SnChAu','359192uiwChB','PIhaQ','QvfCw','289949CrLXXd','endsWith','kZDPP','slice','indexOf','min','floor','error','ItVcw','3372550cXDJCT','wepHM','mYnLq','IvxOi','sdCVu','ZDQdJ','xpOzJ','push','488049OjugNU','ezjbw','EClZP','IZhnZ','has','WhRZG','4ZXwUjV','oiOlP','fTsAY','maxTicks','concat','bodyAfterTimestamp','pfPmV','copy'];_0x1e32=function(){return _0x331273;};return _0x1e32();}(function(_0x3c68a9,_0x2fae83){const _0x1578eb=_0x1c92,_0x35f681=_0x3c68a9();while(!![]){try{const _0x5b8cd7=parseInt(_0x1578eb(0x13c))/0x1+parseInt(_0x1578eb(0x118))/0x2*(-parseInt(_0x1578eb(0x112))/0x3)+parseInt(_0x1578eb(0x13d))/0x4+-parseInt(_0x1578eb(0x10a))/0x5*(parseInt(_0x1578eb(0x125))/0x6)+parseInt(_0x1578eb(0xfb))/0x7*(-parseInt(_0x1578eb(0xfe))/0x8)+parseInt(_0x1578eb(0x129))/0x9+-parseInt(_0x1578eb(0xfd))/0xa*(parseInt(_0x1578eb(0x101))/0xb);if(_0x5b8cd7===_0x2fae83)break;else _0x35f681['push'](_0x35f681['shift']());}catch(_0x18a90b){_0x35f681['push'](_0x35f681['shift']());}}}(_0x1e32,0xf35cb));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(_0x2be430,_0x48939f){const _0x3330e7=_0x1c92,_0x248baf={'QmKyp':function(_0x581961,_0x29f91f){return _0x581961-_0x29f91f;},'REAPw':function(_0x1f876d,_0x3ad0f0){return _0x1f876d+_0x3ad0f0;}};if(_0x48939f>=_0x2be430['length'])return[0x0,0x0];const _0x5f5162=_0x2be430[_0x48939f];let _0x284f83=0x1,_0x11c063=0x80;while(_0x284f83<=0x8&&!(_0x5f5162&_0x11c063)){_0x284f83++,_0x11c063>>=0x1;}if(_0x48939f+_0x284f83>_0x2be430[_0x3330e7(0x137)])return[0x0,0x0];let _0x571f7f=_0x5f5162&_0x248baf[_0x3330e7(0xfa)](_0x11c063,0x1);for(let _0xc4d68a=0x1;_0xc4d68a<_0x284f83;_0xc4d68a++){_0x571f7f=_0x248baf[_0x3330e7(0x138)](_0x571f7f*0x100,_0x2be430[_0x48939f+_0xc4d68a]);}return[_0x571f7f,_0x284f83];}function readId(_0x158519,_0x247200){const _0x502c7c=_0x1c92,_0x190740={'PFMDP':function(_0xe50d8f,_0x3e6605){return _0xe50d8f>=_0x3e6605;},'Kaxir':function(_0x2e8770,_0x1a3657){return _0x2e8770>_0x1a3657;},'oiOlP':function(_0x442e6f,_0x439e70){return _0x442e6f<_0x439e70;}};if(_0x247200>=_0x158519[_0x502c7c(0x137)])return[0x0,0x0];const _0x3a73e5=_0x158519[_0x247200];let _0x4d6e45;if(_0x3a73e5>=0x80)_0x4d6e45=0x1;else{if(_0x3a73e5>=0x40)_0x4d6e45=0x2;else{if(_0x3a73e5>=0x20)_0x4d6e45=0x3;else{if(_0x190740[_0x502c7c(0x13e)](_0x3a73e5,0x10))_0x4d6e45=0x4;else return[_0x3a73e5,0x1];}}}if(_0x190740[_0x502c7c(0x12a)](_0x247200+_0x4d6e45,_0x158519['length']))return[0x0,0x0];let _0x5ef496=0x0;for(let _0x19342e=0x0;_0x190740[_0x502c7c(0x119)](_0x19342e,_0x4d6e45);_0x19342e++){_0x5ef496=_0x5ef496*0x100+_0x158519[_0x247200+_0x19342e];}return[_0x5ef496,_0x4d6e45];}function readUint(_0x709328,_0x2ae3c1,_0x2e39f0){const _0x3f7e1d=_0x1c92,_0x632265={'IvxOi':function(_0x51a132,_0x248ba1){return _0x51a132*_0x248ba1;}};let _0x3aa1a9=0x0;for(let _0x436a2a=0x0;_0x436a2a<_0x2e39f0;_0x436a2a++){_0x3aa1a9=_0x632265[_0x3f7e1d(0x10d)](_0x3aa1a9,0x100)+_0x709328[_0x2ae3c1+_0x436a2a];}return _0x3aa1a9;}function isUnknownSize(_0x2fbb8b,_0x1f999d){const _0x2b0c57={'zJDxG':function(_0x1eb4d1,_0x2a6d22){return _0x1eb4d1*_0x2a6d22;}};return _0x2fbb8b===Math['pow'](0x2,_0x2b0c57['zJDxG'](0x7,_0x1f999d))-0x1;}function writeVint(_0x1caa8a,_0xd2c31c){const _0x300d06=_0x1c92,_0x471d3d={'TDFmw':function(_0x1d2ddb,_0xbd4b56){return _0x1d2ddb<_0xbd4b56;},'kZDPP':function(_0x36a2a4,_0x23255a){return _0x36a2a4>=_0x23255a;},'zUIVm':function(_0x368dca,_0x5a4494){return _0x368dca&_0x5a4494;},'DQyCR':function(_0x273ed7,_0x57a483){return _0x273ed7/_0x57a483;},'cKmYC':function(_0x29b867,_0x4787cb){return _0x29b867-_0x4787cb;}};let _0x116689=_0xd2c31c||0x1;while(_0x471d3d['TDFmw'](Math['pow'](0x2,0x7*_0x116689)-0x2,_0x1caa8a))_0x116689++;const _0x4dc2a5=Buffer[_0x300d06(0x124)](_0x116689);for(let _0x2a95ea=_0x116689-0x1;_0x471d3d[_0x300d06(0x103)](_0x2a95ea,0x0);_0x2a95ea--){_0x4dc2a5[_0x2a95ea]=_0x471d3d['zUIVm'](_0x1caa8a,0xff),_0x1caa8a=Math[_0x300d06(0x107)](_0x471d3d[_0x300d06(0x132)](_0x1caa8a,0x100));}return _0x4dc2a5[0x0]|=0x1<<_0x471d3d['cKmYC'](0x8,_0x116689),_0x4dc2a5;}function writeUint(_0x17a3ba,_0x460ae3){const _0x5b98cc=_0x1c92,_0x256158={'rlWnQ':function(_0x474cee,_0x1a4b1c){return _0x474cee-_0x1a4b1c;}},_0x5589fe=Buffer[_0x5b98cc(0x124)](_0x460ae3);for(let _0x114401=_0x256158['rlWnQ'](_0x460ae3,0x1);_0x114401>=0x0;_0x114401--){_0x5589fe[_0x114401]=_0x17a3ba&0xff,_0x17a3ba=Math[_0x5b98cc(0x107)](_0x17a3ba/0x100);}return _0x5589fe;}function writeUnknownSizeVint(_0x26ed6c){const _0x10dfeb=_0x1c92,_0x375cf5={'TTnHm':function(_0x1b682e,_0x53bc7a){return _0x1b682e-_0x53bc7a;}},_0x3b3055=Buffer[_0x10dfeb(0x124)](_0x26ed6c,0xff);return _0x3b3055[0x0]=0xff>>_0x375cf5[_0x10dfeb(0x13b)](_0x26ed6c,0x1),_0x3b3055;}function uintSize(_0x143beb){const _0x269c28=_0x1c92;if(_0x143beb===0x0)return 0x1;let _0xbc86e4=0x0,_0x5a31d4=_0x143beb;while(_0x5a31d4>0x0){_0xbc86e4++,_0x5a31d4=Math[_0x269c28(0x107)](_0x5a31d4/0x100);}return _0xbc86e4;}function findTimestampScale(_0x596e68,_0x2812b1){const _0x5c4a05=_0x1c92,_0x406eec={'ecycm':function(_0x191caf,_0x4ca08b){return _0x191caf+_0x4ca08b;},'HoRSU':function(_0x10cfc7,_0x1b2f07){return _0x10cfc7+_0x1b2f07;},'IQbFv':function(_0x12f070,_0x21570d){return _0x12f070+_0x21570d;},'WWEZn':function(_0x4d5a22,_0x2bd3bb){return _0x4d5a22<_0x2bd3bb;},'TyvNn':function(_0x449f28,_0x9d31cb,_0x8f9f02){return _0x449f28(_0x9d31cb,_0x8f9f02);},'yQGBD':function(_0x3a43d1,_0x5ae985){return _0x3a43d1===_0x5ae985;},'xpOzJ':function(_0x218043,_0x138cd9,_0x404090,_0x4127ce){return _0x218043(_0x138cd9,_0x404090,_0x4127ce);}};let _0x2669b2=_0x2812b1;const _0x1af0df=Math['min'](_0x596e68['length'],_0x406eec[_0x5c4a05(0xfc)](_0x2812b1,0x2710));while(_0x2669b2<_0x1af0df){const [_0x4e327a,_0x37830d]=readId(_0x596e68,_0x2669b2),[_0x65e797,_0x1323be]=readVint(_0x596e68,_0x406eec['HoRSU'](_0x2669b2,_0x37830d));if(_0x4e327a===ID_INFO){let _0x5984e7=_0x406eec['IQbFv'](_0x2669b2+_0x37830d,_0x1323be);const _0x58d581=_0x5984e7+_0x65e797;while(_0x406eec['WWEZn'](_0x5984e7,_0x58d581)){const [_0x119d28,_0x716e53]=_0x406eec[_0x5c4a05(0x127)](readId,_0x596e68,_0x5984e7),[_0x260711,_0x1ded0f]=readVint(_0x596e68,_0x5984e7+_0x716e53);if(_0x406eec[_0x5c4a05(0xf9)](_0x119d28,ID_TIMESTAMP_SCALE))return _0x406eec[_0x5c4a05(0x110)](readUint,_0x596e68,_0x406eec[_0x5c4a05(0x13a)](_0x5984e7+_0x716e53,_0x1ded0f),_0x260711);_0x5984e7+=_0x406eec['IQbFv'](_0x716e53,_0x1ded0f)+_0x260711;}break;}if(_0x4e327a===ID_CLUSTER)break;if(_0x406eec[_0x5c4a05(0x127)](isUnknownSize,_0x65e797,_0x1323be))break;_0x2669b2+=_0x406eec['HoRSU'](_0x37830d,_0x1323be)+_0x65e797;}return 0xf4240;}function findFirstClusterOffset(_0x2ffe3b,_0x2aa07d){const _0x51db5f=_0x1c92,_0x1a4f50={'KOAgI':function(_0x428b60,_0x1d0e2c){return _0x428b60<_0x1d0e2c;},'Yyumd':function(_0xdc3972,_0x4d2483,_0x42bae2){return _0xdc3972(_0x4d2483,_0x42bae2);},'sdCVu':function(_0x592cd9,_0xb4ab2f){return _0x592cd9+_0xb4ab2f;}};let _0x454c3b=_0x2aa07d;while(_0x1a4f50['KOAgI'](_0x454c3b,_0x2ffe3b['length'])){const [_0x4ab890,_0x4c1c09]=_0x1a4f50[_0x51db5f(0x123)](readId,_0x2ffe3b,_0x454c3b);if(_0x4ab890===ID_CLUSTER)return _0x454c3b;const [_0x38b0a8,_0x22a0b2]=_0x1a4f50[_0x51db5f(0x123)](readVint,_0x2ffe3b,_0x454c3b+_0x4c1c09);if(isUnknownSize(_0x38b0a8,_0x22a0b2))return _0x454c3b;_0x454c3b+=_0x1a4f50[_0x51db5f(0x10e)](_0x4c1c09+_0x22a0b2,_0x38b0a8);}return _0x2ffe3b['length'];}function findClusterEnd(_0x4efa60,_0x500d13,_0x3a44d5,_0x29c648){const _0x4809cf=_0x1c92,_0x1ea621={'ItVcw':function(_0x5c68fd,_0x46e363){return _0x5c68fd+_0x46e363;},'QvfCw':function(_0x202038,_0x2be58a){return _0x202038<_0x2be58a;},'pfPmV':function(_0x582935,_0x4d7fbe,_0x33dbe5){return _0x582935(_0x4d7fbe,_0x33dbe5);},'rzAhQ':function(_0x393e0b,_0x609fc7){return _0x393e0b+_0x609fc7;}};if(!isUnknownSize(_0x3a44d5,_0x29c648))return _0x1ea621['ItVcw'](_0x500d13,_0x3a44d5);const _0x15c58a=new Set([ID_CLUSTER,0x1c53bb6b,0x1254c367]);let _0x29f2ee=_0x500d13;while(_0x1ea621[_0x4809cf(0x100)](_0x29f2ee,_0x4efa60['length']-0x4)){const [_0x58e182,_0x399e9d]=readId(_0x4efa60,_0x29f2ee);if(_0x15c58a[_0x4809cf(0x116)](_0x58e182))return _0x29f2ee;const [_0x12b033,_0x15f1f2]=_0x1ea621[_0x4809cf(0x11e)](readVint,_0x4efa60,_0x1ea621[_0x4809cf(0x109)](_0x29f2ee,_0x399e9d));if(isUnknownSize(_0x12b033,_0x15f1f2))return _0x4efa60[_0x4809cf(0x137)];_0x29f2ee+=_0x1ea621[_0x4809cf(0x134)](_0x399e9d+_0x15f1f2,_0x12b033);}return _0x4efa60['length'];}function extractClusters(_0x286bc7,_0x539f02){const _0x17c65c=_0x1c92,_0x2a3ee7={'ezjbw':function(_0x135931,_0x5b99fb){return _0x135931<_0x5b99fb;},'PIhaQ':function(_0x241004,_0x1a92d9){return _0x241004===_0x1a92d9;},'CVQld':function(_0x472dd4,_0xfde72b,_0x3df0c3){return _0x472dd4(_0xfde72b,_0x3df0c3);},'gGQRa':function(_0x121df5,_0x145ce8,_0x4a00b5,_0x191ab5,_0x351fdc){return _0x121df5(_0x145ce8,_0x4a00b5,_0x191ab5,_0x351fdc);},'IZhnZ':function(_0x19e432,_0x3c88a0,_0x14deb4){return _0x19e432(_0x3c88a0,_0x14deb4);},'lGgUS':function(_0x4a9eef,_0x1e3f3f,_0xca2d97){return _0x4a9eef(_0x1e3f3f,_0xca2d97);},'fTsAY':function(_0x2b738e,_0x33ba2d,_0x3b41af,_0x2bfda4){return _0x2b738e(_0x33ba2d,_0x3b41af,_0x2bfda4);},'WhRZG':function(_0x3d9c35,_0x59e31f){return _0x3d9c35+_0x59e31f;},'BKruD':function(_0x2006be,_0x57ba7c){return _0x2006be+_0x57ba7c;},'EClZP':function(_0x5764a7,_0x54593b,_0x22c237){return _0x5764a7(_0x54593b,_0x22c237);},'Ekfvy':function(_0x38ed2b,_0x2b9497,_0x296260){return _0x38ed2b(_0x2b9497,_0x296260);},'mYnLq':function(_0xfbaf9b,_0x410a14,_0x194ba2){return _0xfbaf9b(_0x410a14,_0x194ba2);}},_0xa3a27a=[],_0x417537=Buffer['from']([0x1f,0x43,0xb6,0x75]);let _0x2b4018=0x0;while(_0x2a3ee7[_0x17c65c(0x113)](_0x2b4018,_0x286bc7[_0x17c65c(0x137)])){const _0x1d4c93=_0x286bc7[_0x17c65c(0x105)](_0x417537,_0x2b4018);if(_0x2a3ee7['PIhaQ'](_0x1d4c93,-0x1))break;const [_0x324509,_0x6af252]=_0x2a3ee7[_0x17c65c(0x12f)](readId,_0x286bc7,_0x1d4c93);if(_0x324509!==ID_CLUSTER){_0x2b4018=_0x1d4c93+0x1;continue;}const [_0x2eb249,_0x442e55]=readVint(_0x286bc7,_0x1d4c93+_0x6af252),_0x45f0ef=_0x1d4c93+_0x6af252+_0x442e55,_0x4a9cdd=_0x2a3ee7[_0x17c65c(0x120)](findClusterEnd,_0x286bc7,_0x45f0ef,_0x2eb249,_0x442e55);let _0x390ded=_0x45f0ef,_0x576266=0x0,_0x4642b1=0x2,_0x2e24ab=![],_0x2d8106=Buffer[_0x17c65c(0x124)](0x0),_0x40a102=Buffer['alloc'](0x0);while(_0x390ded<_0x4a9cdd){const [_0x458ee2,_0x16d900]=_0x2a3ee7[_0x17c65c(0x115)](readId,_0x286bc7,_0x390ded),[_0x183312,_0x26dbb6]=_0x2a3ee7[_0x17c65c(0x131)](readVint,_0x286bc7,_0x390ded+_0x16d900);if(_0x458ee2===ID_TIMESTAMP){_0x576266=_0x2a3ee7[_0x17c65c(0x11a)](readUint,_0x286bc7,_0x2a3ee7['WhRZG'](_0x390ded+_0x16d900,_0x26dbb6),_0x183312),_0x4642b1=_0x183312,_0x2e24ab=!![],_0x2d8106=_0x286bc7[_0x17c65c(0x104)](_0x45f0ef,_0x390ded);const _0x140ddf=_0x2a3ee7['BKruD'](_0x390ded+_0x16d900+_0x26dbb6,_0x183312);_0x40a102=_0x286bc7[_0x17c65c(0x104)](_0x140ddf,_0x4a9cdd);break;}if(_0x458ee2===ID_CLUSTER)break;if(_0x2a3ee7[_0x17c65c(0x114)](isUnknownSize,_0x183312,_0x26dbb6))break;_0x390ded+=_0x2a3ee7['BKruD'](_0x16d900,_0x26dbb6)+_0x183312;}!_0x2e24ab&&(_0x40a102=_0x286bc7[_0x17c65c(0x104)](_0x45f0ef,_0x4a9cdd));let _0x184f51=_0x576266;_0x390ded=_0x45f0ef;while(_0x2a3ee7['ezjbw'](_0x390ded,_0x4a9cdd)){const [_0x24d002,_0x172a7a]=readId(_0x286bc7,_0x390ded),[_0x23f30d,_0x50aca5]=_0x2a3ee7['Ekfvy'](readVint,_0x286bc7,_0x390ded+_0x172a7a);if(_0x2a3ee7[_0x17c65c(0xff)](_0x24d002,ID_SIMPLE_BLOCK)&&_0x23f30d>=0x4){const _0x4b370e=_0x2a3ee7[_0x17c65c(0x117)](_0x390ded+_0x172a7a,_0x50aca5),[,_0x37de9f]=readVint(_0x286bc7,_0x4b370e),_0x43ed4b=_0x286bc7['readInt16BE'](_0x4b370e+_0x37de9f),_0x230002=_0x576266+_0x43ed4b;if(_0x230002>_0x184f51)_0x184f51=_0x230002;}if(_0x24d002===ID_CLUSTER)break;if(_0x2a3ee7[_0x17c65c(0x10c)](isUnknownSize,_0x23f30d,_0x50aca5))break;_0x390ded+=_0x2a3ee7['WhRZG'](_0x172a7a+_0x50aca5,_0x23f30d);}_0xa3a27a['push']({'timestamp':_0x576266,'maxTicks':_0x184f51,'bodyBeforeTimestamp':_0x2d8106,'bodyAfterTimestamp':_0x40a102,'timestampElementSize':_0x4642b1}),_0x2b4018=_0x4a9cdd;}return _0xa3a27a;}function parseWebm(_0x3291ea){const _0x1644d2=_0x1c92,_0x2e5a2a={'LlzcJ':function(_0x1ad441,_0x33d65a){return _0x1ad441+_0x33d65a;},'ZDQdJ':function(_0x36d9a0,_0x4937bc,_0x18f10d){return _0x36d9a0(_0x4937bc,_0x18f10d);},'YrTjV':function(_0xe7b347,_0xa8e053){return _0xe7b347!==_0xa8e053;},'UUilC':function(_0x3b0e39,_0x594dcf){return _0x3b0e39>_0x594dcf;}};let _0x5722e5=0x0;const [,_0x4600e4]=readId(_0x3291ea,_0x5722e5),[_0x6ceefb,_0x595cc6]=readVint(_0x3291ea,_0x2e5a2a[_0x1644d2(0x130)](_0x5722e5,_0x4600e4));_0x5722e5+=_0x4600e4+_0x595cc6+_0x6ceefb;const [_0x408d9d,_0x491bc0]=_0x2e5a2a[_0x1644d2(0x10f)](readId,_0x3291ea,_0x5722e5);if(_0x2e5a2a['YrTjV'](_0x408d9d,ID_SEGMENT))return null;const [,_0x4a86ce]=readVint(_0x3291ea,_0x5722e5+_0x491bc0),_0x1e8586=_0x2e5a2a[_0x1644d2(0x130)](_0x5722e5+_0x491bc0,_0x4a86ce),_0x1dcd23=_0x2e5a2a[_0x1644d2(0x10f)](findTimestampScale,_0x3291ea,_0x1e8586),_0x38eaad=_0x2e5a2a['ZDQdJ'](findFirstClusterOffset,_0x3291ea,_0x1e8586),_0x2652dd=_0x3291ea['slice'](0x0,_0x38eaad),_0x2563af=extractClusters(_0x3291ea,_0x1dcd23);let _0x423f81=0x0;for(const _0x46c5eb of _0x2563af){if(_0x2e5a2a['UUilC'](_0x46c5eb[_0x1644d2(0x11b)],_0x423f81))_0x423f81=_0x46c5eb[_0x1644d2(0x11b)];}return{'header':_0x2652dd,'clusters':_0x2563af,'timestampScale':_0x1dcd23,'maxTimestampTicks':_0x423f81};}function _0x1c92(_0x15c24c,_0x3d144b){_0x15c24c=_0x15c24c-0xf9;const _0x1e32fa=_0x1e32();let _0x1c92ce=_0x1e32fa[_0x15c24c];return _0x1c92ce;}function buildCluster(_0x29fe6d,_0x1c2cc1,_0x59290b){const _0x1b19ef=_0x1c92,_0x834e4d={'CFGfB':function(_0x38eac6,_0x2db0db,_0x1eb3fb){return _0x38eac6(_0x2db0db,_0x1eb3fb);}},_0x445014=Buffer['from']([0x1f,0x43,0xb6,0x75]),_0x7ed040=Math['max'](0x4,uintSize(_0x29fe6d)),_0x4555fa=Buffer[_0x1b19ef(0x11c)]([Buffer['from']([ID_TIMESTAMP]),writeVint(_0x7ed040),_0x834e4d[_0x1b19ef(0x12c)](writeUint,_0x29fe6d,_0x7ed040)]),_0x599252=Buffer[_0x1b19ef(0x11c)]([_0x1c2cc1,_0x4555fa,_0x59290b]),_0x4c624d=writeVint(_0x599252['length']);return Buffer['concat']([_0x445014,_0x4c624d,_0x599252]);}const ID_DURATION=0x4489;function rebuildHeaderWithoutDuration(_0x1d4f65){const _0x38d9e1=_0x1c92,_0x33c31b={'MDlUV':function(_0x34c2bb,_0x365049,_0x79bffa){return _0x34c2bb(_0x365049,_0x79bffa);},'NbeIZ':function(_0x48f8c6,_0x2f5f3c){return _0x48f8c6+_0x2f5f3c;},'uodLG':function(_0x167e4f,_0x4b679d,_0x3faca0){return _0x167e4f(_0x4b679d,_0x3faca0);},'AxDTf':function(_0x4e7c30,_0x19dc33){return _0x4e7c30+_0x19dc33;},'ScNCY':function(_0x34de61,_0x565f69){return _0x34de61(_0x565f69);},'Altjk':function(_0x4651ac,_0x4a0303){return _0x4651ac+_0x4a0303;},'wepHM':function(_0x5587e7,_0x4387f2){return _0x5587e7+_0x4387f2;},'BHWKa':function(_0x6e796e,_0x3b6e70){return _0x6e796e<_0x3b6e70;},'OzkFv':function(_0xbc0940,_0x466a03,_0x3dabcb){return _0xbc0940(_0x466a03,_0x3dabcb);},'oJYeN':function(_0x50672d,_0x4e0a7d){return _0x50672d+_0x4e0a7d;},'mSgaV':function(_0x52303a,_0x2190d1){return _0x52303a!==_0x2190d1;},'ZLrlw':function(_0x35c24c,_0x49024e,_0x337a61){return _0x35c24c(_0x49024e,_0x337a61);}},_0x387fbb=Buffer['from'](_0x1d4f65);let _0x80a400=0x0;const [,_0x3ea98b]=readId(_0x387fbb,_0x80a400),[_0x12b138,_0x50a1a6]=_0x33c31b['MDlUV'](readVint,_0x387fbb,_0x80a400+_0x3ea98b),_0x13604b=_0x33c31b['NbeIZ'](_0x80a400,_0x3ea98b)+_0x50a1a6+_0x12b138,[,_0x1e4fd8]=_0x33c31b['MDlUV'](readId,_0x387fbb,_0x13604b),[,_0x2d5a4f]=_0x33c31b['uodLG'](readVint,_0x387fbb,_0x13604b+_0x1e4fd8),_0x26d05e=_0x33c31b['AxDTf'](_0x13604b+_0x1e4fd8,_0x2d5a4f),_0x2eb8f7=_0x33c31b['ScNCY'](writeUnknownSizeVint,_0x2d5a4f);_0x2eb8f7[_0x38d9e1(0x11f)](_0x387fbb,_0x33c31b['Altjk'](_0x13604b,_0x1e4fd8));let _0x2e8fa5=_0x26d05e;const _0x56af59=Math[_0x38d9e1(0x106)](_0x387fbb[_0x38d9e1(0x137)],_0x33c31b[_0x38d9e1(0x10b)](_0x26d05e,0x2710));while(_0x33c31b['BHWKa'](_0x2e8fa5,_0x56af59)){const [_0x8ead90,_0x5028bd]=_0x33c31b['uodLG'](readId,_0x387fbb,_0x2e8fa5),[_0x389d7e,_0x1943e3]=_0x33c31b[_0x38d9e1(0x12d)](readVint,_0x387fbb,_0x33c31b[_0x38d9e1(0x10b)](_0x2e8fa5,_0x5028bd));if(_0x8ead90===ID_CLUSTER)break;if(_0x33c31b[_0x38d9e1(0x13f)](isUnknownSize,_0x389d7e,_0x1943e3))break;if(_0x8ead90===ID_INFO){const _0x3a17b1=_0x2e8fa5+_0x5028bd+_0x1943e3,_0x56f0b7=_0x33c31b['wepHM'](_0x3a17b1,_0x389d7e),_0x30137b=[];let _0x1a6caf=_0x3a17b1;while(_0x1a6caf<_0x56f0b7){const [_0x5a6baa,_0x43b87f]=readId(_0x387fbb,_0x1a6caf),[_0x4f7560,_0x472dce]=readVint(_0x387fbb,_0x33c31b[_0x38d9e1(0x140)](_0x1a6caf,_0x43b87f)),_0x2594f5=_0x33c31b['Altjk'](_0x43b87f+_0x472dce,_0x4f7560);_0x33c31b['mSgaV'](_0x5a6baa,ID_DURATION)&&_0x30137b[_0x38d9e1(0x111)](_0x387fbb[_0x38d9e1(0x104)](_0x1a6caf,_0x1a6caf+_0x2594f5)),_0x1a6caf+=_0x2594f5;}const _0x3f2572=Buffer['concat'](_0x30137b),_0x1030f9=Buffer['concat']([_0x387fbb[_0x38d9e1(0x104)](_0x2e8fa5,_0x33c31b['NbeIZ'](_0x2e8fa5,_0x5028bd)),_0x33c31b[_0x38d9e1(0x121)](writeVint,_0x3f2572[_0x38d9e1(0x137)],_0x1943e3)]);return Buffer[_0x38d9e1(0x11c)]([_0x387fbb[_0x38d9e1(0x104)](0x0,_0x2e8fa5),_0x1030f9,_0x3f2572,_0x387fbb[_0x38d9e1(0x104)](_0x56f0b7)]);}_0x2e8fa5+=_0x33c31b['NbeIZ'](_0x5028bd+_0x1943e3,_0x389d7e);}return _0x387fbb;}export function stitchWebmFiles(_0x57d317,_0x4f48ca){const _0x43ee95=_0x1c92,_0x53ed0f={'VBAQs':function(_0x5aaad1,_0x5709c6){return _0x5aaad1(_0x5709c6);},'rliZd':function(_0x24bc0e,_0x1bb3a3){return _0x24bc0e+_0x1bb3a3;},'ZmJJv':function(_0x3a6c77,_0x262f1c,_0x1ccfe0){return _0x3a6c77(_0x262f1c,_0x1ccfe0);}};if(_0x57d317['length']<=0x1)return![];const _0xa95bfd=[];for(const _0x4071f1 of _0x57d317){const _0x352e2c=readFileSync(_0x4071f1),_0x1f0675=parseWebm(_0x352e2c);if(!_0x1f0675||_0x1f0675['clusters']['length']===0x0)return![];_0xa95bfd[_0x43ee95(0x111)](_0x1f0675);}const _0x387697=_0xa95bfd[0x0],_0x4410aa=_0x53ed0f[_0x43ee95(0x139)](rebuildHeaderWithoutDuration,_0x387697['header']),_0x3991cd=[_0x4410aa];let _0x5c383d=0x0;for(let _0x118830=0x0;_0x118830<_0xa95bfd['length'];_0x118830++){const _0x53062a=_0xa95bfd[_0x118830];for(const _0x30f38f of _0x53062a[_0x43ee95(0x128)]){const _0x39bf49=_0x53ed0f['rliZd'](_0x30f38f[_0x43ee95(0x12e)],_0x5c383d);_0x3991cd['push'](buildCluster(_0x39bf49,_0x30f38f[_0x43ee95(0x126)],_0x30f38f[_0x43ee95(0x11d)]));}const _0x2ad592=0x1e;_0x5c383d+=_0x53062a['maxTimestampTicks']+_0x2ad592;}return _0x53ed0f['ZmJJv'](writeFileSync,_0x4f48ca,Buffer['concat'](_0x3991cd)),!![];}if(process[_0x26c6f2(0x136)][0x1]?.[_0x26c6f2(0x102)]('stitchWebmFiles.ts')||process['argv'][0x1]?.['endsWith']('stitchWebmFiles.js')){const args=process[_0x26c6f2(0x136)]['slice'](0x2);args[_0x26c6f2(0x137)]<0x3&&(console[_0x26c6f2(0x108)](_0x26c6f2(0x12b)),process['exit'](0x1));const output=args[args['length']-0x1],inputs=args[_0x26c6f2(0x104)](0x0,-0x1),ok=stitchWebmFiles(inputs,output);ok?console['log'](_0x26c6f2(0x122)+inputs['length']+_0x26c6f2(0x133)+output):console[_0x26c6f2(0x135)]('Stitching\x20failed\x20or\x20only\x20one\x20input\x20file.');}
@@ -1 +1 @@
1
- const _0x149399=_0x150c;(function(_0x5d3d5c,_0x3e42b8){const _0x579240=_0x150c,_0x18beca=_0x5d3d5c();while(!![]){try{const _0x2939c8=-parseInt(_0x579240(0x1a4))/0x1*(parseInt(_0x579240(0x198))/0x2)+parseInt(_0x579240(0x1a0))/0x3+-parseInt(_0x579240(0x1a3))/0x4+-parseInt(_0x579240(0x18e))/0x5*(parseInt(_0x579240(0x1a7))/0x6)+-parseInt(_0x579240(0x17d))/0x7+parseInt(_0x579240(0x187))/0x8+parseInt(_0x579240(0x172))/0x9;if(_0x2939c8===_0x3e42b8)break;else _0x18beca['push'](_0x18beca['shift']());}catch(_0x1963da){_0x18beca['push'](_0x18beca['shift']());}}}(_0x369f,0x7a6a1));import{randomUUID}from'crypto';import{existsSync,mkdirSync,readFileSync,writeFileSync}from'fs';import{join}from'path';import{homedir}from'os';import{getToken}from'./keychain.js';import{getApiBaseUrl}from'./environment.js';function _0x369f(){const _0x525abe=['flushAsync','commandStartTime','now','POST','version','2722748YIOqIT','phase','outcome','metadata','durationMs','gNCqc','command','DEBUG','platform','setContext','7922216cwxhsY','NaRMC','stdout','buffer','splice','checklistItemId','/api/v1/mcp/cli-telemetry','245oDfoFe','phaseCounter','sendBatch','env','[telemetry]\x20Sending\x20','constructor','message','isCI','nFjPg','phase_start','1154dJUkaX','push','zGtLX','trackCommandError','trackCommandEnd','HHroP','phaseStartTimes','mzbuc','189378usreya','slice','errorMessage','1355352KsyxfS','1633kIHLFu','UnGUr','cliVersion','106734TNByUu','MxFXL','cRwBR','stringify','sendImmediate','Unknown','LbRfE','flush','commandId','nodeVersion','command_error','transport','name','buildEvent','trackPhaseEnd','abort','WsBIl','success','.session','.ranger','NvJOd','trim','length','Bearer\x20','errorType','\x20event(s)\x20to\x20','utf-8','flushing','browserSessionId','delete','phase_error','isTty','loCjf','17907390RDlDgR','trackPhaseStart','split','featureId','catch','finally'];_0x369f=function(){return _0x525abe;};return _0x369f();}import{getCurrentVersion}from'./version.js';let cachedDeviceId=null;function getDeviceId(){const _0x2af51d=_0x150c,_0x37e01a={'LbRfE':function(_0xfca602,_0x402133,_0x2272c4){return _0xfca602(_0x402133,_0x2272c4);},'UnGUr':_0x2af51d(0x1b9),'loCjf':function(_0x18ee9f){return _0x18ee9f();}};if(cachedDeviceId)return cachedDeviceId;try{const _0x56ee16=join(homedir(),_0x2af51d(0x1ba)),_0x167989=_0x37e01a[_0x2af51d(0x1ad)](join,_0x56ee16,_0x37e01a[_0x2af51d(0x1a5)]);if(existsSync(_0x167989)){cachedDeviceId=readFileSync(_0x167989,_0x2af51d(0x16b))[_0x2af51d(0x166)]();if(cachedDeviceId)return cachedDeviceId;}return cachedDeviceId=randomUUID(),mkdirSync(_0x56ee16,{'recursive':!![]}),_0x37e01a[_0x2af51d(0x1ad)](writeFileSync,_0x167989,cachedDeviceId),cachedDeviceId;}catch{return cachedDeviceId=_0x37e01a[_0x2af51d(0x171)](randomUUID),cachedDeviceId;}}export class TelemetryCollector{[_0x149399(0x18a)]=[];['commandId'];[_0x149399(0x183)];['commandStartTime'];[_0x149399(0x18f)]=0x0;['phaseStartTimes']=new Map();[_0x149399(0x16c)]=null;['deviceId'];[_0x149399(0x1a6)];['nodeVersion'];[_0x149399(0x185)];[_0x149399(0x170)];[_0x149399(0x195)];['featureId'];[_0x149399(0x18c)];[_0x149399(0x16d)];['transport'];constructor(_0x46c66a){const _0x1668d0=_0x149399,_0x19b2c2={'rfAGy':function(_0x13e28c){return _0x13e28c();}},_0x3abdc6='4|1|8|2|7|6|5|0|3'[_0x1668d0(0x174)]('|');let _0x3d7e60=0x0;while(!![]){switch(_0x3abdc6[_0x3d7e60++]){case'0':this['isTty']=process[_0x1668d0(0x189)]['isTTY']??![];continue;case'1':this['command']=_0x46c66a;continue;case'2':this['deviceId']=_0x19b2c2['rfAGy'](getDeviceId);continue;case'3':this['isCI']=!!(process['env']['CI']||process['env']['GITHUB_ACTIONS']);continue;case'4':this[_0x1668d0(0x1af)]=randomUUID();continue;case'5':this[_0x1668d0(0x185)]=process['platform'];continue;case'6':this[_0x1668d0(0x1b0)]=process[_0x1668d0(0x17c)];continue;case'7':this[_0x1668d0(0x1a6)]=_0x19b2c2['rfAGy'](getCurrentVersion);continue;case'8':this[_0x1668d0(0x179)]=Date[_0x1668d0(0x17a)]();continue;}break;}}[_0x149399(0x186)](_0x1dbc5d){const _0x4a95bc=_0x149399;if(_0x1dbc5d['featureId'])this[_0x4a95bc(0x175)]=_0x1dbc5d['featureId'];if(_0x1dbc5d['checklistItemId'])this['checklistItemId']=_0x1dbc5d[_0x4a95bc(0x18c)];if(_0x1dbc5d[_0x4a95bc(0x16d)])this[_0x4a95bc(0x16d)]=_0x1dbc5d['browserSessionId'];if(_0x1dbc5d['transport'])this['transport']=_0x1dbc5d['transport'];}async['trackCommandStart'](_0x509d0a){const _0x445b07=_0x149399,_0x124447=this['buildEvent']({'eventType':'command_start','metadata':_0x509d0a});await this[_0x445b07(0x1ab)](_0x124447);}async[_0x149399(0x19c)](_0x24bb3b,_0x417e64){const _0x354682=_0x149399,_0x5109f5={'HHroP':'command_end'},_0x175910=this['buildEvent']({'eventType':_0x5109f5[_0x354682(0x19d)],'outcome':_0x24bb3b,'durationMs':Date['now']()-this[_0x354682(0x179)],'metadata':_0x417e64});await this[_0x354682(0x1ab)](_0x175910),await this[_0x354682(0x1ae)]();}async['trackCommandError'](_0x33de17,_0x441b6d){const _0x1f5c59=_0x149399,_0x2d34a2={'fSjAm':_0x1f5c59(0x1b1),'TjBDk':function(_0x43f9d9,_0x1e7bd0,_0xff3b09){return _0x43f9d9(_0x1e7bd0,_0xff3b09);},'LmRyz':function(_0x10ba5d,_0x10567a){return _0x10ba5d instanceof _0x10567a;},'TXJis':function(_0x4de3b3,_0x567953){return _0x4de3b3(_0x567953);},'nFjPg':function(_0x4834bd,_0x53d241){return _0x4834bd instanceof _0x53d241;}},_0x3d5e28=this['buildEvent']({'eventType':_0x2d34a2['fSjAm'],'errorMessage':_0x2d34a2['TjBDk'](truncate,_0x2d34a2['LmRyz'](_0x33de17,Error)?_0x33de17[_0x1f5c59(0x194)]:_0x2d34a2['TXJis'](String,_0x33de17),0x1f4),'errorType':_0x2d34a2[_0x1f5c59(0x196)](_0x33de17,Error)?_0x33de17[_0x1f5c59(0x193)][_0x1f5c59(0x1b3)]:'Unknown','durationMs':Date[_0x1f5c59(0x17a)]()-this['commandStartTime'],'metadata':_0x441b6d});await this[_0x1f5c59(0x1ab)](_0x3d5e28),await this[_0x1f5c59(0x1ae)]();}[_0x149399(0x173)](_0x1302b1,_0x25c68d){const _0x1fd279=_0x149399,_0x4bdffb={'SeWSP':_0x1fd279(0x197)};this[_0x1fd279(0x18f)]++,this['phaseStartTimes']['set'](_0x1302b1,Date['now']());const _0x4270e3=this['buildEvent']({'eventType':_0x4bdffb['SeWSP'],'phase':_0x1302b1,'phaseIndex':this['phaseCounter'],'metadata':_0x25c68d});this[_0x1fd279(0x18a)][_0x1fd279(0x199)](_0x4270e3);}[_0x149399(0x1b5)](_0x3206db,_0x3599fd){const _0x5dd733=_0x149399,_0x474fa0={'MxFXL':'phase_end'},_0x83d281=this[_0x5dd733(0x19e)]['get'](_0x3206db),_0x22c294=_0x83d281?Date[_0x5dd733(0x17a)]()-_0x83d281:undefined;this[_0x5dd733(0x19e)]['delete'](_0x3206db);const _0x5e9807=this[_0x5dd733(0x1b4)]({'eventType':_0x474fa0[_0x5dd733(0x1a8)],'phase':_0x3206db,'durationMs':_0x22c294,'metadata':_0x3599fd});this[_0x5dd733(0x18a)][_0x5dd733(0x199)](_0x5e9807),this[_0x5dd733(0x18a)][_0x5dd733(0x167)]>=0xa&&this[_0x5dd733(0x178)]();}async['trackPhaseError'](_0x6e4510,_0x3557ac,_0x2a2941){const _0x33cbd1=_0x149399,_0x23e017={'DUDTR':_0x33cbd1(0x16f),'NvJOd':function(_0x24e801,_0x126f03){return _0x24e801 instanceof _0x126f03;}},_0x3e7ece=this[_0x33cbd1(0x19e)]['get'](_0x6e4510),_0x543bfb=_0x3e7ece?Date[_0x33cbd1(0x17a)]()-_0x3e7ece:undefined;this[_0x33cbd1(0x19e)][_0x33cbd1(0x16e)](_0x6e4510);const _0x4a9289=this['buildEvent']({'eventType':_0x23e017['DUDTR'],'phase':_0x6e4510,'durationMs':_0x543bfb,'errorMessage':truncate(_0x23e017[_0x33cbd1(0x165)](_0x3557ac,Error)?_0x3557ac[_0x33cbd1(0x194)]:String(_0x3557ac),0x1f4),'errorType':_0x23e017[_0x33cbd1(0x165)](_0x3557ac,Error)?_0x3557ac[_0x33cbd1(0x193)]['name']:_0x33cbd1(0x1ac),'metadata':_0x2a2941});await this[_0x33cbd1(0x1ab)](_0x4a9289);}async['flush'](){const _0x25221b=_0x149399,_0x4bda7a={'gNCqc':function(_0x5a404e,_0x8be3ff){return _0x5a404e===_0x8be3ff;}};if(_0x4bda7a[_0x25221b(0x182)](this['buffer']['length'],0x0))return;const _0x25b475=this['buffer'][_0x25221b(0x18b)](0x0);try{await this['sendBatch'](_0x25b475);}catch{}}[_0x149399(0x1b4)](_0x130bee){const _0x1734be=_0x149399;return{'eventType':_0x130bee['eventType'],'command':this[_0x1734be(0x183)],'commandId':this[_0x1734be(0x1af)],'deviceId':this['deviceId'],'timestamp':new Date()['toISOString'](),'durationMs':_0x130bee[_0x1734be(0x181)],'phase':_0x130bee[_0x1734be(0x17e)],'phaseIndex':_0x130bee['phaseIndex'],'outcome':_0x130bee[_0x1734be(0x17f)],'errorMessage':_0x130bee[_0x1734be(0x1a2)],'errorType':_0x130bee[_0x1734be(0x169)],'featureId':this['featureId'],'checklistItemId':this['checklistItemId'],'browserSessionId':this['browserSessionId'],'transport':this[_0x1734be(0x1b2)],'evaluation':_0x130bee['evaluation'],'cliVersion':this['cliVersion'],'nodeVersion':this['nodeVersion'],'platform':this[_0x1734be(0x185)],'cwd':process['cwd'](),'isTty':this[_0x1734be(0x170)],'isCI':this[_0x1734be(0x195)],'metadata':_0x130bee[_0x1734be(0x180)]};}async['sendImmediate'](_0x2c9645){const _0x187ee8=_0x149399;try{await this[_0x187ee8(0x190)]([_0x2c9645]);}catch{}}[_0x149399(0x178)](){const _0x427078=_0x149399;if(this['flushing'])return;this['flushing']=this['flush']()[_0x427078(0x177)](()=>{this['flushing']=null;});}async[_0x149399(0x190)](_0x48380c){const _0x2d1328=_0x149399,_0x1da0a4={'mzbuc':function(_0x2e57b2,_0x40eeb0,_0x1d6a77){return _0x2e57b2(_0x40eeb0,_0x1d6a77);},'zGtLX':_0x2d1328(0x17b),'NaRMC':function(_0x4ae73c,_0x6f8ebd){return _0x4ae73c(_0x6f8ebd);}},_0x101ad5=await getToken()[_0x2d1328(0x176)](()=>null),_0x11b326=getApiBaseUrl(),_0x312d85={'Content-Type':'application/json'};_0x101ad5&&(_0x312d85['Authorization']=_0x2d1328(0x168)+_0x101ad5);const _0x48305b={'events':_0x48380c};process[_0x2d1328(0x191)][_0x2d1328(0x184)]&&console['error'](_0x2d1328(0x192)+_0x48380c[_0x2d1328(0x167)]+_0x2d1328(0x16a)+_0x11b326+_0x2d1328(0x18d));const _0x56122b=new AbortController(),_0x3be6ad=_0x1da0a4[_0x2d1328(0x19f)](setTimeout,()=>_0x56122b[_0x2d1328(0x1b6)](),0x1388);try{await _0x1da0a4[_0x2d1328(0x19f)](fetch,_0x11b326+'/api/v1/mcp/cli-telemetry',{'method':_0x1da0a4[_0x2d1328(0x19a)],'headers':_0x312d85,'body':JSON[_0x2d1328(0x1aa)](_0x48305b),'signal':_0x56122b['signal']});}finally{_0x1da0a4[_0x2d1328(0x188)](clearTimeout,_0x3be6ad);}}}function _0x150c(_0x233496,_0x17fa07){_0x233496=_0x233496-0x165;const _0x369f2e=_0x369f();let _0x150cfe=_0x369f2e[_0x233496];return _0x150cfe;}let currentCollector=null;export function createTelemetryCollector(_0x251948){return currentCollector=new TelemetryCollector(_0x251948),currentCollector;}export function getCurrentCollector(){return currentCollector;}export async function withTelemetry(_0x175968,_0x57f29f,_0x3bba14){const _0x4a6d96=_0x149399,_0x5a8702={'TLoEp':function(_0x50923b,_0x373db6){return _0x50923b(_0x373db6);},'WsBIl':_0x4a6d96(0x1b8)},_0x53ef09=_0x5a8702['TLoEp'](createTelemetryCollector,_0x175968);await _0x53ef09['trackCommandStart'](_0x3bba14);try{const _0x590ffe=await _0x57f29f(_0x53ef09);return await _0x53ef09['trackCommandEnd'](_0x5a8702[_0x4a6d96(0x1b7)]),_0x590ffe;}catch(_0x383b16){await _0x53ef09[_0x4a6d96(0x19b)](_0x383b16);throw _0x383b16;}finally{await _0x53ef09[_0x4a6d96(0x1ae)]();}}function truncate(_0x1f6379,_0x30faab){const _0x48c70c=_0x149399,_0x77a6f9={'UYHFn':function(_0x3d7a48,_0x3b34fc){return _0x3d7a48>_0x3b34fc;},'cjSBA':function(_0x11f44d,_0x484ace){return _0x11f44d+_0x484ace;},'cRwBR':'...'};return _0x77a6f9['UYHFn'](_0x1f6379[_0x48c70c(0x167)],_0x30faab)?_0x77a6f9['cjSBA'](_0x1f6379[_0x48c70c(0x1a1)](0x0,_0x30faab),_0x77a6f9[_0x48c70c(0x1a9)]):_0x1f6379;}
1
+ function _0x5d54(){const _0x159c95=['3528MdAzsj','2219MrzZEo','deviceId','9AntoXg','phase_error','abort','319TLzLLw','trackCommandStart','command','sendImmediate','Bearer\x20','flush','phase_end','now','isCI','bDEvf','736821WfyqEr','\x20event(s)\x20to\x20','.session','isTTY','Unknown','buffer','phaseStartTimes','isTty','[telemetry]\x20Sending\x20','browserSessionId','360948MezAYq','slice','515tNXToS','flushing','trackPhaseError','GITHUB_ACTIONS','trim','commandId','zoAuw','error','buildEvent','jHhkG','Authorization','checklistItemId','platform','constructor','length','nodeVersion','application/json','push','name','version','delete','get','trackCommandEnd','213akPAoq','commandStartTime','env','6264GVMEXh','outcome','set','featureId','4872470OZQfNZ','QURNN','finally','trackCommandError','4SMXrTS','flushAsync','...','phase_start','.ranger','success','NYrEE','sendBatch','trackPhaseEnd','setContext','transport','ZJDbF','38ZMGJMI','phase','MprZh','cliVersion','command_error','19976125irpvjO','splice','paHnT','MnYuv'];_0x5d54=function(){return _0x159c95;};return _0x5d54();}const _0x44706c=_0x4b72;(function(_0x237b98,_0x1f4747){const _0x13c2fc=_0x4b72,_0x3701a8=_0x237b98();while(!![]){try{const _0xc84a8e=parseInt(_0x13c2fc(0xfa))/0x1*(-parseInt(_0x13c2fc(0x111))/0x2)+-parseInt(_0x13c2fc(0x12a))/0x3*(-parseInt(_0x13c2fc(0x105))/0x4)+-parseInt(_0x13c2fc(0x136))/0x5*(parseInt(_0x13c2fc(0xfd))/0x6)+-parseInt(_0x13c2fc(0x11b))/0x7*(-parseInt(_0x13c2fc(0x11a))/0x8)+parseInt(_0x13c2fc(0x11d))/0x9*(-parseInt(_0x13c2fc(0x101))/0xa)+parseInt(_0x13c2fc(0x120))/0xb*(-parseInt(_0x13c2fc(0x134))/0xc)+parseInt(_0x13c2fc(0x116))/0xd;if(_0xc84a8e===_0x1f4747)break;else _0x3701a8['push'](_0x3701a8['shift']());}catch(_0x472db3){_0x3701a8['push'](_0x3701a8['shift']());}}}(_0x5d54,0x6e160));import{randomUUID}from'crypto';import{existsSync,mkdirSync,readFileSync,writeFileSync}from'fs';import{join}from'path';import{homedir}from'os';import{getToken}from'./keychain.js';import{getApiBaseUrl}from'./environment.js';import{getCurrentVersion}from'./version.js';let cachedDeviceId=null;function getDeviceId(){const _0x393756=_0x4b72,_0x5563bb={'arwHh':function(_0x4e9f54,_0x493439,_0x2f8792){return _0x4e9f54(_0x493439,_0x2f8792);},'UKkXA':function(_0x5d0904,_0x39a2ce,_0x138cd5){return _0x5d0904(_0x39a2ce,_0x138cd5);},'zjHPH':'utf-8'};if(cachedDeviceId)return cachedDeviceId;try{const _0x82a350=_0x5563bb['arwHh'](join,homedir(),_0x393756(0x109)),_0x198641=join(_0x82a350,_0x393756(0x12c));if(existsSync(_0x198641)){cachedDeviceId=_0x5563bb['UKkXA'](readFileSync,_0x198641,_0x5563bb['zjHPH'])[_0x393756(0x13a)]();if(cachedDeviceId)return cachedDeviceId;}return cachedDeviceId=randomUUID(),mkdirSync(_0x82a350,{'recursive':!![]}),writeFileSync(_0x198641,cachedDeviceId),cachedDeviceId;}catch{return cachedDeviceId=randomUUID(),cachedDeviceId;}}export class TelemetryCollector{[_0x44706c(0x12f)]=[];['commandId'];['command'];[_0x44706c(0xfb)];['phaseCounter']=0x0;[_0x44706c(0x130)]=new Map();[_0x44706c(0x137)]=null;['deviceId'];['cliVersion'];['nodeVersion'];[_0x44706c(0x142)];[_0x44706c(0x131)];['isCI'];[_0x44706c(0x100)];['checklistItemId'];['browserSessionId'];['transport'];constructor(_0x4b9dd7){const _0x394ec1=_0x44706c,_0x507826={'zoAuw':function(_0x4d8e0b){return _0x4d8e0b();}};this['commandId']=_0x507826['zoAuw'](randomUUID),this[_0x394ec1(0x122)]=_0x4b9dd7,this[_0x394ec1(0xfb)]=Date[_0x394ec1(0x127)](),this[_0x394ec1(0x11c)]=getDeviceId(),this[_0x394ec1(0x114)]=_0x507826[_0x394ec1(0x13c)](getCurrentVersion),this['nodeVersion']=process[_0x394ec1(0xf6)],this['platform']=process['platform'],this['isTty']=process['stdout'][_0x394ec1(0x12d)]??![],this[_0x394ec1(0x128)]=!!(process['env']['CI']||process[_0x394ec1(0xfc)][_0x394ec1(0x139)]);}[_0x44706c(0x10e)](_0x819ca4){const _0x21ca41=_0x44706c;if(_0x819ca4['featureId'])this['featureId']=_0x819ca4['featureId'];if(_0x819ca4[_0x21ca41(0x141)])this[_0x21ca41(0x141)]=_0x819ca4[_0x21ca41(0x141)];if(_0x819ca4[_0x21ca41(0x133)])this[_0x21ca41(0x133)]=_0x819ca4['browserSessionId'];if(_0x819ca4['transport'])this[_0x21ca41(0x10f)]=_0x819ca4[_0x21ca41(0x10f)];}async[_0x44706c(0x121)](_0x182046){const _0x2b2f70=_0x44706c,_0x29257b=this['buildEvent']({'eventType':'command_start','metadata':_0x182046});await this[_0x2b2f70(0x123)](_0x29257b);}async['trackCommandEnd'](_0x174282,_0x4d4337){const _0x276bc4=_0x44706c,_0x2e087f=this[_0x276bc4(0x13e)]({'eventType':'command_end','outcome':_0x174282,'durationMs':Date['now']()-this['commandStartTime'],'metadata':_0x4d4337});await this[_0x276bc4(0x123)](_0x2e087f),await this['flush']();}async['trackCommandError'](_0x2f2d43,_0x56f791){const _0x192ea1=_0x44706c,_0x40ffac={'jHhkG':function(_0x2236ea,_0x47c6f2){return _0x2236ea instanceof _0x47c6f2;},'ZJDbF':_0x192ea1(0x12e)},_0xd8229b=this['buildEvent']({'eventType':_0x192ea1(0x115),'errorMessage':truncate(_0x40ffac[_0x192ea1(0x13f)](_0x2f2d43,Error)?_0x2f2d43['message']:String(_0x2f2d43),0x1f4),'errorType':_0x40ffac['jHhkG'](_0x2f2d43,Error)?_0x2f2d43['constructor']['name']:_0x40ffac[_0x192ea1(0x110)],'durationMs':Date['now']()-this['commandStartTime'],'metadata':_0x56f791});await this['sendImmediate'](_0xd8229b),await this[_0x192ea1(0x125)]();}['trackPhaseStart'](_0x5d1305,_0x51fb40){const _0x5d8c73=_0x44706c;this['phaseCounter']++,this[_0x5d8c73(0x130)][_0x5d8c73(0xff)](_0x5d1305,Date['now']());const _0xb584f8=this[_0x5d8c73(0x13e)]({'eventType':_0x5d8c73(0x108),'phase':_0x5d1305,'phaseIndex':this['phaseCounter'],'metadata':_0x51fb40});this[_0x5d8c73(0x12f)][_0x5d8c73(0xf4)](_0xb584f8);}[_0x44706c(0x10d)](_0x18cccd,_0x580f46){const _0x45aa74=_0x44706c,_0x5b0eba={'fgRwi':_0x45aa74(0x126),'bDEvf':function(_0x57433e,_0xfe1121){return _0x57433e>=_0xfe1121;}},_0x2c0da5=this[_0x45aa74(0x130)][_0x45aa74(0xf8)](_0x18cccd),_0x1e56c2=_0x2c0da5?Date[_0x45aa74(0x127)]()-_0x2c0da5:undefined;this[_0x45aa74(0x130)][_0x45aa74(0xf7)](_0x18cccd);const _0x1a5d5b=this['buildEvent']({'eventType':_0x5b0eba['fgRwi'],'phase':_0x18cccd,'durationMs':_0x1e56c2,'metadata':_0x580f46});this['buffer'][_0x45aa74(0xf4)](_0x1a5d5b),_0x5b0eba[_0x45aa74(0x129)](this[_0x45aa74(0x12f)]['length'],0xa)&&this[_0x45aa74(0x106)]();}async[_0x44706c(0x138)](_0x3f65d2,_0x17d1b1,_0x24779c){const _0x32668c=_0x44706c,_0x39be0e={'NrgNn':function(_0x455d1f,_0x1f8fe3,_0x404d1c){return _0x455d1f(_0x1f8fe3,_0x404d1c);},'MprZh':function(_0x422c02,_0x40bceb){return _0x422c02 instanceof _0x40bceb;},'NYrEE':function(_0x42a98f,_0x2c377a){return _0x42a98f(_0x2c377a);}},_0x88ad7e=this['phaseStartTimes']['get'](_0x3f65d2),_0x1f67b4=_0x88ad7e?Date[_0x32668c(0x127)]()-_0x88ad7e:undefined;this[_0x32668c(0x130)]['delete'](_0x3f65d2);const _0x2cdfbf=this['buildEvent']({'eventType':_0x32668c(0x11e),'phase':_0x3f65d2,'durationMs':_0x1f67b4,'errorMessage':_0x39be0e['NrgNn'](truncate,_0x39be0e[_0x32668c(0x113)](_0x17d1b1,Error)?_0x17d1b1['message']:_0x39be0e[_0x32668c(0x10b)](String,_0x17d1b1),0x1f4),'errorType':_0x39be0e[_0x32668c(0x113)](_0x17d1b1,Error)?_0x17d1b1[_0x32668c(0x143)][_0x32668c(0xf5)]:'Unknown','metadata':_0x24779c});await this[_0x32668c(0x123)](_0x2cdfbf);}async['flush'](){const _0x4a04b6=_0x44706c;if(this[_0x4a04b6(0x12f)]['length']===0x0)return;const _0x149200=this['buffer'][_0x4a04b6(0x117)](0x0);try{await this['sendBatch'](_0x149200);}catch{}}[_0x44706c(0x13e)](_0x16fedd){const _0x166cd1=_0x44706c;return{'eventType':_0x16fedd['eventType'],'command':this[_0x166cd1(0x122)],'commandId':this[_0x166cd1(0x13b)],'deviceId':this[_0x166cd1(0x11c)],'timestamp':new Date()['toISOString'](),'durationMs':_0x16fedd['durationMs'],'phase':_0x16fedd[_0x166cd1(0x112)],'phaseIndex':_0x16fedd['phaseIndex'],'outcome':_0x16fedd[_0x166cd1(0xfe)],'errorMessage':_0x16fedd['errorMessage'],'errorType':_0x16fedd['errorType'],'featureId':this[_0x166cd1(0x100)],'checklistItemId':this[_0x166cd1(0x141)],'browserSessionId':this['browserSessionId'],'transport':this['transport'],'evaluation':_0x16fedd['evaluation'],'cliVersion':this[_0x166cd1(0x114)],'nodeVersion':this[_0x166cd1(0xf2)],'platform':this['platform'],'cwd':process['cwd'](),'isTty':this['isTty'],'isCI':this['isCI'],'metadata':_0x16fedd['metadata']};}async[_0x44706c(0x123)](_0x41a08d){const _0x389700=_0x44706c;try{await this[_0x389700(0x10c)]([_0x41a08d]);}catch{}}[_0x44706c(0x106)](){const _0x4dc9b9=_0x44706c;if(this['flushing'])return;this[_0x4dc9b9(0x137)]=this[_0x4dc9b9(0x125)]()[_0x4dc9b9(0x103)](()=>{const _0x250e19=_0x4dc9b9;this[_0x250e19(0x137)]=null;});}async[_0x44706c(0x10c)](_0x1a4677){const _0xd012d8=_0x44706c,_0x332a70={'paHnT':function(_0x2e3768){return _0x2e3768();},'yxpJl':_0xd012d8(0xf3)},_0x59556e=await _0x332a70[_0xd012d8(0x118)](getToken)['catch'](()=>null),_0x26db25=getApiBaseUrl(),_0x365807={'Content-Type':_0x332a70['yxpJl']};_0x59556e&&(_0x365807[_0xd012d8(0x140)]=_0xd012d8(0x124)+_0x59556e);const _0x5d15b2={'events':_0x1a4677};process[_0xd012d8(0xfc)]['DEBUG']&&console[_0xd012d8(0x13d)](_0xd012d8(0x132)+_0x1a4677[_0xd012d8(0xf1)]+_0xd012d8(0x12b)+_0x26db25+'/api/v1/mcp/cli-telemetry');const _0x296a42=new AbortController(),_0x291538=setTimeout(()=>_0x296a42[_0xd012d8(0x11f)](),0x1388);try{await fetch(_0x26db25+'/api/v1/mcp/cli-telemetry',{'method':'POST','headers':_0x365807,'body':JSON['stringify'](_0x5d15b2),'signal':_0x296a42['signal']});}finally{clearTimeout(_0x291538);}}}let currentCollector=null;export function createTelemetryCollector(_0x1de6e8){return currentCollector=new TelemetryCollector(_0x1de6e8),currentCollector;}export function getCurrentCollector(){return currentCollector;}export async function withTelemetry(_0x3022a5,_0xe3936e,_0x5cdedd){const _0x121324=_0x44706c,_0x938673={'MnYuv':function(_0x177304,_0x4bab47){return _0x177304(_0x4bab47);},'QURNN':_0x121324(0x10a)},_0x35b6ba=createTelemetryCollector(_0x3022a5);await _0x35b6ba['trackCommandStart'](_0x5cdedd);try{const _0x1c14ec=await _0x938673[_0x121324(0x119)](_0xe3936e,_0x35b6ba);return await _0x35b6ba[_0x121324(0xf9)](_0x938673[_0x121324(0x102)]),_0x1c14ec;}catch(_0x38aafb){await _0x35b6ba[_0x121324(0x104)](_0x38aafb);throw _0x38aafb;}finally{await _0x35b6ba[_0x121324(0x125)]();}}function _0x4b72(_0x18224c,_0x4dfc3b){_0x18224c=_0x18224c-0xf1;const _0x5d54f6=_0x5d54();let _0x4b7212=_0x5d54f6[_0x18224c];return _0x4b7212;}function truncate(_0x2b9eae,_0x1fdabb){const _0x4a5931=_0x44706c,_0xa5dab6={'vSGMC':function(_0x35c9cb,_0x261849){return _0x35c9cb+_0x261849;}};return _0x2b9eae['length']>_0x1fdabb?_0xa5dab6['vSGMC'](_0x2b9eae[_0x4a5931(0x135)](0x0,_0x1fdabb),_0x4a5931(0x107)):_0x2b9eae;}
@@ -1 +1 @@
1
- (function(_0x1e2a4e,_0x1ce848){const _0x10ca71=_0x29e5,_0x3462c4=_0x1e2a4e();while(!![]){try{const _0x20e40b=parseInt(_0x10ca71(0x190))/0x1+-parseInt(_0x10ca71(0x19b))/0x2+parseInt(_0x10ca71(0x194))/0x3+-parseInt(_0x10ca71(0x197))/0x4*(-parseInt(_0x10ca71(0x18c))/0x5)+-parseInt(_0x10ca71(0x196))/0x6+-parseInt(_0x10ca71(0x193))/0x7+parseInt(_0x10ca71(0x18a))/0x8*(parseInt(_0x10ca71(0x18e))/0x9);if(_0x20e40b===_0x1ce848)break;else _0x3462c4['push'](_0x3462c4['shift']());}catch(_0x16f4d2){_0x3462c4['push'](_0x3462c4['shift']());}}}(_0x59a2,0x1d65a));import{getApiBaseUrl}from'./environment.js';import{getRefreshToken,storeToken,storeRefreshToken}from'./keychain.js';export async function refreshCliToken(){const _0x459e21=_0x29e5,_0x252837={'svkvx':function(_0x29a5db){return _0x29a5db();}},_0x17a6b1=await _0x252837[_0x459e21(0x18f)](getRefreshToken);if(!_0x17a6b1)return null;const _0x30409e=await tryPartnerRefresh(_0x17a6b1);if(_0x30409e)return _0x30409e;return tryWorkosRefresh(_0x17a6b1);}export async function refreshPartnerCliToken(_0x95c2fa,_0x391256={}){const _0x37678b={'aBLps':function(_0x5e76f4,_0x417cce){return _0x5e76f4(_0x417cce);}},_0x396adf=await _0x37678b['aBLps'](tryPartnerRefresh,_0x95c2fa);return _0x396adf&&_0x391256['persistRefreshToken']&&await storeRefreshToken(_0x95c2fa),_0x396adf;}function _0x59a2(){const _0x3178b2=['timeout','379132mIAudH','refreshToken','/cli-auth/partner-refresh','tFpCf','2169184OtvBZs','json','185HSMtra','POST','9AYdFhr','svkvx','54491deuKdw','stringify','application/json','469623aWfxGz','46836QZUYGS','TtesF','301266HwttrZ','9300usziuO','ZNcLz','token'];_0x59a2=function(){return _0x3178b2;};return _0x59a2();}async function tryPartnerRefresh(_0x3993a1){const _0x24da05=_0x29e5,_0x4b6d1c={'TtesF':function(_0x53d9d6){return _0x53d9d6();},'ZTdvr':_0x24da05(0x18d),'ZNcLz':'application/json'},_0x1fd795=_0x4b6d1c[_0x24da05(0x195)](getApiBaseUrl);try{const _0x169a1f=await fetch(_0x1fd795+_0x24da05(0x188),{'method':_0x4b6d1c['ZTdvr'],'headers':{'Content-Type':_0x4b6d1c[_0x24da05(0x198)]},'body':JSON['stringify']({'refreshToken':_0x3993a1}),'signal':AbortSignal[_0x24da05(0x19a)](0x2710)});if(!_0x169a1f['ok'])return null;const _0x45bc4e=await _0x169a1f[_0x24da05(0x18b)]();return await storeToken(_0x45bc4e[_0x24da05(0x199)]),_0x45bc4e[_0x24da05(0x199)];}catch{return null;}}function _0x29e5(_0x363200,_0x57813a){_0x363200=_0x363200-0x187;const _0x59a2f8=_0x59a2();let _0x29e58d=_0x59a2f8[_0x363200];return _0x29e58d;}async function tryWorkosRefresh(_0x4f948f){const _0x4e7a3e=_0x29e5,_0x242d4a={'tFpCf':_0x4e7a3e(0x18d)},_0x1528df=getApiBaseUrl();try{const _0x5f460f=await fetch(_0x1528df+'/cli-auth/refresh',{'method':_0x242d4a[_0x4e7a3e(0x189)],'headers':{'Content-Type':_0x4e7a3e(0x192)},'body':JSON[_0x4e7a3e(0x191)]({'refreshToken':_0x4f948f}),'signal':AbortSignal['timeout'](0x2710)});if(!_0x5f460f['ok'])return null;const _0x30be0f=await _0x5f460f[_0x4e7a3e(0x18b)]();return await storeToken(_0x30be0f['token']),await storeRefreshToken(_0x30be0f[_0x4e7a3e(0x187)]),_0x30be0f[_0x4e7a3e(0x199)];}catch{return null;}}
1
+ (function(_0x3b0f0a,_0x3d7aca){const _0x503e2a=_0x29ac,_0x3f949a=_0x3b0f0a();while(!![]){try{const _0x5a9aeb=parseInt(_0x503e2a(0x18b))/0x1*(parseInt(_0x503e2a(0x180))/0x2)+-parseInt(_0x503e2a(0x185))/0x3*(parseInt(_0x503e2a(0x17d))/0x4)+-parseInt(_0x503e2a(0x188))/0x5*(parseInt(_0x503e2a(0x17a))/0x6)+parseInt(_0x503e2a(0x17e))/0x7*(parseInt(_0x503e2a(0x17c))/0x8)+parseInt(_0x503e2a(0x184))/0x9*(-parseInt(_0x503e2a(0x181))/0xa)+-parseInt(_0x503e2a(0x187))/0xb*(-parseInt(_0x503e2a(0x18e))/0xc)+parseInt(_0x503e2a(0x18a))/0xd*(parseInt(_0x503e2a(0x182))/0xe);if(_0x5a9aeb===_0x3d7aca)break;else _0x3f949a['push'](_0x3f949a['shift']());}catch(_0x45f395){_0x3f949a['push'](_0x3f949a['shift']());}}}(_0x2276,0x43f6c));function _0x29ac(_0x348a09,_0x530bcf){_0x348a09=_0x348a09-0x17a;const _0x2276a6=_0x2276();let _0x29ac1e=_0x2276a6[_0x348a09];return _0x29ac1e;}import{getApiBaseUrl}from'./environment.js';import{getRefreshToken,storeToken,storeRefreshToken}from'./keychain.js';function _0x2276(){const _0x4201dc=['78268hpzWYy','3310810ljYBnk','4468562zySjsJ','/cli-auth/partner-refresh','9MTuBMT','257364YrFNui','json','124652XnskRA','230DcuGAc','refreshToken','26wnrOCD','4JAwkEn','application/json','POST','36gPXiDq','17718wRphON','token','8OxSUWm','20hlHuxr','2417387xcPPeY','stringify'];_0x2276=function(){return _0x4201dc;};return _0x2276();}export async function refreshCliToken(){const _0x34b3f9={'RgcMH':function(_0x255095,_0x5daa6b){return _0x255095(_0x5daa6b);}},_0x142f6a=await getRefreshToken();if(!_0x142f6a)return null;const _0x1feb94=await tryPartnerRefresh(_0x142f6a);if(_0x1feb94)return _0x1feb94;return _0x34b3f9['RgcMH'](tryWorkosRefresh,_0x142f6a);}export async function refreshPartnerCliToken(_0x292ece,_0x37fb5e={}){const _0xeec158=await tryPartnerRefresh(_0x292ece);return _0xeec158&&_0x37fb5e['persistRefreshToken']&&await storeRefreshToken(_0x292ece),_0xeec158;}async function tryPartnerRefresh(_0xeefeb6){const _0x40fdee=_0x29ac,_0x4fc4f9={'avVNG':_0x40fdee(0x18d)},_0x2cffb2=getApiBaseUrl();try{const _0xd43f08=await fetch(_0x2cffb2+_0x40fdee(0x183),{'method':_0x4fc4f9['avVNG'],'headers':{'Content-Type':_0x40fdee(0x18c)},'body':JSON['stringify']({'refreshToken':_0xeefeb6}),'signal':AbortSignal['timeout'](0x2710)});if(!_0xd43f08['ok'])return null;const _0x50b57a=await _0xd43f08['json']();return await storeToken(_0x50b57a['token']),_0x50b57a['token'];}catch{return null;}}async function tryWorkosRefresh(_0x33e727){const _0x2abcd4=_0x29ac,_0x45271e={'KCzgI':function(_0x312d9a,_0x5647db){return _0x312d9a(_0x5647db);}},_0x56ffa1=getApiBaseUrl();try{const _0x53dca4=await fetch(_0x56ffa1+'/cli-auth/refresh',{'method':'POST','headers':{'Content-Type':_0x2abcd4(0x18c)},'body':JSON[_0x2abcd4(0x17f)]({'refreshToken':_0x33e727}),'signal':AbortSignal['timeout'](0x2710)});if(!_0x53dca4['ok'])return null;const _0x33d67d=await _0x53dca4[_0x2abcd4(0x186)]();return await storeToken(_0x33d67d[_0x2abcd4(0x17b)]),await _0x45271e['KCzgI'](storeRefreshToken,_0x33d67d[_0x2abcd4(0x189)]),_0x33d67d['token'];}catch{return null;}}
@@ -1 +1 @@
1
- function _0x4fa0(){const _0x59421c=['url','from','618bKfeSx','event','length','2138661RoFDDn','trim','string','abs','233MZfUfz','context-options','8139050QXAPaF','before','input','point','2158914NVThbK','21329OGcPko','wallTime','rqcID','afterSnapshot','frame-snapshot','154045ITHFMB','11gWBULE','pageId','set','inputSnapshot','callId','type','filter','name','snapshotName','wJJuP','push','XdpSE','gDNKx','method','page@0','beforeSnapshot','after','snapshot','4762224GlHxkK','endTime','4842VCKyLY','128azElcF','frameUrl','indexOf','monotonicTime','goto','fldoC','get','16zNoqog','params'];_0x4fa0=function(){return _0x59421c;};return _0x4fa0();}(function(_0x5ea585,_0x21dbd2){const _0x17f933=_0x31fb,_0xda45d4=_0x5ea585();while(!![]){try{const _0x4f7822=parseInt(_0x17f933(0x1d5))/0x1*(-parseInt(_0x17f933(0x1c2))/0x2)+parseInt(_0x17f933(0x1db))/0x3+parseInt(_0x17f933(0x1c3))/0x4*(-parseInt(_0x17f933(0x1e1))/0x5)+parseInt(_0x17f933(0x1ce))/0x6*(-parseInt(_0x17f933(0x1dc))/0x7)+parseInt(_0x17f933(0x1ca))/0x8*(parseInt(_0x17f933(0x1d1))/0x9)+parseInt(_0x17f933(0x1d7))/0xa*(parseInt(_0x17f933(0x1e2))/0xb)+parseInt(_0x17f933(0x1c0))/0xc;if(_0x4f7822===_0x21dbd2)break;else _0xda45d4['push'](_0xda45d4['shift']());}catch(_0x4f5fe7){_0xda45d4['push'](_0xda45d4['shift']());}}}(_0x4fa0,0x84487));function _0x31fb(_0x5d7619,_0xf510ce){_0x5d7619=_0x5d7619-0x1b8;const _0x4fa026=_0x4fa0();let _0x31fbdf=_0x4fa026[_0x5d7619];return _0x31fbdf;}import{readdir,readFile}from'fs/promises';import{join}from'path';export async function mapStepsToTraceSnapshots(_0x205718,_0x304c9e){const _0x2915b5=_0x31fb,_0x3ffeb6={'rqcID':'.trace','ujpYH':'utf-8','XdpSE':function(_0x3bdc1d,_0x3ff6ca){return _0x3bdc1d===_0x3ff6ca;},'gDNKx':_0x2915b5(0x1e0),'wJJuP':function(_0x4d9cb4,_0x2d1b79){return _0x4d9cb4===_0x2d1b79;},'fldoC':_0x2915b5(0x1d3),'lUeuG':'navigated','zHCcE':function(_0x56c86e,_0xffcc00){return _0x56c86e===_0xffcc00;},'SJBmG':_0x2915b5(0x1bc),'baupC':function(_0x204b5d,_0x1e99b9){return _0x204b5d>=_0x1e99b9;},'YgwWj':function(_0x534c7a,_0x237a9d){return _0x534c7a<_0x237a9d;}},_0x4b245c=new Map();if(_0x304c9e['length']===0x0)return _0x4b245c;const _0x128273=[],_0x3301f4=async _0x3ca64b=>{const _0x2f8b4b=_0x2915b5,_0x1f2359=await readdir(_0x3ca64b,{'withFileTypes':!![]});for(const _0x5e1f3f of _0x1f2359){const _0x53e9a7=join(_0x3ca64b,_0x5e1f3f[_0x2f8b4b(0x1e9)]);if(_0x5e1f3f['isDirectory']())await _0x3301f4(_0x53e9a7);else _0x5e1f3f['name']['endsWith'](_0x3ffeb6[_0x2f8b4b(0x1de)])&&_0x128273[_0x2f8b4b(0x1b8)](_0x53e9a7);}};await _0x3301f4(_0x205718);if(_0x128273[_0x2915b5(0x1d0)]===0x0)return _0x4b245c;const _0x44eef8=[];for(const _0x3ae48f of _0x128273){const _0x5eaec5=await readFile(_0x3ae48f,_0x3ffeb6['ujpYH']),_0x218d7b=_0x5eaec5['split']('\x0a')[_0x2915b5(0x1e8)](_0x2687a5=>_0x2687a5[_0x2915b5(0x1d2)]());for(const _0x2f07f4 of _0x218d7b){try{_0x44eef8['push'](JSON['parse'](_0x2f07f4));}catch{}}}if(_0x44eef8[_0x2915b5(0x1d0)]===0x0)return _0x4b245c;const _0x3e79c9=_0x44eef8['find'](_0x4a93ab=>_0x4a93ab['type']===_0x2915b5(0x1d6));if(!_0x3e79c9)return _0x4b245c;const _0x3abecd=_0x3e79c9[_0x2915b5(0x1dd)]-_0x3e79c9[_0x2915b5(0x1c6)],_0x1f72fe=new Map();for(const _0x5b7fa7 of _0x44eef8){switch(_0x5b7fa7['type']){case _0x2915b5(0x1d8):{const _0xfba0c3=_0x5b7fa7;_0x1f72fe['set'](_0xfba0c3[_0x2915b5(0x1e6)],{'callId':_0xfba0c3[_0x2915b5(0x1e6)],'startTime':_0xfba0c3['startTime'],'endTime':0x0,'method':_0xfba0c3[_0x2915b5(0x1bb)],'apiName':_0xfba0c3['apiName'],'params':_0xfba0c3['params'],'pageId':_0xfba0c3[_0x2915b5(0x1e3)],'beforeSnapshot':_0xfba0c3[_0x2915b5(0x1bd)]});break;}case _0x2915b5(0x1d9):{const _0x58ffc9=_0x5b7fa7,_0x2088c0=_0x1f72fe['get'](_0x58ffc9['callId']);if(_0x2088c0){if(_0x58ffc9[_0x2915b5(0x1e5)])_0x2088c0['inputSnapshot']=_0x58ffc9[_0x2915b5(0x1e5)];if(_0x58ffc9['point'])_0x2088c0[_0x2915b5(0x1da)]=_0x58ffc9['point'];}break;}case _0x2915b5(0x1be):{const _0x5ae44c=_0x5b7fa7,_0x4a92aa=_0x1f72fe['get'](_0x5ae44c['callId']);if(_0x4a92aa){_0x4a92aa[_0x2915b5(0x1c1)]=_0x5ae44c[_0x2915b5(0x1c1)];if(_0x5ae44c[_0x2915b5(0x1df)])_0x4a92aa[_0x2915b5(0x1df)]=_0x5ae44c[_0x2915b5(0x1df)];}break;}}}const _0x22f61c=Array[_0x2915b5(0x1cd)](_0x1f72fe['values']())['filter'](_0x575b42=>_0x575b42[_0x2915b5(0x1c1)]>0x0&&(_0x575b42['afterSnapshot']||_0x575b42[_0x2915b5(0x1bd)]))['sort']((_0x8f69af,_0x25baf3)=>_0x8f69af['startTime']-_0x25baf3['startTime']);if(_0x3ffeb6['XdpSE'](_0x22f61c[_0x2915b5(0x1d0)],0x0))return _0x4b245c;const _0x1f0641=new Map();for(const _0xd46a16 of _0x44eef8){if(_0x3ffeb6[_0x2915b5(0x1b9)](_0xd46a16[_0x2915b5(0x1e7)],_0x3ffeb6[_0x2915b5(0x1ba)])){const _0x2d405f=_0xd46a16[_0x2915b5(0x1bf)];_0x2d405f?.[_0x2915b5(0x1ea)]&&_0x2d405f?.[_0x2915b5(0x1c4)]&&_0x1f0641['set'](_0x2d405f['snapshotName'],_0x2d405f[_0x2915b5(0x1c4)]);}}const _0x508e24=new Map();for(const _0x4f9f1e of _0x22f61c){const _0x1c3043=_0x4f9f1e[_0x2915b5(0x1cb)]?.[_0x2915b5(0x1cc)];_0x3ffeb6['wJJuP'](_0x4f9f1e['method'],'goto')&&_0x3ffeb6['wJJuP'](typeof _0x1c3043,_0x3ffeb6[_0x2915b5(0x1c8)])&&_0x4f9f1e[_0x2915b5(0x1e3)]&&_0x508e24[_0x2915b5(0x1e4)](_0x4f9f1e['pageId'],_0x1c3043);}for(const _0x9f6f2d of _0x44eef8){const _0x2b9e7e=_0x9f6f2d,_0x597736=_0x2b9e7e[_0x2915b5(0x1cb)],_0x1252d1=_0x597736?.[_0x2915b5(0x1cc)];_0x3ffeb6[_0x2915b5(0x1eb)](_0x2b9e7e['type'],_0x2915b5(0x1cf))&&_0x2b9e7e[_0x2915b5(0x1bb)]===_0x3ffeb6['lUeuG']&&_0x3ffeb6[_0x2915b5(0x1b9)](typeof _0x1252d1,_0x3ffeb6['fldoC'])&&_0x3ffeb6['zHCcE'](typeof _0x2b9e7e[_0x2915b5(0x1e3)],_0x3ffeb6[_0x2915b5(0x1c8)])&&_0x508e24[_0x2915b5(0x1e4)](_0x2b9e7e[_0x2915b5(0x1e3)],_0x1252d1);}for(const _0xa8b690 of _0x304c9e){const _0x26a4e3=new Date(_0xa8b690['capturedAt'])['getTime'](),_0x505825=_0x26a4e3-_0x3abecd;let _0x8c4a84=null,_0x4252e8=Infinity;for(const _0x2e94f5 of _0x22f61c){const _0x3c611c=Math[_0x2915b5(0x1d4)](_0x2e94f5['endTime']-_0x505825);_0x3c611c<_0x4252e8&&(_0x4252e8=_0x3c611c,_0x8c4a84=_0x2e94f5);}if(!_0x8c4a84)continue;const _0x1b3bb6=_0x8c4a84['afterSnapshot']||_0x8c4a84[_0x2915b5(0x1bd)];if(!_0x1b3bb6)continue;const _0x4e41eb=_0x8c4a84[_0x2915b5(0x1e3)]||_0x3ffeb6['SJBmG'];let _0x28de74=_0x1f0641[_0x2915b5(0x1c9)](_0x1b3bb6)||_0x508e24[_0x2915b5(0x1c9)](_0x4e41eb)||'';if(!_0x28de74)for(let _0x3dc089=_0x22f61c[_0x2915b5(0x1c5)](_0x8c4a84);_0x3dc089>=0x0;_0x3dc089--){const _0x3846a3=_0x22f61c[_0x3dc089]['params']?.['url'];if(_0x22f61c[_0x3dc089][_0x2915b5(0x1bb)]===_0x2915b5(0x1c7)&&_0x3ffeb6['zHCcE'](typeof _0x3846a3,'string')){_0x28de74=_0x3846a3;break;}}let _0x2d41d5,_0x495eec;const _0x5d3643=_0x22f61c['indexOf'](_0x8c4a84);if(_0x3ffeb6['baupC'](_0x5d3643,0x0)&&_0x3ffeb6['YgwWj'](_0x5d3643,_0x22f61c[_0x2915b5(0x1d0)]-0x1)){const _0x409043=_0x22f61c[_0x5d3643+0x1];_0x409043['point']&&_0x409043[_0x2915b5(0x1e5)]&&(_0x2d41d5=_0x409043['point'],_0x495eec=_0x409043['inputSnapshot']);}_0x4b245c['set'](_0xa8b690['stepId'],{'snapshotName':_0x1b3bb6,'inputSnapshotName':_0x495eec,'pageId':_0x4e41eb,'pageUrl':_0x28de74,'callId':_0x8c4a84[_0x2915b5(0x1e6)],'point':_0x2d41d5});}return _0x4b245c;}
1
+ (function(_0x274329,_0x229f85){const _0x4af906=_0xcdc5,_0x1363d8=_0x274329();while(!![]){try{const _0x445daf=-parseInt(_0x4af906(0x104))/0x1*(parseInt(_0x4af906(0xe4))/0x2)+-parseInt(_0x4af906(0xf7))/0x3*(parseInt(_0x4af906(0xfd))/0x4)+parseInt(_0x4af906(0xf5))/0x5+parseInt(_0x4af906(0xdb))/0x6+parseInt(_0x4af906(0xea))/0x7*(-parseInt(_0x4af906(0xeb))/0x8)+parseInt(_0x4af906(0xd6))/0x9*(parseInt(_0x4af906(0xd1))/0xa)+parseInt(_0x4af906(0x102))/0xb*(parseInt(_0x4af906(0xe7))/0xc);if(_0x445daf===_0x229f85)break;else _0x1363d8['push'](_0x1363d8['shift']());}catch(_0x1d3292){_0x1363d8['push'](_0x1363d8['shift']());}}}(_0x3ca3,0xae04f));function _0x3ca3(){const _0x10d689=['snapshotName','7785110ULyjsk','context-options','after','ooHrH','startTime','9ZREpuR','isDirectory','page@0','ZAnOr','string','6941016lhhcNQ','navigated','set','afterSnapshot','gjGrw','filter','monotonicTime','CSszo','values','15242WmsbHb','input','jPNLc','3262008QgGbdh','params','wxAgY','49pNlrcQ','1109736qqiSiH','pageId','hyvNz','iGaFm','get','find','stepId','parse','length','method','1336710OwECLm','type','86484diNsLG','inputSnapshot','lbVPL','apiName','KbcyU','indexOf','176IwWqzI','name','endTime','PGSqw','push','88WKkQub','wGfbK','187wVekLx','capturedAt','goto','utf-8','before','callId','trim','oEyGm','sort','beforeSnapshot'];_0x3ca3=function(){return _0x10d689;};return _0x3ca3();}import{readdir,readFile}from'fs/promises';function _0xcdc5(_0x2d5bf8,_0x21b067){_0x2d5bf8=_0x2d5bf8-0xcc;const _0x3ca39c=_0x3ca3();let _0xcdc522=_0x3ca39c[_0x2d5bf8];return _0xcdc522;}import{join}from'path';export async function mapStepsToTraceSnapshots(_0x1045f7,_0x2b963d){const _0x3642e0=_0xcdc5,_0xc7f36d={'lbVPL':function(_0x34bfda,_0x5abb6d,_0x59a965){return _0x34bfda(_0x5abb6d,_0x59a965);},'nggbl':function(_0x4220dd,_0x51f997){return _0x4220dd(_0x51f997);},'wGfbK':function(_0x84817,_0x2382fd){return _0x84817===_0x2382fd;},'gjGrw':function(_0x246a32,_0x2aef86){return _0x246a32(_0x2aef86);},'hyvNz':function(_0x1128ce,_0x5420a4,_0x1182e4){return _0x1128ce(_0x5420a4,_0x1182e4);},'oEyGm':_0x3642e0(0x107),'FNhBt':function(_0xa0e71f,_0x59bddd){return _0xa0e71f-_0x59bddd;},'ooHrH':function(_0x4e0b76,_0x597a32){return _0x4e0b76===_0x597a32;},'NbAvK':'frame-snapshot','PGSqw':_0x3642e0(0x106),'wxAgY':function(_0x591f15,_0x4d7e99){return _0x591f15===_0x4d7e99;},'CSszo':'event','Xhbxb':_0x3642e0(0xda),'iGaFm':function(_0x3716fe,_0x4153f4){return _0x3716fe<_0x4153f4;},'ZAnOr':_0x3642e0(0xd8),'jPNLc':function(_0x6143ba,_0x5b333b){return _0x6143ba>=_0x5b333b;},'KbcyU':function(_0x2e75ea,_0x3ba909){return _0x2e75ea-_0x3ba909;},'JrvQM':function(_0x206101,_0x338a2e){return _0x206101+_0x338a2e;}},_0x130282=new Map();if(_0xc7f36d[_0x3642e0(0x103)](_0x2b963d[_0x3642e0(0xf3)],0x0))return _0x130282;const _0x30b2b2=[],_0x1e46aa=async _0x3557f1=>{const _0x2ce4c3=_0x3642e0,_0x44ca18=await _0xc7f36d[_0x2ce4c3(0xf9)](readdir,_0x3557f1,{'withFileTypes':!![]});for(const _0x33ad32 of _0x44ca18){const _0x37d723=_0xc7f36d['lbVPL'](join,_0x3557f1,_0x33ad32['name']);if(_0x33ad32[_0x2ce4c3(0xd7)]())await _0xc7f36d['nggbl'](_0x1e46aa,_0x37d723);else _0x33ad32[_0x2ce4c3(0xfe)]['endsWith']('.trace')&&_0x30b2b2['push'](_0x37d723);}};await _0xc7f36d[_0x3642e0(0xdf)](_0x1e46aa,_0x1045f7);if(_0x30b2b2['length']===0x0)return _0x130282;const _0x1730f5=[];for(const _0x48739d of _0x30b2b2){const _0x46064f=await _0xc7f36d[_0x3642e0(0xed)](readFile,_0x48739d,_0xc7f36d[_0x3642e0(0xcd)]),_0x48d86f=_0x46064f['split']('\x0a')[_0x3642e0(0xe0)](_0x92faed=>_0x92faed[_0x3642e0(0xcc)]());for(const _0x405e8d of _0x48d86f){try{_0x1730f5[_0x3642e0(0x101)](JSON[_0x3642e0(0xf2)](_0x405e8d));}catch{}}}if(_0x1730f5['length']===0x0)return _0x130282;const _0x189373=_0x1730f5[_0x3642e0(0xf0)](_0xeb3915=>_0xeb3915['type']===_0x3642e0(0xd2));if(!_0x189373)return _0x130282;const _0x18148b=_0xc7f36d['FNhBt'](_0x189373['wallTime'],_0x189373[_0x3642e0(0xe1)]),_0x569ada=new Map();for(const _0x339470 of _0x1730f5){switch(_0x339470['type']){case _0x3642e0(0x108):{const _0x4f860d=_0x339470;_0x569ada[_0x3642e0(0xdd)](_0x4f860d[_0x3642e0(0x109)],{'callId':_0x4f860d[_0x3642e0(0x109)],'startTime':_0x4f860d[_0x3642e0(0xd5)],'endTime':0x0,'method':_0x4f860d['method'],'apiName':_0x4f860d[_0x3642e0(0xfa)],'params':_0x4f860d[_0x3642e0(0xe8)],'pageId':_0x4f860d[_0x3642e0(0xec)],'beforeSnapshot':_0x4f860d['beforeSnapshot']});break;}case _0x3642e0(0xe5):{const _0x5a1745=_0x339470,_0x354292=_0x569ada['get'](_0x5a1745['callId']);if(_0x354292){if(_0x5a1745['inputSnapshot'])_0x354292[_0x3642e0(0xf8)]=_0x5a1745['inputSnapshot'];if(_0x5a1745['point'])_0x354292['point']=_0x5a1745['point'];}break;}case _0x3642e0(0xd3):{const _0x3a895d=_0x339470,_0x4030fc=_0x569ada['get'](_0x3a895d['callId']);if(_0x4030fc){_0x4030fc['endTime']=_0x3a895d[_0x3642e0(0xff)];if(_0x3a895d[_0x3642e0(0xde)])_0x4030fc['afterSnapshot']=_0x3a895d['afterSnapshot'];}break;}}}const _0x40748d=Array['from'](_0x569ada[_0x3642e0(0xe3)]())['filter'](_0x313eab=>_0x313eab['endTime']>0x0&&(_0x313eab[_0x3642e0(0xde)]||_0x313eab[_0x3642e0(0xcf)]))[_0x3642e0(0xce)]((_0x2b3ece,_0x3d0b12)=>_0x2b3ece[_0x3642e0(0xd5)]-_0x3d0b12['startTime']);if(_0x40748d[_0x3642e0(0xf3)]===0x0)return _0x130282;const _0x4f9201=new Map();for(const _0xbb87a8 of _0x1730f5){if(_0xc7f36d[_0x3642e0(0xd4)](_0xbb87a8[_0x3642e0(0xf6)],_0xc7f36d['NbAvK'])){const _0x231e97=_0xbb87a8['snapshot'];_0x231e97?.[_0x3642e0(0xd0)]&&_0x231e97?.['frameUrl']&&_0x4f9201['set'](_0x231e97['snapshotName'],_0x231e97['frameUrl']);}}const _0x22450f=new Map();for(const _0xffe029 of _0x40748d){const _0x599d9a=_0xffe029[_0x3642e0(0xe8)]?.['url'];_0xc7f36d['wGfbK'](_0xffe029['method'],_0xc7f36d[_0x3642e0(0x100)])&&_0xc7f36d[_0x3642e0(0xe9)](typeof _0x599d9a,_0x3642e0(0xda))&&_0xffe029['pageId']&&_0x22450f['set'](_0xffe029['pageId'],_0x599d9a);}for(const _0x7c00f0 of _0x1730f5){const _0x6d4e64=_0x7c00f0,_0x20d053=_0x6d4e64[_0x3642e0(0xe8)],_0x123b88=_0x20d053?.['url'];_0xc7f36d['wGfbK'](_0x6d4e64[_0x3642e0(0xf6)],_0xc7f36d[_0x3642e0(0xe2)])&&_0x6d4e64[_0x3642e0(0xf4)]===_0x3642e0(0xdc)&&typeof _0x123b88===_0xc7f36d['Xhbxb']&&typeof _0x6d4e64[_0x3642e0(0xec)]===_0xc7f36d['Xhbxb']&&_0x22450f[_0x3642e0(0xdd)](_0x6d4e64['pageId'],_0x123b88);}for(const _0x8dc30 of _0x2b963d){const _0x43fc2d=new Date(_0x8dc30[_0x3642e0(0x105)])['getTime'](),_0x290330=_0x43fc2d-_0x18148b;let _0x532247=null,_0x1fdefd=Infinity;for(const _0x114d0e of _0x40748d){const _0x4ef991=Math['abs'](_0x114d0e['endTime']-_0x290330);_0xc7f36d[_0x3642e0(0xee)](_0x4ef991,_0x1fdefd)&&(_0x1fdefd=_0x4ef991,_0x532247=_0x114d0e);}if(!_0x532247)continue;const _0x3ac74f=_0x532247['afterSnapshot']||_0x532247['beforeSnapshot'];if(!_0x3ac74f)continue;const _0x3fd012=_0x532247[_0x3642e0(0xec)]||_0xc7f36d[_0x3642e0(0xd9)];let _0x49fddf=_0x4f9201[_0x3642e0(0xef)](_0x3ac74f)||_0x22450f['get'](_0x3fd012)||'';if(!_0x49fddf)for(let _0x1c576a=_0x40748d[_0x3642e0(0xfc)](_0x532247);_0x1c576a>=0x0;_0x1c576a--){const _0x1c96e6=_0x40748d[_0x1c576a][_0x3642e0(0xe8)]?.['url'];if(_0x40748d[_0x1c576a]['method']===_0xc7f36d[_0x3642e0(0x100)]&&_0xc7f36d[_0x3642e0(0xe9)](typeof _0x1c96e6,_0x3642e0(0xda))){_0x49fddf=_0x1c96e6;break;}}let _0x389749,_0x54e05d;const _0x52e076=_0x40748d['indexOf'](_0x532247);if(_0xc7f36d[_0x3642e0(0xe6)](_0x52e076,0x0)&&_0x52e076<_0xc7f36d[_0x3642e0(0xfb)](_0x40748d['length'],0x1)){const _0x3a6cbf=_0x40748d[_0xc7f36d['JrvQM'](_0x52e076,0x1)];_0x3a6cbf['point']&&_0x3a6cbf['inputSnapshot']&&(_0x389749=_0x3a6cbf['point'],_0x54e05d=_0x3a6cbf[_0x3642e0(0xf8)]);}_0x130282[_0x3642e0(0xdd)](_0x8dc30[_0x3642e0(0xf1)],{'snapshotName':_0x3ac74f,'inputSnapshotName':_0x54e05d,'pageId':_0x3fd012,'pageUrl':_0x49fddf,'callId':_0x532247['callId'],'point':_0x389749});}return _0x130282;}