@ranger-testing/ranger-cli 2.5.4-alpha.feb9faf-20 → 2.5.4

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 (82) hide show
  1. package/README.md +14 -36
  2. package/build/cli.js +1 -1
  3. package/build/commands/addEnv.js +1 -1
  4. package/build/commands/authEncrypt.js +1 -1
  5. package/build/commands/clean.js +1 -1
  6. package/build/commands/config.js +1 -1
  7. package/build/commands/env.js +1 -1
  8. package/build/commands/feature.js +1 -1
  9. package/build/commands/hook.js +1 -1
  10. package/build/commands/hooks/autoPrompt.js +1 -1
  11. package/build/commands/hooks/disable.js +1 -1
  12. package/build/commands/hooks/enable.js +1 -1
  13. package/build/commands/hooks/exitPlanMode.js +1 -1
  14. package/build/commands/hooks/index.js +1 -1
  15. package/build/commands/hooks/output.js +1 -1
  16. package/build/commands/hooks/planReminder.js +1 -1
  17. package/build/commands/hooks/planStart.js +1 -1
  18. package/build/commands/hooks/postEdit.js +1 -1
  19. package/build/commands/hooks/preCompact.js +1 -1
  20. package/build/commands/hooks/sessionEnd.js +1 -1
  21. package/build/commands/hooks/sessionStart.js +1 -1
  22. package/build/commands/hooks/stopHook.js +1 -1
  23. package/build/commands/index.js +1 -1
  24. package/build/commands/login.js +1 -1
  25. package/build/commands/mcpBootstrap.js +1 -1
  26. package/build/commands/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/crypto.js +1 -1
  42. package/build/commands/utils/desirePathLog.js +1 -1
  43. package/build/commands/utils/deviceAuth.js +1 -1
  44. package/build/commands/utils/environment.js +1 -1
  45. package/build/commands/utils/featureApi.js +1 -1
  46. package/build/commands/utils/fixWebmDuration.js +1 -1
  47. package/build/commands/utils/keychain.js +1 -1
  48. package/build/commands/utils/localAgentInstallationsApi.js +1 -1
  49. package/build/commands/utils/mcpImageBase64.js +1 -1
  50. package/build/commands/utils/model.js +1 -1
  51. package/build/commands/utils/opencodeConfig.js +1 -1
  52. package/build/commands/utils/playwrightCli.js +1 -1
  53. package/build/commands/utils/profileMessages.js +1 -1
  54. package/build/commands/utils/profileSetupBanner.js +1 -1
  55. package/build/commands/utils/rangerConfig.js +1 -1
  56. package/build/commands/utils/rangerRoot.js +1 -1
  57. package/build/commands/utils/retry.js +1 -1
  58. package/build/commands/utils/sessionCache.js +1 -1
  59. package/build/commands/utils/settings.js +1 -1
  60. package/build/commands/utils/skillContent.js +1 -1
  61. package/build/commands/utils/skills.js +1 -1
  62. package/build/commands/utils/stitchWebmFiles.js +1 -1
  63. package/build/commands/utils/telemetry.js +1 -1
  64. package/build/commands/utils/tokenRefresh.js +1 -1
  65. package/build/commands/utils/traceSnapshotMapper.js +1 -1
  66. package/build/commands/utils/userApi.js +1 -1
  67. package/build/commands/utils/version.js +1 -1
  68. package/build/commands/verifyFeature.js +1 -1
  69. package/build/commands/verifyFeatureCli.js +1 -1
  70. package/build/skills/ranger/SKILL.md +6 -36
  71. package/build/skills/ranger/create.md +0 -19
  72. package/build/skills/ranger/verify.md +7 -46
  73. package/package.json +3 -8
  74. package/build/commands/migrateProfile.js +0 -1
  75. package/build/commands/utils/cloudProfile.js +0 -1
  76. package/build/commands/utils/cloudProfileSession.js +0 -1
  77. package/build/commands/utils/gitTracked.js +0 -1
  78. package/build/commands/utils/legacyWarning.js +0 -1
  79. package/build/commands/utils/matchAuthEnvironment.js +0 -1
  80. package/build/commands/utils/projectsConfig.js +0 -1
  81. package/build/commands/utils/resolveProfileContext.js +0 -1
  82. package/build/commands/utils/resolveProfileUrl.js +0 -1
@@ -1 +1 @@
1
- (function(_0x3a7b82,_0x51edb0){const _0x5809ae=_0x332f,_0x4dd505=_0x3a7b82();while(!![]){try{const _0x5c8dc1=-parseInt(_0x5809ae(0x16b))/0x1+-parseInt(_0x5809ae(0x189))/0x2*(-parseInt(_0x5809ae(0x195))/0x3)+parseInt(_0x5809ae(0x197))/0x4*(-parseInt(_0x5809ae(0x14b))/0x5)+-parseInt(_0x5809ae(0x1af))/0x6*(-parseInt(_0x5809ae(0x199))/0x7)+-parseInt(_0x5809ae(0x19e))/0x8+-parseInt(_0x5809ae(0x196))/0x9*(parseInt(_0x5809ae(0x16d))/0xa)+-parseInt(_0x5809ae(0x192))/0xb*(-parseInt(_0x5809ae(0x15d))/0xc);if(_0x5c8dc1===_0x51edb0)break;else _0x4dd505['push'](_0x4dd505['shift']());}catch(_0xd71988){_0x4dd505['push'](_0x4dd505['shift']());}}}(_0x2ae8,0xdef6f));import{readdir,rm}from'fs/promises';import{join}from'path';import{existsSync}from'fs';import _0x356642 from'inquirer';import{getRangerDir,getRangerHomeDir}from'./utils/rangerRoot.js';import{writeActiveProfileName}from'./utils/activeProfile.js';import{fetchAuthConfig,createCloudProfile,manualBrowserLogin,ApiError}from'./utils/cloudProfile.js';import{matchAuthEnvironment}from'./utils/matchAuthEnvironment.js';import{isPathGitTracked}from'./utils/gitTracked.js';import{setProfileOverride}from'./utils/projectsConfig.js';async function checkUrlReachability(_0x2b8bc2){const _0x473a0e=_0x332f,_0x586490={'NwNNX':function(_0x230330,_0x56f7d9,_0x55a319){return _0x230330(_0x56f7d9,_0x55a319);},'WHzsY':function(_0x536408,_0x430383){return _0x536408(_0x430383);},'srfLx':function(_0xf5acde,_0x2da8b1){return _0xf5acde<_0x2da8b1;},'mPjbA':function(_0x5618fa,_0x31dac8){return _0x5618fa===_0x31dac8;},'IjvJk':'fetch\x20failed'};try{const _0x12a9e1=new AbortController(),_0xf4dc5f=setTimeout(()=>_0x12a9e1['abort'](),0x1388),_0x2f37df={'method':_0x473a0e(0x160),'signal':_0x12a9e1['signal'],'redirect':_0x473a0e(0x18f)};/^https:\/\/localhost(:\d+)?/i['test'](_0x2b8bc2)&&(process[_0x473a0e(0x1b5)][_0x473a0e(0x1a3)]='0');const _0xce2d87=await _0x586490[_0x473a0e(0x1b2)](fetch,_0x2b8bc2,_0x2f37df);delete process['env'][_0x473a0e(0x1a3)],_0x586490[_0x473a0e(0x1c7)](clearTimeout,_0xf4dc5f);if(_0x586490[_0x473a0e(0x149)](_0xce2d87['status'],0x190))return{'ok':!![]};return{'ok':![],'error':_0x473a0e(0x14a)+_0xce2d87['status']};}catch(_0x467aae){delete process[_0x473a0e(0x1b5)]['NODE_TLS_REJECT_UNAUTHORIZED'];const _0xa6f0=_0x467aae,_0x59c006=_0xa6f0[_0x473a0e(0x180)]||String(_0x467aae),_0x16013a=_0x59c006[_0x473a0e(0x19f)]('Invalid\x20URL')||_0x586490[_0x473a0e(0x161)](_0xa6f0['name'],_0x473a0e(0x18b))||_0x59c006['includes'](_0x586490['IjvJk']);return{'ok':![],'error':_0x59c006,'isProtocolError':_0x16013a};}}async function sweepOrphanLocalProfile(_0x3455f7,_0x171edb,_0x355c12){const _0x42c640=_0x332f,_0x3c77a5={'sZRdE':function(_0x31352e,_0x164271,_0x17d89c){return _0x31352e(_0x164271,_0x17d89c);},'lFNCB':'local','iiUkL':function(_0x1a0b0a,_0x78afa5){return _0x1a0b0a(_0x78afa5);}},_0x5233d8=_0x3c77a5[_0x42c640(0x185)](join,_0x171edb,_0x3c77a5[_0x42c640(0x159)]),_0x275d18=_0x3c77a5[_0x42c640(0x185)](join,_0x5233d8,_0x3455f7);existsSync(_0x275d18)&&(_0x355c12&&await isPathGitTracked(_0x275d18)?console['log']('\x20\x20Note:\x20found\x20git-tracked\x20local\x20profile\x20at\x20'+_0x275d18+_0x42c640(0x19a)):(await rm(_0x275d18,{'recursive':!![],'force':!![]}),console[_0x42c640(0x1a4)](_0x42c640(0x17f)+_0x275d18)));if(_0x3c77a5['iiUkL'](existsSync,_0x5233d8)){let _0x420890=[];try{_0x420890=await readdir(_0x5233d8);}catch{return;}const _0x527ad0='.tmp-'+_0x3455f7+'-';for(const _0x24580f of _0x420890){if(!_0x24580f[_0x42c640(0x177)](_0x527ad0))continue;const _0x2abab2=_0x3c77a5[_0x42c640(0x185)](join,_0x5233d8,_0x24580f);await rm(_0x2abab2,{'recursive':!![],'force':!![]}),console[_0x42c640(0x1a4)](_0x42c640(0x17f)+_0x2abab2);}}}async function sweepOrphansBestEffort(_0x2803c2){const _0x135974=_0x332f,_0x154008={'FUgJA':function(_0x44a825,_0x106cd6){return _0x44a825!==_0x106cd6;},'ycldD':function(_0x3b0cac,_0x2cee7e){return _0x3b0cac(_0x2cee7e);}};try{await sweepOrphanLocalProfile(_0x2803c2,getRangerHomeDir(),![]);const _0x2f19ae=getRangerDir();_0x154008[_0x135974(0x170)](_0x2f19ae,getRangerHomeDir())&&await sweepOrphanLocalProfile(_0x2803c2,_0x2f19ae,!![]);}catch(_0x55471b){console['log'](_0x135974(0x154)+(_0x55471b instanceof Error?_0x55471b[_0x135974(0x180)]:_0x154008['ycldD'](String,_0x55471b))+').');}}function _0x2ae8(){const _0x34d4a4=['\x0a🌐\x20Profile\x20Setup\x0a','\x20\x20Details:\x20https://docs.ranger.net/main/concepts/profiles#automated-login','HEAD','mPjbA','Hbiap','MpWhs','\x20\x20Make\x20sure\x20your\x20app\x20is\x20running\x20locally\x20before\x20continuing.','RPpAN','\x20\x20Next:\x20ranger\x20go\x20--profile\x20','url','KjJyd','cwd','http://localhost:3000','530962klazPe','⚠\x20Could\x20not\x20reach\x20','290tfKxJz','FLsnp','JfLls','FUgJA','capture','profile.add.autoRouteSkipped','cdpEndpoint','RxqRK','\x0a\x20\x20(domains:\x20','\x0a\x20\x20Failed\x20to\x20create\x20cloud\x20profile\x20\x22','startsWith','prompt','hBywO','retry','UtpqF','\x0a\x20\x20Cloud\x20profile\x20created,\x20but\x20failed\x20to\x20write\x20per-cwd\x20CDP\x20override\x20to\x20projects.json:\x20','WxvLA','KssPC','\x20\x20Cleaned\x20up\x20orphan\x20local\x20profile\x20at\x20','message','--cdp-endpoint\x20must\x20not\x20be\x20empty.\x20Provide\x20the\x20CDP\x20URL,\x20e.g.\x20--cdp-endpoint\x20http://localhost:9222','trackPhaseEnd','What\x20is\x20the\x20URL\x20of\x20your\x20running\x20app?','error','sZRdE','fJZCP','Use\x20','ncNoK','8WojPSV','hcpBZ','TypeError','iuERG','\x20\x20Did\x20you\x20mean\x20','\x0a\x20\x20Still\x20could\x20not\x20reach\x20','manual','Enter\x20a\x20new\x20URL\x20(or\x20press\x20enter\x20to\x20keep\x20current):','`\x20again\x20without\x20--skip-auth.','21399917XpGspx','continue','input','196539tSoozh','241443wvEVpB','2104QHYTuQ','FvEyC','14hmGvZe','\x20—\x20not\x20removing.\x20Delete\x20manually\x20if\x20you\x20want\x20it\x20gone.','What\x20would\x20you\x20like\x20to\x20do?','qGHRT','\x20\x20Workaround\x20for\x20now:\x20create\x20a\x20profile\x20without\x20a\x20captured\x20session\x20and\x20supply\x20one\x20later:\x0a','2161544wcNQeh','includes','keys','zWXnJ','ghDsV','NODE_TLS_REJECT_UNAUTHORIZED','log','yes','action','exit','vaWRj','otUeX','baseUrl','setupHeaders','\x0a\x20\x20A\x20profile\x20named\x20\x22','for\x20you,\x20so\x20the\x20encrypted-CI\x20flow\x20is\x20unnecessary.\x0a','Automated\x20login\x20isn\x27t\x20set\x20up\x20for\x20your\x20team.\x20Capture\x20a\x20session\x20via\x20a\x20headed\x20browser\x20instead?','3191724pVOOyR','To\x20set\x20up\x20a\x20profile,\x20run:\x0a','length','NwNNX','BpHIF','Enter\x20a\x20different\x20URL','env','confirm','\x27\x20to\x20the\x20cloud?','status','\x27\x20matching\x20','QfMHx','\x20\x20https://docs.ranger.net/main/concepts/profiles','\x22.\x20Expected\x20\x22Name:\x20Value\x22.','YjCCF','luZOJ','isElectron','✓\x20Profile\x20\x27','domains','slice','join','\x22:\x20','profile.add.autoRouted','mkRQP','WHzsY','\x20\x20Set\x20active\x20profile:\x20','srfLx','HTTP\x20','7405CoDTPT','\x20--url\x20','trim','\x0a🔌\x20CDP\x20Profile\x20Setup\x0a','\x0a\x20\x20Could\x20not\x20fetch\x20this\x20org\x27s\x20auth\x20config:\x20','environments','Could\x20not\x20reach\x20','saveToCloud','xfGOB','\x20\x20Note:\x20cloud\x20profile\x20created,\x20but\x20failed\x20to\x20sweep\x20orphan\x20local\x20dirs\x20(','use_suggestion','force','\x0a\x20\x20Declined.\x20Re-run\x20with\x20--skip-auth\x20to\x20create\x20a\x20profile\x20without\x20a\x20session,\x0a','\x22\x20already\x20exists.\x20To\x20refresh\x20its\x20session,\x20run:\x0a','lFNCB','--url\x20and\x20--cdp-endpoint\x20are\x20mutually\x20exclusive.\x20Use\x20--url\x20for\x20web\x20apps\x20or\x20--cdp-endpoint\x20for\x20Electron/CDP\x20apps,\x20not\x20both.','GSkDI','\x0aMake\x20sure\x20your\x20app\x20is\x20running,\x20then\x20try\x20again.\x20To\x20skip\x20this\x20check,\x20pass\x20--force.','12wPBOTR'];_0x2ae8=function(){return _0x34d4a4;};return _0x2ae8();}async function markActive(_0x21e361){const _0x3c35f6=_0x332f,_0x5bafed={'TeyTK':'Warning:\x20Profile\x20created,\x20but\x20failed\x20to\x20mark\x20it\x20as\x20active.'};try{await writeActiveProfileName(_0x21e361),console[_0x3c35f6(0x1a4)](_0x3c35f6(0x1c8)+_0x21e361);}catch{console['log'](_0x5bafed['TeyTK']);}}async function tryAutoRouteCloudProfile(_0x5b323e,_0x172863,_0x131112,_0x2ecc43,_0x465de2){const _0x272560=_0x332f,_0x587951={'cNFSf':function(_0x1ffd00,_0x241b06){return _0x1ffd00===_0x241b06;},'MpWhs':function(_0x44530a,_0x3a5b8f){return _0x44530a instanceof _0x3a5b8f;},'ieMlw':function(_0x3a3a7b,_0x16cc2c){return _0x3a3a7b(_0x16cc2c);},'mkRQP':'profile.add.autoRouteSkipped','otUeX':function(_0x628bda,_0x4616d4){return _0x628bda+_0x4616d4;},'PEqvF':function(_0x471285,_0x31bd7b){return _0x471285+_0x31bd7b;},'MmyMC':'\x0a\x20\x20Automated\x20login\x20isn\x27t\x20set\x20up\x20for\x20your\x20team\x20yet\x20—\x20that\x27s\x20the\x20path\x20that\x20lets\x20Ranger\x20log\x20into\x20your\x20app\x20for\x20you\x20in\x20CI\x20/\x20background\x20agents.\x0a','mdOnB':_0x272560(0x19d),'WxvLA':'\x20\x20To\x20get\x20automated\x20login\x20set\x20up\x20for\x20your\x20team\x20(a\x20one-time\x20call):\x20eng@ranger.net\x0a','zlifT':_0x272560(0x15f),'jsdwk':function(_0x287c68,_0x5963d2,_0x4ac38a){return _0x287c68(_0x5963d2,_0x4ac38a);},'Srqoi':'no_match','zXWpQ':'user_declined','JfLls':_0x272560(0x1c5)};let _0x116fc8;try{_0x116fc8=await fetchAuthConfig();}catch(_0x1a8397){return _0x465de2?.['trackPhaseEnd'](_0x272560(0x172),{'reason':'no_auth_config','profileName':_0x5b323e}),console['error'](_0x272560(0x14f)+(_0x587951[_0x272560(0x163)](_0x1a8397,Error)?_0x1a8397['message']:_0x587951['ieMlw'](String,_0x1a8397))),![];}if(!_0x116fc8||!_0x116fc8['environments']||Object[_0x272560(0x1a0)](_0x116fc8[_0x272560(0x150)])[_0x272560(0x1b1)]===0x0){if(_0x2ecc43)return await captureEnvLessProfile(_0x5b323e,_0x172863,_0x131112,_0x465de2);return _0x465de2?.['trackPhaseEnd'](_0x587951['mkRQP'],{'reason':'no_auth_config','profileName':_0x5b323e}),console[_0x272560(0x184)](_0x587951[_0x272560(0x1a9)](_0x587951['PEqvF'](_0x587951['MmyMC'],'\x0a')+_0x587951['mdOnB']+('\x20\x20\x20\x20\x20\x20ranger\x20profile\x20add\x20'+_0x5b323e+_0x272560(0x14c)+_0x172863+'\x20--skip-auth\x0a')+'\x0a',_0x587951[_0x272560(0x17d)])+_0x587951['zlifT']),![];}const _0x536407=_0x587951['jsdwk'](matchAuthEnvironment,_0x172863,_0x116fc8);if(!_0x536407)return _0x465de2?.['trackPhaseEnd'](_0x587951[_0x272560(0x1c6)],{'reason':_0x587951['Srqoi'],'profileName':_0x5b323e}),console[_0x272560(0x184)]('\x0a\x20\x20No\x20auth\x20env\x20matches\x20'+_0x172863+'.\x20Configured\x20envs:\x20'+Object['keys'](_0x116fc8[_0x272560(0x150)])[_0x272560(0x1c3)](',\x20')+'.'),![];const _0x4bf430=_0x116fc8[_0x272560(0x150)][_0x536407],_0x3d0b07=_0x4bf430?.[_0x272560(0x1c1)]??[];if(_0x2ecc43&&!_0x131112[_0x272560(0x1a5)]){const {saveToCloud:_0x38de62}=await _0x356642['prompt']([{'type':_0x272560(0x1b6),'name':_0x272560(0x152),'message':'Found\x20auth\x20environment\x20\x27'+_0x536407+_0x272560(0x1b9)+_0x172863+_0x272560(0x175)+_0x3d0b07[_0x272560(0x1c3)](',\x20')+')\x0a\x20\x20Save\x20\x27'+_0x5b323e+_0x272560(0x1b7),'default':!![]}]);if(!_0x38de62)return _0x465de2?.[_0x272560(0x182)](_0x587951['mkRQP'],{'reason':_0x587951['zXWpQ'],'profileName':_0x5b323e}),console['error']('\x0a\x20\x20Declined.\x20Re-run\x20with\x20--skip-auth\x20to\x20create\x20a\x20profile\x20without\x20a\x20cloud-managed\x20session.'),![];}const _0x38321d=_0x3d0b07['some'](_0x5b6a03=>{try{return _0x587951['cNFSf'](new URL(_0x5b6a03)['origin'],new URL(_0x172863)['origin']);}catch{return![];}}),_0x338ecb={};!_0x38321d&&(_0x338ecb['baseUrl']=_0x172863);try{await createCloudProfile(_0x5b323e,_0x536407,{'settings':_0x338ecb});}catch(_0x50f856){if(_0x50f856 instanceof ApiError&&_0x50f856['status']===0x199){console['error'](_0x272560(0x1ac)+_0x5b323e+_0x272560(0x158)+('\x20\x20\x20\x20\x20\x20ranger\x20profile\x20update\x20'+_0x5b323e));throw _0x50f856;}throw _0x50f856;}return console['log'](_0x587951['PEqvF']('✓\x20Profile\x20\x27'+_0x5b323e+'\x27\x20created.\x0a',_0x272560(0x166)+_0x5b323e)),await _0x587951['ieMlw'](sweepOrphansBestEffort,_0x5b323e),_0x465de2?.[_0x272560(0x182)](_0x587951[_0x272560(0x16f)],{'envKey':_0x536407,'profileName':_0x5b323e}),!![];}async function createUnconfiguredCloudProfile(_0x4cf094,_0x2060ca){const _0x2d37dd=_0x332f;try{await createCloudProfile(_0x4cf094,undefined,{'settings':_0x2060ca});}catch(_0x8a7084){_0x8a7084 instanceof ApiError&&_0x8a7084['status']===0x199&&console[_0x2d37dd(0x184)](_0x2d37dd(0x1ac)+_0x4cf094+'\x22\x20already\x20exists.\x20To\x20refresh\x20its\x20session,\x20run:\x0a'+('\x20\x20\x20\x20\x20\x20ranger\x20profile\x20update\x20'+_0x4cf094));throw _0x8a7084;}}function _0x332f(_0x46d516,_0x50f596){_0x46d516=_0x46d516-0x149;const _0x2ae82e=_0x2ae8();let _0x332f2f=_0x2ae82e[_0x46d516];return _0x332f2f;}async function captureEnvLessProfile(_0x310457,_0x58cf30,_0x4eb74f,_0x4fe327){const _0xced005=_0x332f,_0x379fb8={'YVdQW':'confirm','ncNoK':'user_declined','BpHIF':function(_0x3d6842,_0x2c068d){return _0x3d6842+_0x2c068d;},'UtpqF':function(_0xb9964f,_0x3df03b){return _0xb9964f===_0x3df03b;},'jynut':function(_0x41eb3c,_0x3fa305){return _0x41eb3c>_0x3fa305;},'luZOJ':function(_0x3011be,_0x1ef4d3,_0xd24a7,_0x527cd2){return _0x3011be(_0x1ef4d3,_0xd24a7,_0x527cd2);},'zWXnJ':function(_0x4de165,_0x1da359){return _0x4de165 instanceof _0x1da359;},'hcpBZ':function(_0x164031,_0xba4341,_0x11046b){return _0x164031(_0xba4341,_0x11046b);},'pIXoc':_0xced005(0x1c5)};if(!_0x4eb74f['yes']){const {capture:_0x434ff0}=await _0x356642[_0xced005(0x178)]([{'type':_0x379fb8['YVdQW'],'name':_0xced005(0x171),'message':_0xced005(0x1ae),'default':!![]}]);if(!_0x434ff0)return _0x4fe327?.[_0xced005(0x182)](_0xced005(0x172),{'reason':_0x379fb8[_0xced005(0x188)],'profileName':_0x310457}),console['error'](_0x379fb8[_0xced005(0x1b3)](_0xced005(0x157),'\x20\x20or\x20contact\x20eng@ranger.net\x20to\x20set\x20up\x20automated\x20login\x20for\x20your\x20team.')),![];}const _0x5f41d4={};if(_0x4eb74f['setupHeader'])for(const _0x37c4a5 of _0x4eb74f['setupHeader']){const _0x288345=_0x37c4a5['indexOf'](':');if(_0x379fb8[_0xced005(0x17b)](_0x288345,-0x1))continue;_0x5f41d4[_0x37c4a5['slice'](0x0,_0x288345)[_0xced005(0x14d)]()]=_0x37c4a5[_0xced005(0x1c2)](_0x288345+0x1)['trim']();}const _0x638116={'baseUrl':_0x58cf30};_0x379fb8['jynut'](Object['keys'](_0x5f41d4)['length'],0x0)&&(_0x638116[_0xced005(0x1ab)]=_0x5f41d4);let _0x4eb625;try{_0x4eb625=await _0x379fb8[_0xced005(0x1be)](createCloudProfile,_0x310457,undefined,{'settings':_0x638116});}catch(_0x3c63de){_0x379fb8[_0xced005(0x1a1)](_0x3c63de,ApiError)&&_0x379fb8['UtpqF'](_0x3c63de[_0xced005(0x1b8)],0x199)&&console[_0xced005(0x184)]('\x0a\x20\x20A\x20profile\x20named\x20\x22'+_0x310457+'\x22\x20already\x20exists.\x20To\x20refresh\x20its\x20session,\x20run:\x0a'+('\x20\x20\x20\x20\x20\x20ranger\x20profile\x20update\x20'+_0x310457));throw _0x3c63de;}return await _0x379fb8[_0xced005(0x18a)](manualBrowserLogin,_0x4eb625,{'key':'','domains':[_0x58cf30],'setupHeaders':Object['keys'](_0x5f41d4)['length']>0x0?_0x5f41d4:undefined}),console[_0xced005(0x1a4)]('\x0a✓\x20Profile\x20\x27'+_0x310457+'\x27\x20created\x20with\x20a\x20captured\x20session.\x0a'+('\x20\x20Next:\x20ranger\x20go\x20--profile\x20'+_0x310457)),await sweepOrphansBestEffort(_0x310457),_0x4fe327?.[_0xced005(0x182)](_0x379fb8['pIXoc'],{'envKey':null,'profileName':_0x310457}),!![];}export async function addEnv(_0x5fbf0f,_0x300611={},_0x24c80a){const _0x5aa2ce=_0x332f,_0x91573d={'oqhpD':_0x5aa2ce(0x1ad),'FLsnp':_0x5aa2ce(0x1b0),'hBywO':function(_0x1b07e1,_0x22ed34){return _0x1b07e1+_0x22ed34;},'vaWRj':function(_0x1780be,_0x588b73){return _0x1780be!==_0x588b73;},'QfMHx':function(_0x2c7e68,_0x549257){return _0x2c7e68===_0x549257;},'iuERG':_0x5aa2ce(0x181),'vxWsw':_0x5aa2ce(0x15a),'oGVaO':function(_0x1edf21,_0x4cbc04){return _0x1edf21(_0x4cbc04);},'RxqRK':function(_0x1448c9,_0x4b2efc,_0x5a88ae){return _0x1448c9(_0x4b2efc,_0x5a88ae);},'fJZCP':function(_0x59b22b,_0x4261d3,_0x9cb2be,_0x1d0ed1,_0x5c83c2){return _0x59b22b(_0x4261d3,_0x9cb2be,_0x1d0ed1,_0x5c83c2);},'Hbiap':function(_0x26f963,_0xf287dd,_0x3abd86,_0x13aaa4,_0xe9108){return _0x26f963(_0xf287dd,_0x3abd86,_0x13aaa4,_0xe9108);},'dMwIa':_0x5aa2ce(0x1bf),'aOxii':function(_0x4e9593,_0x574da6){return _0x4e9593(_0x574da6);},'KjJyd':function(_0x3b04a2,_0xebc72c){return _0x3b04a2>_0xebc72c;},'qGHRT':function(_0x5b7e72,_0xd44ad3){return _0x5b7e72(_0xd44ad3);},'ghDsV':function(_0x1f7741,_0x4513fe){return _0x1f7741(_0x4513fe);},'JjFVt':_0x5aa2ce(0x1aa),'RPpAN':_0x5aa2ce(0x190),'YjCCF':_0x5aa2ce(0x16a),'FvEyC':_0x5aa2ce(0x1a6),'KssPC':_0x5aa2ce(0x19b),'xfGOB':_0x5aa2ce(0x1b4),'ZTdOg':'Continue\x20anyway','SMvUK':function(_0x29f1b2,_0x441072){return _0x29f1b2===_0x441072;},'Rfhha':_0x5aa2ce(0x155),'GSkDI':function(_0x433218,_0x2c4f69){return _0x433218(_0x2c4f69);}};_0x300611['ci']&&(console[_0x5aa2ce(0x184)]('The\x20--ci\x20flag\x20is\x20no\x20longer\x20supported.\x20Ranger\x20now\x20manages\x20session\x20state\x0a'+_0x91573d['oqhpD']+'\x0a'+_0x91573d[_0x5aa2ce(0x16e)]+'\x20\x20ranger\x20profile\x20add\x20<name>\x0a'+'\x0a'+'For\x20CI\x20/\x20background\x20agents\x20and\x20other\x20setup\x20options,\x20see:\x0a'+_0x5aa2ce(0x1bb)),process['exit'](0x1));const _0x1a5f1b={};if(_0x300611['setupHeader'])for(const _0x51d256 of _0x300611['setupHeader']){const _0x6b1f77=_0x51d256['indexOf'](':');if(_0x6b1f77===-0x1)throw new Error('Invalid\x20--setup-header\x20format:\x20\x22'+_0x51d256+_0x5aa2ce(0x1bc));const _0x1db0cd=_0x51d256[_0x5aa2ce(0x1c2)](0x0,_0x6b1f77)[_0x5aa2ce(0x14d)](),_0x49a291=_0x51d256['slice'](_0x91573d[_0x5aa2ce(0x179)](_0x6b1f77,0x1))['trim']();_0x1a5f1b[_0x1db0cd]=_0x49a291;}if(_0x91573d[_0x5aa2ce(0x1a8)](_0x300611[_0x5aa2ce(0x173)],undefined)&&_0x91573d[_0x5aa2ce(0x1ba)](_0x300611['cdpEndpoint']['trim'](),''))throw new Error(_0x91573d[_0x5aa2ce(0x18c)]);if(_0x300611['cdpEndpoint']&&_0x300611['url'])throw new Error(_0x91573d['vxWsw']);const _0x3910c9=_0x91573d['oGVaO'](Boolean,_0x300611['cdpEndpoint']),_0x45543a=process['stdin']['isTTY']&&process['stdout']['isTTY'];if(!_0x45543a&&!_0x300611['url']&&!_0x3910c9&&!_0x300611['skipAuth'])throw new Error('Please\x20provide\x20--url\x20when\x20running\x20in\x20non-interactive\x20mode.\x0aMake\x20sure\x20the\x20service\x20is\x20running\x20on\x20that\x20port\x20before\x20retrying.\x0aExample:\x20ranger\x20profile\x20add\x20local\x20--url\x20http://localhost:3000');if(_0x3910c9){const _0x5e0be3=_0x300611[_0x5aa2ce(0x173)];console[_0x5aa2ce(0x1a4)](_0x5aa2ce(0x14e)),console['log']('\x20\x20Configuring\x20Ranger\x20to\x20connect\x20to:\x20'+_0x5e0be3);const _0x4bf96b={'cdpEndpoint':_0x5e0be3,'isElectron':!![]};Object['keys'](_0x1a5f1b)['length']>0x0&&(_0x4bf96b[_0x5aa2ce(0x1ab)]=_0x1a5f1b);await _0x91573d[_0x5aa2ce(0x174)](createUnconfiguredCloudProfile,_0x5fbf0f,_0x4bf96b);try{_0x91573d[_0x5aa2ce(0x186)](setProfileOverride,process['cwd'](),_0x5fbf0f,_0x5aa2ce(0x173),_0x5e0be3),_0x91573d[_0x5aa2ce(0x162)](setProfileOverride,process[_0x5aa2ce(0x169)](),_0x5fbf0f,_0x91573d['dMwIa'],!![]);}catch(_0x3491fd){console[_0x5aa2ce(0x184)](_0x5aa2ce(0x17c)+(_0x3491fd instanceof Error?_0x3491fd[_0x5aa2ce(0x180)]:String(_0x3491fd)));}console[_0x5aa2ce(0x1a4)]('✓\x20Cloud\x20profile\x20\x27'+_0x5fbf0f+'\x27\x20created\x20(CDP).'),await _0x91573d['aOxii'](sweepOrphansBestEffort,_0x5fbf0f),await markActive(_0x5fbf0f);return;}if(_0x300611['skipAuth']){const _0x37e18b={};_0x300611[_0x5aa2ce(0x167)]&&(_0x37e18b[_0x5aa2ce(0x1aa)]=_0x300611['url']);_0x91573d[_0x5aa2ce(0x168)](Object[_0x5aa2ce(0x1a0)](_0x1a5f1b)['length'],0x0)&&(_0x37e18b['setupHeaders']=_0x1a5f1b);await createUnconfiguredCloudProfile(_0x5fbf0f,_0x37e18b),console['log'](_0x91573d['hBywO'](_0x5aa2ce(0x1c0)+_0x5fbf0f+'\x27\x20created\x20(no\x20session).\x0a','\x20\x20When\x20you\x27re\x20ready\x20to\x20log\x20in,\x20run\x20`ranger\x20profile\x20add\x20'+_0x5fbf0f+_0x5aa2ce(0x191))),await _0x91573d[_0x5aa2ce(0x19c)](sweepOrphansBestEffort,_0x5fbf0f),await _0x91573d[_0x5aa2ce(0x1a2)](markActive,_0x5fbf0f);return;}if(_0x300611['url']){const _0x5732cb=_0x300611['url'],_0x5c237e=await _0x91573d['oGVaO'](checkUrlReachability,_0x5732cb);if(!_0x5c237e['ok']&&!_0x300611[_0x5aa2ce(0x156)])throw new Error(_0x5aa2ce(0x151)+_0x5732cb+':\x20'+_0x5c237e['error']+_0x5aa2ce(0x15c));!_0x5c237e['ok']&&_0x300611['force']&&console['log'](_0x5aa2ce(0x16c)+_0x5732cb+':\x20'+_0x5c237e[_0x5aa2ce(0x184)]+'\x20(continuing\x20with\x20--force)');}else{console['log'](_0x5aa2ce(0x15e)),console[_0x5aa2ce(0x1a4)](_0x5aa2ce(0x164)),console[_0x5aa2ce(0x1a4)]('\x20\x20Ranger\x20will\x20use\x20it\x20to\x20look\x20up\x20the\x20right\x20cloud\x20auth\x20env\x20to\x20attach.\x0a');let _0x2774bb='',_0x429716=![];while(!![]){const _0xb4b7b5=await _0x356642['prompt']([{'type':_0x5aa2ce(0x194),'name':_0x91573d['JjFVt'],'message':_0x429716?_0x91573d[_0x5aa2ce(0x165)]:_0x5aa2ce(0x183),'default':_0x2774bb||_0x91573d[_0x5aa2ce(0x1bd)]}]);_0x2774bb=_0xb4b7b5['baseUrl'];const _0x78d5fe=await checkUrlReachability(_0x2774bb);if(_0x78d5fe['ok'])break;const _0x4da3af=/^[a-zA-Z][\w+.-]*:\/\//['test'](_0x2774bb),_0x1bf393=_0x78d5fe['isProtocolError']&&!_0x4da3af,_0x58ad06=_0x1bf393?'http://'+_0x2774bb:null;_0x429716=!![],console[_0x5aa2ce(0x1a4)]('\x0a\x20\x20Could\x20not\x20reach\x20'+_0x2774bb+':\x20'+_0x78d5fe['error']);_0x58ad06&&console[_0x5aa2ce(0x1a4)](_0x5aa2ce(0x18d)+_0x58ad06+'?');const {action:_0x537b94}=await _0x356642['prompt']([{'type':'list','name':_0x91573d[_0x5aa2ce(0x198)],'message':_0x91573d[_0x5aa2ce(0x17e)],'choices':[..._0x58ad06?[{'name':_0x5aa2ce(0x187)+_0x58ad06,'value':_0x5aa2ce(0x155)}]:[],{'name':_0x91573d[_0x5aa2ce(0x153)],'value':_0x5aa2ce(0x17a)},{'name':_0x91573d['ZTdOg'],'value':'continue'}]}]);if(_0x91573d['SMvUK'](_0x537b94,_0x91573d['Rfhha'])&&_0x58ad06){_0x2774bb=_0x58ad06;const _0x1c5a26=await _0x91573d[_0x5aa2ce(0x15b)](checkUrlReachability,_0x2774bb);if(_0x1c5a26['ok'])break;console['log'](_0x5aa2ce(0x18e)+_0x2774bb+':\x20'+_0x1c5a26['error']);}else{if(_0x537b94===_0x5aa2ce(0x193))break;}}_0x300611={..._0x300611,'url':_0x2774bb};}let _0x3a73d6=![];try{_0x3a73d6=await tryAutoRouteCloudProfile(_0x5fbf0f,_0x300611[_0x5aa2ce(0x167)],_0x300611,_0x45543a,_0x24c80a);}catch(_0x1e9757){console['error'](_0x5aa2ce(0x176)+_0x5fbf0f+_0x5aa2ce(0x1c4)+(_0x1e9757 instanceof Error?_0x1e9757[_0x5aa2ce(0x180)]:String(_0x1e9757))),process[_0x5aa2ce(0x1a7)](0x1);}!_0x3a73d6&&process['exit'](0x1),await _0x91573d[_0x5aa2ce(0x15b)](markActive,_0x5fbf0f);}
1
+ (function(_0x1e65e0,_0x3b23c9){const _0x2617e6=_0x409c,_0x457ae2=_0x1e65e0();while(!![]){try{const _0x213fe8=parseInt(_0x2617e6(0xe0))/0x1*(parseInt(_0x2617e6(0xc3))/0x2)+parseInt(_0x2617e6(0xd8))/0x3+parseInt(_0x2617e6(0x125))/0x4*(-parseInt(_0x2617e6(0xba))/0x5)+-parseInt(_0x2617e6(0x132))/0x6*(-parseInt(_0x2617e6(0xc4))/0x7)+-parseInt(_0x2617e6(0xf5))/0x8*(-parseInt(_0x2617e6(0xd1))/0x9)+parseInt(_0x2617e6(0x105))/0xa*(-parseInt(_0x2617e6(0x12b))/0xb)+-parseInt(_0x2617e6(0x110))/0xc;if(_0x213fe8===_0x3b23c9)break;else _0x457ae2['push'](_0x457ae2['shift']());}catch(_0x30dd83){_0x457ae2['push'](_0x457ae2['shift']());}}}(_0x58d8,0xa95bf));import{mkdir,writeFile,readFile,unlink,rm,mkdtemp,rename}from'fs/promises';import{join}from'path';import _0x4dbb64 from'inquirer';import{chromium}from'playwright';import{findExistingEnv,loadSettings}from'./utils/settings.js';import{encrypt}from'./utils/crypto.js';import{getToken}from'./utils/keychain.js';import{getRangerDir,getRangerHomeDir}from'./utils/rangerRoot.js';function _0x409c(_0x496bad,_0x376467){_0x496bad=_0x496bad-0xb0;const _0x58d826=_0x58d8();let _0x409cba=_0x58d826[_0x496bad];return _0x409cba;}import{writeActiveProfileName}from'./utils/activeProfile.js';import{addProfileSetupBanner}from'./utils/profileSetupBanner.js';async function checkUrlReachability(_0x323df2){const _0x108aa8=_0x409c,_0x109c10={'OhRtV':function(_0x387d7f,_0xcafb61,_0x172154){return _0x387d7f(_0xcafb61,_0x172154);},'KGDjy':'HEAD','yrWTK':'manual','HSUXW':function(_0x3a98de,_0x4b2bb7){return _0x3a98de(_0x4b2bb7);},'NLBoA':_0x108aa8(0xd0),'MVgDw':function(_0x13ef12,_0x313a00){return _0x13ef12===_0x313a00;},'wWeHX':_0x108aa8(0xb3)};try{const _0x17d89e=new AbortController(),_0x4b1423=_0x109c10[_0x108aa8(0xc2)](setTimeout,()=>_0x17d89e['abort'](),0x1388),_0x450d13={'method':_0x109c10['KGDjy'],'signal':_0x17d89e['signal'],'redirect':_0x109c10['yrWTK']};/^https:\/\/localhost(:\d+)?/i[_0x108aa8(0x108)](_0x323df2)&&(process['env']['NODE_TLS_REJECT_UNAUTHORIZED']='0');const _0x360efb=await fetch(_0x323df2,_0x450d13);delete process[_0x108aa8(0xbf)]['NODE_TLS_REJECT_UNAUTHORIZED'],_0x109c10['HSUXW'](clearTimeout,_0x4b1423);if(_0x360efb['status']<0x190)return{'ok':!![]};return{'ok':![],'error':_0x108aa8(0xf1)+_0x360efb['status']};}catch(_0x2e6c19){delete process['env']['NODE_TLS_REJECT_UNAUTHORIZED'];const _0x24e286=_0x2e6c19,_0x2f03fe=_0x24e286[_0x108aa8(0xf8)]||_0x109c10[_0x108aa8(0x12c)](String,_0x2e6c19),_0x341a64=_0x2f03fe['includes'](_0x109c10['NLBoA'])||_0x109c10['MVgDw'](_0x24e286[_0x108aa8(0xdb)],'TypeError')||_0x2f03fe[_0x108aa8(0xed)](_0x109c10['wWeHX']);return{'ok':![],'error':_0x2f03fe,'isProtocolError':_0x341a64};}}export async function addEnv(_0x3b1dac,_0x550d59={},_0x5c3aa1){const _0x5714c3=_0x409c,_0x396852={'rzKpx':'close','Ppkfo':'user','sekTg':function(_0x179e02,_0x2b5ba1,_0x193a7d,_0x3fa2c8){return _0x179e02(_0x2b5ba1,_0x193a7d,_0x3fa2c8);},'dHQsn':function(_0x193106,_0x56b60d){return _0x193106+_0x56b60d;},'WHseH':function(_0x2f5b26,_0x3b6d64,_0x52499b){return _0x2f5b26(_0x3b6d64,_0x52499b);},'JHCto':function(_0x55395e,_0x28e75d){return _0x55395e!==_0x28e75d;},'Gqutq':_0x5714c3(0x12e),'grUEZ':function(_0x321e11,_0x44fdd9,_0x55be4e){return _0x321e11(_0x44fdd9,_0x55be4e);},'mpEbN':function(_0x19b1b6,_0x434c74){return _0x19b1b6===_0x434c74;},'ljQAr':'confirm','divnj':'overwrite','rkjQy':_0x5714c3(0xc5),'fIbzP':_0x5714c3(0x106),'MKjoA':function(_0x3b7d4f,_0x3de76a){return _0x3b7d4f(_0x3de76a);},'RYOFr':_0x5714c3(0x10b),'SXyas':'\x20\x20Ranger\x20will\x20open\x20it\x20in\x20a\x20browser\x20so\x20you\x20can\x20log\x20in\x20and\x20save\x20your\x20session.\x0a','oSNbB':'baseUrl','WtDbt':_0x5714c3(0xb1),'lXYAS':_0x5714c3(0xe1),'CkQzA':function(_0x4e78ab,_0x1bd660){return _0x4e78ab||_0x1bd660;},'RhQbh':function(_0x560a92,_0x7fea36){return _0x560a92(_0x7fea36);},'NoRho':_0x5714c3(0xf2),'IKZRi':_0x5714c3(0x107),'tLlqx':_0x5714c3(0xdf),'jWQiQ':'continue','akOxP':function(_0x454576,_0x23afae){return _0x454576===_0x23afae;},'ymNMD':_0x5714c3(0x12f),'TmlUs':function(_0x1fe122,_0x2c09b6){return _0x1fe122(_0x2c09b6);},'CndcK':function(_0x47fe2b,_0x4a843a){return _0x47fe2b===_0x4a843a;},'QjPVT':_0x5714c3(0xf9),'jpezy':function(_0x3e8b2f,_0x4bf73a){return _0x3e8b2f(_0x4bf73a);},'GBKsZ':function(_0x1e1081,_0x54d3fd,_0x25fe19){return _0x1e1081(_0x54d3fd,_0x25fe19);},'DXQiH':_0x5714c3(0x122),'ZSBnQ':_0x5714c3(0xe2),'oAuqg':'\x20\x20\x20A\x20browser\x20will\x20open.\x20Please\x20log\x20in\x20to\x20the\x20profile\x20you\x20want\x20to\x20test\x20so\x20Ranger\x20can\x20access\x20it.','hFkxi':'\x20\x20\x20When\x20done\x20logging\x20in,\x20close\x20the\x20browser\x20to\x20save\x20the\x20session.','qjNwX':_0x5714c3(0x119),'QAvhl':'--allow-insecure-localhost','Fzzbs':function(_0x3aea90,_0x4c59c9){return _0x3aea90||_0x4c59c9;},'nUXBg':_0x5714c3(0xc7),'AoEWo':_0x5714c3(0xcb),'jPaeT':'You\x20can\x20try\x20again\x20with\x20one\x20of:','dcFiR':'Browser\x20closed\x20before\x20authentication\x20was\x20saved.','aNPqa':function(_0x31bbde){return _0x31bbde();},'tkfsX':_0x5714c3(0xe5),'YVGAL':function(_0x91f294,_0x5d7191){return _0x91f294(_0x5d7191);},'fKHKD':_0x5714c3(0x130),'Rmame':function(_0x2dc0fb,_0x4e78a4,_0x457dd6){return _0x2dc0fb(_0x4e78a4,_0x457dd6);},'AlDWN':function(_0x370e73,_0x4d131f){return _0x370e73+_0x4d131f;},'sGmGM':'\x20\x20You\x20can\x20safely\x20commit\x20this\x20file\x20to\x20git.','ZcAJi':_0x5714c3(0x104),'XXzFo':'config_write','RHiFo':function(_0x234f0c,_0xcbbcce,_0x2f5569){return _0x234f0c(_0xcbbcce,_0x2f5569);},'TNRWa':function(_0x35b015,_0x32f82e){return _0x35b015(_0x32f82e);},'MKYeI':_0x5714c3(0xbe),'WWAWI':function(_0x7008bc,_0x589471,_0x2915ac){return _0x7008bc(_0x589471,_0x2915ac);}},_0x4ee75c=_0x550d59['ci']??![],_0x33327f=_0x4ee75c?'ci':_0x5714c3(0x121),_0xc43885=_0x550d59[_0x5714c3(0xb8)]===_0x396852['Ppkfo']?getRangerHomeDir():getRangerDir(),_0x38d099=_0x396852['sekTg'](join,_0xc43885,_0x33327f,_0x3b1dac),_0x9eeca8={};if(_0x550d59[_0x5714c3(0x116)])for(const _0x38232c of _0x550d59['setupHeader']){const _0x3e1531=_0x38232c['indexOf'](':');if(_0x3e1531===-0x1)throw new Error('Invalid\x20--setup-header\x20format:\x20\x22'+_0x38232c+'\x22.\x20Expected\x20\x22Name:\x20Value\x22.');const _0x48fa74=_0x38232c[_0x5714c3(0xbc)](0x0,_0x3e1531)[_0x5714c3(0xb5)](),_0x9d0156=_0x38232c['slice'](_0x396852[_0x5714c3(0x120)](_0x3e1531,0x1))[_0x5714c3(0xb5)]();_0x9eeca8[_0x48fa74]=_0x9d0156;}const _0x3adcfd=_0x396852[_0x5714c3(0xcc)](join,_0xc43885,_0x33327f);if(_0x396852['JHCto'](_0x550d59['cdpEndpoint'],undefined)&&_0x550d59[_0x5714c3(0xc9)][_0x5714c3(0xb5)]()==='')throw new Error(_0x396852['Gqutq']);if(_0x550d59[_0x5714c3(0xc9)]&&_0x550d59['url'])throw new Error('--url\x20and\x20--cdp-endpoint\x20are\x20mutually\x20exclusive.\x20Use\x20--url\x20for\x20web\x20apps\x20or\x20--cdp-endpoint\x20for\x20Electron/CDP\x20apps,\x20not\x20both.');if(_0x550d59['cdpEndpoint']&&_0x550d59['ci'])throw new Error('--ci\x20and\x20--cdp-endpoint\x20cannot\x20be\x20used\x20together.\x20Electron/CDP\x20profiles\x20only\x20work\x20with\x20a\x20locally\x20running\x20app\x20and\x20are\x20not\x20supported\x20in\x20CI.');const _0x394d67=Boolean(_0x550d59[_0x5714c3(0xc9)]),_0x29fd85=!_0x550d59[_0x5714c3(0x11f)]&&!_0x394d67,_0x509f3a=process[_0x5714c3(0x11b)][_0x5714c3(0x102)]&&process['stdout']['isTTY'];if(!_0x509f3a&&!_0x550d59[_0x5714c3(0x114)]&&!_0x394d67)throw new Error('Please\x20provide\x20--url\x20when\x20running\x20in\x20non-interactive\x20mode.\x0aMake\x20sure\x20the\x20service\x20is\x20running\x20on\x20that\x20port\x20before\x20retrying.\x0aExample:\x20ranger\x20profile\x20add\x20local\x20--url\x20http://localhost:3000');const _0x37960f=_0x396852['grUEZ'](findExistingEnv,_0x3b1dac,{'rangerDir':_0xc43885});let _0x52d69c=null;if(_0x37960f){if(!_0x509f3a)_0x52d69c=_0x37960f;else{if(_0x396852[_0x5714c3(0xec)](_0x37960f[_0x5714c3(0x10c)],_0x33327f)){const {overwrite:_0x26ed03}=await _0x4dbb64['prompt']([{'type':_0x396852[_0x5714c3(0x131)],'name':_0x396852['divnj'],'message':'Profile\x20\x22'+_0x3b1dac+'\x22\x20already\x20exists.\x20Overwrite?','default':![]}]);if(!_0x26ed03){console['log']('Aborted.');return;}_0x52d69c=_0x37960f;}else{const _0x463012=_0x396852[_0x5714c3(0xec)](_0x37960f[_0x5714c3(0x10c)],'legacy')?'root\x20(.ranger/)':_0x37960f[_0x5714c3(0x10c)];console['error'](_0x5714c3(0x10a)+_0x3b1dac+'\x22\x20already\x20exists\x20in\x20'+_0x463012+':\x20'+_0x37960f[_0x5714c3(0xc1)]),console['error']('\x20\x20\x20Creating\x20it\x20in\x20'+_0x33327f+'\x20would\x20shadow\x20the\x20existing\x20profile.');const {shouldReplace:_0x57d747}=await _0x4dbb64[_0x5714c3(0xd9)]([{'type':_0x5714c3(0xd4),'name':_0x5714c3(0x10f),'message':'Delete\x20existing\x20and\x20create\x20new\x20in\x20'+_0x33327f+'?','default':![]}]);if(!_0x57d747){console[_0x5714c3(0xcf)](_0x396852[_0x5714c3(0xd7)]);return;}_0x52d69c=_0x37960f;}}}_0x5c3aa1?.['trackPhaseStart'](_0x5714c3(0xf9));let _0x47f07e='';if(_0x394d67)console['log'](_0x396852[_0x5714c3(0xb4)]),console[_0x5714c3(0xcf)]('\x20\x20Configuring\x20Ranger\x20to\x20connect\x20to:\x20'+_0x550d59['cdpEndpoint']),console['log'](_0x5714c3(0xfa));else{if(_0x550d59[_0x5714c3(0x114)]){_0x47f07e=_0x550d59['url'];const _0x5ff7e2=await _0x396852[_0x5714c3(0xde)](checkUrlReachability,_0x47f07e);if(!_0x5ff7e2['ok']&&!_0x550d59['force'])throw new Error('Could\x20not\x20reach\x20'+_0x47f07e+':\x20'+_0x5ff7e2[_0x5714c3(0x129)]+_0x5714c3(0xee));!_0x5ff7e2['ok']&&_0x550d59[_0x5714c3(0x128)]&&console[_0x5714c3(0xcf)](_0x5714c3(0xf3)+_0x47f07e+':\x20'+_0x5ff7e2['error']+_0x5714c3(0x103));}else{console['log'](_0x396852[_0x5714c3(0x11e)]),console[_0x5714c3(0xcf)](_0x5714c3(0x123)),console['log'](_0x396852[_0x5714c3(0x117)]);let _0x3cd0fa=![];while(!![]){const _0x27f66d=await _0x4dbb64[_0x5714c3(0xd9)]([{'type':'input','name':_0x396852[_0x5714c3(0xce)],'message':_0x3cd0fa?_0x396852['WtDbt']:_0x396852['lXYAS'],'default':_0x396852[_0x5714c3(0xfd)](_0x47f07e,_0x5714c3(0xbb))}]);_0x47f07e=_0x27f66d['baseUrl'];const _0x3952b9=await _0x396852[_0x5714c3(0xd2)](checkUrlReachability,_0x47f07e);if(_0x3952b9['ok'])break;const _0x4413d9=/^[a-zA-Z][\w+.-]*:\/\//[_0x5714c3(0x108)](_0x47f07e),_0x1f6d86=_0x3952b9['isProtocolError']&&!_0x4413d9,_0xce4183=_0x1f6d86?_0x5714c3(0x126)+_0x47f07e:null;_0x3cd0fa=!![],console['log'](_0x5714c3(0x10e)+_0x47f07e+':\x20'+_0x3952b9['error']);_0xce4183&&console['log']('\x20\x20Did\x20you\x20mean\x20'+_0xce4183+'?');const {action:_0xd66dff}=await _0x4dbb64['prompt']([{'type':_0x5714c3(0xe4),'name':_0x396852[_0x5714c3(0xb7)],'message':_0x396852[_0x5714c3(0xbd)],'choices':[..._0xce4183?[{'name':'Use\x20'+_0xce4183,'value':'use_suggestion'}]:[],{'name':_0x396852[_0x5714c3(0xfe)],'value':'retry'},{'name':_0x5714c3(0xe3),'value':_0x396852['jWQiQ']}]}]);if(_0x396852['akOxP'](_0xd66dff,_0x396852[_0x5714c3(0x10d)])&&_0xce4183){_0x47f07e=_0xce4183;const _0x5ecc62=await _0x396852['TmlUs'](checkUrlReachability,_0x47f07e);if(_0x5ecc62['ok'])break;console[_0x5714c3(0xcf)](_0x5714c3(0x12a)+_0x47f07e+':\x20'+_0x5ecc62['error']);}else{if(_0x396852[_0x5714c3(0x127)](_0xd66dff,_0x5714c3(0xb2)))break;}}}}_0x5c3aa1?.[_0x5714c3(0xda)](_0x396852['QjPVT']);const _0x3de90b={};if(_0x52d69c){const _0x5e73fd=await loadSettings(_0x3b1dac);Object[_0x5714c3(0xd6)](_0x3de90b,_0x5e73fd['setupHeaders']);}Object['assign'](_0x3de90b,_0x9eeca8),await _0x396852[_0x5714c3(0xcc)](mkdir,_0x3adcfd,{'recursive':!![]});const _0x34421b=await _0x396852['jpezy'](mkdtemp,_0x396852['WHseH'](join,_0x3adcfd,'.tmp-'+_0x3b1dac+'-')),_0x590349=_0x396852['GBKsZ'](join,_0x34421b,_0x5714c3(0x11d)),_0x386932=_0x396852['RhQbh'](Boolean,_0x47f07e)&&/^https:\/\/localhost(:\d+)?/i['test'](_0x47f07e);try{if(_0x29fd85){_0x5c3aa1?.[_0x5714c3(0xb9)](_0x396852['DXQiH']),console[_0x5714c3(0xcf)](_0x396852[_0x5714c3(0xd3)]),console['log'](_0x396852[_0x5714c3(0x112)]),console[_0x5714c3(0xcf)](_0x396852[_0x5714c3(0xe6)]);!_0x509f3a?(console['log'](_0x5714c3(0x11a)),console['log'](_0x396852[_0x5714c3(0xef)])):console['log']('');await new Promise(_0x604305=>setTimeout(_0x604305,0xbb8));const _0x252328=[];_0x550d59[_0x5714c3(0xca)]&&_0x252328[_0x5714c3(0xf6)](_0x5714c3(0xff));const _0x46bcba=_0x550d59['allowInsecureLocalhost']||_0x386932;_0x46bcba&&_0x252328[_0x5714c3(0xf6)](_0x396852[_0x5714c3(0xc6)]);const _0x123339=await chromium[_0x5714c3(0xf4)]({'headless':![],..._0x252328['length']>0x0?{'args':_0x252328}:{}});try{const _0x73bcda=Object['keys'](_0x3de90b)[_0x5714c3(0x111)]>0x0,_0x16865d={'ignoreHTTPSErrors':!![]};_0x73bcda&&(_0x16865d['extraHTTPHeaders']=_0x3de90b);const _0x25735f=await _0x123339['newContext'](_0x16865d);await addProfileSetupBanner(_0x25735f);const _0x323753=await _0x25735f['newPage']();await _0x323753[_0x5714c3(0xeb)](_0x396852['Fzzbs'](_0x47f07e,_0x396852['nUXBg']));let _0x55de33=![];await new Promise(_0x5525d8=>{const _0x2e912e={'OTsnM':'Saving\x20authentication\x20state...','BlKEl':function(_0x1790b8){return _0x1790b8();}};_0x323753['on'](_0x396852['rzKpx'],async()=>{const _0xabbcda=_0x409c;try{console['log'](_0x2e912e[_0xabbcda(0xfc)]),await _0x25735f['storageState']({'path':_0x590349}),_0x55de33=!![];}catch{}_0x2e912e[_0xabbcda(0x100)](_0x5525d8);});});if(!_0x55de33){console['log'](_0x396852['AoEWo']);!_0x550d59[_0x5714c3(0xca)]&&(console[_0x5714c3(0xcf)]('This\x20can\x20happen\x20due\x20to\x20a\x20browser\x20compatibility\x20issue\x20on\x20some\x20systems.\x0a'),console[_0x5714c3(0xcf)](_0x396852['jPaeT']),console[_0x5714c3(0xcf)]('\x20\x20ranger\x20profile\x20add\x20'+_0x3b1dac+'\x20--safe-mode\x20\x20\x20\x20(disables\x20browser\x20features\x20that\x20can\x20cause\x20crashes)'),console['log']('\x20\x20ranger\x20profile\x20add\x20'+_0x3b1dac+'\x20--skip-auth\x20\x20\x20\x20(skip\x20browser\x20auth\x20entirely)\x0a'));throw new Error(_0x396852[_0x5714c3(0xea)]);}}finally{await _0x123339['close']()['catch'](()=>{});}if(_0x4ee75c){const _0x5d4208=await readFile(_0x590349,_0x5714c3(0x124)),_0x65e9e4=await _0x396852[_0x5714c3(0x109)](getToken);if(!_0x65e9e4){console['error'](_0x396852['tkfsX']),await _0x396852[_0x5714c3(0xdc)](unlink,_0x590349)['catch'](()=>{});throw new Error(_0x396852[_0x5714c3(0x12d)]);}else{const _0x388cfb=_0x396852[_0x5714c3(0xc8)](encrypt,_0x5d4208,_0x65e9e4);await _0x396852[_0x5714c3(0x11c)](writeFile,_0x396852['AlDWN'](_0x590349,_0x5714c3(0x113)),_0x388cfb),await _0x396852[_0x5714c3(0x101)](unlink,_0x590349),console[_0x5714c3(0xcf)]('✓\x20Encrypted\x20auth\x20saved\x20to:\x20'+_0x590349+_0x5714c3(0x113)),console[_0x5714c3(0xcf)](_0x396852[_0x5714c3(0x115)]),console['log'](_0x396852[_0x5714c3(0xb0)]);}}else console[_0x5714c3(0xcf)](_0x5714c3(0xdd)+_0x590349);_0x5c3aa1?.[_0x5714c3(0xda)](_0x396852['DXQiH']);}_0x5c3aa1?.[_0x5714c3(0xb9)](_0x396852['XXzFo']);const _0x2dba53={};_0x47f07e&&(_0x2dba53[_0x5714c3(0xf0)]=_0x47f07e);_0x550d59['cdpEndpoint']&&(_0x2dba53[_0x5714c3(0xc9)]=_0x550d59[_0x5714c3(0xc9)],_0x2dba53[_0x5714c3(0xe7)]=!![]);(_0x550d59[_0x5714c3(0x118)]||_0x386932)&&(_0x2dba53[_0x5714c3(0x118)]=!![]);_0x550d59['safeMode']&&(_0x2dba53['safeMode']=!![]);Object['keys'](_0x3de90b)['length']>0x0&&(_0x2dba53[_0x5714c3(0xcd)]=_0x3de90b);await writeFile(join(_0x34421b,_0x5714c3(0xe8)),JSON[_0x5714c3(0xd5)](_0x2dba53,null,0x2)),console['log'](_0x5714c3(0xb6)+join(_0x38d099,'settings.json'));if(_0x396852['mpEbN'](_0x52d69c?.[_0x5714c3(0x10c)],_0x33327f)){const _0x37f8cc=_0x52d69c['path']+'.backup-'+Date['now']();await _0x396852[_0x5714c3(0xc8)](rename,_0x52d69c[_0x5714c3(0xc1)],_0x37f8cc);try{await _0x396852['grUEZ'](rename,_0x34421b,_0x38d099);}catch(_0x2de28e){await _0x396852['RHiFo'](rename,_0x37f8cc,_0x52d69c['path']);throw _0x2de28e;}try{await rm(_0x37f8cc,{'recursive':!![]});}catch{console[_0x5714c3(0xcf)]('Warning:\x20Could\x20not\x20remove\x20old\x20profile\x20backup\x20at\x20'+_0x37f8cc);}}else{await _0x396852['GBKsZ'](rename,_0x34421b,_0x38d099);if(_0x52d69c)try{await rm(_0x52d69c['path'],{'recursive':!![]}),console['log'](_0x5714c3(0xfb)+_0x52d69c[_0x5714c3(0xc1)]);}catch{console[_0x5714c3(0xcf)]('Warning:\x20Could\x20not\x20remove\x20old\x20profile\x20at\x20'+_0x52d69c[_0x5714c3(0xc1)]);}}try{await _0x396852[_0x5714c3(0xf7)](writeActiveProfileName,_0x3b1dac),console[_0x5714c3(0xcf)]('\x20\x20Set\x20active\x20profile:\x20'+_0x3b1dac);}catch{console[_0x5714c3(0xcf)](_0x396852['MKYeI']);}_0x5c3aa1?.['trackPhaseEnd'](_0x396852[_0x5714c3(0xe9)]),console['log']('\x0a\x20\x20Profile\x20\x22'+_0x3b1dac+'\x22\x20configured');}catch(_0xeca34b){await _0x396852[_0x5714c3(0xc0)](rm,_0x34421b,{'recursive':!![],'force':!![]});throw _0xeca34b;}}function _0x58d8(){const _0x53aaa6=['Rmame','cdpEndpoint','safeMode','\x0aThe\x20browser\x20closed\x20unexpectedly\x20before\x20authentication\x20could\x20be\x20saved.','WHseH','setupHeaders','oSNbB','log','Invalid\x20URL','313515SdxHgh','RhQbh','ZSBnQ','confirm','stringify','assign','rkjQy','3204954URDPhs','prompt','trackPhaseEnd','name','YVGAL','✓\x20Auth\x20state\x20saved\x20to:\x20','MKjoA','Enter\x20a\x20different\x20URL','4GrfQfo','What\x20is\x20the\x20URL\x20of\x20your\x20running\x20app?','\x0a📋\x20Authentication\x20Setup','Continue\x20anyway','list','\x20\x20Could\x20not\x20encrypt:\x20No\x20API\x20token\x20found.\x20Run:\x20ranger\x20setup\x20[token]','hFkxi','isElectron','settings.json','XXzFo','dcFiR','goto','mpEbN','includes','\x0aMake\x20sure\x20your\x20app\x20is\x20running,\x20then\x20try\x20again.\x20To\x20skip\x20this\x20check,\x20pass\x20--force.','qjNwX','baseUrl','HTTP\x20','action','⚠\x20Could\x20not\x20reach\x20','launch','88iDSPap','push','TNRWa','message','url_setup','\x20\x20Make\x20sure\x20your\x20Electron\x20app\x20(or\x20browser)\x20is\x20running\x20with\x20remote\x20debugging\x20enabled.\x0a','Removed\x20existing\x20profile\x20at\x20','OTsnM','CkQzA','tLlqx','--disable-features=WebBluetooth','BlKEl','TmlUs','isTTY','\x20(continuing\x20with\x20--force)','\x20\x20Run\x20ranger\x20setup\x20in\x20CI\x20to\x20decrypt\x20at\x20runtime.','170bIZIrY','\x0a🔌\x20CDP\x20Profile\x20Setup\x0a','What\x20would\x20you\x20like\x20to\x20do?','test','aNPqa','\x0a⚠️\x20\x20Profile\x20\x22','\x0a🌐\x20Profile\x20Setup\x0a','location','ymNMD','\x0a\x20\x20Could\x20not\x20reach\x20','shouldReplace','12321684TJppoQ','length','oAuqg','.enc','url','sGmGM','setupHeader','SXyas','allowInsecureLocalhost','\x20\x20\x20If\x20you\x20are\x20an\x20agent,\x20background\x20this\x20process\x20and\x20let\x20your\x20user\x20know\x20they\x20need\x20to\x20complete\x20browser\x20authentication.\x0a','\x0a\x20\x20\x20⚠\x20This\x20step\x20requires\x20human\x20interaction\x20in\x20a\x20browser.','stdin','grUEZ','auth.json','RYOFr','skipAuth','dHQsn','local','browser_auth','\x20\x20Make\x20sure\x20your\x20app\x20is\x20running\x20locally\x20before\x20continuing.','utf-8','1272uObCAe','http://','CndcK','force','error','\x0a\x20\x20Still\x20could\x20not\x20reach\x20','126467XyZJim','HSUXW','fKHKD','--cdp-endpoint\x20must\x20not\x20be\x20empty.\x20Provide\x20the\x20CDP\x20URL,\x20e.g.\x20--cdp-endpoint\x20http://localhost:9222','use_suggestion','Missing\x20API\x20token;\x20aborting\x20CI\x20profile\x20creation.','ljQAr','12zDSVtU','ZcAJi','Enter\x20a\x20new\x20URL\x20(or\x20press\x20enter\x20to\x20keep\x20current):','continue','fetch\x20failed','fIbzP','trim','✓\x20Created\x20settings:\x20','NoRho','scope','trackPhaseStart','15735PwtlGP','http://localhost:3000','slice','IKZRi','Warning:\x20Profile\x20created,\x20but\x20failed\x20to\x20mark\x20it\x20as\x20active.','env','WWAWI','path','OhRtV','73574oTQCRC','4613161HrFABW','Aborted.','QAvhl','about:blank'];_0x58d8=function(){return _0x53aaa6;};return _0x58d8();}
@@ -1 +1 @@
1
- (function(_0x53ba59,_0x56b44d){var _0x5c584e=_0x2fdd,_0xee69b1=_0x53ba59();while(!![]){try{var _0x42bbb2=parseInt(_0x5c584e(0x179))/0x1+-parseInt(_0x5c584e(0x175))/0x2*(-parseInt(_0x5c584e(0x174))/0x3)+parseInt(_0x5c584e(0x171))/0x4*(-parseInt(_0x5c584e(0x16d))/0x5)+-parseInt(_0x5c584e(0x172))/0x6+-parseInt(_0x5c584e(0x16c))/0x7+-parseInt(_0x5c584e(0x16e))/0x8*(-parseInt(_0x5c584e(0x173))/0x9)+parseInt(_0x5c584e(0x176))/0xa*(parseInt(_0x5c584e(0x178))/0xb);if(_0x42bbb2===_0x56b44d)break;else _0xee69b1['push'](_0xee69b1['shift']());}catch(_0xbc3dac){_0xee69b1['push'](_0xee69b1['shift']());}}}(_0x4cb3,0xe8b54));function _0x2fdd(_0x25be0b,_0x17f3a3){_0x25be0b=_0x25be0b-0x16c;var _0x4cb34f=_0x4cb3();var _0x2fdd10=_0x4cb34f[_0x25be0b];return _0x2fdd10;}function _0x4cb3(){var _0x41c826=['9VWLvtT','1353360IpLrna','2alqgud','31630oTehye','session\x20state\x20for\x20you,\x20so\x20encrypted\x20on-disk\x20auth\x20is\x20unnecessary.\x0a','14861JTEZEJ','308859WYcNDi','mmSPS','13291915HZPsoB','45635kefrHh','4313648wxSpYf','ranger\x20profile\x20encrypt-auth\x20is\x20no\x20longer\x20supported.\x20Ranger\x20now\x20manages\x0a','For\x20CI\x20/\x20background\x20agents\x20and\x20other\x20setup\x20options,\x20see:\x0a','780IVttpk','5643696RLcdfw'];_0x4cb3=function(){return _0x41c826;};return _0x4cb3();}export async function authEncrypt(_0x170247){var _0xa809e8=_0x2fdd,_0xdc9747={'tKZVQ':_0xa809e8(0x177),'MFQJf':'To\x20set\x20up\x20a\x20fresh\x20profile,\x20run:\x0a','mmSPS':'\x20\x20ranger\x20profile\x20add\x20<name>\x0a','JjcFq':'\x20\x20https://docs.ranger.net/main/concepts/profiles'};console['error'](_0xa809e8(0x16f)+_0xdc9747['tKZVQ']+'\x0a'+_0xdc9747['MFQJf']+_0xdc9747[_0xa809e8(0x17a)]+'\x0a'+_0xa809e8(0x170)+_0xdc9747['JjcFq']),process['exit'](0x1);}
1
+ (function(_0x2fdb09,_0x11d51c){const _0x3a4618=_0x1a36,_0x528618=_0x2fdb09();while(!![]){try{const _0x11376a=-parseInt(_0x3a4618(0xa4))/0x1*(parseInt(_0x3a4618(0xad))/0x2)+parseInt(_0x3a4618(0xa0))/0x3+parseInt(_0x3a4618(0xaa))/0x4+-parseInt(_0x3a4618(0xa2))/0x5*(-parseInt(_0x3a4618(0xaf))/0x6)+-parseInt(_0x3a4618(0x9c))/0x7+parseInt(_0x3a4618(0xae))/0x8*(-parseInt(_0x3a4618(0xac))/0x9)+-parseInt(_0x3a4618(0xab))/0xa;if(_0x11376a===_0x11d51c)break;else _0x528618['push'](_0x528618['shift']());}catch(_0x1a1261){_0x528618['push'](_0x528618['shift']());}}}(_0x1aed,0x9cab1));import{readFile,writeFile}from'fs/promises';import{join}from'path';import{existsSync}from'fs';import{encrypt}from'./utils/crypto.js';import{getToken}from'./utils/keychain.js';function _0x1aed(){const _0x3c839c=['No\x20auth.json\x20found\x20at\x20','\x0a✓\x20Encrypted\x20auth\x20saved\x20to:\x20','1035366iaiPSV','VEWFd','255BhwUjZ','\x22\x20not\x20found.\x20Run\x20first:\x20ranger\x20profile\x20add\x20','2447saygcq','.enc','uALpK','No\x20API\x20token\x20found.\x20Run:\x20ranger\x20setup\x20[token]','.\x20Run\x20first:\x20ranger\x20profile\x20add\x20with\x20authentication,\x20or\x20ranger\x20profile\x20update','log','4655812JVpxfN','2313950UlbRoP','5554935DPPUlx','16VbCyBH','8WHzBoK','3480MmzvMQ','201292JWwyAm','YLJzN'];_0x1aed=function(){return _0x3c839c;};return _0x1aed();}import{getEnvDir}from'./utils/settings.js';function _0x1a36(_0x157993,_0xab2c41){_0x157993=_0x157993-0x9c;const _0x1aed84=_0x1aed();let _0x1a3672=_0x1aed84[_0x157993];return _0x1a3672;}export async function authEncrypt(_0x2eb997){const _0x5253c9=_0x1a36,_0x21485a={'uALpK':function(_0x3f4164,_0x3f6f82){return _0x3f4164(_0x3f6f82);},'YLJzN':function(_0x194bec,_0x2e4b71){return _0x194bec(_0x2e4b71);},'VEWFd':function(_0x232c74,_0x40e60d,_0x3fdf5b){return _0x232c74(_0x40e60d,_0x3fdf5b);}},_0x1702ee=_0x21485a[_0x5253c9(0xa6)](getEnvDir,_0x2eb997),_0x235553=join(_0x1702ee,'auth.json'),_0x3e87a0=_0x235553+_0x5253c9(0xa5);if(!existsSync(_0x1702ee))throw new Error('Profile\x20\x22'+_0x2eb997+_0x5253c9(0xa3)+_0x2eb997);if(!_0x21485a[_0x5253c9(0x9d)](existsSync,_0x235553))throw new Error(_0x5253c9(0x9e)+_0x235553+_0x5253c9(0xa8));const _0x29c548=await getToken();if(!_0x29c548)throw new Error(_0x5253c9(0xa7));const _0x1f1d71=await readFile(_0x235553,'utf-8'),_0x43953a=_0x21485a[_0x5253c9(0xa1)](encrypt,_0x1f1d71,_0x29c548);await writeFile(_0x3e87a0,_0x43953a),console[_0x5253c9(0xa9)](_0x5253c9(0x9f)+_0x3e87a0),console[_0x5253c9(0xa9)]('\x20\x20You\x20can\x20safely\x20commit\x20this\x20file\x20to\x20git.'),console[_0x5253c9(0xa9)]('\x20\x20Run\x20ranger\x20setup\x20in\x20CI\x20to\x20decrypt\x20at\x20runtime.'),_0x21485a['YLJzN'](existsSync,_0x3e87a0)&&(console[_0x5253c9(0xa9)]('\x0a\x20\x20The\x20plaintext\x20auth.json\x20is\x20gitignored\x20for\x20security.'),console['log']('\x20\x20The\x20encrypted\x20auth.json.enc\x20can\x20be\x20committed.'));}
@@ -1 +1 @@
1
- const _0x1cade7=_0x3912;(function(_0x596813,_0x570e21){const _0xce5c86=_0x3912,_0xb73c59=_0x596813();while(!![]){try{const _0x7e8988=parseInt(_0xce5c86(0x16f))/0x1+parseInt(_0xce5c86(0x171))/0x2*(-parseInt(_0xce5c86(0x16c))/0x3)+-parseInt(_0xce5c86(0x170))/0x4+-parseInt(_0xce5c86(0x18b))/0x5*(parseInt(_0xce5c86(0x178))/0x6)+parseInt(_0xce5c86(0x166))/0x7+parseInt(_0xce5c86(0x16e))/0x8*(-parseInt(_0xce5c86(0x172))/0x9)+-parseInt(_0xce5c86(0x189))/0xa*(parseInt(_0xce5c86(0x164))/0xb);if(_0x7e8988===_0x570e21)break;else _0xb73c59['push'](_0xb73c59['shift']());}catch(_0x589181){_0xb73c59['push'](_0xb73c59['shift']());}}}(_0x5c92,0xd19f9));import{rm,readFile,writeFile}from'fs/promises';import{join}from'path';import{existsSync}from'fs';import{spawn}from'child_process';function _0x3912(_0x569125,_0x433c4d){_0x569125=_0x569125-0x15f;const _0x5c9253=_0x5c92();let _0x39123f=_0x5c9253[_0x569125];return _0x39123f;}import{deleteAllCredentials}from'./utils/keychain.js';import{getProjectRoot,getProjectSkillsDir,getUserSkillsDir}from'./utils/claudeConfig.js';import{getRangerDir}from'./utils/rangerRoot.js';function _0x5c92(){const _0x1571f0=['wSQaC','cgrjj','log','pGpTR','ignore','lhdxb','wWSty','@ranger-testing/opencode-plugin','claude','project','platform','✓\x20Removed\x20OpenCode\x20plugin\x20(user\x20config)','plugin','CzVwr','length','10eSEfqN','filter','45foBZOz','laVEF','user','error','feature-tracker','Nothing\x20to\x20clean\x20up.\x0a','✓\x20Removed\x20user\x20skill:\x20','✓\x20Removed\x20OpenCode\x20project\x20skill:\x20','vNDkc','jgmxM','✓\x20Removed\x20OpenCode\x20user\x20skill:\x20','close','e2e-test-recommender','marketplace','XJiMH','string','7724365HOJfaX','MRTCQ','10198272QwJpBm','✓\x20Removed\x20trailhead\x20marketplace','Gbost','gGHPk','bug-bash','replace','123LhuDlK','vhcYn','2013272xxPlqw','1528123wPeqVY','1539908EkushQ','33738vgsEah','9hTtujs','✓\x20Uninstalled\x20Claude\x20plugin\x20(user\x20scope)','MPOSM','\x0a✅\x20Cleanup\x20complete!\x0a','stringify','utf-8','63948wPilZD','Ofipa'];_0x5c92=function(){return _0x1571f0;};return _0x5c92();}import{getCacheFile}from'./utils/sessionCache.js';import{getOpencodeConfigDir,getOpencodeSkillsDir}from'./utils/opencodeConfig.js';const skillsToRemove=['ranger',_0x1cade7(0x18f),_0x1cade7(0x16a),_0x1cade7(0x160)],opencodePluginName=_0x1cade7(0x181);function parseJsonc(_0x12396a){const _0x2f2176=_0x1cade7,_0x1a9ede=_0x12396a[_0x2f2176(0x16b)](/\/\*[\s\S]*?\*\//g,''),_0x28de11=_0x1a9ede[_0x2f2176(0x16b)](/^\s*\/\/.*$/gm,''),_0x503b8e=_0x28de11['replace'](/,\s*([}\]])/g,'$1');return JSON['parse'](_0x503b8e);}async function removeOpencodePluginConfig(_0x478a7d){const _0x2d992a=_0x1cade7,_0x22dcfa={'lhdxb':function(_0x19d3e7,_0x37b095){return _0x19d3e7!==_0x37b095;},'XkUqZ':_0x2d992a(0x177),'QrPxn':function(_0x29612f,_0xf6a8df){return _0x29612f(_0xf6a8df);},'Gbost':function(_0x59f6a8,_0x47f903){return _0x59f6a8===_0x47f903;},'Ofipa':function(_0x39202f,_0xff02cd,_0x6dd68f){return _0x39202f(_0xff02cd,_0x6dd68f);},'gGHPk':function(_0x3be5a7,_0x4f6b81){return _0x3be5a7+_0x4f6b81;}};if(!existsSync(_0x478a7d))return![];let _0x9a7db5;try{const _0xc008e8=await readFile(_0x478a7d,_0x22dcfa['XkUqZ']);_0x9a7db5=_0x22dcfa['QrPxn'](parseJsonc,_0xc008e8);}catch{return![];}const _0xbbd764=Array['isArray'](_0x9a7db5[_0x2d992a(0x186)])?_0x9a7db5[_0x2d992a(0x186)]:[];if(_0xbbd764[_0x2d992a(0x188)]===0x0)return![];const _0x11cb1d=_0xbbd764[_0x2d992a(0x18a)](_0x4b4f51=>{const _0xfcd229=_0x2d992a;if(typeof _0x4b4f51!==_0xfcd229(0x163))return!![];return _0x22dcfa[_0xfcd229(0x17f)](_0x4b4f51,opencodePluginName);});if(_0x22dcfa[_0x2d992a(0x168)](_0x11cb1d['length'],_0xbbd764['length']))return![];return _0x11cb1d[_0x2d992a(0x188)]===0x0?delete _0x9a7db5[_0x2d992a(0x186)]:_0x9a7db5[_0x2d992a(0x186)]=_0x11cb1d,await _0x22dcfa[_0x2d992a(0x179)](writeFile,_0x478a7d,_0x22dcfa[_0x2d992a(0x169)](JSON[_0x2d992a(0x176)](_0x9a7db5,null,0x2),'\x0a')),!![];}async function uninstallClaudePlugin(_0x111ee5){const _0x3720eb=_0x1cade7,_0x2ccbd7={'eVLOI':function(_0x1daa45,_0x29298a){return _0x1daa45(_0x29298a);},'NdNzA':'plugin','laVEF':'--scope','Kmdgm':function(_0x1ebd50,_0x42e74b,_0x3379bc,_0x37c7a5){return _0x1ebd50(_0x42e74b,_0x3379bc,_0x37c7a5);},'vNDkc':_0x3720eb(0x17e),'vhcYn':function(_0xf5463a){return _0xf5463a();}};return new Promise(_0x5c854e=>{const _0x54b91d=_0x3720eb,_0x28922c=[_0x2ccbd7['NdNzA'],'uninstall','ranger@trailhead'];_0x111ee5&&_0x28922c['push'](_0x2ccbd7[_0x54b91d(0x18c)],_0x111ee5);const _0x1cda7e=_0x2ccbd7['Kmdgm'](spawn,_0x54b91d(0x182),_0x28922c,{'stdio':[_0x2ccbd7[_0x54b91d(0x193)],_0x54b91d(0x17e),'ignore'],'cwd':_0x111ee5?_0x2ccbd7[_0x54b91d(0x16d)](getProjectRoot):undefined,'shell':process[_0x54b91d(0x184)]==='win32'});_0x1cda7e['on']('close',_0x27b1a0=>{_0x5c854e(_0x27b1a0===0x0);}),_0x1cda7e['on'](_0x54b91d(0x18e),()=>{_0x2ccbd7['eVLOI'](_0x5c854e,![]);});});}async function removeMarketplace(){const _0x4a37af=_0x1cade7,_0x29e006={'XJiMH':function(_0x28097d,_0x111e31,_0x2e7e82,_0x3355df){return _0x28097d(_0x111e31,_0x2e7e82,_0x3355df);},'jgmxM':'plugin','FVKbB':'trailhead','CzVwr':'ignore','QTfxS':function(_0x27297a,_0x593f47){return _0x27297a===_0x593f47;},'AeZMC':_0x4a37af(0x15f),'zZRzC':_0x4a37af(0x18e)};return new Promise(_0x1ead6d=>{const _0x1f5b46=_0x4a37af,_0x387e20={'WfNTZ':function(_0x54fbb0,_0x355481){return _0x54fbb0(_0x355481);}},_0x318ed9=_0x29e006[_0x1f5b46(0x162)](spawn,'claude',[_0x29e006[_0x1f5b46(0x194)],_0x1f5b46(0x161),'remove',_0x29e006['FVKbB']],{'stdio':[_0x29e006[_0x1f5b46(0x187)],'ignore','ignore'],'shell':_0x29e006['QTfxS'](process[_0x1f5b46(0x184)],'win32')});_0x318ed9['on'](_0x29e006['AeZMC'],_0x19d5d8=>{_0x1ead6d(_0x19d5d8===0x0);}),_0x318ed9['on'](_0x29e006['zZRzC'],()=>{_0x387e20['WfNTZ'](_0x1ead6d,![]);});});}export async function clean(){const _0x162b09=_0x1cade7,_0x11480f={'bGBaL':function(_0x2558ed){return _0x2558ed();},'cgrjj':function(_0x337235,_0x1d0ce4){return _0x337235(_0x1d0ce4);},'MRTCQ':function(_0x1279a2){return _0x1279a2();},'pGpTR':_0x162b09(0x183),'wWSty':function(_0xda81e8,_0x20397e,_0x1d4703){return _0xda81e8(_0x20397e,_0x1d4703);},'wSQaC':_0x162b09(0x18d),'HjyZJ':'opencode.json','MPOSM':function(_0x537199,_0x5f3b45){return _0x537199(_0x5f3b45);},'NJxft':_0x162b09(0x173),'QsQAT':_0x162b09(0x167),'SqdNv':_0x162b09(0x175)};console['log']('\x0a🧹\x20Cleaning\x20up\x20Ranger\x20artifacts...\x0a');let _0x3ec225=![];try{await _0x11480f['bGBaL'](deleteAllCredentials),console[_0x162b09(0x17c)]('✓\x20Removed\x20stored\x20credentials'),_0x3ec225=!![];}catch{}const _0x572dc0=getCacheFile();existsSync(_0x572dc0)&&(await _0x11480f[_0x162b09(0x17b)](rm,_0x572dc0),_0x3ec225=!![]);const _0x58ca4f=getRangerDir();_0x11480f['cgrjj'](existsSync,_0x58ca4f)&&(await rm(_0x58ca4f,{'recursive':!![]}),console[_0x162b09(0x17c)]('✓\x20Removed\x20.ranger/\x20directory'),_0x3ec225=!![]);const _0x39d533=_0x11480f[_0x162b09(0x165)](getProjectSkillsDir);for(const _0x5bc329 of skillsToRemove){const _0x4dfcc0=join(_0x39d533,_0x5bc329);existsSync(_0x4dfcc0)&&(await rm(_0x4dfcc0,{'recursive':!![]}),console['log']('✓\x20Removed\x20project\x20skill:\x20'+_0x5bc329),_0x3ec225=!![]);}const _0x3681b8=getUserSkillsDir();for(const _0x154be2 of skillsToRemove){const _0x38a672=join(_0x3681b8,_0x154be2);existsSync(_0x38a672)&&(await rm(_0x38a672,{'recursive':!![]}),console['log'](_0x162b09(0x191)+_0x154be2),_0x3ec225=!![]);}const _0x3bd53b=_0x11480f[_0x162b09(0x17b)](getOpencodeSkillsDir,_0x11480f[_0x162b09(0x17d)]);for(const _0x1be5e7 of skillsToRemove){const _0x197d70=_0x11480f[_0x162b09(0x180)](join,_0x3bd53b,_0x1be5e7);existsSync(_0x197d70)&&(await _0x11480f['wWSty'](rm,_0x197d70,{'recursive':!![]}),console[_0x162b09(0x17c)](_0x162b09(0x192)+_0x1be5e7),_0x3ec225=!![]);}const _0x543579=getOpencodeSkillsDir(_0x11480f['wSQaC']);for(const _0x291413 of skillsToRemove){const _0x4c4b3b=_0x11480f['wWSty'](join,_0x543579,_0x291413);existsSync(_0x4c4b3b)&&(await rm(_0x4c4b3b,{'recursive':!![]}),console['log'](_0x162b09(0x195)+_0x291413),_0x3ec225=!![]);}const _0x5d17c=join(getOpencodeConfigDir('project'),_0x11480f['HjyZJ']);await _0x11480f['cgrjj'](removeOpencodePluginConfig,_0x5d17c)&&(console[_0x162b09(0x17c)]('✓\x20Removed\x20OpenCode\x20plugin\x20(project\x20config)'),_0x3ec225=!![]);const _0xe7a664=join(_0x11480f['MPOSM'](getOpencodeConfigDir,_0x11480f[_0x162b09(0x17a)]),'opencode.json');await _0x11480f['MPOSM'](removeOpencodePluginConfig,_0xe7a664)&&(console[_0x162b09(0x17c)](_0x162b09(0x185)),_0x3ec225=!![]);const _0x58fd78=await uninstallClaudePlugin();_0x58fd78&&(console[_0x162b09(0x17c)](_0x11480f['NJxft']),_0x3ec225=!![]);const _0x8371e=await _0x11480f[_0x162b09(0x174)](uninstallClaudePlugin,_0x11480f['pGpTR']);_0x8371e&&(console[_0x162b09(0x17c)]('✓\x20Uninstalled\x20Claude\x20plugin\x20(project\x20scope)'),_0x3ec225=!![]);const _0x924c5a=await removeMarketplace();_0x924c5a&&(console['log'](_0x11480f['QsQAT']),_0x3ec225=!![]),_0x3ec225?console['log'](_0x11480f['SqdNv']):console['log'](_0x162b09(0x190));}
1
+ const _0x3fe56e=_0x43fd;(function(_0x112cee,_0x596709){const _0x29f1b7=_0x43fd,_0x454f74=_0x112cee();while(!![]){try{const _0x50a7f3=parseInt(_0x29f1b7(0xdd))/0x1*(parseInt(_0x29f1b7(0xdc))/0x2)+parseInt(_0x29f1b7(0xff))/0x3*(-parseInt(_0x29f1b7(0xda))/0x4)+-parseInt(_0x29f1b7(0xe1))/0x5*(-parseInt(_0x29f1b7(0xd5))/0x6)+parseInt(_0x29f1b7(0xec))/0x7*(-parseInt(_0x29f1b7(0xe8))/0x8)+parseInt(_0x29f1b7(0xfd))/0x9*(parseInt(_0x29f1b7(0xef))/0xa)+-parseInt(_0x29f1b7(0xe6))/0xb*(parseInt(_0x29f1b7(0x10e))/0xc)+-parseInt(_0x29f1b7(0xfc))/0xd;if(_0x50a7f3===_0x596709)break;else _0x454f74['push'](_0x454f74['shift']());}catch(_0x57366f){_0x454f74['push'](_0x454f74['shift']());}}}(_0x35f7,0xca032));function _0x35f7(){const _0x5dc3cd=['nxdTh','string','✓\x20Removed\x20stored\x20credentials','772mmTOzd','project','2jMVyyR','1569044oaTeqj','✓\x20Removed\x20user\x20skill:\x20','RdqwO','replace','30jmKxtg','QLabG','close','HeaAU','feature-tracker','1535413DBHUMc','noBKQ','16rPghUs','koOBF','platform','✓\x20Removed\x20OpenCode\x20user\x20skill:\x20','1090327shcRBD','filter','✓\x20Removed\x20OpenCode\x20plugin\x20(project\x20config)','88710EWlrwT','nzewU','ranger@trailhead','bug-bash','pkOZf','akwPy','zpSLD','prlaD','e2e-test-recommender','plugin','pipe','error','claude','3819257vRbqmA','90PsbHfq','remove','297tWgBYt','jlJNh','UFjMl','PMVEz','\x0a🧹\x20Cleaning\x20up\x20Ranger\x20artifacts...\x0a','length','✓\x20Removed\x20OpenCode\x20plugin\x20(user\x20config)','AtqHG','win32','Equzl','log','JEyjd','NlGET','QhHCZ','IYIUM','24RjOEBM','\x0a✅\x20Cleanup\x20complete!\x0a','dWdlq','ScPoQ','tJZUZ','73272YJIvlt','✓\x20Removed\x20.ranger/\x20directory'];_0x35f7=function(){return _0x5dc3cd;};return _0x35f7();}import{rm,readFile,writeFile}from'fs/promises';import{join}from'path';function _0x43fd(_0x4ead94,_0x45fd59){_0x4ead94=_0x4ead94-0xd2;const _0x35f7cb=_0x35f7();let _0x43fdd3=_0x35f7cb[_0x4ead94];return _0x43fdd3;}import{existsSync}from'fs';import{spawn}from'child_process';import{deleteAllCredentials}from'./utils/keychain.js';import{getProjectSkillsDir,getUserSkillsDir}from'./utils/claudeConfig.js';import{getRangerDir}from'./utils/rangerRoot.js';import{getCacheFile}from'./utils/sessionCache.js';import{getOpencodeConfigDir,getOpencodeSkillsDir}from'./utils/opencodeConfig.js';const skillsToRemove=['ranger',_0x3fe56e(0xe5),_0x3fe56e(0xf2),_0x3fe56e(0xf7)],opencodePluginName='@ranger-testing/opencode-plugin';function parseJsonc(_0x14427e){const _0x416cc6=_0x3fe56e,_0x4db217=_0x14427e['replace'](/\/\*[\s\S]*?\*\//g,''),_0x31e19c=_0x4db217[_0x416cc6(0xe0)](/^\s*\/\/.*$/gm,''),_0x438fec=_0x31e19c['replace'](/,\s*([}\]])/g,'$1');return JSON['parse'](_0x438fec);}async function removeOpencodePluginConfig(_0x552ec9){const _0x29323e=_0x3fe56e,_0x300b82={'dWdlq':_0x29323e(0xd8),'jlJNh':function(_0x32c3e9,_0xf29790){return _0x32c3e9(_0xf29790);},'PMzpe':'utf-8','Uefuu':function(_0x87f5f3,_0xe7f38a){return _0x87f5f3(_0xe7f38a);},'kHzdX':function(_0x2a83d7,_0x4be4c9,_0x225c16){return _0x2a83d7(_0x4be4c9,_0x225c16);}};if(!_0x300b82[_0x29323e(0x100)](existsSync,_0x552ec9))return![];let _0x44090b;try{const _0x23ef6b=await readFile(_0x552ec9,_0x300b82['PMzpe']);_0x44090b=_0x300b82['Uefuu'](parseJsonc,_0x23ef6b);}catch{return![];}const _0xe5cdc8=Array['isArray'](_0x44090b[_0x29323e(0xf8)])?_0x44090b[_0x29323e(0xf8)]:[];if(_0xe5cdc8[_0x29323e(0x104)]===0x0)return![];const _0x555c8c=_0xe5cdc8[_0x29323e(0xed)](_0xfd70a6=>{const _0x2a96d6=_0x29323e;if(typeof _0xfd70a6!==_0x300b82[_0x2a96d6(0xd2)])return!![];return _0xfd70a6!==opencodePluginName;});if(_0x555c8c['length']===_0xe5cdc8[_0x29323e(0x104)])return![];return _0x555c8c['length']===0x0?delete _0x44090b[_0x29323e(0xf8)]:_0x44090b['plugin']=_0x555c8c,await _0x300b82['kHzdX'](writeFile,_0x552ec9,JSON['stringify'](_0x44090b,null,0x2)+'\x0a'),!![];}async function uninstallClaudePlugin(_0x1fc935){const _0x321b8b=_0x3fe56e,_0x4ee2fb={'gcEOs':function(_0x5655da,_0x2a04b7){return _0x5655da(_0x2a04b7);},'nzewU':function(_0x26d88d,_0x3caba2){return _0x26d88d===_0x3caba2;},'tPsUc':function(_0x13d8f8,_0x4c66f9){return _0x13d8f8(_0x4c66f9);},'JEyjd':_0x321b8b(0xf8),'ScPoQ':function(_0x5e658f,_0x317af7,_0x288a33,_0x13f4ec){return _0x5e658f(_0x317af7,_0x288a33,_0x13f4ec);},'yhaar':'claude','eAycn':_0x321b8b(0x107),'akwPy':_0x321b8b(0xe3)};return new Promise(_0x1e98ad=>{const _0x4c8552=_0x321b8b,_0x3f42c8={'CTNAa':function(_0x54af25,_0x295a3e){return _0x4ee2fb['gcEOs'](_0x54af25,_0x295a3e);},'nxdTh':function(_0x39862f,_0x215304){const _0x13c436=_0x43fd;return _0x4ee2fb[_0x13c436(0xf0)](_0x39862f,_0x215304);},'NlGET':function(_0x2e2403,_0x5ee547){return _0x4ee2fb['tPsUc'](_0x2e2403,_0x5ee547);}},_0x36bb77=[_0x4ee2fb[_0x4c8552(0x10a)],'uninstall',_0x4c8552(0xf1)];_0x1fc935&&_0x36bb77['push']('--scope',_0x1fc935);const _0x592104=_0x4ee2fb[_0x4c8552(0xd3)](spawn,_0x4ee2fb['yhaar'],_0x36bb77,{'stdio':'pipe','shell':process[_0x4c8552(0xea)]===_0x4ee2fb['eAycn']});_0x592104['on'](_0x4ee2fb[_0x4c8552(0xf4)],_0x349ef8=>{const _0x46f67b=_0x4c8552;_0x3f42c8['CTNAa'](_0x1e98ad,_0x3f42c8[_0x46f67b(0xd7)](_0x349ef8,0x0));}),_0x592104['on'](_0x4c8552(0xfa),()=>{const _0x11c3c7=_0x4c8552;_0x3f42c8[_0x11c3c7(0x10b)](_0x1e98ad,![]);});});}async function removeMarketplace(){const _0x1f5b38=_0x3fe56e,_0x21daa2={'XnMLl':function(_0x362179,_0x16ac66){return _0x362179(_0x16ac66);},'sFxAr':function(_0x43e0ec,_0xc1a3e7){return _0x43e0ec===_0xc1a3e7;},'pkOZf':function(_0x4428ac,_0x2e6455,_0x405572,_0x1d8c7d){return _0x4428ac(_0x2e6455,_0x405572,_0x1d8c7d);},'NHLSS':_0x1f5b38(0xfb),'hEpbk':'marketplace','PdhLL':'trailhead','UFjMl':_0x1f5b38(0xf9),'Equzl':'win32','QhHCZ':'error'};return new Promise(_0x5b40e8=>{const _0x24fe29=_0x1f5b38,_0x4d2c67=_0x21daa2[_0x24fe29(0xf3)](spawn,_0x21daa2['NHLSS'],[_0x24fe29(0xf8),_0x21daa2['hEpbk'],_0x24fe29(0xfe),_0x21daa2['PdhLL']],{'stdio':_0x21daa2[_0x24fe29(0x101)],'shell':process['platform']===_0x21daa2[_0x24fe29(0x108)]});_0x4d2c67['on']('close',_0x4c0c63=>{_0x21daa2['XnMLl'](_0x5b40e8,_0x21daa2['sFxAr'](_0x4c0c63,0x0));}),_0x4d2c67['on'](_0x21daa2[_0x24fe29(0x10c)],()=>{_0x5b40e8(![]);});});}export async function clean(){const _0x305343=_0x3fe56e,_0x393ca7={'gdvtH':function(_0x4b9194){return _0x4b9194();},'prlaD':function(_0x1fa1c1,_0x51d888){return _0x1fa1c1(_0x51d888);},'SQTaM':function(_0x57f9f7){return _0x57f9f7();},'tJZUZ':function(_0x1f9ec9,_0x51d898,_0x226cd7){return _0x1f9ec9(_0x51d898,_0x226cd7);},'FCEWl':_0x305343(0xd6),'AtqHG':function(_0xcd7fae,_0x2513fb){return _0xcd7fae(_0x2513fb);},'koOBF':'project','tkQeN':function(_0x1f3f52,_0x5783ee,_0x341906){return _0x1f3f52(_0x5783ee,_0x341906);},'IYIUM':'user','noBKQ':function(_0x5c7a08,_0x76b366,_0x492e97){return _0x5c7a08(_0x76b366,_0x492e97);},'PMVEz':function(_0x2e05e1,_0x1c9c97){return _0x2e05e1(_0x1c9c97);},'RdqwO':_0x305343(0xee),'HeaAU':function(_0x41446b,_0x2c5059){return _0x41446b(_0x2c5059);},'DkIMy':'opencode.json','ENhor':'✓\x20Uninstalled\x20Claude\x20plugin\x20(user\x20scope)','zpSLD':function(_0x28571b){return _0x28571b();},'QLabG':_0x305343(0x10f)};console[_0x305343(0x109)](_0x305343(0x103));let _0xc26dbd=![];try{await deleteAllCredentials(),console['log'](_0x305343(0xd9)),_0xc26dbd=!![];}catch{}const _0x403bde=_0x393ca7['gdvtH'](getCacheFile);_0x393ca7['prlaD'](existsSync,_0x403bde)&&(await _0x393ca7[_0x305343(0xf6)](rm,_0x403bde),_0xc26dbd=!![]);const _0x4d528b=_0x393ca7['SQTaM'](getRangerDir);_0x393ca7[_0x305343(0xf6)](existsSync,_0x4d528b)&&(await _0x393ca7[_0x305343(0xd4)](rm,_0x4d528b,{'recursive':!![]}),console['log'](_0x393ca7['FCEWl']),_0xc26dbd=!![]);const _0x1a9a5c=getProjectSkillsDir();for(const _0x2f4bc6 of skillsToRemove){const _0xcb0687=join(_0x1a9a5c,_0x2f4bc6);_0x393ca7[_0x305343(0x106)](existsSync,_0xcb0687)&&(await _0x393ca7['tJZUZ'](rm,_0xcb0687,{'recursive':!![]}),console[_0x305343(0x109)]('✓\x20Removed\x20project\x20skill:\x20'+_0x2f4bc6),_0xc26dbd=!![]);}const _0x579769=getUserSkillsDir();for(const _0x87af67 of skillsToRemove){const _0x1a2f9f=join(_0x579769,_0x87af67);existsSync(_0x1a2f9f)&&(await rm(_0x1a2f9f,{'recursive':!![]}),console[_0x305343(0x109)](_0x305343(0xde)+_0x87af67),_0xc26dbd=!![]);}const _0x2281a4=getOpencodeSkillsDir(_0x393ca7[_0x305343(0xe9)]);for(const _0xd6134a of skillsToRemove){const _0x5cabb7=_0x393ca7['tJZUZ'](join,_0x2281a4,_0xd6134a);existsSync(_0x5cabb7)&&(await _0x393ca7['tkQeN'](rm,_0x5cabb7,{'recursive':!![]}),console['log']('✓\x20Removed\x20OpenCode\x20project\x20skill:\x20'+_0xd6134a),_0xc26dbd=!![]);}const _0x57c88f=_0x393ca7[_0x305343(0x106)](getOpencodeSkillsDir,_0x393ca7[_0x305343(0x10d)]);for(const _0x3e21ac of skillsToRemove){const _0x126f4d=join(_0x57c88f,_0x3e21ac);_0x393ca7['prlaD'](existsSync,_0x126f4d)&&(await rm(_0x126f4d,{'recursive':!![]}),console[_0x305343(0x109)](_0x305343(0xeb)+_0x3e21ac),_0xc26dbd=!![]);}const _0x3f9721=_0x393ca7[_0x305343(0xe7)](join,_0x393ca7['AtqHG'](getOpencodeConfigDir,'project'),'opencode.json');await _0x393ca7['PMVEz'](removeOpencodePluginConfig,_0x3f9721)&&(console[_0x305343(0x109)](_0x393ca7[_0x305343(0xdf)]),_0xc26dbd=!![]);const _0x1bd865=_0x393ca7[_0x305343(0xe7)](join,_0x393ca7[_0x305343(0xe4)](getOpencodeConfigDir,_0x393ca7[_0x305343(0x10d)]),_0x393ca7['DkIMy']);await removeOpencodePluginConfig(_0x1bd865)&&(console['log'](_0x305343(0x105)),_0xc26dbd=!![]);const _0x395ddc=await uninstallClaudePlugin();_0x395ddc&&(console[_0x305343(0x109)](_0x393ca7['ENhor']),_0xc26dbd=!![]);const _0x3c47c8=await _0x393ca7[_0x305343(0x102)](uninstallClaudePlugin,_0x305343(0xdb));_0x3c47c8&&(console['log']('✓\x20Uninstalled\x20Claude\x20plugin\x20(project\x20scope)'),_0xc26dbd=!![]);const _0x15585d=await _0x393ca7[_0x305343(0xf5)](removeMarketplace);_0x15585d&&(console[_0x305343(0x109)]('✓\x20Removed\x20trailhead\x20marketplace'),_0xc26dbd=!![]),_0xc26dbd?console['log'](_0x393ca7[_0x305343(0xe2)]):console[_0x305343(0x109)]('Nothing\x20to\x20clean\x20up.\x0a');}
@@ -1 +1 @@
1
- const _0x4343d1=_0x1133;(function(_0x2d65cc,_0x50e81e){const _0x1cbbb6=_0x1133,_0x58aeb2=_0x2d65cc();while(!![]){try{const _0x24b0a4=-parseInt(_0x1cbbb6(0x18c))/0x1+parseInt(_0x1cbbb6(0x191))/0x2*(parseInt(_0x1cbbb6(0x184))/0x3)+parseInt(_0x1cbbb6(0x189))/0x4+parseInt(_0x1cbbb6(0x1b1))/0x5+-parseInt(_0x1cbbb6(0x1a9))/0x6+parseInt(_0x1cbbb6(0x1a7))/0x7+-parseInt(_0x1cbbb6(0x182))/0x8*(-parseInt(_0x1cbbb6(0x1a4))/0x9);if(_0x24b0a4===_0x50e81e)break;else _0x58aeb2['push'](_0x58aeb2['shift']());}catch(_0x22ac17){_0x58aeb2['push'](_0x58aeb2['shift']());}}}(_0x11f7,0xe3468));import{existsSync}from'fs';import{loadSettings,getNestedValue,deleteNestedValue,formatSettings,getSettingsPath,getEnvDir}from'./utils/settings.js';import{fetchCloudProfile}from'./utils/cloudProfile.js';import{mergeCloudProfileSettings,readProfileOverrides,resetProfileOverrides,setProfileOverride,unsetProfileOverride}from'./utils/projectsConfig.js';function _0x1133(_0x591d76,_0x348dd9){_0x591d76=_0x591d76-0x17c;const _0x11f70d=_0x11f7();let _0x1133a=_0x11f70d[_0x591d76];return _0x1133a;}const BOOLEAN_KEYS=[_0x4343d1(0x185),'allowInsecureLocalhost'];function parseLocalValue(_0x9b7aea,_0x284634){const _0x48e0be=_0x4343d1,_0x2de147={'NZmRU':function(_0x99aeb7,_0x2a75a2){return _0x99aeb7===_0x2a75a2;}};if(BOOLEAN_KEYS[_0x48e0be(0x1b4)](_0x9b7aea)){if(_0x2de147[_0x48e0be(0x1aa)](_0x284634,'true'))return!![];if(_0x284634==='false')return![];throw new Error(_0x48e0be(0x196)+_0x9b7aea+_0x48e0be(0x1a2));}return _0x284634;}function parseOverrideValue(_0x19257e){const _0x5c3c4e=_0x4343d1,_0x8fd4b2={'FfVzR':function(_0x1bde8f,_0x39bafb){return _0x1bde8f===_0x39bafb;},'yQuXL':_0x5c3c4e(0x1ab),'DZvXw':'false','PkQKK':'null','FIdLZ':function(_0xbcc118,_0x9bf43){return _0xbcc118(_0x9bf43);}};if(_0x8fd4b2['FfVzR'](_0x19257e,_0x8fd4b2['yQuXL']))return!![];if(_0x8fd4b2[_0x5c3c4e(0x199)](_0x19257e,_0x8fd4b2['DZvXw']))return![];if(_0x19257e===_0x8fd4b2['PkQKK'])return null;if(_0x19257e==='undefined')return undefined;if(/^-?\d+$/['test'](_0x19257e)){const _0x4275d5=_0x8fd4b2['FIdLZ'](Number,_0x19257e);if(Number['isSafeInteger'](_0x4275d5))return _0x4275d5;}if(/^-?\d+\.\d+$/['test'](_0x19257e)){const _0x446861=Number(_0x19257e);if(!Number[_0x5c3c4e(0x1b0)](_0x446861))return _0x446861;}const _0x22bfa4=_0x19257e['trim']();if(_0x22bfa4[_0x5c3c4e(0x1ad)]('{')&&_0x22bfa4['endsWith']('}')||_0x22bfa4['startsWith']('[')&&_0x22bfa4['endsWith'](']'))try{return JSON[_0x5c3c4e(0x19a)](_0x22bfa4);}catch{}return _0x19257e;}async function resolveProfileTarget(_0x9dcee3){const _0xec17eb=_0x4343d1,_0x142d73={'rLMrQ':function(_0x1a8019,_0x245e7d){return _0x1a8019(_0x245e7d);},'mFura':function(_0x4cf18f,_0x484789){return _0x4cf18f(_0x484789);},'XoEAl':'cloud','Lleey':_0xec17eb(0x17f)},_0x256d82=_0x142d73['rLMrQ'](existsSync,getEnvDir(_0x9dcee3));let _0x350a5e=![];try{const _0x5afb4b=await _0x142d73['mFura'](fetchCloudProfile,_0x9dcee3);_0x350a5e=Boolean(_0x5afb4b);}catch{}if(_0x350a5e)return{'kind':_0x142d73[_0xec17eb(0x17c)],'alsoExistsElsewhere':_0x256d82};if(_0x256d82)return{'kind':_0x142d73['Lleey'],'alsoExistsElsewhere':![]};throw new Error(_0xec17eb(0x1b2)+_0x9dcee3+_0xec17eb(0x19f)+_0x9dcee3);}function printDualExistsHint(_0x548fd8){console['log']('\x20\x20Note:\x20\x22'+_0x548fd8+'\x22\x20also\x20exists\x20as\x20a\x20local\x20profile;\x20editing\x20the\x20cloud\x20profile.');}function getProjectPath(){const _0x28e590=_0x4343d1;return process[_0x28e590(0x18a)]();}async function loadEffectiveCloudSettings(_0x5f1971){const _0x466607=_0x4343d1,_0x4deed4={'aCJVh':function(_0x39ea3c,_0x37c382){return _0x39ea3c(_0x37c382);},'rwtep':function(_0xeb9ebd){return _0xeb9ebd();}},_0x189cde=await _0x4deed4[_0x466607(0x1a3)](fetchCloudProfile,_0x5f1971),_0x3adf44=readProfileOverrides(_0x4deed4[_0x466607(0x18d)](getProjectPath),_0x5f1971);return mergeCloudProfileSettings(_0x189cde?.[_0x466607(0x17d)]??{},_0x3adf44??undefined);}export async function configSet(_0xbb5401,_0x8acc0e,_0x474cbe){const _0x4468e3=_0x4343d1,_0x26ad8f={'YTiKJ':function(_0x26adf5,_0x1a5973){return _0x26adf5(_0x1a5973);},'lZHWw':'cloud','wNsBN':function(_0x1eb63a){return _0x1eb63a();}},_0x26c953=await _0x26ad8f[_0x4468e3(0x1a0)](resolveProfileTarget,_0xbb5401);if(_0x26c953[_0x4468e3(0x1b3)]===_0x26ad8f[_0x4468e3(0x188)]){if(_0x26c953[_0x4468e3(0x194)])printDualExistsHint(_0xbb5401);const _0x5cf888=_0x26ad8f['YTiKJ'](parseOverrideValue,_0x474cbe);setProfileOverride(_0x26ad8f['wNsBN'](getProjectPath),_0xbb5401,_0x8acc0e,_0x5cf888),console['log'](_0x4468e3(0x193)+_0x8acc0e+_0x4468e3(0x1a8)+JSON[_0x4468e3(0x18e)](_0x5cf888)+'\x20for\x20\x22'+_0xbb5401+'\x22');return;}const _0x265f78=parseLocalValue(_0x8acc0e,_0x474cbe);setProfileOverride(getProjectPath(),_0xbb5401,_0x8acc0e,_0x265f78),console[_0x4468e3(0x187)]('Set\x20'+_0x8acc0e+'\x20=\x20'+_0x265f78+'\x20for\x20\x22'+_0xbb5401+'\x22');}export async function configGet(_0x3e9b93,_0x25e93e){const _0x1924fa=_0x4343d1,_0xb754a3={'PyenQ':function(_0x33ccee,_0x57ebee){return _0x33ccee(_0x57ebee);},'UxUuf':function(_0x4088f4,_0xccdd50){return _0x4088f4===_0xccdd50;},'FfCbw':_0x1924fa(0x1af)},_0x28ae44=await _0xb754a3[_0x1924fa(0x186)](resolveProfileTarget,_0x3e9b93);if(_0x28ae44[_0x1924fa(0x1b3)]===_0x1924fa(0x18f)){const _0x14d12f=await _0xb754a3['PyenQ'](loadEffectiveCloudSettings,_0x3e9b93),_0x574261=getNestedValue(_0x14d12f,_0x25e93e);if(_0x574261===undefined)console[_0x1924fa(0x187)](_0x1924fa(0x19c));else _0xb754a3['UxUuf'](typeof _0x574261,_0x1924fa(0x1af))?console['log'](JSON['stringify'](_0x574261,null,0x2)):console['log'](_0x574261);return;}const _0x5b30cc=await loadSettings(_0x3e9b93),_0x32107d=getNestedValue(_0x5b30cc,_0x25e93e);if(_0x32107d===undefined)console['log'](_0x1924fa(0x19c));else _0xb754a3['UxUuf'](typeof _0x32107d,_0xb754a3[_0x1924fa(0x19b)])?console['log'](JSON[_0x1924fa(0x18e)](_0x32107d,null,0x2)):console['log'](_0x32107d);}function _0x11f7(){const _0x2539fc=['aCJVh','9okIDSo','Removed\x20','\x22\x20and\x20cannot\x20be\x20unset;\x20the\x20legacy\x20tree\x20is\x20read-only\x20under\x20cloud\x20profiles.','3084599BDZHPP','\x20=\x20','10738098sFrptV','NZmRU','true','bhroy','startsWith','\x20<key>\x22\x20to\x20remove\x20individual\x20values.','object','isNaN','450425AZzeVA','Profile\x20\x22','kind','includes','XoEAl','settings','\x22\x20lives\x20in\x20the\x20legacy\x20settings\x20file\x20for\x20\x22','local','xXWBc','length','14622536ucMHFj','No\x20configuration\x20set\x20for\x20\x22','87mddoYd','headless','PyenQ','log','lZHWw','2517820YYfUdr','cwd','Key\x20\x22','1744207PPkdyb','rwtep','stringify','cloud','nsgIC','101848KCGNpB','FRvFx','Set\x20','alsoExistsElsewhere','Cleared\x20local\x20overrides\x20for\x20\x22','Invalid\x20value\x20for\x20','\x22\x20is\x20a\x20local\x20profile.\x20Use\x20\x22ranger\x20profile\x20config\x20unset\x20','RMBJB','FfVzR','parse','FfCbw','(not\x20set)','\x20for\x20\x22','amaXa','\x22\x20does\x20not\x20exist.\x20Run:\x20ranger\x20profile\x20add\x20','YTiKJ','ywRPV',':\x20expected\x20\x22true\x22\x20or\x20\x22false\x22'];_0x11f7=function(){return _0x2539fc;};return _0x11f7();}export async function configList(_0x271b9b){const _0x59c964=_0x4343d1,_0x1e67a5={'awBpr':'cloud','FofSs':function(_0x2112a8,_0x1746be){return _0x2112a8(_0x1746be);},'ucwBS':function(_0x36ac0a,_0x3c742e){return _0x36ac0a===_0x3c742e;},'mqeWd':function(_0x37d547,_0x119ca5){return _0x37d547(_0x119ca5);},'FEqdf':function(_0x2da2d8,_0xffb351){return _0x2da2d8(_0xffb351);}},_0x341ffb=await resolveProfileTarget(_0x271b9b);if(_0x341ffb['kind']===_0x1e67a5['awBpr']){const _0x424003=await _0x1e67a5['FofSs'](loadEffectiveCloudSettings,_0x271b9b);if(!_0x424003||_0x1e67a5['ucwBS'](Object['keys'](_0x424003)[_0x59c964(0x181)],0x0)){console['log'](_0x59c964(0x183)+_0x271b9b+'\x22');return;}console['log'](JSON[_0x59c964(0x18e)](_0x424003,null,0x2));return;}const _0x5c3174=_0x1e67a5['mqeWd'](getSettingsPath,_0x271b9b);if(!_0x1e67a5['FEqdf'](existsSync,_0x5c3174)){console[_0x59c964(0x187)](_0x59c964(0x183)+_0x271b9b+'\x22');return;}const _0x397dd3=await loadSettings(_0x271b9b),_0x4fba46=formatSettings(_0x397dd3);!_0x4fba46?console[_0x59c964(0x187)](_0x59c964(0x183)+_0x271b9b+'\x22'):console[_0x59c964(0x187)](_0x4fba46);}export async function configUnset(_0x27ca5d,_0x41ea05){const _0x3d2561=_0x4343d1,_0x32ac3a={'FRvFx':function(_0xd7aaaa,_0x34cd9c){return _0xd7aaaa(_0x34cd9c);},'amaXa':_0x3d2561(0x18f),'ywRPV':function(_0x931acf,_0x2815e7,_0x4cf2a6,_0x44e157){return _0x931acf(_0x2815e7,_0x4cf2a6,_0x44e157);},'nsgIC':function(_0x4d42f3,_0xa5b83d,_0x10c252,_0x578447){return _0x4d42f3(_0xa5b83d,_0x10c252,_0x578447);},'QMLFK':function(_0x17088e,_0x455f04,_0x394843){return _0x17088e(_0x455f04,_0x394843);}},_0x4d6f73=await _0x32ac3a[_0x3d2561(0x192)](resolveProfileTarget,_0x27ca5d);if(_0x4d6f73['kind']===_0x32ac3a[_0x3d2561(0x19e)]){if(_0x4d6f73[_0x3d2561(0x194)])printDualExistsHint(_0x27ca5d);const _0x450249=_0x32ac3a[_0x3d2561(0x1a1)](unsetProfileOverride,getProjectPath(),_0x27ca5d,_0x41ea05);_0x450249?console[_0x3d2561(0x187)](_0x3d2561(0x1a5)+_0x41ea05+_0x3d2561(0x19d)+_0x27ca5d+'\x22'):console['log']('Key\x20\x22'+_0x41ea05+'\x22\x20not\x20found');return;}const _0x10fec0=_0x32ac3a[_0x3d2561(0x190)](unsetProfileOverride,getProjectPath(),_0x27ca5d,_0x41ea05);if(_0x10fec0){console['log']('Removed\x20'+_0x41ea05);return;}const _0x5af632=await loadSettings(_0x27ca5d),_0x3c9443=_0x32ac3a['QMLFK'](deleteNestedValue,_0x5af632,_0x41ea05);_0x3c9443?console['log'](_0x3d2561(0x18b)+_0x41ea05+_0x3d2561(0x17e)+_0x27ca5d+_0x3d2561(0x1a6)):console[_0x3d2561(0x187)]('Key\x20\x22'+_0x41ea05+'\x22\x20not\x20found');}export async function configReset(_0x373c51){const _0x4ca736=_0x4343d1,_0x1d6eab={'xXWBc':function(_0xad427a,_0x35661c){return _0xad427a(_0x35661c);},'RMBJB':_0x4ca736(0x18f),'bhroy':function(_0x717b89,_0x101d35,_0x28dcb2){return _0x717b89(_0x101d35,_0x28dcb2);}},_0x157e45=await _0x1d6eab[_0x4ca736(0x180)](resolveProfileTarget,_0x373c51);if(_0x157e45[_0x4ca736(0x1b3)]===_0x1d6eab[_0x4ca736(0x198)]){_0x1d6eab[_0x4ca736(0x1ac)](resetProfileOverrides,getProjectPath(),_0x373c51),console['log'](_0x4ca736(0x195)+_0x373c51+'\x22');return;}console['log']('\x22'+_0x373c51+_0x4ca736(0x197)+_0x373c51+_0x4ca736(0x1ae));}
1
+ const _0x2a29cb=_0x5187;(function(_0x1b2859,_0x1566ce){const _0x43ab4c=_0x5187,_0x2bd312=_0x1b2859();while(!![]){try{const _0x44cfb8=parseInt(_0x43ab4c(0xef))/0x1*(parseInt(_0x43ab4c(0xf8))/0x2)+-parseInt(_0x43ab4c(0x107))/0x3*(parseInt(_0x43ab4c(0xff))/0x4)+-parseInt(_0x43ab4c(0xf4))/0x5*(parseInt(_0x43ab4c(0x10e))/0x6)+parseInt(_0x43ab4c(0x108))/0x7+-parseInt(_0x43ab4c(0x104))/0x8+-parseInt(_0x43ab4c(0xf2))/0x9*(-parseInt(_0x43ab4c(0x112))/0xa)+-parseInt(_0x43ab4c(0xf9))/0xb*(parseInt(_0x43ab4c(0xfb))/0xc);if(_0x44cfb8===_0x1566ce)break;else _0x2bd312['push'](_0x2bd312['shift']());}catch(_0x18c45f){_0x2bd312['push'](_0x2bd312['shift']());}}}(_0x13fe,0x4757f));import{existsSync}from'fs';import{loadSettings,saveSettings,getNestedValue,setNestedValue,deleteNestedValue,formatSettings,getSettingsPath,getEnvDir}from'./utils/settings.js';function _0x13fe(){const _0x10cd95=['3830080DIGQNX','Profile\x20\x22','stringify','37233nSolPV','3957583SypmNg','UEDSS','\x22\x20does\x20not\x20exist.\x20Run:\x20ranger\x20profile\x20add\x20','nTFVb','true','false','6ybvYxu','headless','No\x20configuration\x20set\x20for\x20\x22','JAPKH','70NzSADn','GpLmH','15CcQAFV','includes','(not\x20set)','485163PcbtcQ','\x22\x20not\x20found','298805xVLXOb','object','\x22\x20does\x20not\x20exist.','log','36020vdvcPW','1336423ExxPzV','EYzfC','12QcmGQx','Set\x20','arckW','TfTjn','84WigRZV','Key\x20\x22','Removed\x20','allowInsecureLocalhost','Invalid\x20value\x20for\x20'];_0x13fe=function(){return _0x10cd95;};return _0x13fe();}function _0x5187(_0x50a4ff,_0x1aeddb){_0x50a4ff=_0x50a4ff-0xef;const _0x13feed=_0x13fe();let _0x5187a3=_0x13feed[_0x50a4ff];return _0x5187a3;}const BOOLEAN_KEYS=[_0x2a29cb(0x10f),_0x2a29cb(0x102)];function parseValue(_0x47609c,_0x4d10a6){const _0x14f6d9=_0x2a29cb,_0x5d1d24={'arckW':function(_0x33f3ca,_0x9b7321){return _0x33f3ca===_0x9b7321;},'UEDSS':_0x14f6d9(0x10c)};if(BOOLEAN_KEYS[_0x14f6d9(0xf0)](_0x47609c)){if(_0x5d1d24[_0x14f6d9(0xfd)](_0x4d10a6,_0x5d1d24[_0x14f6d9(0x109)]))return!![];if(_0x4d10a6===_0x14f6d9(0x10d))return![];throw new Error(_0x14f6d9(0x103)+_0x47609c+':\x20expected\x20\x22true\x22\x20or\x20\x22false\x22');}return _0x4d10a6;}export async function configSet(_0x3881eb,_0x3fd8ea,_0x37968f){const _0x25caf4=_0x2a29cb,_0x2e7dab={'TfTjn':function(_0x4930b6,_0x4ca95e){return _0x4930b6(_0x4ca95e);},'nTFVb':function(_0x4654b0,_0x182477,_0x4ee7d3,_0x4f85bf){return _0x4654b0(_0x182477,_0x4ee7d3,_0x4f85bf);},'Fbgnf':function(_0xf62d0b,_0x5747af,_0x22ee73){return _0xf62d0b(_0x5747af,_0x22ee73);}},_0x5484c6=_0x2e7dab['TfTjn'](getEnvDir,_0x3881eb);if(!_0x2e7dab[_0x25caf4(0xfe)](existsSync,_0x5484c6))throw new Error(_0x25caf4(0x105)+_0x3881eb+_0x25caf4(0x10a)+_0x3881eb);const _0x1c9a19=await loadSettings(_0x3881eb),_0x33b12c=parseValue(_0x3fd8ea,_0x37968f);_0x2e7dab[_0x25caf4(0x10b)](setNestedValue,_0x1c9a19,_0x3fd8ea,_0x33b12c),await _0x2e7dab['Fbgnf'](saveSettings,_0x3881eb,_0x1c9a19),console[_0x25caf4(0xf7)](_0x25caf4(0xfc)+_0x3fd8ea+'\x20=\x20'+_0x33b12c);}export async function configGet(_0x435294,_0x373833){const _0x4def4a=_0x2a29cb,_0x4b0867={'GpLmH':function(_0x4e8521,_0x4f2762){return _0x4e8521(_0x4f2762);},'EYzfC':function(_0x2a487e,_0x2abc4b){return _0x2a487e===_0x2abc4b;}},_0x11e5d4=getEnvDir(_0x435294);if(!_0x4b0867['GpLmH'](existsSync,_0x11e5d4))throw new Error(_0x4def4a(0x105)+_0x435294+_0x4def4a(0xf6));const _0x2f35a6=await _0x4b0867[_0x4def4a(0x113)](loadSettings,_0x435294),_0x18c218=getNestedValue(_0x2f35a6,_0x373833);if(_0x4b0867[_0x4def4a(0xfa)](_0x18c218,undefined))console['log'](_0x4def4a(0xf1));else typeof _0x18c218===_0x4def4a(0xf5)?console['log'](JSON[_0x4def4a(0x106)](_0x18c218,null,0x2)):console['log'](_0x18c218);}export async function configList(_0x520fc){const _0x5401dd=_0x2a29cb,_0x32d951={'JAPKH':function(_0x396b66,_0x1571da){return _0x396b66(_0x1571da);},'DhsXv':function(_0x1c1021,_0x165f4e){return _0x1c1021(_0x165f4e);}},_0x44d868=_0x32d951[_0x5401dd(0x111)](getSettingsPath,_0x520fc);if(!_0x32d951['DhsXv'](existsSync,_0x44d868)){const _0x8c5fd0=_0x32d951['DhsXv'](getEnvDir,_0x520fc);if(!existsSync(_0x8c5fd0))throw new Error('Profile\x20\x22'+_0x520fc+'\x22\x20does\x20not\x20exist.');console[_0x5401dd(0xf7)](_0x5401dd(0x110)+_0x520fc+'\x22');return;}const _0x11a4d8=await loadSettings(_0x520fc),_0x3aaae4=formatSettings(_0x11a4d8);!_0x3aaae4?console['log'](_0x5401dd(0x110)+_0x520fc+'\x22'):console['log'](_0x3aaae4);}export async function configUnset(_0x309d43,_0x2c0595){const _0x4c0c67=_0x2a29cb,_0x3d6635={'BELFq':function(_0x16bfec,_0x2cfa38){return _0x16bfec(_0x2cfa38);}},_0x2f33bf=getEnvDir(_0x309d43);if(!existsSync(_0x2f33bf))throw new Error(_0x4c0c67(0x105)+_0x309d43+'\x22\x20does\x20not\x20exist.');const _0x30c2ab=await _0x3d6635['BELFq'](loadSettings,_0x309d43),_0x5f0dd6=deleteNestedValue(_0x30c2ab,_0x2c0595);_0x5f0dd6?(await saveSettings(_0x309d43,_0x30c2ab),console[_0x4c0c67(0xf7)](_0x4c0c67(0x101)+_0x2c0595)):console['log'](_0x4c0c67(0x100)+_0x2c0595+_0x4c0c67(0xf3));}
@@ -1 +1 @@
1
- const _0x4cb18e=_0x42d8;function _0x42d8(_0x4ef2a0,_0x31d99d){_0x4ef2a0=_0x4ef2a0-0x1c7;const _0x11b954=_0x11b9();let _0x42d8d6=_0x11b954[_0x4ef2a0];return _0x42d8d6;}(function(_0xdb812d,_0x1a3a51){const _0x110464=_0x42d8,_0x355d26=_0xdb812d();while(!![]){try{const _0x1fd3cd=-parseInt(_0x110464(0x1df))/0x1*(parseInt(_0x110464(0x1d5))/0x2)+-parseInt(_0x110464(0x1ca))/0x3+-parseInt(_0x110464(0x1ed))/0x4+-parseInt(_0x110464(0x1d6))/0x5+-parseInt(_0x110464(0x1e2))/0x6+-parseInt(_0x110464(0x1e9))/0x7+parseInt(_0x110464(0x1dd))/0x8;if(_0x1fd3cd===_0x1a3a51)break;else _0x355d26['push'](_0x355d26['shift']());}catch(_0x521b3e){_0x355d26['push'](_0x355d26['shift']());}}}(_0x11b9,0xb7b87));import{readdir,stat}from'fs/promises';import{join}from'path';import{existsSync}from'fs';import{getRangerDir}from'./utils/rangerRoot.js';import{loadSettings}from'./utils/settings.js';import{readActiveProfileName}from'./utils/activeProfile.js';import{listCloudProfiles}from'./utils/cloudProfile.js';const NON_ENV_DIRS=[_0x4cb18e(0x1ea),'bug-bashes',_0x4cb18e(0x1d9),'local','ci'];export async function getEnvNames(){const _0x4245e7=_0x4cb18e,_0x30ca03={'tTGyy':function(_0x5d5b0d){return _0x5d5b0d();},'KyRCU':function(_0x4d5070,_0x242277,_0x25f044){return _0x4d5070(_0x242277,_0x25f044);},'ucMIE':_0x4245e7(0x1e0),'uvztj':function(_0x20453a,_0x4176be){return _0x20453a(_0x4176be);},'PZdCr':function(_0x4b17c5,_0x1a81a4){return _0x4b17c5(_0x1a81a4);},'JkOhV':function(_0xa44b14,_0x788fe3){return _0xa44b14(_0x788fe3);},'vRbab':function(_0x3c66ea,_0x12b33b){return _0x3c66ea(_0x12b33b);},'tTKsD':function(_0x1df6c0,_0x5715ca,_0x2088d8){return _0x1df6c0(_0x5715ca,_0x2088d8);},'HuNxo':'legacy'},_0x10556f=_0x30ca03[_0x4245e7(0x1de)](getRangerDir);if(!existsSync(_0x10556f))return{'envNames':[],'activeEnv':null,'envTypes':{}};const _0x1b194d=await readActiveProfileName(),_0x278b73=[],_0x27b672={},_0x4b8220=_0x30ca03[_0x4245e7(0x1ce)](join,_0x10556f,_0x30ca03['ucMIE']);if(existsSync(_0x4b8220)){const _0x2c0f2f=await readdir(_0x4b8220);for(const _0x5e4e39 of _0x2c0f2f){const _0x1f4128=join(_0x4b8220,_0x5e4e39),_0x5b5d85=await _0x30ca03['uvztj'](stat,_0x1f4128);_0x5b5d85[_0x4245e7(0x1c9)]()&&(_0x278b73[_0x4245e7(0x1e5)](_0x5e4e39),_0x27b672[_0x5e4e39]=_0x30ca03['ucMIE']);}}const _0x2faca5=join(_0x10556f,'ci');if(_0x30ca03[_0x4245e7(0x1c8)](existsSync,_0x2faca5)){const _0x5afeb3=await _0x30ca03['JkOhV'](readdir,_0x2faca5);for(const _0x41bf81 of _0x5afeb3){const _0x91edec=_0x30ca03[_0x4245e7(0x1ce)](join,_0x2faca5,_0x41bf81),_0xf063e1=await _0x30ca03[_0x4245e7(0x1d3)](stat,_0x91edec);_0xf063e1['isDirectory']()&&(_0x278b73['push'](_0x41bf81),_0x27b672[_0x41bf81]='ci');}}const _0x548977=await readdir(_0x10556f);for(const _0x386432 of _0x548977){if(NON_ENV_DIRS['includes'](_0x386432))continue;if(_0x386432[_0x4245e7(0x1e3)]('.'))continue;if(_0x386432['endsWith'](_0x4245e7(0x1eb)))continue;const _0x32bfe6=join(_0x10556f,_0x386432),_0xf454ae=await _0x30ca03[_0x4245e7(0x1d3)](stat,_0x32bfe6);_0xf454ae['isDirectory']()&&_0x30ca03['vRbab'](existsSync,_0x30ca03['tTKsD'](join,_0x32bfe6,'settings.json'))&&(!_0x278b73['includes'](_0x386432)&&(_0x278b73['push'](_0x386432),_0x27b672[_0x386432]=_0x30ca03['HuNxo']));}return{'envNames':_0x278b73,'activeEnv':_0x1b194d,'envTypes':_0x27b672};}export async function envList(){const _0x4904de=_0x4cb18e,_0x704380={'Omkly':function(_0x25e000){return _0x25e000();},'YJxMH':function(_0xc3ba0c,_0x469aca){return _0xc3ba0c===_0x469aca;},'bywcp':_0x4904de(0x1cb),'TJBLC':'Run:\x20ranger\x20profile\x20add\x20<profile-name>','oksNx':function(_0x3e2381,_0x391b07){return _0x3e2381>_0x391b07;},'CHhpe':'local','zCeCB':function(_0x28bbbd,_0x3c3e8e){return _0x28bbbd(_0x3c3e8e);},'hSuhI':'legacy','HAnLl':'\x0aCloud\x20Profiles:','HeQGS':function(_0x2a2f7a,_0x5edd86){return _0x2a2f7a===_0x5edd86;},'xdOvu':'no\x20session'},{envNames:_0x3192b9,activeEnv:_0x2397fd,envTypes:_0x383c3e}=await _0x704380[_0x4904de(0x1c7)](getEnvNames);let _0x53cbc2=[];try{_0x53cbc2=await _0x704380['Omkly'](listCloudProfiles);}catch{}if(_0x3192b9['length']===0x0&&_0x704380['YJxMH'](_0x53cbc2['length'],0x0)){console[_0x4904de(0x1db)](_0x704380[_0x4904de(0x1d4)]),console[_0x4904de(0x1db)](_0x704380['TJBLC']);return;}const _0x47c9a8=new Set(_0x53cbc2[_0x4904de(0x1d7)](_0x4a0575=>_0x4a0575[_0x4904de(0x1e8)]));if(_0x704380['oksNx'](_0x3192b9['length'],0x0)){console[_0x4904de(0x1db)](_0x4904de(0x1e4));for(const _0x32dd19 of _0x3192b9['sort']()){const _0x4cb202=_0x32dd19===_0x2397fd&&!_0x47c9a8[_0x4904de(0x1d0)](_0x32dd19),_0x3f3212=_0x383c3e[_0x32dd19]||_0x704380['CHhpe'],_0x5741a4=await _0x704380['zCeCB'](loadSettings,_0x32dd19),_0x5f17de=_0x3f3212===_0x704380['hSuhI']?'':'\x20['+_0x3f3212+']';console[_0x4904de(0x1db)]('\x20\x20'+(_0x4cb202?'*\x20':'\x20\x20')+_0x32dd19+_0x5f17de),_0x5741a4['baseUrl']&&console['log'](_0x4904de(0x1da)+_0x5741a4[_0x4904de(0x1cd)]),_0x5741a4['environmentDetails']&&console['log']('\x20\x20\x20\x20\x20\x20Details:\x20'+_0x5741a4[_0x4904de(0x1e1)]);}}if(_0x53cbc2['length']>0x0){console['log'](_0x704380[_0x4904de(0x1e7)]);for(const _0x9541da of _0x53cbc2[_0x4904de(0x1cf)]((_0x264f64,_0x40e63c)=>_0x264f64[_0x4904de(0x1e8)][_0x4904de(0x1dc)](_0x40e63c[_0x4904de(0x1e8)]))){const _0x4f517b=_0x704380[_0x4904de(0x1d2)](_0x9541da[_0x4904de(0x1e8)],_0x2397fd),_0x5a9972=_0x9541da[_0x4904de(0x1d1)]?'\x20('+_0x9541da[_0x4904de(0x1d1)]+')':'',_0x329dc8=_0x9541da['sessionUpdatedAt']?'cached\x20(updated\x20'+_0x9541da[_0x4904de(0x1cc)]+')':_0x704380[_0x4904de(0x1e6)];console[_0x4904de(0x1db)]('\x20\x20'+(_0x4f517b?'*\x20':'\x20\x20')+_0x9541da['name']+_0x4904de(0x1d8)+_0x5a9972),console[_0x4904de(0x1db)](_0x4904de(0x1ec)+_0x329dc8);}}_0x2397fd&&console[_0x4904de(0x1db)]('\x0a*\x20=\x20active\x20profile');}function _0x11b9(){const _0x2bb4fb=['log','localeCompare','47960040JQlVZL','tTGyy','45463ZVcsXQ','local','environmentDetails','5664540inikwy','startsWith','\x0aLocal\x20Profiles\x20(legacy):','push','xdOvu','HAnLl','name','6326460DekgwC','sessions','.txt','\x20\x20\x20\x20\x20\x20Session:\x20','327732ZaisJz','Omkly','PZdCr','isDirectory','4114164JLrevI','\x0aNo\x20profiles\x20found.','sessionUpdatedAt','baseUrl','KyRCU','sort','has','environmentKey','HeQGS','vRbab','bywcp','38yWEyQA','5387490rANJww','map','\x20[cloud]','reports','\x20\x20\x20\x20\x20\x20URL:\x20'];_0x11b9=function(){return _0x2bb4fb;};return _0x11b9();}
1
+ const _0x160dd0=_0x301f;function _0x35f2(){const _0x3741f6=['sort','isDirectory','\x0aProfiles:','yVxVg','2907110ucFZyb','2521068VmzZgn','7atzPwl','5295766KoljRN','5iKmWtd','249272UHkPNJ','push','local','settings.json','4922784LgvsFU','endsWith','\x20\x20\x20\x20\x20\x20Details:\x20','reports','8rsumQS','3732aflYWe','\x0a*\x20=\x20active\x20profile','sessions','48081bfNjAu','mTSQw','log','GvVZe','baseUrl','fUVdA','gXTZz','545667xwUQAF','includes','Run:\x20ranger\x20profile\x20add\x20<profile-name>','\x0aNo\x20profiles\x20found.','ufuzx','4XVfQAc'];_0x35f2=function(){return _0x3741f6;};return _0x35f2();}(function(_0x2f433e,_0xdc93e2){const _0x37337e=_0x301f,_0x3f1f49=_0x2f433e();while(!![]){try{const _0x5d230d=-parseInt(_0x37337e(0x18f))/0x1*(parseInt(_0x37337e(0x192))/0x2)+-parseInt(_0x37337e(0x183))/0x3*(-parseInt(_0x37337e(0x188))/0x4)+-parseInt(_0x37337e(0x191))/0x5*(-parseInt(_0x37337e(0x18e))/0x6)+-parseInt(_0x37337e(0x190))/0x7+parseInt(_0x37337e(0x19a))/0x8*(parseInt(_0x37337e(0x196))/0x9)+-parseInt(_0x37337e(0x18d))/0xa+parseInt(_0x37337e(0x19e))/0xb*(parseInt(_0x37337e(0x19b))/0xc);if(_0x5d230d===_0xdc93e2)break;else _0x3f1f49['push'](_0x3f1f49['shift']());}catch(_0x3e96b5){_0x3f1f49['push'](_0x3f1f49['shift']());}}}(_0x35f2,0x8fbb3));import{readdir,stat}from'fs/promises';import{join}from'path';import{existsSync}from'fs';import{getRangerDir}from'./utils/rangerRoot.js';import{loadSettings}from'./utils/settings.js';import{readActiveProfileName}from'./utils/activeProfile.js';const NON_ENV_DIRS=[_0x160dd0(0x19d),'bug-bashes',_0x160dd0(0x199),'local','ci'];function _0x301f(_0x52f0ff,_0x39e84b){_0x52f0ff=_0x52f0ff-0x182;const _0x35f29f=_0x35f2();let _0x301f5e=_0x35f29f[_0x52f0ff];return _0x301f5e;}export async function getEnvNames(){const _0x2c5423=_0x160dd0,_0x235624={'yVxVg':function(_0x1d7030,_0x38083a,_0x2a6d74){return _0x1d7030(_0x38083a,_0x2a6d74);},'fUVdA':'local','gXTZz':function(_0x107869,_0x2d9bd5){return _0x107869(_0x2d9bd5);},'mTSQw':function(_0x2ed62f,_0x22c6ee){return _0x2ed62f(_0x22c6ee);},'NGDEy':function(_0x462eef,_0x30b74f,_0x2d0bf2){return _0x462eef(_0x30b74f,_0x2d0bf2);},'GvVZe':function(_0x13e5b3,_0x3c96ba){return _0x13e5b3(_0x3c96ba);},'PfJti':function(_0x21b7c3,_0x4ff575){return _0x21b7c3(_0x4ff575);},'xyEtD':'legacy'},_0x2a5f8a=getRangerDir();if(!existsSync(_0x2a5f8a))return{'envNames':[],'activeEnv':null,'envTypes':{}};const _0x237eb1=await readActiveProfileName(),_0x90e1d1=[],_0x85a408={},_0x14abed=_0x235624[_0x2c5423(0x18c)](join,_0x2a5f8a,_0x235624[_0x2c5423(0x1a3)]);if(existsSync(_0x14abed)){const _0x2efa2a=await _0x235624[_0x2c5423(0x182)](readdir,_0x14abed);for(const _0x3ce8b7 of _0x2efa2a){const _0x27fb2b=join(_0x14abed,_0x3ce8b7),_0x179298=await _0x235624[_0x2c5423(0x19f)](stat,_0x27fb2b);_0x179298['isDirectory']()&&(_0x90e1d1['push'](_0x3ce8b7),_0x85a408[_0x3ce8b7]=_0x235624[_0x2c5423(0x1a3)]);}}const _0x675a6a=_0x235624['NGDEy'](join,_0x2a5f8a,'ci');if(_0x235624[_0x2c5423(0x182)](existsSync,_0x675a6a)){const _0x297ea2=await _0x235624[_0x2c5423(0x1a1)](readdir,_0x675a6a);for(const _0x4cc119 of _0x297ea2){const _0x3cf11f=join(_0x675a6a,_0x4cc119),_0x5c1819=await _0x235624['PfJti'](stat,_0x3cf11f);_0x5c1819[_0x2c5423(0x18a)]()&&(_0x90e1d1[_0x2c5423(0x193)](_0x4cc119),_0x85a408[_0x4cc119]='ci');}}const _0x3dd3ac=await readdir(_0x2a5f8a);for(const _0x10266d of _0x3dd3ac){if(NON_ENV_DIRS[_0x2c5423(0x184)](_0x10266d))continue;if(_0x10266d['startsWith']('.'))continue;if(_0x10266d[_0x2c5423(0x197)]('.txt'))continue;const _0x4b17ba=join(_0x2a5f8a,_0x10266d),_0x34a941=await stat(_0x4b17ba);_0x34a941[_0x2c5423(0x18a)]()&&existsSync(join(_0x4b17ba,_0x2c5423(0x195)))&&(!_0x90e1d1['includes'](_0x10266d)&&(_0x90e1d1[_0x2c5423(0x193)](_0x10266d),_0x85a408[_0x10266d]=_0x235624['xyEtD']));}return{'envNames':_0x90e1d1,'activeEnv':_0x237eb1,'envTypes':_0x85a408};}export async function envList(){const _0x3d206f=_0x160dd0,_0x184933={'TlyTQ':function(_0x1dcd3f,_0x349a15){return _0x1dcd3f===_0x349a15;},'Pbqss':_0x3d206f(0x186),'cptmg':_0x3d206f(0x185),'ufuzx':_0x3d206f(0x18b),'KIJbm':function(_0x2c6d4b,_0x2a15fd){return _0x2c6d4b===_0x2a15fd;}},{envNames:_0x27d013,activeEnv:_0x3d6b2c,envTypes:_0x18d6ab}=await getEnvNames();if(_0x184933['TlyTQ'](_0x27d013['length'],0x0)){console['log'](_0x184933['Pbqss']),console[_0x3d206f(0x1a0)](_0x184933['cptmg']);return;}console[_0x3d206f(0x1a0)](_0x184933[_0x3d206f(0x187)]);for(const _0x514d17 of _0x27d013[_0x3d206f(0x189)]()){const _0x211527=_0x184933['TlyTQ'](_0x514d17,_0x3d6b2c),_0x2cac56=_0x18d6ab[_0x514d17]||_0x3d206f(0x194),_0x29157e=await loadSettings(_0x514d17),_0x36dcca=_0x184933['KIJbm'](_0x2cac56,'legacy')?'':'\x20['+_0x2cac56+']';console[_0x3d206f(0x1a0)]('\x20\x20'+(_0x211527?'*\x20':'\x20\x20')+_0x514d17+_0x36dcca),_0x29157e[_0x3d206f(0x1a2)]&&console[_0x3d206f(0x1a0)]('\x20\x20\x20\x20\x20\x20URL:\x20'+_0x29157e[_0x3d206f(0x1a2)]),_0x29157e['environmentDetails']&&console[_0x3d206f(0x1a0)](_0x3d206f(0x198)+_0x29157e['environmentDetails']);}_0x3d6b2c&&console['log'](_0x3d206f(0x19c));}
@@ -1 +1 @@
1
- const _0x24d357=_0x50f1;(function(_0x3ffff7,_0x55ba8d){const _0x28bd5e=_0x50f1,_0x23d0a9=_0x3ffff7();while(!![]){try{const _0x2cbd94=parseInt(_0x28bd5e(0x177))/0x1*(parseInt(_0x28bd5e(0x138))/0x2)+-parseInt(_0x28bd5e(0x1cf))/0x3+-parseInt(_0x28bd5e(0x12f))/0x4*(parseInt(_0x28bd5e(0x1af))/0x5)+-parseInt(_0x28bd5e(0x18b))/0x6*(-parseInt(_0x28bd5e(0x19e))/0x7)+parseInt(_0x28bd5e(0x1ae))/0x8+parseInt(_0x28bd5e(0x1ba))/0x9*(parseInt(_0x28bd5e(0x193))/0xa)+parseInt(_0x28bd5e(0x132))/0xb;if(_0x2cbd94===_0x55ba8d)break;else _0x23d0a9['push'](_0x23d0a9['shift']());}catch(_0x3cf32d){_0x23d0a9['push'](_0x23d0a9['shift']());}}}(_0x4e83,0x9b97c));import{readFile,writeFile,mkdir}from'fs/promises';import{join}from'path';import{existsSync}from'fs';import{execSync}from'child_process';import _0x32f418 from'inquirer';import{createFeature,listFeatures,getFeature,updateFeature,getFeatureReport,getFeatureReportMarkdown,listFeatureSessions,startSession,concludeSession,createChecklistItem,getActionItems,getItemFeedback,softDeleteFeature,restoreFeature,updateChecklistItem}from'./utils/featureApi.js';import{getBrowserSessionSteps}from'./utils/browserSessionsApi.js';import{getApiBaseUrl}from'./utils/environment.js';import{getRangerDir}from'./utils/rangerRoot.js';function _0x4e83(){const _0x3d5c1b=['0|5|3|1|2|4','Showing\x20','\x20scenario(s).','FfVUN','from','iteration','\x0a📁\x20Sessions\x20for\x20feature\x20review:\x20','\x20in\x20progress','LxsqR','\x0a❌\x20Invalid\x20scenario\x20number(s):\x20','version','utf-8','pipe','\x20blocked','LaeAm','toLocaleString','efpmj','json','No\x20feature\x20review\x20ID\x20provided\x20and\x20no\x20active\x20feature\x20review\x20set.','verified','\x20—\x20','7528etjjXa','numeric','FoxFX','14787289TCvirx','totalCount',':\x20\x22','wxfzr','prompt','push','2kSCARL','screenshotUrls','linkedSession','rhhvd','items','\x20\x20\x20Branch:\x20','selected','blockedReason','incompleteReason','canonicalFlow','CvTmO','\x20\x20\x20\x20\x20Progress:\x20','\x0a\x20\x20\x20Scenarios:','No\x20feature\x20review\x20ID\x20provided\x20and\x20no\x20active\x20feature\x20review\x20set.\x20Run:\x20ranger\x20resume\x20<id>\x20to\x20set\x20an\x20active\x20feature\x20review','CLAUDE_SESSION_ID','checklistItems','domRef','RANGER_TEST_USERNAME','EsGKu','filter','assetUrl','\x0a❌\x20Invalid\x20scenario\x20index:\x20','spatial','scenario','limit','\x20of\x20','\x20\x20\x20Progress:\x20','\x20\x20\x20Repository:\x20','\x20\x20\x20\x20','\x1b[1m','\x20--current-branch','fyFGW','yxRxR','aVLLZ','exit','ieYiA','Screenshot\x20','latestReview','warn','in_progress','):\x20\x22','arrayBuffer','wCyHW','NWuGu','LFxCg','error','\x20Session\x20','\x0a✅\x20Scenario\x20added','zBOBd','qEKpr','GKbOg','\x0aCreating\x20feature\x20review...','closed','PLqIh','RdpVj','scenarios','reports','\x20\x20\x20Completed:\x20','North','\x0a❌\x20No\x20scenarios\x20found\x20to\x20edit.','\x20[has\x20reviewer\x20feedback]','LIfdF','\x0a➡️\x20\x20Set\x20as\x20active\x20feature\x20review','5777CTRdkg','createdAt','\x20—\x20no\x20comments','No\x20scenarios\x20found.','unaddressedComments','yciUj','\x20concluded.','Not\x20in\x20a\x20git\x20repository.','terminalReason','Run:\x20ranger\x20create\x20\x22<name>\x22\x20to\x20create\x20a\x20new\x20feature\x20review','approved','replace','pSsQs','/api/v1/mcp/browser-sessions/','completed','includeDeleted','qaDwI','screenshot','\x20\x20\x20','TxuyN','2502vKuIKv','canceledReason','\x0a❌\x20No\x20scenarios\x20found\x20to\x20include.','agentResponse','1|4|5|0|3|2','coordinates','\x20\x20\x20▶️\x20Started\x20session\x20','active-feature.txt','169250RLkFka','\x20\x20\x20\x20\x20Branch:\x20','...','pop','JytAy','.\x20Feature\x20review\x20has\x20','currentSessionId','hKEEB','IfFTA','Next\x20page:\x20ranger\x20list\x20--offset\x20','incompleteItems','11809vNveWs','FRVkL','\x20\x20\x20Updated\x20branch\x20to:\x20','sessionId','browserSessionId','stepName','DiGJX','env','has','rhwSJ','verification_in_progress','notes','ossGH','stringify','trim','dashboardUrl','4542728NKiQqI','3385MKAWHX','qTxoV','Please\x20finish\x20your\x20review\x20first:','xRjPL','FYPLP','UJBKc','\x20\x20\x20Created:\x20','\x20\x20\x20\x20\x20\x20Approved','PJSMG','dQTyC','vQdGi','18MgBlzs','log','map','mjqXf','WzfpX','isTTY','\x0a✅\x20Resumed\x20feature\x20review:\x20','blocked','git\x20rev-parse\x20--abbrev-ref\x20HEAD','toFixed','AwIXB','\x20\x20\x20ID:\x20','\x0aNo\x20matching\x20active\x20feature\x20reviews\x20found.','currentBranch','lxZjZ','gitBranch','gAFVF','completedAt','CKgxp','Cannot\x20conclude\x20session\x20with\x20status:\x20','HMwkl','2231472dYtBNe','pendingItems','\x20/\x20','\x20at\x20[','\x0a✅\x20Session\x20','Scenario\x20','offset','name','write','github.com/','assetType','\x0a❌\x20Cannot\x20edit\x20scenario:\x20feature\x20review\x20has\x20an\x20active\x20review.','\x20\x20\x20\x20\x20📋\x20Selector:\x20','guLad','\x0aAvailable\x20scenarios:','length','cOGZJ','No\x20active\x20session\x20for\x20this\x20feature\x20review.','psuBM','toLocaleDateString','\x0a🗑️\x20\x20Deleted\x20feature\x20review:\x20','vVBWR','parentItemId','status','description','stats','split','\x20feature\x20review(s)\x20found','submittedAt','LzDWL','\x20\x20Expected\x20flow:','\x20\x20\x20\x20\x20📍\x20Annotation:\x20point\x20at\x20(','authorName','MGVuE','\x20\x20\x20\x20\x20🎯\x20Element:\x20<','Current\x20session\x20not\x20found.','\x0aSearching\x20for\x20feature\x20reviews\x20matching:\x20'];_0x4e83=function(){return _0x3d5c1b;};return _0x4e83();}import{registerSession}from'./utils/sessionCache.js';import{getEnvNames}from'./env.js';import{formatProfileRequiredMessage}from'./utils/profileMessages.js';import{listCloudProfiles}from'./utils/cloudProfile.js';const ACTIVE_FEATURE_FILE=_0x24d357(0x192),bold=_0x4887ec=>_0x24d357(0x155)+_0x4887ec+'\x1b[0m';function getGitRepoUrl(){const _0x4ce97c=_0x24d357,_0x1da8b6={'DolBx':'git\x20remote\x20get-url\x20origin','rhhvd':'pipe'};try{const _0x381d10=execSync(_0x1da8b6['DolBx'],{'encoding':'utf-8','stdio':[_0x4ce97c(0x126),_0x1da8b6[_0x4ce97c(0x13b)],_0x1da8b6['rhhvd']]})[_0x4ce97c(0x1ac)]();return _0x381d10[_0x4ce97c(0x182)](/\.git$/,'')[_0x4ce97c(0x182)](/^git@github\.com:/,_0x4ce97c(0x1d8))[_0x4ce97c(0x182)](/^https?:\/\//,'');}catch{return undefined;}}function _0x50f1(_0x424933,_0x4e77bf){_0x424933=_0x424933-0x118;const _0x4e8332=_0x4e83();let _0x50f155=_0x4e8332[_0x424933];return _0x50f155;}function getGitBranch(){const _0x476dfa=_0x24d357,_0x387bed={'EncHD':_0x476dfa(0x1c2),'qDrAc':_0x476dfa(0x125)};try{return execSync(_0x387bed['EncHD'],{'encoding':_0x387bed['qDrAc'],'stdio':[_0x476dfa(0x126),_0x476dfa(0x126),_0x476dfa(0x126)]})['trim']();}catch{return undefined;}}export async function getActiveFeatureId(){const _0x408c7d=_0x24d357,_0x5e2e8b={'fQuFl':function(_0x4c30be,_0x4887e5,_0x13cac9){return _0x4c30be(_0x4887e5,_0x13cac9);},'QrkwK':function(_0x2ed0b4){return _0x2ed0b4();},'LFxCg':'utf-8'},_0x29162b=_0x5e2e8b['fQuFl'](join,_0x5e2e8b['QrkwK'](getRangerDir),ACTIVE_FEATURE_FILE);if(!existsSync(_0x29162b))return null;try{const _0x4a9fa9=await _0x5e2e8b['fQuFl'](readFile,_0x29162b,_0x5e2e8b[_0x408c7d(0x164)]);return _0x4a9fa9['trim']()||null;}catch{return null;}}async function setActiveFeatureId(_0x29f11b){const _0x18d059=_0x24d357,_0x353b6d={'dlUkp':function(_0x4f8f5f,_0x3dd47c,_0x2bba3d){return _0x4f8f5f(_0x3dd47c,_0x2bba3d);},'SLGDc':function(_0x4a607d,_0x4f302d){return _0x4a607d(_0x4f302d);},'gAFVF':function(_0xf1cf0b,_0x58a9f9,_0xd67b6d,_0x3f42dd){return _0xf1cf0b(_0x58a9f9,_0xd67b6d,_0x3f42dd);},'WpoVY':'utf-8'},_0x3a71bd=getRangerDir(),_0xff13e9=_0x353b6d['dlUkp'](join,_0x3a71bd,ACTIVE_FEATURE_FILE);!_0x353b6d['SLGDc'](existsSync,_0x3a71bd)&&await mkdir(_0x3a71bd,{'recursive':!![]}),await _0x353b6d[_0x18d059(0x1ca)](writeFile,_0xff13e9,_0x29f11b,_0x353b6d['WpoVY']);}function getProgressDisplay(_0x191095){const _0x3a7cd2=_0x24d357,_0x1cdbf7={'lxZjZ':function(_0x2073f2,_0x5b8e56){return _0x2073f2+_0x5b8e56;},'mdMig':function(_0x42c3b8,_0x38917a){return _0x42c3b8+_0x38917a;},'teNji':function(_0x114723,_0x5d9cc5){return _0x114723===_0x5d9cc5;},'UJBKc':function(_0x1825c1,_0x3d4dd6){return _0x1825c1*_0x3d4dd6;},'yxRxR':function(_0x2cc928,_0x36d205){return _0x2cc928-_0x36d205;},'PJSMG':function(_0x249072,_0x2ac006){return _0x249072>_0x2ac006;}},_0x3b8281=_0x191095['verifiedItems']||0x0,_0x5d6082=_0x191095['verificationInProgressItems']||0x0,_0x5de6ab=_0x191095['blockedItems']||0x0,_0x1d35d0=_0x191095[_0x3a7cd2(0x19d)]||0x0,_0x3cfd0d=_0x191095[_0x3a7cd2(0x1d0)]||0x0,_0x356c82=_0x1cdbf7[_0x3a7cd2(0x1c8)](_0x1cdbf7[_0x3a7cd2(0x1c8)](_0x1cdbf7['mdMig'](_0x3b8281,_0x5d6082),_0x5de6ab)+_0x1d35d0,_0x3cfd0d);if(_0x1cdbf7['teNji'](_0x356c82,0x0))return'-';const _0x43ef54=0xa,_0x1df4a4=Math['round'](_0x1cdbf7[_0x3a7cd2(0x1b4)](_0x3b8281/_0x356c82,_0x43ef54)),_0x1b193a=_0x1cdbf7[_0x3a7cd2(0x1c8)]('█'['repeat'](_0x1df4a4),'░'['repeat'](_0x1cdbf7[_0x3a7cd2(0x158)](_0x43ef54,_0x1df4a4))),_0x5c7b0c=[];if(_0x5de6ab>0x0)_0x5c7b0c['push'](_0x5de6ab+_0x3a7cd2(0x127));if(_0x1d35d0>0x0)_0x5c7b0c[_0x3a7cd2(0x137)](_0x1d35d0+'\x20incomplete');if(_0x1cdbf7[_0x3a7cd2(0x1b7)](_0x5d6082,0x0))_0x5c7b0c['push'](_0x5d6082+_0x3a7cd2(0x121));const _0x173efd=_0x1cdbf7['PJSMG'](_0x5c7b0c['length'],0x0)?'\x20('+_0x5c7b0c['join'](',\x20')+')':'';return _0x1b193a+'\x20'+_0x3b8281+'/'+_0x356c82+'\x20verified'+_0x173efd;}function getCurrentSessionItems(_0x523315,_0x3323e4){const _0x493324=_0x24d357;if(!_0x523315[_0x493324(0x199)])return _0x3323e4[_0x493324(0x14b)](_0x187248=>!_0x187248['sessionId']);return _0x3323e4['filter'](_0x2ad8af=>_0x2ad8af[_0x493324(0x1a1)]===_0x523315[_0x493324(0x199)]||!_0x2ad8af['sessionId']);}function displayFeature(_0xab87e5,_0xa4937){const _0x490e82=_0x24d357,_0x5c0f9c={'vVBWR':function(_0x29a565,_0x597940){return _0x29a565(_0x597940);},'vQdGi':function(_0x298981,_0x542064){return _0x298981>_0x542064;},'PWEjl':function(_0x10df9d,_0x430529){return _0x10df9d<_0x430529;},'xRjPL':_0x490e82(0x16c),'NGLZU':'approved','plMSb':function(_0x5c0aef,_0x5ac2cd){return _0x5c0aef===_0x5ac2cd;},'FfVUN':'incomplete','hgwhS':_0x490e82(0x1c1),'ieYiA':'verification_in_progress','GJNyt':function(_0x596a33,_0xcb5871){return _0x596a33>_0xcb5871;},'ivzyP':function(_0x579816,_0x2ba67b){return _0x579816!==_0x2ba67b;},'oezZn':'verified','rhwSJ':function(_0x5007fc,_0x1c49d5){return _0x5007fc===_0x1c49d5;},'Yvoex':function(_0x174760,_0x585eb0){return _0x174760===_0x585eb0;}};console[_0x490e82(0x1bb)]('\x0a'+_0xab87e5[_0x490e82(0x1d6)]+'\x20('+_0xab87e5[_0x490e82(0x1ad)]+')');_0xab87e5['stats']&&console[_0x490e82(0x1bb)]('\x20\x20\x20Progress:\x20'+_0x5c0f9c[_0x490e82(0x1e4)](getProgressDisplay,_0xab87e5['stats']));_0xab87e5[_0x490e82(0x1e7)]&&console['log']('\x20\x20\x20Description:\x20'+_0xab87e5[_0x490e82(0x1e7)]);_0xab87e5['gitRepoUrl']&&console[_0x490e82(0x1bb)](_0x490e82(0x153)+_0xab87e5['gitRepoUrl']);_0xab87e5['gitBranch']&&console[_0x490e82(0x1bb)](_0x490e82(0x13d)+_0xab87e5['gitBranch']);console[_0x490e82(0x1bb)]('\x20\x20\x20Created:\x20'+new Date(_0xab87e5[_0x490e82(0x178)])['toLocaleString']());_0xab87e5['completedAt']&&console['log']('\x20\x20\x20Completed:\x20'+new Date(_0xab87e5['completedAt'])[_0x490e82(0x129)]());if(_0xa4937&&_0x5c0f9c[_0x490e82(0x1b9)](_0xa4937['length'],0x0)){console['log'](_0x490e82(0x144));for(let _0x3ffc36=0x0;_0x5c0f9c['PWEjl'](_0x3ffc36,_0xa4937[_0x490e82(0x1de)]);_0x3ffc36++){const _0x292091=_0xa4937[_0x3ffc36];let _0xb9a2f9;if(_0x292091['status']===_0x5c0f9c[_0x490e82(0x1b2)]&&_0x292091[_0x490e82(0x17f)]===_0x5c0f9c['NGLZU'])_0xb9a2f9='✅';else{if(_0x292091['status']===_0x490e82(0x12d))_0xb9a2f9='🟢';else{if(_0x5c0f9c['plMSb'](_0x292091['status'],_0x5c0f9c['FfVUN']))_0xb9a2f9='🟠';else{if(_0x292091[_0x490e82(0x1e6)]===_0x5c0f9c['hgwhS'])_0xb9a2f9='🛑';else{if(_0x292091['status']==='closed')_0xb9a2f9='⛔';else _0x292091[_0x490e82(0x1e6)]===_0x5c0f9c[_0x490e82(0x15b)]?_0xb9a2f9='⏳':_0xb9a2f9='⬜';}}}}const _0x206ab1=_0x5c0f9c['GJNyt'](_0x292091['version'],0x1)?'\x20(v'+_0x292091['version']+')':'',_0x112186=_0x292091['version']>0x1&&_0x292091[_0x490e82(0x1e5)]&&_0x5c0f9c['ivzyP'](_0x292091['status'],_0x5c0f9c['xRjPL'])&&_0x292091['status']!==_0x5c0f9c['oezZn']?_0x490e82(0x174):'';console['log'](_0x490e82(0x189)+(_0x3ffc36+0x1)+'.\x20'+_0xb9a2f9+'\x20'+_0x292091['description']+_0x206ab1+_0x112186);_0x5c0f9c[_0x490e82(0x1a7)](_0x292091[_0x490e82(0x1e6)],_0x5c0f9c['hgwhS'])&&_0x292091[_0x490e82(0x13f)]&&console['log']('\x20\x20\x20\x20\x20\x20Blocked:\x20'+_0x292091['blockedReason']);_0x292091[_0x490e82(0x1e6)]===_0x5c0f9c[_0x490e82(0x11d)]&&_0x292091[_0x490e82(0x140)]&&console[_0x490e82(0x1bb)]('\x20\x20\x20\x20\x20\x20Incomplete:\x20'+_0x292091[_0x490e82(0x140)]);if(_0x292091[_0x490e82(0x1e6)]===_0x5c0f9c['xRjPL']&&_0x292091['terminalReason']===_0x490e82(0x181))console[_0x490e82(0x1bb)](_0x490e82(0x1b6));else _0x5c0f9c['Yvoex'](_0x292091[_0x490e82(0x1e6)],_0x490e82(0x16c))&&_0x292091[_0x490e82(0x18c)]&&console['log']('\x20\x20\x20\x20\x20\x20Cancelled:\x20'+_0x292091['canceledReason']);}}}export async function featureCreate(_0x2bdca7,_0x3e4554){const _0x2f2fc5=_0x24d357,_0x1e8222={'CvTmO':function(_0x329532){return _0x329532();},'MbqdY':function(_0x38b831,_0x1200f4){return _0x38b831===_0x1200f4;},'EyscD':function(_0x3d5351,_0xd39390){return _0x3d5351(_0xd39390);},'MBFQR':function(_0x387f06,_0x5dc229,_0x24a17d){return _0x387f06(_0x5dc229,_0x24a17d);},'ossGH':function(_0x1b0b31,_0x5131e8,_0x330163){return _0x1b0b31(_0x5131e8,_0x330163);}},{envNames:_0x337eca}=await getEnvNames();if(_0x337eca['length']===0x0&&!process[_0x2f2fc5(0x1a5)][_0x2f2fc5(0x149)]){let _0x30d623=0x0;try{_0x30d623=(await _0x1e8222[_0x2f2fc5(0x142)](listCloudProfiles))['length'];}catch{_0x30d623=0x1;}_0x1e8222['MbqdY'](_0x30d623,0x0)&&console[_0x2f2fc5(0x15e)]('\x0a'+formatProfileRequiredMessage(_0x503db0=>bold(_0x503db0)));}const _0x364130=_0x3e4554['scenarios']?_0x3e4554[_0x2f2fc5(0x16f)]['map'](_0xa49a06=>_0xa49a06['trim']()):[],_0x11b503=_0x1e8222[_0x2f2fc5(0x142)](getGitRepoUrl),_0x3872dc=_0x1e8222['CvTmO'](getGitBranch);console['log'](_0x2f2fc5(0x16b));const _0x1fcf90=await createFeature({'name':_0x2bdca7,'description':_0x3e4554[_0x2f2fc5(0x1e7)],'checklist':_0x364130,'gitRepoUrl':_0x11b503,'gitBranch':_0x3872dc});await _0x1e8222['EyscD'](setActiveFeatureId,_0x1fcf90['id']),await tryStartCurrentSession(_0x1fcf90['id']);const _0x5c4896=process['env'][_0x2f2fc5(0x146)];_0x5c4896&&_0x1e8222['MBFQR'](registerSession,_0x5c4896,_0x1fcf90['id']),console[_0x2f2fc5(0x1bb)]('\x0a✅\x20Feature\x20review\x20created:\x20'+_0x1fcf90['id']),_0x1e8222[_0x2f2fc5(0x1aa)](displayFeature,_0x1fcf90,_0x1fcf90['checklistItems']),console[_0x2f2fc5(0x1bb)](_0x2f2fc5(0x176));}export async function featureList(_0x3146b3){const _0x38c2ce=_0x24d357,_0x43b31b={'rEjer':function(_0x493d73){return _0x493d73();},'jWTVE':function(_0x40a185,_0x27ee5a){return _0x40a185===_0x27ee5a;},'oPBPk':'\x0aNo\x20feature\x20reviews\x20found.','aVLLZ':_0x38c2ce(0x11a),'efpmj':function(_0x54b281,_0x321522){return _0x54b281(_0x321522);},'FRVkL':function(_0x2a41fc,_0x58dc20){return _0x2a41fc!==_0x58dc20;}},_0x53e9ef={'limit':_0x3146b3['limit']??0xa,'offset':_0x3146b3['offset']??0x0,'includeDeleted':_0x3146b3[_0x38c2ce(0x186)]};_0x3146b3['currentBranch']&&(_0x53e9ef['gitRepoUrl']=getGitRepoUrl(),_0x53e9ef[_0x38c2ce(0x1c9)]=_0x43b31b['rEjer'](getGitBranch));const _0x565c33=await listFeatures(_0x53e9ef);if(_0x43b31b['jWTVE'](_0x565c33['items'][_0x38c2ce(0x1de)],0x0)){console['log'](_0x43b31b['oPBPk']);return;}const _0x4c8ad6=_0x565c33['totalCount']>_0x565c33['items']['length']?_0x38c2ce(0x11b)+_0x565c33[_0x38c2ce(0x13c)]['length']+_0x38c2ce(0x151)+_0x565c33[_0x38c2ce(0x133)]:_0x565c33['totalCount']+_0x38c2ce(0x1ea);console['log']('\x0a'+_0x4c8ad6+':\x0a');for(const _0x229080 of _0x565c33[_0x38c2ce(0x13c)]){const _0x5567a8=_0x43b31b[_0x38c2ce(0x159)][_0x38c2ce(0x1e9)]('|');let _0x2ba154=0x0;while(!![]){switch(_0x5567a8[_0x2ba154++]){case'0':console[_0x38c2ce(0x1bb)](''+_0x229080['name']);continue;case'1':_0x229080[_0x38c2ce(0x1c9)]&&console['log']('\x20\x20\x20Branch:\x20'+_0x229080['gitBranch']);continue;case'2':console['log'](_0x38c2ce(0x1b5)+new Date(_0x229080['createdAt'])[_0x38c2ce(0x1e2)]());continue;case'3':_0x229080['stats']&&console[_0x38c2ce(0x1bb)](_0x38c2ce(0x152)+_0x43b31b[_0x38c2ce(0x12a)](getProgressDisplay,_0x229080['stats']));continue;case'4':console['log']('');continue;case'5':console['log'](_0x38c2ce(0x1c5)+_0x229080['id']);continue;}break;}}const _0x540c14=_0x53e9ef[_0x38c2ce(0x150)]??0xa,_0x4729fc=(_0x53e9ef[_0x38c2ce(0x1d5)]??0x0)+_0x565c33['items']['length'];if(_0x4729fc<_0x565c33[_0x38c2ce(0x133)]){const _0x21a8ee=_0x43b31b[_0x38c2ce(0x19f)](_0x540c14,0xa)?'\x20--limit\x20'+_0x540c14:'',_0x2166e1=_0x3146b3[_0x38c2ce(0x1c7)]?_0x38c2ce(0x156):'',_0x5e79f4=_0x3146b3['includeDeleted']?'\x20--include-deleted':'';console['log'](_0x38c2ce(0x19c)+_0x4729fc+_0x21a8ee+_0x2166e1+_0x5e79f4);}}export async function featureShow(_0x3e8ec5){const _0x3c7780={'jqtFI':'No\x20feature\x20review\x20ID\x20provided\x20and\x20no\x20active\x20feature\x20review\x20set.\x20Run:\x20ranger\x20resume\x20<id>\x20to\x20set\x20an\x20active\x20feature\x20review'},_0x58d156=_0x3e8ec5||await getActiveFeatureId();if(!_0x58d156)throw new Error(_0x3c7780['jqtFI']);const _0x464319=await getFeature(_0x58d156);displayFeature(_0x464319,_0x464319['checklistItems']);}export async function featureResume(_0x4ce80e){const _0x1a7426=_0x24d357,_0x3a4d81={'VTxzb':function(_0x2c391f){return _0x2c391f();},'GKbOg':function(_0x158743,_0x45c24e){return _0x158743(_0x45c24e);},'YIvSd':function(_0x239663,_0x40a60b,_0x53b5db){return _0x239663(_0x40a60b,_0x53b5db);},'North':function(_0x58a594){return _0x58a594();},'CnbIP':_0x1a7426(0x17e),'xtLsu':'any','wxfzr':function(_0x1f7966,_0x1d2621){return _0x1f7966===_0x1d2621;},'IoBgz':'Please\x20specify\x20the\x20feature\x20review\x20ID:\x20ranger\x20resume\x20<id>','hKEEB':'Multiple\x20feature\x20reviews\x20found.\x20Select\x20one:','wCyHW':function(_0x4ef9fd,_0x4fc0e2){return _0x4ef9fd!==_0x4fc0e2;},'psuBM':function(_0x50f99f,_0x2fd2ed){return _0x50f99f(_0x2fd2ed);},'TxuyN':function(_0x2c8891,_0xea6c59,_0x5be473){return _0x2c8891(_0xea6c59,_0x5be473);}};if(_0x4ce80e){const _0x3e107d=await getFeature(_0x4ce80e);await setActiveFeatureId(_0x3e107d['id']);const _0x512cc0=_0x3a4d81['VTxzb'](getGitBranch);_0x512cc0&&_0x512cc0!==_0x3e107d[_0x1a7426(0x1c9)]&&(await updateFeature(_0x3e107d['id'],{'gitBranch':_0x512cc0}),console[_0x1a7426(0x1bb)](_0x1a7426(0x1a0)+_0x512cc0));console[_0x1a7426(0x1bb)](_0x1a7426(0x1c0)+_0x3e107d['name']+'\x20('+_0x3e107d['id']+')'),await _0x3a4d81[_0x1a7426(0x16a)](tryStartCurrentSession,_0x3e107d['id']);const _0x4822a5=process[_0x1a7426(0x1a5)]['CLAUDE_SESSION_ID'];_0x4822a5&&_0x3a4d81['YIvSd'](registerSession,_0x4822a5,_0x3e107d['id']);displayFeature(_0x3e107d,_0x3e107d[_0x1a7426(0x147)]),await _0x3a4d81['GKbOg'](printFeedbackNudge,_0x3e107d['id']);return;}const _0x330419=_0x3a4d81[_0x1a7426(0x172)](getGitRepoUrl),_0x1dca65=_0x3a4d81['VTxzb'](getGitBranch);if(!_0x330419&&!_0x1dca65)throw new Error(_0x3a4d81['CnbIP']);console[_0x1a7426(0x1bb)](_0x1a7426(0x119)+(_0x330419||_0x3a4d81['xtLsu'])+_0x1a7426(0x1d1)+(_0x1dca65||'any')+_0x1a7426(0x195));const _0x3f35b4=await listFeatures({'gitRepoUrl':_0x330419,'gitBranch':_0x1dca65}),_0x22ffed=_0x3f35b4['items'][_0x1a7426(0x14b)](_0x4182b0=>_0x4182b0[_0x1a7426(0x1e6)]?_0x4182b0[_0x1a7426(0x1e6)]!==_0x1a7426(0x12d):!_0x4182b0[_0x1a7426(0x1cb)]);if(_0x3a4d81[_0x1a7426(0x135)](_0x22ffed[_0x1a7426(0x1de)],0x0)){console[_0x1a7426(0x1bb)](_0x1a7426(0x1c6)),console[_0x1a7426(0x1bb)](_0x1a7426(0x180));return;}let _0x5c5179;if(_0x22ffed['length']===0x1)_0x5c5179=_0x22ffed[0x0];else{const _0x1dba5e=process['stdin']['isTTY']&&process['stdout'][_0x1a7426(0x1bf)];if(!_0x1dba5e){console['log']('\x0aNon-interactive\x20mode\x20detected.\x20Multiple\x20feature\x20reviews\x20found:');for(const _0x4f2029 of _0x22ffed){console[_0x1a7426(0x1bb)]('\x20\x20'+_0x4f2029[_0x1a7426(0x1d6)]),console[_0x1a7426(0x1bb)]('\x20\x20\x20\x20\x20ID:\x20'+_0x4f2029['id']),_0x4f2029[_0x1a7426(0x1e8)]&&console[_0x1a7426(0x1bb)](_0x1a7426(0x143)+getProgressDisplay(_0x4f2029['stats'])),_0x4f2029[_0x1a7426(0x1c9)]&&console[_0x1a7426(0x1bb)](_0x1a7426(0x194)+_0x4f2029[_0x1a7426(0x1c9)]);}throw new Error(_0x3a4d81['IoBgz']);}const {selected:_0x310b70}=await _0x32f418[_0x1a7426(0x136)]([{'type':'list','name':_0x1a7426(0x13e),'message':_0x3a4d81[_0x1a7426(0x19a)],'choices':_0x22ffed[_0x1a7426(0x1bc)](_0x5041b4=>({'name':_0x5041b4['name']+'\x20('+_0x5041b4['id']+')','value':_0x5041b4['id']}))}]);_0x5c5179=_0x22ffed['find'](_0x91d30f=>_0x91d30f['id']===_0x310b70);}await _0x3a4d81[_0x1a7426(0x16a)](setActiveFeatureId,_0x5c5179['id']);_0x1dca65&&_0x3a4d81[_0x1a7426(0x162)](_0x1dca65,_0x5c5179[_0x1a7426(0x1c9)])&&(await updateFeature(_0x5c5179['id'],{'gitBranch':_0x1dca65}),console['log']('\x20\x20\x20Updated\x20branch\x20to:\x20'+_0x1dca65));console['log']('\x0a✅\x20Resumed\x20feature\x20review:\x20'+_0x5c5179[_0x1a7426(0x1d6)]+'\x20('+_0x5c5179['id']+')'),await _0x3a4d81[_0x1a7426(0x1e1)](tryStartCurrentSession,_0x5c5179['id']);const _0x527527=await getFeature(_0x5c5179['id']),_0x259e65=process['env'][_0x1a7426(0x146)];_0x259e65&&registerSession(_0x259e65,_0x527527['id']),_0x3a4d81[_0x1a7426(0x18a)](displayFeature,_0x527527,_0x527527[_0x1a7426(0x147)]),await printFeedbackNudge(_0x527527['id']);}async function printFeedbackNudge(_0x39bff1){const _0x443232=_0x24d357,_0x45b0e0={'JytAy':function(_0x40a059,_0x2463b6){return _0x40a059(_0x2463b6);},'jcvWc':function(_0xb6b19f,_0x4e123a){return _0xb6b19f>_0x4e123a;}};try{const {items:_0x3a0c88}=await _0x45b0e0[_0x443232(0x197)](getActionItems,_0x39bff1);let _0x377b2f=0x0,_0x179758=0x0;for(const _0xa59cd7 of _0x3a0c88){const _0x2bbbc8=await getItemFeedback(_0x39bff1,_0xa59cd7['id']);_0x45b0e0['jcvWc'](_0x2bbbc8[_0x443232(0x17b)]['length'],0x0)&&(_0x377b2f+=_0x2bbbc8['unaddressedComments']['length'],_0x179758++);}_0x377b2f>0x0&&(console[_0x443232(0x1bb)]('\x0a⚠️\x20\x20'+_0x377b2f+'\x20unaddressed\x20reviewer\x20comment(s)\x20across\x20'+_0x179758+_0x443232(0x11c)),console[_0x443232(0x1bb)]('\x20\x20\x20Run\x20`ranger\x20get-review`\x20to\x20see\x20what\x20needs\x20to\x20be\x20fixed.'));}catch{}}async function tryStartCurrentSession(_0x88daee){const _0x574a30=_0x24d357,_0x5d56b6={'EqcGt':function(_0x37bac2,_0x4dfa29,_0x5ac92c){return _0x37bac2(_0x4dfa29,_0x5ac92c);}};try{const {sessions:_0x3f695f}=await listFeatureSessions(_0x88daee),_0x279e57=_0x3f695f['find'](_0x3428c8=>_0x3428c8['status']==='ready');_0x279e57&&(await _0x5d56b6['EqcGt'](startSession,_0x88daee,_0x279e57['id']),console[_0x574a30(0x1bb)](_0x574a30(0x191)+_0x279e57['iteration']));}catch{}}export async function featureReport(_0x4598b2,_0x2e56eb){const _0x575205=_0x24d357,_0x17c076={'pxgpB':function(_0x17c897){return _0x17c897();},'qTxoV':'No\x20feature\x20review\x20ID\x20provided\x20and\x20no\x20active\x20feature\x20review\x20set.','IfFTA':function(_0x228099,_0x3e952d,_0x32bd83,_0xef5f23){return _0x228099(_0x3e952d,_0x32bd83,_0xef5f23);},'qaDwI':function(_0x30b7cd){return _0x30b7cd();},'EtUky':_0x575205(0x170),'EsGKu':function(_0x4d3a97,_0x2f39ad,_0x45302d){return _0x4d3a97(_0x2f39ad,_0x45302d);},'auhCy':function(_0x3e0ae5,_0x4bf80f,_0xd7fe9d,_0x30629e){return _0x3e0ae5(_0x4bf80f,_0xd7fe9d,_0x30629e);}},_0x55ba14=_0x4598b2||await _0x17c076['pxgpB'](getActiveFeatureId);if(!_0x55ba14)throw new Error(_0x17c076[_0x575205(0x1b0)]);console[_0x575205(0x1bb)]('\x0aGenerating\x20report...');const _0x1e8d2a=await getFeatureReportMarkdown(_0x55ba14,{'style':_0x2e56eb['style']}),_0x19be0c=_0x2e56eb['output']||_0x17c076[_0x575205(0x19b)](join,_0x17c076[_0x575205(0x187)](getRangerDir),_0x17c076['EtUky'],_0x55ba14+'.md'),_0x241646=_0x17c076[_0x575205(0x14a)](join,_0x19be0c,'..');!existsSync(_0x241646)&&await _0x17c076[_0x575205(0x14a)](mkdir,_0x241646,{'recursive':!![]}),await _0x17c076['auhCy'](writeFile,_0x19be0c,_0x1e8d2a,_0x575205(0x125)),console[_0x575205(0x1bb)]('\x0a✅\x20Report\x20generated:\x20'+_0x19be0c);}function getScenarioResult(_0x55698b){const _0x329803=_0x24d357,_0x3ff30b={'LIfdF':function(_0xe1fb58,_0x54ce4b){return _0xe1fb58===_0x54ce4b;},'iyPuo':'closed','yCbKc':'in_progress'};if(_0x3ff30b[_0x329803(0x175)](_0x55698b[_0x329803(0x1e6)],_0x3ff30b['iyPuo']))return _0x55698b['terminalReason']??_0x329803(0x16c);if(_0x55698b['status']===_0x329803(0x1a8))return _0x3ff30b['yCbKc'];return _0x55698b['status'];}function getScenarioRationale(_0xf222c5,_0x379e5f){const _0x3e419b=_0x24d357,_0x4df157={'XMFpO':_0x3e419b(0x18f)},_0x558267=_0x4df157['XMFpO'][_0x3e419b(0x1e9)]('|');let _0x5ec274=0x0;while(!![]){switch(_0x558267[_0x5ec274++]){case'0':if(_0xf222c5['canceledReason'])return _0xf222c5['canceledReason'];continue;case'1':if(_0x379e5f)return _0x379e5f;continue;case'2':return null;case'3':if(_0xf222c5['notes'])return _0xf222c5[_0x3e419b(0x1a9)];continue;case'4':if(_0xf222c5[_0x3e419b(0x13f)])return _0xf222c5[_0x3e419b(0x13f)];continue;case'5':if(_0xf222c5[_0x3e419b(0x140)])return _0xf222c5[_0x3e419b(0x140)];continue;}break;}}export async function featureReportPrDescription(_0x2a1573,_0x1e9c4a){const _0x42d04e=_0x24d357,_0x329ec5={'HMwkl':function(_0x5dcc16){return _0x5dcc16();},'cOGZJ':_0x42d04e(0x12c),'pSsQs':function(_0x3ae8c3,_0x2f8bf1){return _0x3ae8c3===_0x2f8bf1;},'WzfpX':_0x42d04e(0x18d),'Nvotv':'\x0aAvailable\x20scenarios:','hAYUL':function(_0x31aa16,_0x41f94d){return _0x31aa16+_0x41f94d;},'GNokD':'\x0a❌\x20All\x20scenarios\x20were\x20excluded.'},_0x1deefc=_0x2a1573||await _0x329ec5[_0x42d04e(0x1ce)](getActiveFeatureId);if(!_0x1deefc)throw new Error(_0x329ec5[_0x42d04e(0x1df)]);const _0x553640=await getFeature(_0x1deefc),_0x4c322b=_0x553640['checklistItems']||[],_0x5cbec7=getCurrentSessionItems(_0x553640,_0x4c322b);_0x329ec5[_0x42d04e(0x183)](_0x5cbec7['length'],0x0)&&(console['error'](_0x329ec5[_0x42d04e(0x1be)]),process[_0x42d04e(0x15a)](0x1));const _0x18e921=_0x1e9c4a['excludeScenarios']??[],_0x31985a=_0x18e921[_0x42d04e(0x14b)](_0x5df255=>!Number['isInteger'](_0x5df255)||_0x5df255<0x1||_0x5df255>_0x5cbec7['length']);if(_0x31985a[_0x42d04e(0x1de)]>0x0){console[_0x42d04e(0x165)](_0x42d04e(0x123)+_0x31985a['join'](',\x20')),console[_0x42d04e(0x1bb)](_0x329ec5['Nvotv']);for(let _0x9b0d88=0x0;_0x9b0d88<_0x5cbec7['length'];_0x9b0d88++){console['log']('\x20\x20'+_0x329ec5['hAYUL'](_0x9b0d88,0x1)+'.\x20'+_0x5cbec7[_0x9b0d88]['description']);}process['exit'](0x1);}const _0xeb590f=new Set(_0x18e921[_0x42d04e(0x1bc)](_0x2186dd=>_0x2186dd-0x1)),_0x2a13da=_0x5cbec7[_0x42d04e(0x14b)]((_0x2c05c7,_0x1f9445)=>!_0xeb590f[_0x42d04e(0x1a6)](_0x1f9445));_0x2a13da[_0x42d04e(0x1de)]===0x0&&(console[_0x42d04e(0x165)](_0x329ec5['GNokD']),process['exit'](0x1));if(_0x1e9c4a[_0x42d04e(0x12b)])await outputJsonReport(_0x1deefc,_0x553640,_0x2a13da);else{const _0x26ccf8=await getFeatureReportMarkdown(_0x1deefc,{'itemIds':_0x2a13da['map'](_0x404c97=>_0x404c97['id'])});process['stdout'][_0x42d04e(0x1d7)](_0x26ccf8['trimEnd']()+'\x0a');}}async function outputJsonReport(_0x235a44,_0xdf0dd2,_0xd8ae90){const _0x2da812=_0x24d357,_0x55d5d3={'YSqCy':function(_0x5e0ed1,_0xb5c459){return _0x5e0ed1>_0xb5c459;},'fesvJ':function(_0x7b8ee9,_0x46b74c){return _0x7b8ee9(_0x46b74c);},'dyoqF':function(_0x51c535){return _0x51c535();},'gWKsf':function(_0x54fba2,_0x2d2821){return _0x54fba2(_0x2d2821);},'JUbfe':function(_0x4a114d,_0x51192b){return _0x4a114d+_0x51192b;}},_0x1da074=_0x55d5d3['dyoqF'](getApiBaseUrl),_0x4fc319=await _0x55d5d3['gWKsf'](getFeatureReport,_0x235a44),_0x4e72a2=new Map(_0x4fc319['checklistItems']['map'](_0x1b352a=>[_0x1b352a['id'],_0x1b352a])),_0x5d1290=await Promise['all'](_0xd8ae90['map'](async _0x5e6fa1=>{const _0x3d6fd5=_0x50f1,_0x10e16b=_0x4e72a2['get'](_0x5e6fa1['id']),_0x1e5426=_0x10e16b?.[_0x3d6fd5(0x13a)]??null;let _0x21325b=[];if(_0x5e6fa1[_0x3d6fd5(0x1a2)])try{const {steps:_0x114821}=await getBrowserSessionSteps(_0x5e6fa1[_0x3d6fd5(0x1a2)]);_0x55d5d3['YSqCy'](_0x114821[_0x3d6fd5(0x1de)],0x0)&&(_0x21325b=_0x114821[_0x3d6fd5(0x1bc)](_0x71fc87=>{const _0x49711c=_0x3d6fd5,_0x4c53b4=_0x71fc87['assets']['find'](_0x26eb67=>_0x26eb67[_0x49711c(0x1d9)]===_0x49711c(0x188)&&_0x26eb67['timing']==='after')??_0x71fc87['assets']['find'](_0x4c5205=>_0x4c5205[_0x49711c(0x1d9)]===_0x49711c(0x188));let _0x4006d=null,_0x149350=null;if(_0x4c53b4){const _0x41e426=_0x4c53b4['storage']['location']['split']('/')[_0x49711c(0x196)]();_0x4006d=_0x1da074+_0x49711c(0x184)+_0x5e6fa1['browserSessionId']+'/artifacts/'+_0x41e426,_0x41e426&&(_0x149350=_0x41e426['replace'](/\.\w+$/,'')[_0x49711c(0x182)](/^(key_)?\d+_/,'')['replace'](/[-_]/g,'\x20'));}return{'description':_0x149350||_0x71fc87['description']||_0x71fc87[_0x49711c(0x1a3)]||'Step\x20'+_0x71fc87['position'],'screenshot':_0x4006d,'is_key_step':_0x71fc87['isKeyStep']};}));}catch{}return _0x21325b['length']===0x0&&_0x1e5426?.[_0x3d6fd5(0x139)]&&(_0x21325b=_0x1e5426['screenshotUrls'][_0x3d6fd5(0x1bc)]((_0x30f1cd,_0x31ec9d)=>({'description':_0x3d6fd5(0x15c)+(_0x31ec9d+0x1),'screenshot':_0x30f1cd,'is_key_step':![]}))),{'description':_0x5e6fa1['description'],'result':_0x55d5d3['fesvJ'](getScenarioResult,_0x5e6fa1),'rationale':getScenarioRationale(_0x5e6fa1,_0x1e5426?.[_0x3d6fd5(0x18e)]),'steps':_0x21325b};})),_0x172995={'url':_0xdf0dd2[_0x2da812(0x1ad)],'scenarios':_0x5d1290};process['stdout']['write'](_0x55d5d3['JUbfe'](JSON[_0x2da812(0x1ab)](_0x172995,null,0x2),'\x0a'));}export async function featureConcludeSession(_0x2280b6){const _0x53485f=_0x24d357,_0x4c7435={'AwIXB':function(_0x27c757,_0x4df0a4){return _0x27c757(_0x4df0a4);},'mbFrY':_0x53485f(0x118),'fyFGW':'completed','mjqXf':'\x0a✅\x20Session\x20is\x20already\x20completed.','WMSnF':'\x0aConcluding\x20session...'},_0x1c6dc8=_0x2280b6||await getActiveFeatureId();if(!_0x1c6dc8)throw new Error(_0x53485f(0x145));const _0x10082b=await _0x4c7435[_0x53485f(0x1c4)](getFeature,_0x1c6dc8);if(!_0x10082b[_0x53485f(0x199)])throw new Error(_0x53485f(0x1e0));const {sessions:_0x3b9c39}=await listFeatureSessions(_0x1c6dc8),_0x323f56=_0x3b9c39['find'](_0x2f193e=>_0x2f193e['id']===_0x10082b['currentSessionId']);if(!_0x323f56)throw new Error(_0x4c7435['mbFrY']);if(_0x323f56[_0x53485f(0x1e6)]===_0x4c7435[_0x53485f(0x157)]){console['log'](_0x4c7435[_0x53485f(0x1bd)]);return;}if(_0x323f56[_0x53485f(0x1e6)]!==_0x53485f(0x15f))throw new Error(_0x53485f(0x1cd)+_0x323f56[_0x53485f(0x1e6)]);console[_0x53485f(0x1bb)](_0x4c7435['WMSnF']),await concludeSession(_0x1c6dc8,_0x10082b['currentSessionId']),console[_0x53485f(0x1bb)](_0x53485f(0x1d3)+_0x323f56[_0x53485f(0x11f)]+_0x53485f(0x17d)),console[_0x53485f(0x1bb)]('\x20\x20\x20The\x20feature\x20review\x20is\x20now\x20ready\x20for\x20human\x20review\x20on\x20the\x20Ranger\x20dashboard.');}export async function featureSessions(_0x1eb9f6){const _0x510adf=_0x24d357,_0x374dde={'EuWpR':function(_0x5c1014){return _0x5c1014();},'PLqIh':_0x510adf(0x12c),'NWuGu':function(_0x572761,_0x3b3181){return _0x572761(_0x3b3181);}},_0x21c25f=_0x1eb9f6||await _0x374dde['EuWpR'](getActiveFeatureId);if(!_0x21c25f)throw new Error(_0x374dde[_0x510adf(0x16d)]);const _0x5eb6c2=await _0x374dde['NWuGu'](getFeature,_0x21c25f);console[_0x510adf(0x1bb)](_0x510adf(0x120)+_0x5eb6c2[_0x510adf(0x1d6)]+'\x0a');const {sessions:_0x227d91}=await _0x374dde[_0x510adf(0x163)](listFeatureSessions,_0x21c25f);if(_0x227d91['length']===0x0){console['log']('No\x20sessions\x20found.');return;}for(const _0x364b65 of _0x227d91){const _0x3a34b2=_0x364b65[_0x510adf(0x1e6)]===_0x510adf(0x185)?'✅':_0x364b65[_0x510adf(0x1e6)]==='in_progress'?'🔄':'▶️';console[_0x510adf(0x1bb)](_0x3a34b2+_0x510adf(0x166)+_0x364b65[_0x510adf(0x11f)]+'\x20('+_0x364b65['id']+')'),console['log']('\x20\x20\x20Status:\x20'+_0x364b65['status']),console[_0x510adf(0x1bb)]('\x20\x20\x20Created:\x20'+new Date(_0x364b65[_0x510adf(0x178)])['toLocaleString']()),_0x364b65['completedAt']&&console[_0x510adf(0x1bb)](_0x510adf(0x171)+new Date(_0x364b65[_0x510adf(0x1cb)])['toLocaleString']()),console[_0x510adf(0x1bb)]('');}}export async function featureAddScenario(_0x53e11c,_0x54ae61){const _0x2f81ad=_0x24d357,_0x55638d={'DiGJX':function(_0x3941bf){return _0x3941bf();},'GHCoo':function(_0x3ffafd,_0x50c422,_0xbd55e6){return _0x3ffafd(_0x50c422,_0xbd55e6);},'LOQQp':function(_0x1bb9bb,_0x496e69){return _0x1bb9bb(_0x496e69);}},_0xac4ffc=_0x54ae61||await _0x55638d[_0x2f81ad(0x1a4)](getActiveFeatureId);if(!_0xac4ffc)throw new Error(_0x2f81ad(0x145));const _0x4b0dc3=await getFeature(_0xac4ffc);if(_0x4b0dc3[_0x2f81ad(0x15d)]&&!_0x4b0dc3['latestReview']['submittedAt'])throw new Error('Cannot\x20add\x20scenario:\x20feature\x20review\x20has\x20an\x20active\x20review.\x20Please\x20finish\x20your\x20review\x20first:\x20'+_0x4b0dc3[_0x2f81ad(0x1ad)]);await _0x55638d['GHCoo'](createChecklistItem,_0xac4ffc,_0x53e11c);const _0x283a75=await _0x55638d['LOQQp'](getFeature,_0xac4ffc);console[_0x2f81ad(0x1bb)](_0x2f81ad(0x167)),displayFeature(_0x283a75,_0x283a75['checklistItems']);}export async function featureEditScenario(_0x1da771,_0x3738b0){const _0x10aa4b=_0x24d357,_0x2d9ebf={'MGVuE':function(_0x277996){return _0x277996();},'QKYlt':'\x0a❌\x20No\x20feature\x20review\x20ID\x20provided\x20and\x20no\x20active\x20feature\x20review\x20set.','HNFpg':'Run:\x20ranger\x20resume\x20<id>\x20to\x20set\x20an\x20active\x20feature\x20review','klYQO':function(_0x5599f6,_0x340884){return _0x5599f6(_0x340884);},'dQTyC':function(_0x3dca38,_0xf8e7a4){return _0x3dca38===_0xf8e7a4;},'OTGDK':_0x10aa4b(0x173),'GztSh':_0x10aa4b(0x1dd),'PMZCM':function(_0x1da774,_0x58fd28){return _0x1da774+_0x58fd28;},'qEKpr':function(_0x3cb902,_0x433dae){return _0x3cb902-_0x433dae;},'CKgxp':function(_0x52509a,_0x293b8d){return _0x52509a+_0x293b8d;},'EKwUC':function(_0x568064,_0x107df3,_0x231b68,_0x3a080c){return _0x568064(_0x107df3,_0x231b68,_0x3a080c);},'cYABu':function(_0x437ca5,_0x4cc404,_0x1bb7f5){return _0x437ca5(_0x4cc404,_0x1bb7f5);}},_0x4fff97=_0x3738b0['id']||await _0x2d9ebf[_0x10aa4b(0x1f0)](getActiveFeatureId);!_0x4fff97&&(console['error'](_0x2d9ebf['QKYlt']),console['error'](_0x2d9ebf['HNFpg']),process[_0x10aa4b(0x15a)](0x1));const _0x3da1a9=await _0x2d9ebf['klYQO'](getFeature,_0x4fff97);_0x3da1a9[_0x10aa4b(0x15d)]&&!_0x3da1a9['latestReview'][_0x10aa4b(0x1eb)]&&(console['error'](_0x10aa4b(0x1da)),console[_0x10aa4b(0x165)](_0x10aa4b(0x1b1)),console[_0x10aa4b(0x165)]('\x20\x20'+_0x3da1a9['dashboardUrl']),process[_0x10aa4b(0x15a)](0x1));const _0x3c0394=_0x3da1a9[_0x10aa4b(0x147)]||[];_0x2d9ebf['dQTyC'](_0x3c0394[_0x10aa4b(0x1de)],0x0)&&(console['error'](_0x2d9ebf['OTGDK']),process[_0x10aa4b(0x15a)](0x1));if(_0x2d9ebf[_0x10aa4b(0x1b8)](_0x3738b0['scenario'],undefined)){console['error']('\x0a❌\x20No\x20scenario\x20number\x20provided.\x20Use\x20--scenario\x20<number>.'),console['log'](_0x2d9ebf['GztSh']);for(let _0x308240=0x0;_0x308240<_0x3c0394[_0x10aa4b(0x1de)];_0x308240++){console[_0x10aa4b(0x1bb)]('\x20\x20'+_0x2d9ebf['PMZCM'](_0x308240,0x1)+'.\x20'+_0x3c0394[_0x308240]['description']);}process[_0x10aa4b(0x15a)](0x1);}const _0x26f630=_0x2d9ebf[_0x10aa4b(0x169)](_0x3738b0[_0x10aa4b(0x14f)],0x1);if(_0x26f630<0x0||_0x26f630>=_0x3c0394[_0x10aa4b(0x1de)]){console['error'](_0x10aa4b(0x14d)+_0x3738b0['scenario']+_0x10aa4b(0x198)+_0x3c0394[_0x10aa4b(0x1de)]+'\x20scenarios.'),console['log']('\x0aAvailable\x20scenarios:');for(let _0xf5f409=0x0;_0xf5f409<_0x3c0394[_0x10aa4b(0x1de)];_0xf5f409++){console['log']('\x20\x20'+_0x2d9ebf[_0x10aa4b(0x1cc)](_0xf5f409,0x1)+'.\x20'+_0x3c0394[_0xf5f409][_0x10aa4b(0x1e7)]);}process[_0x10aa4b(0x15a)](0x1);}const _0x56bc76=_0x3c0394[_0x26f630];await _0x2d9ebf['EKwUC'](updateChecklistItem,_0x4fff97,_0x56bc76['id'],{'description':_0x1da771});const _0x81cbe=await _0x2d9ebf['klYQO'](getFeature,_0x4fff97);console[_0x10aa4b(0x1bb)]('\x0a✅\x20Scenario\x20updated'),_0x2d9ebf['cYABu'](displayFeature,_0x81cbe,_0x81cbe['checklistItems']);}async function downloadFeedbackImage(_0x608aac,_0x1ec51e){const _0x2409ca=_0x24d357,_0x2b2239={'YiITU':'feedback-images','FoxFX':function(_0xdfc907,_0x229236,_0x400188){return _0xdfc907(_0x229236,_0x400188);},'pzAlP':function(_0x2cb0f6,_0x11ee67){return _0x2cb0f6(_0x11ee67);}};try{const _0x40444f=join(getRangerDir(),_0x2b2239['YiITU']);await mkdir(_0x40444f,{'recursive':!![]});const _0x4537e0=_0x2b2239[_0x2409ca(0x131)](join,_0x40444f,'comment_'+_0x1ec51e+'.png'),_0x37efc6=await _0x2b2239['pzAlP'](fetch,_0x608aac);if(!_0x37efc6['ok'])return null;const _0x4ed454=Buffer[_0x2409ca(0x11e)](await _0x37efc6[_0x2409ca(0x161)]());return await _0x2b2239['FoxFX'](writeFile,_0x4537e0,_0x4ed454),_0x4537e0;}catch{return null;}}export async function featureGetReview(_0x5f18e6){const _0x312f0f=_0x24d357,_0x39c98d={'RdpVj':function(_0x591bf0){return _0x591bf0();},'guLad':'No\x20feature\x20review\x20ID\x20provided\x20and\x20no\x20active\x20feature\x20review\x20set.\x20Run:\x20ranger\x20resume\x20<id>\x20to\x20set\x20an\x20active\x20feature\x20review','FYPLP':_0x312f0f(0x17a),'yciUj':function(_0x59a31f,_0x4303ce){return _0x59a31f>_0x4303ce;},'CvsjS':'en-US','KRBfa':'point','LaeAm':function(_0x9d00e2,_0x3fa25e){return _0x9d00e2+_0x3fa25e;}},_0x3bed7b=_0x5f18e6||await _0x39c98d[_0x312f0f(0x16e)](getActiveFeatureId);if(!_0x3bed7b)throw new Error(_0x39c98d[_0x312f0f(0x1dc)]);const _0x2594ae=await getFeature(_0x3bed7b),{items:_0xce874f}=await getActionItems(_0x3bed7b);console[_0x312f0f(0x1bb)]('\x0a📋\x20Feedback\x20for:\x20'+_0x2594ae[_0x312f0f(0x1d6)]+'\x20('+_0x2594ae['id']+')\x0a');if(_0xce874f['length']===0x0){console[_0x312f0f(0x1bb)](_0x39c98d[_0x312f0f(0x1b3)]);return;}for(let _0x45fa13=0x0;_0x45fa13<_0xce874f[_0x312f0f(0x1de)];_0x45fa13++){const _0x115067=_0xce874f[_0x45fa13],_0x5b0ab1=_0x39c98d[_0x312f0f(0x17c)](_0x115067[_0x312f0f(0x124)],0x1)?'\x20(v'+_0x115067[_0x312f0f(0x124)]+')':'',_0x4d0cde=await getItemFeedback(_0x3bed7b,_0x115067['id']);if(_0x4d0cde['unaddressedComments'][_0x312f0f(0x1de)]>0x0){console[_0x312f0f(0x1bb)](_0x312f0f(0x1d4)+(_0x45fa13+0x1)+_0x312f0f(0x134)+_0x115067['description']+'\x22'+_0x5b0ab1+_0x312f0f(0x12e)+_0x4d0cde[_0x312f0f(0x17b)]['length']+'\x20unaddressed\x20comment(s)');for(const _0x1589e2 of _0x4d0cde[_0x312f0f(0x17b)]){const _0x1896fb=new Date(_0x1589e2['createdAt'])['toLocaleDateString'](_0x39c98d['CvsjS'],{'month':'short','day':_0x312f0f(0x130)}),_0x2f73c5=_0x1589e2[_0x312f0f(0x1ef)]||_0x1589e2['authorEmail']||'Unknown';console['log']('\x20\x20💬\x20'+_0x2f73c5+'\x20('+_0x1896fb+_0x312f0f(0x160)+_0x1589e2['content']+'\x22');if(_0x1589e2['assetUrl']){const _0x2f3876=await downloadFeedbackImage(_0x1589e2[_0x312f0f(0x14c)],_0x1589e2['id']);_0x2f3876&&console[_0x312f0f(0x1bb)]('\x20\x20\x20\x20\x20📷\x20Screenshot:\x20'+_0x2f3876);}if(_0x1589e2[_0x312f0f(0x148)]){const _0xadd8aa=_0x1589e2[_0x312f0f(0x148)]['selector'][_0x312f0f(0x1e9)]('\x20>\x20')['pop']()?.[_0x312f0f(0x1e9)](':')[0x0]||'element',_0x1b16ed=_0x1589e2['domRef']['textContent']?'\x20\x22'+_0x1589e2[_0x312f0f(0x148)]['textContent']['slice'](0x0,0x3c)+'\x22':'';console[_0x312f0f(0x1bb)](_0x312f0f(0x1f1)+_0xadd8aa+'>'+_0x1b16ed),console['log'](_0x312f0f(0x1db)+_0x1589e2[_0x312f0f(0x148)]['selector']);}else{if(_0x1589e2['spatial']){const _0x2108d7=_0x1589e2[_0x312f0f(0x14e)][_0x312f0f(0x190)];_0x1589e2[_0x312f0f(0x14e)]['type']===_0x39c98d['KRBfa']&&_0x2108d7['length']>=0x2?console[_0x312f0f(0x1bb)](_0x312f0f(0x1ee)+_0x2108d7[0x0]['toFixed'](0x2)+',\x20'+_0x2108d7[0x1][_0x312f0f(0x1c3)](0x2)+')'):console[_0x312f0f(0x1bb)]('\x20\x20\x20\x20\x20📍\x20Annotation:\x20'+_0x1589e2['spatial']['type']+_0x312f0f(0x1d2)+_0x2108d7['map'](_0x4b19d4=>_0x4b19d4[_0x312f0f(0x1c3)](0x2))['join'](',\x20')+']');}}}if(_0x4d0cde[_0x312f0f(0x141)]){console[_0x312f0f(0x1bb)](_0x312f0f(0x1ed));for(const _0x2fd090 of _0x4d0cde[_0x312f0f(0x141)]['split']('\x0a')){console['log'](_0x312f0f(0x154)+_0x2fd090);}}}else console['log']('Scenario\x20'+_0x39c98d[_0x312f0f(0x128)](_0x45fa13,0x1)+_0x312f0f(0x134)+_0x115067['description']+'\x22'+_0x5b0ab1+_0x312f0f(0x179)),console['log']('\x20\x20✅\x20No\x20feedback\x20to\x20address');console['log']('');}}export async function featureDelete(_0x2a2f25){const _0x1d999f=_0x24d357,_0x5f5cdd={'EfSHv':_0x1d999f(0x145),'VKwMj':function(_0x2ff31c,_0x42cbdc){return _0x2ff31c(_0x42cbdc);},'aYoUS':function(_0x188a04,_0x642039){return _0x188a04+_0x642039;},'zBOBd':'\x20\x20\x20To\x20restore\x20it,\x20run:\x20ranger\x20restore\x20'},_0x45a35e=_0x2a2f25||await getActiveFeatureId();if(!_0x45a35e)throw new Error(_0x5f5cdd['EfSHv']);const _0x2cae14=await getFeature(_0x45a35e);await _0x5f5cdd['VKwMj'](softDeleteFeature,_0x45a35e),console['log'](_0x1d999f(0x1e3)+_0x2cae14['name']+'\x20('+_0x45a35e+')'),console[_0x1d999f(0x1bb)](_0x5f5cdd['aYoUS'](_0x5f5cdd[_0x1d999f(0x168)],_0x45a35e));}export async function featureRestore(_0x3167b9){const _0xec319e=_0x24d357,_0x231f31={'LxsqR':function(_0x4c1fa9,_0x8a8a08){return _0x4c1fa9(_0x8a8a08);},'LzDWL':function(_0x38d15a,_0x5aabc8){return _0x38d15a(_0x5aabc8);}};await _0x231f31[_0xec319e(0x122)](restoreFeature,_0x3167b9);const _0x43bc72=await _0x231f31[_0xec319e(0x1ec)](getFeature,_0x3167b9);console[_0xec319e(0x1bb)]('\x0a✅\x20Restored\x20feature\x20review:\x20'+_0x43bc72['name']+'\x20('+_0x3167b9+')'),displayFeature(_0x43bc72,_0x43bc72['checklistItems']);}
1
+ const _0x5ccc84=_0x4e5e;(function(_0x1d7d6a,_0x2876a6){const _0x34c9e0=_0x4e5e,_0x3f6a49=_0x1d7d6a();while(!![]){try{const _0x138357=-parseInt(_0x34c9e0(0xa4))/0x1+parseInt(_0x34c9e0(0x107))/0x2*(parseInt(_0x34c9e0(0xc3))/0x3)+parseInt(_0x34c9e0(0xed))/0x4+-parseInt(_0x34c9e0(0x111))/0x5*(parseInt(_0x34c9e0(0x11e))/0x6)+-parseInt(_0x34c9e0(0x115))/0x7*(-parseInt(_0x34c9e0(0x106))/0x8)+-parseInt(_0x34c9e0(0x130))/0x9+parseInt(_0x34c9e0(0x131))/0xa;if(_0x138357===_0x2876a6)break;else _0x3f6a49['push'](_0x3f6a49['shift']());}catch(_0x93185c){_0x3f6a49['push'](_0x3f6a49['shift']());}}}(_0x3995,0x3325a));import{readFile,writeFile,mkdir}from'fs/promises';import{join}from'path';import{existsSync}from'fs';import{execSync}from'child_process';import _0x3c4e02 from'inquirer';import{createFeature,listFeatures,getFeature,updateFeature,getFeatureReport,getFeatureReportMarkdown,listFeatureSessions,startSession,concludeSession,createChecklistItem,getActionItems,getItemFeedback,softDeleteFeature,restoreFeature,updateChecklistItem}from'./utils/featureApi.js';import{getBrowserSessionSteps}from'./utils/browserSessionsApi.js';import{getApiBaseUrl}from'./utils/environment.js';import{getRangerDir}from'./utils/rangerRoot.js';import{registerSession}from'./utils/sessionCache.js';import{getEnvNames}from'./env.js';import{formatProfileRequiredMessage}from'./utils/profileMessages.js';const ACTIVE_FEATURE_FILE=_0x5ccc84(0x141),bold=_0x8e1747=>_0x5ccc84(0xad)+_0x8e1747+_0x5ccc84(0xc4);function getGitRepoUrl(){const _0x6baccf=_0x5ccc84,_0x1525f8={'NClhD':'pipe'};try{const _0x3bbd4b=execSync(_0x6baccf(0xb8),{'encoding':_0x6baccf(0xc1),'stdio':[_0x6baccf(0xd1),_0x1525f8['NClhD'],_0x1525f8[_0x6baccf(0xcf)]]})[_0x6baccf(0x15c)]();return _0x3bbd4b['replace'](/\.git$/,'')['replace'](/^git@github\.com:/,'github.com/')['replace'](/^https?:\/\//,'');}catch{return undefined;}}function getGitBranch(){const _0x45efff=_0x5ccc84,_0x309fdc={'FMsmm':function(_0x38fd20,_0x41e9d7,_0x88a6db){return _0x38fd20(_0x41e9d7,_0x88a6db);},'rNQNG':'pipe'};try{return _0x309fdc['FMsmm'](execSync,'git\x20rev-parse\x20--abbrev-ref\x20HEAD',{'encoding':_0x45efff(0xc1),'stdio':[_0x309fdc[_0x45efff(0x160)],_0x309fdc[_0x45efff(0x160)],_0x309fdc['rNQNG']]})[_0x45efff(0x15c)]();}catch{return undefined;}}export async function getActiveFeatureId(){const _0x434b6d=_0x5ccc84,_0x252ec2={'JqdmV':function(_0x1284c1,_0x54620e,_0x59a17b){return _0x1284c1(_0x54620e,_0x59a17b);},'Zbtjl':function(_0xefe4c9){return _0xefe4c9();},'HklAG':function(_0x2b91ed,_0x51991c,_0x21c5b7){return _0x2b91ed(_0x51991c,_0x21c5b7);},'yluAJ':_0x434b6d(0xc1)},_0x356ade=_0x252ec2[_0x434b6d(0x78)](join,_0x252ec2['Zbtjl'](getRangerDir),ACTIVE_FEATURE_FILE);if(!existsSync(_0x356ade))return null;try{const _0x1e4ac3=await _0x252ec2[_0x434b6d(0xe6)](readFile,_0x356ade,_0x252ec2[_0x434b6d(0x149)]);return _0x1e4ac3['trim']()||null;}catch{return null;}}async function setActiveFeatureId(_0x560a40){const _0x3d311f=_0x5ccc84,_0x576da9={'MumEu':function(_0x45283b){return _0x45283b();},'TjRlp':function(_0x3638e1,_0x53ba20,_0x25344d){return _0x3638e1(_0x53ba20,_0x25344d);},'fkphW':function(_0x278668,_0x2fd36e){return _0x278668(_0x2fd36e);}},_0x149510=_0x576da9[_0x3d311f(0x15d)](getRangerDir),_0x294c64=_0x576da9['TjRlp'](join,_0x149510,ACTIVE_FEATURE_FILE);!_0x576da9[_0x3d311f(0xd4)](existsSync,_0x149510)&&await mkdir(_0x149510,{'recursive':!![]}),await writeFile(_0x294c64,_0x560a40,'utf-8');}function _0x4e5e(_0x5aa5dc,_0x3741f7){_0x5aa5dc=_0x5aa5dc-0x70;const _0x399529=_0x3995();let _0x4e5e09=_0x399529[_0x5aa5dc];return _0x4e5e09;}function getProgressDisplay(_0x16008f){const _0x43518d=_0x5ccc84,_0x28deee={'etBsP':function(_0x1ad7a5,_0x3463ce){return _0x1ad7a5+_0x3463ce;},'rBLKm':function(_0x5b4c47,_0x4623e7){return _0x5b4c47===_0x4623e7;},'EpqYs':function(_0x1d95b0,_0x218ac8){return _0x1d95b0*_0x218ac8;},'FqFpC':function(_0x46a5a9,_0x482ff3){return _0x46a5a9+_0x482ff3;},'gVrUJ':function(_0x639b7c,_0x2564d1){return _0x639b7c>_0x2564d1;},'wtCFm':function(_0x26a423,_0x335928){return _0x26a423>_0x335928;},'VVSip':function(_0x3d36f0,_0x4c9f90){return _0x3d36f0>_0x4c9f90;}},_0x47c324=_0x16008f['verifiedItems']||0x0,_0x538b3f=_0x16008f[_0x43518d(0x136)]||0x0,_0x56ced2=_0x16008f['blockedItems']||0x0,_0x551f6a=_0x16008f[_0x43518d(0xbf)]||0x0,_0x994d7d=_0x16008f['pendingItems']||0x0,_0x3c627f=_0x28deee[_0x43518d(0x9e)](_0x28deee['etBsP'](_0x28deee[_0x43518d(0x9e)](_0x47c324+_0x538b3f,_0x56ced2),_0x551f6a),_0x994d7d);if(_0x28deee[_0x43518d(0xfd)](_0x3c627f,0x0))return'-';const _0x4f5b0f=0xa,_0x3f9109=Math['round'](_0x28deee['EpqYs'](_0x47c324/_0x3c627f,_0x4f5b0f)),_0x305dc4=_0x28deee['FqFpC']('█'[_0x43518d(0x152)](_0x3f9109),'░'[_0x43518d(0x152)](_0x4f5b0f-_0x3f9109)),_0x5a4cc0=[];if(_0x28deee['gVrUJ'](_0x56ced2,0x0))_0x5a4cc0['push'](_0x56ced2+_0x43518d(0x145));if(_0x28deee['wtCFm'](_0x551f6a,0x0))_0x5a4cc0['push'](_0x551f6a+_0x43518d(0xae));if(_0x28deee['VVSip'](_0x538b3f,0x0))_0x5a4cc0[_0x43518d(0x12a)](_0x538b3f+'\x20in\x20progress');const _0x3ae0f5=_0x28deee['gVrUJ'](_0x5a4cc0['length'],0x0)?'\x20('+_0x5a4cc0['join'](',\x20')+')':'';return _0x305dc4+'\x20'+_0x47c324+'/'+_0x3c627f+'\x20verified'+_0x3ae0f5;}function getCurrentSessionItems(_0xb226b3,_0x286f85){const _0x442363=_0x5ccc84;if(!_0xb226b3[_0x442363(0x144)])return _0x286f85['filter'](_0x22840e=>!_0x22840e['sessionId']);return _0x286f85['filter'](_0x28fb69=>_0x28fb69[_0x442363(0x119)]===_0xb226b3['currentSessionId']||!_0x28fb69[_0x442363(0x119)]);}function displayFeature(_0x2bb8de,_0xc469da){const _0xc67079=_0x5ccc84,_0x2d79b2={'EYSur':function(_0x35788a,_0x2a721b){return _0x35788a(_0x2a721b);},'huLLw':'\x0a\x20\x20\x20Scenarios:','mwZhW':_0xc67079(0xf9),'Oltgt':function(_0x275f4b,_0x155f94){return _0x275f4b===_0x155f94;},'iDfbZ':'verified','OJdTq':'incomplete','gFyPs':'verification_in_progress','UTXmJ':function(_0x26db8a,_0x3f1ed1){return _0x26db8a!==_0x3f1ed1;},'tavCr':_0xc67079(0xbe),'OOEuN':function(_0x287e6d,_0x5d6cba){return _0x287e6d===_0x5d6cba;},'tlqaR':function(_0x27f20b,_0x459b07){return _0x27f20b===_0x459b07;},'WHuqk':'approved'};console['log']('\x0a'+_0x2bb8de[_0xc67079(0x162)]+'\x20('+_0x2bb8de[_0xc67079(0xd0)]+')');_0x2bb8de[_0xc67079(0xb2)]&&console[_0xc67079(0x153)]('\x20\x20\x20Progress:\x20'+_0x2d79b2[_0xc67079(0x12e)](getProgressDisplay,_0x2bb8de['stats']));_0x2bb8de[_0xc67079(0xbc)]&&console['log'](_0xc67079(0xbb)+_0x2bb8de['description']);_0x2bb8de['gitRepoUrl']&&console['log'](_0xc67079(0x13e)+_0x2bb8de['gitRepoUrl']);_0x2bb8de['gitBranch']&&console['log']('\x20\x20\x20Branch:\x20'+_0x2bb8de['gitBranch']);console[_0xc67079(0x153)](_0xc67079(0xab)+new Date(_0x2bb8de[_0xc67079(0xe3)])[_0xc67079(0xac)]());_0x2bb8de[_0xc67079(0x74)]&&console[_0xc67079(0x153)]('\x20\x20\x20Completed:\x20'+new Date(_0x2bb8de[_0xc67079(0x74)])['toLocaleString']());if(_0xc469da&&_0xc469da['length']>0x0){console[_0xc67079(0x153)](_0x2d79b2[_0xc67079(0x87)]);for(let _0x35c828=0x0;_0x35c828<_0xc469da['length'];_0x35c828++){const _0x179125=_0xc469da[_0x35c828];let _0x5a62ae;if(_0x179125['status']===_0x2d79b2[_0xc67079(0x14e)]&&_0x2d79b2['Oltgt'](_0x179125['terminalReason'],'approved'))_0x5a62ae='✅';else{if(_0x179125['status']===_0x2d79b2[_0xc67079(0x150)])_0x5a62ae='🟢';else{if(_0x179125[_0xc67079(0xc5)]===_0x2d79b2['OJdTq'])_0x5a62ae='🟠';else{if(_0x179125['status']===_0xc67079(0xd5))_0x5a62ae='🛑';else{if(_0x179125[_0xc67079(0xc5)]===_0x2d79b2[_0xc67079(0x14e)])_0x5a62ae='⛔';else _0x179125[_0xc67079(0xc5)]===_0x2d79b2[_0xc67079(0x13b)]?_0x5a62ae='⏳':_0x5a62ae='⬜';}}}}const _0x4a2e49=_0x179125[_0xc67079(0x148)]>0x1?_0xc67079(0xf0)+_0x179125['version']+')':'',_0x15b35c=_0x179125[_0xc67079(0x148)]>0x1&&_0x179125['parentItemId']&&_0x2d79b2[_0xc67079(0xaa)](_0x179125['status'],'closed')&&_0x179125[_0xc67079(0xc5)]!==_0xc67079(0xe4)?_0x2d79b2['tavCr']:'';console['log']('\x20\x20\x20'+(_0x35c828+0x1)+'.\x20'+_0x5a62ae+'\x20'+_0x179125[_0xc67079(0xbc)]+_0x4a2e49+_0x15b35c);_0x2d79b2['OOEuN'](_0x179125['status'],_0xc67079(0xd5))&&_0x179125['blockedReason']&&console[_0xc67079(0x153)]('\x20\x20\x20\x20\x20\x20Blocked:\x20'+_0x179125['blockedReason']);_0x2d79b2['tlqaR'](_0x179125['status'],_0x2d79b2['OJdTq'])&&_0x179125[_0xc67079(0xc9)]&&console['log'](_0xc67079(0x125)+_0x179125['incompleteReason']);if(_0x2d79b2['Oltgt'](_0x179125['status'],'closed')&&_0x2d79b2['tlqaR'](_0x179125['terminalReason'],_0x2d79b2['WHuqk']))console['log']('\x20\x20\x20\x20\x20\x20Approved');else _0x179125[_0xc67079(0xc5)]===_0x2d79b2['mwZhW']&&_0x179125[_0xc67079(0xca)]&&console['log']('\x20\x20\x20\x20\x20\x20Cancelled:\x20'+_0x179125['canceledReason']);}}}export async function featureCreate(_0x17f7de,_0x83acc9){const _0x39c171=_0x5ccc84,_0x1b9f0e={'NdRZT':function(_0x5356b6){return _0x5356b6();},'Nipcs':function(_0xab9b4b,_0xb4dcc6){return _0xab9b4b(_0xb4dcc6);},'jEmof':function(_0x33558b){return _0x33558b();},'rOliH':'\x0aCreating\x20feature\x20review...','GFONK':function(_0x106eac,_0x3c8cbf){return _0x106eac(_0x3c8cbf);},'IAeYE':function(_0x1f3098,_0x272ab7,_0x121831){return _0x1f3098(_0x272ab7,_0x121831);}},{envNames:_0x4abff2}=await _0x1b9f0e[_0x39c171(0xdd)](getEnvNames);_0x4abff2['length']===0x0&&console[_0x39c171(0xb5)]('\x0a'+_0x1b9f0e['Nipcs'](formatProfileRequiredMessage,_0x59c7f1=>bold(_0x59c7f1)));const _0x1f1b2e=_0x83acc9[_0x39c171(0x92)]?_0x83acc9[_0x39c171(0x92)][_0x39c171(0xf2)](_0x1cc694=>_0x1cc694['trim']()):[],_0x3f7ab9=getGitRepoUrl(),_0xe42535=_0x1b9f0e[_0x39c171(0xf1)](getGitBranch);console[_0x39c171(0x153)](_0x1b9f0e[_0x39c171(0x12b)]);const _0x43a28b=await _0x1b9f0e[_0x39c171(0x8c)](createFeature,{'name':_0x17f7de,'description':_0x83acc9['description'],'checklist':_0x1f1b2e,'gitRepoUrl':_0x3f7ab9,'gitBranch':_0xe42535});await setActiveFeatureId(_0x43a28b['id']),await tryStartCurrentSession(_0x43a28b['id']);const _0x1f3972=process['env']['CLAUDE_SESSION_ID'];_0x1f3972&&_0x1b9f0e[_0x39c171(0xd6)](registerSession,_0x1f3972,_0x43a28b['id']),console[_0x39c171(0x153)](_0x39c171(0x81)+_0x43a28b['id']),_0x1b9f0e[_0x39c171(0xd6)](displayFeature,_0x43a28b,_0x43a28b[_0x39c171(0x117)]),console['log'](_0x39c171(0xee));}export async function featureList(_0x48c49e){const _0x337a5b=_0x5ccc84,_0x1600ee={'JkRKO':function(_0xfee8f4,_0x3b5047){return _0xfee8f4===_0x3b5047;},'WIDMl':function(_0x1af9f1,_0x64ec41){return _0x1af9f1(_0x64ec41);},'QpAEB':function(_0x4bd541,_0x5d3372){return _0x4bd541+_0x5d3372;},'IRRVg':function(_0x19c787,_0x164349){return _0x19c787<_0x164349;},'VtuTa':function(_0x437e4b,_0x166ee9){return _0x437e4b!==_0x166ee9;},'Dfzdx':'\x20--current-branch'},_0x26b3ea={'limit':_0x48c49e['limit']??0xa,'offset':_0x48c49e[_0x337a5b(0xa0)]??0x0,'includeDeleted':_0x48c49e['includeDeleted']};_0x48c49e['currentBranch']&&(_0x26b3ea['gitRepoUrl']=getGitRepoUrl(),_0x26b3ea['gitBranch']=getGitBranch());const _0x2c569a=await listFeatures(_0x26b3ea);if(_0x1600ee[_0x337a5b(0xcc)](_0x2c569a['items']['length'],0x0)){console[_0x337a5b(0x153)]('\x0aNo\x20feature\x20reviews\x20found.');return;}const _0x4c73ed=_0x2c569a[_0x337a5b(0x94)]>_0x2c569a[_0x337a5b(0x158)]['length']?_0x337a5b(0x11c)+_0x2c569a[_0x337a5b(0x158)]['length']+'\x20of\x20'+_0x2c569a[_0x337a5b(0x94)]:_0x2c569a[_0x337a5b(0x94)]+_0x337a5b(0x11f);console['log']('\x0a'+_0x4c73ed+':\x0a');for(const _0x338180 of _0x2c569a[_0x337a5b(0x158)]){const _0x304ba3=_0x337a5b(0x12c)['split']('|');let _0x2c194b=0x0;while(!![]){switch(_0x304ba3[_0x2c194b++]){case'0':_0x338180[_0x337a5b(0x151)]&&console['log']('\x20\x20\x20Branch:\x20'+_0x338180[_0x337a5b(0x151)]);continue;case'1':console[_0x337a5b(0x153)]('\x20\x20\x20Created:\x20'+new Date(_0x338180[_0x337a5b(0xe3)])[_0x337a5b(0xbd)]());continue;case'2':console[_0x337a5b(0x153)](''+_0x338180['name']);continue;case'3':console[_0x337a5b(0x153)](_0x337a5b(0x11b)+_0x338180['id']);continue;case'4':_0x338180['stats']&&console[_0x337a5b(0x153)](_0x337a5b(0x139)+_0x1600ee['WIDMl'](getProgressDisplay,_0x338180['stats']));continue;case'5':console[_0x337a5b(0x153)]('');continue;}break;}}const _0x58fdb9=_0x26b3ea[_0x337a5b(0x102)]??0xa,_0x336adb=_0x1600ee[_0x337a5b(0x15b)](_0x26b3ea[_0x337a5b(0xa0)]??0x0,_0x2c569a[_0x337a5b(0x158)]['length']);if(_0x1600ee[_0x337a5b(0xe7)](_0x336adb,_0x2c569a['totalCount'])){const _0x4099fb=_0x1600ee[_0x337a5b(0x13f)](_0x58fdb9,0xa)?'\x20--limit\x20'+_0x58fdb9:'',_0x1e0dd4=_0x48c49e[_0x337a5b(0xdf)]?_0x1600ee['Dfzdx']:'',_0x5dee40=_0x48c49e['includeDeleted']?_0x337a5b(0x135):'';console['log']('Next\x20page:\x20ranger\x20list\x20--offset\x20'+_0x336adb+_0x4099fb+_0x1e0dd4+_0x5dee40);}}export async function featureShow(_0x2fd802){const _0x5668ef=_0x5ccc84,_0x15ef57={'pZXQW':function(_0x17a768){return _0x17a768();}},_0x42f53d=_0x2fd802||await _0x15ef57[_0x5668ef(0xda)](getActiveFeatureId);if(!_0x42f53d)throw new Error(_0x5668ef(0x96));const _0x2c5a18=await getFeature(_0x42f53d);displayFeature(_0x2c5a18,_0x2c5a18[_0x5668ef(0x117)]);}export async function featureResume(_0x424312){const _0x2bdccf=_0x5ccc84,_0x3c0fcd={'mYimd':function(_0x51c417,_0x1d05dc){return _0x51c417(_0x1d05dc);},'DiEAN':function(_0x9d503b,_0xa9825f){return _0x9d503b(_0xa9825f);},'amsXT':function(_0x140a44){return _0x140a44();},'NGDlL':function(_0x27fc26,_0x50207f){return _0x27fc26!==_0x50207f;},'NWtbA':function(_0x5544da,_0x17590d,_0x2fb711){return _0x5544da(_0x17590d,_0x2fb711);},'lGiaF':function(_0x322d31,_0xbd2d81,_0x1b1965){return _0x322d31(_0xbd2d81,_0x1b1965);},'cUPWM':function(_0x243d86,_0x2b9c81){return _0x243d86(_0x2b9c81);},'ulTLn':function(_0x2a6065){return _0x2a6065();},'NiEaY':_0x2bdccf(0x126),'YeapK':_0x2bdccf(0x82),'tWxHg':function(_0x322986,_0x2ec4aa){return _0x322986(_0x2ec4aa);},'VYNLT':_0x2bdccf(0x146),'YaEHY':_0x2bdccf(0xb9),'iykzt':_0x2bdccf(0xb6)};if(_0x424312){const _0x8da21d=await _0x3c0fcd['mYimd'](getFeature,_0x424312);await _0x3c0fcd[_0x2bdccf(0x7d)](setActiveFeatureId,_0x8da21d['id']);const _0x18e754=_0x3c0fcd[_0x2bdccf(0x85)](getGitBranch);_0x18e754&&_0x3c0fcd[_0x2bdccf(0x7a)](_0x18e754,_0x8da21d[_0x2bdccf(0x151)])&&(await _0x3c0fcd['NWtbA'](updateFeature,_0x8da21d['id'],{'gitBranch':_0x18e754}),console['log']('\x20\x20\x20Updated\x20branch\x20to:\x20'+_0x18e754));console['log']('\x0a✅\x20Resumed\x20feature\x20review:\x20'+_0x8da21d[_0x2bdccf(0x162)]+'\x20('+_0x8da21d['id']+')'),await _0x3c0fcd[_0x2bdccf(0x8f)](tryStartCurrentSession,_0x8da21d['id']);const _0x522192=process['env'][_0x2bdccf(0xa3)];_0x522192&&_0x3c0fcd['lGiaF'](registerSession,_0x522192,_0x8da21d['id']);_0x3c0fcd['NWtbA'](displayFeature,_0x8da21d,_0x8da21d[_0x2bdccf(0x117)]),await _0x3c0fcd[_0x2bdccf(0x14c)](printFeedbackNudge,_0x8da21d['id']);return;}const _0x462396=_0x3c0fcd['ulTLn'](getGitRepoUrl),_0x22906b=getGitBranch();if(!_0x462396&&!_0x22906b)throw new Error(_0x3c0fcd['NiEaY']);console['log'](_0x2bdccf(0xf6)+(_0x462396||_0x3c0fcd[_0x2bdccf(0xa9)])+'\x20/\x20'+(_0x22906b||_0x3c0fcd[_0x2bdccf(0xa9)])+_0x2bdccf(0xfa));const _0x4bcea2=await _0x3c0fcd[_0x2bdccf(0x80)](listFeatures,{'gitRepoUrl':_0x462396,'gitBranch':_0x22906b}),_0x172afb=_0x4bcea2['items'][_0x2bdccf(0x134)](_0x52b0a8=>_0x52b0a8['status']?_0x52b0a8['status']!=='verified':!_0x52b0a8['completedAt']);if(_0x172afb[_0x2bdccf(0xd2)]===0x0){console['log'](_0x3c0fcd['VYNLT']),console[_0x2bdccf(0x153)](_0x2bdccf(0xd7));return;}let _0x4b91ec;if(_0x172afb[_0x2bdccf(0xd2)]===0x1)_0x4b91ec=_0x172afb[0x0];else{const _0xb43e29=process[_0x2bdccf(0xb7)][_0x2bdccf(0x159)]&&process[_0x2bdccf(0x10c)]['isTTY'];if(!_0xb43e29){console['log']('\x0aNon-interactive\x20mode\x20detected.\x20Multiple\x20feature\x20reviews\x20found:');for(const _0x50a3a2 of _0x172afb){console['log']('\x20\x20'+_0x50a3a2['name']),console['log'](_0x2bdccf(0x8d)+_0x50a3a2['id']),_0x50a3a2['stats']&&console['log'](_0x2bdccf(0x7e)+getProgressDisplay(_0x50a3a2['stats'])),_0x50a3a2['gitBranch']&&console['log'](_0x2bdccf(0xdb)+_0x50a3a2[_0x2bdccf(0x151)]);}throw new Error(_0x3c0fcd['YaEHY']);}const {selected:_0x1e941d}=await _0x3c4e02['prompt']([{'type':_0x3c0fcd[_0x2bdccf(0x8b)],'name':'selected','message':'Multiple\x20feature\x20reviews\x20found.\x20Select\x20one:','choices':_0x172afb['map'](_0x281d3e=>({'name':_0x281d3e['name']+'\x20('+_0x281d3e['id']+')','value':_0x281d3e['id']}))}]);_0x4b91ec=_0x172afb[_0x2bdccf(0x73)](_0x55ba87=>_0x55ba87['id']===_0x1e941d);}await _0x3c0fcd[_0x2bdccf(0x8f)](setActiveFeatureId,_0x4b91ec['id']);_0x22906b&&_0x22906b!==_0x4b91ec['gitBranch']&&(await updateFeature(_0x4b91ec['id'],{'gitBranch':_0x22906b}),console[_0x2bdccf(0x153)](_0x2bdccf(0x13c)+_0x22906b));console['log'](_0x2bdccf(0xc8)+_0x4b91ec['name']+'\x20('+_0x4b91ec['id']+')'),await tryStartCurrentSession(_0x4b91ec['id']);const _0x16f497=await getFeature(_0x4b91ec['id']),_0x222365=process['env']['CLAUDE_SESSION_ID'];_0x222365&&_0x3c0fcd['lGiaF'](registerSession,_0x222365,_0x16f497['id']),_0x3c0fcd['lGiaF'](displayFeature,_0x16f497,_0x16f497[_0x2bdccf(0x117)]),await printFeedbackNudge(_0x16f497['id']);}async function printFeedbackNudge(_0x5d3f0d){const _0x1f393b=_0x5ccc84,_0x320a13={'PXecu':function(_0x2cec2e,_0x59257d){return _0x2cec2e(_0x59257d);},'iyXSl':function(_0x5449b5,_0x44991e,_0x3311fd){return _0x5449b5(_0x44991e,_0x3311fd);},'SpJft':function(_0x54fb2c,_0x4bd081){return _0x54fb2c>_0x4bd081;}};try{const {items:_0x423850}=await _0x320a13['PXecu'](getActionItems,_0x5d3f0d);let _0x416917=0x0,_0x387e1d=0x0;for(const _0x4f2a90 of _0x423850){const _0x2b3046=await _0x320a13['iyXSl'](getItemFeedback,_0x5d3f0d,_0x4f2a90['id']);_0x2b3046[_0x1f393b(0x123)][_0x1f393b(0xd2)]>0x0&&(_0x416917+=_0x2b3046[_0x1f393b(0x123)][_0x1f393b(0xd2)],_0x387e1d++);}_0x320a13['SpJft'](_0x416917,0x0)&&(console['log'](_0x1f393b(0xe1)+_0x416917+'\x20unaddressed\x20reviewer\x20comment(s)\x20across\x20'+_0x387e1d+'\x20scenario(s).'),console['log'](_0x1f393b(0xa5)));}catch{}}async function tryStartCurrentSession(_0x597215){const _0xd0d54f=_0x5ccc84,_0xf2fb32={'oJGcb':function(_0x837383,_0x42bdce){return _0x837383(_0x42bdce);},'cZIar':function(_0x389951,_0x385533,_0x56c185){return _0x389951(_0x385533,_0x56c185);}};try{const {sessions:_0x262fc3}=await _0xf2fb32[_0xd0d54f(0x91)](listFeatureSessions,_0x597215),_0x4ac39a=_0x262fc3['find'](_0x2a81ed=>_0x2a81ed['status']===_0xd0d54f(0xea));_0x4ac39a&&(await _0xf2fb32['cZIar'](startSession,_0x597215,_0x4ac39a['id']),console['log'](_0xd0d54f(0xe2)+_0x4ac39a['iteration']));}catch{}}export async function featureReport(_0x3e7f34,_0x55ed3c){const _0x188164=_0x5ccc84,_0x3c0cb4={'uHGVA':_0x188164(0x143),'CbZRT':'\x0aGenerating\x20report...','izJum':function(_0x1d7571,_0x373aa0,_0x5a46f6){return _0x1d7571(_0x373aa0,_0x5a46f6);},'nmLid':function(_0x1347ae,_0x4dfd48,_0x308bdb,_0x241927){return _0x1347ae(_0x4dfd48,_0x308bdb,_0x241927);},'dvueM':function(_0x5039d1){return _0x5039d1();},'SdPfZ':_0x188164(0x113),'KoawY':function(_0xefb94d,_0x1cb99b,_0x403ebe){return _0xefb94d(_0x1cb99b,_0x403ebe);},'TxAJO':function(_0x701db3,_0x172d6e){return _0x701db3(_0x172d6e);}},_0x583568=_0x3e7f34||await getActiveFeatureId();if(!_0x583568)throw new Error(_0x3c0cb4['uHGVA']);console[_0x188164(0x153)](_0x3c0cb4['CbZRT']);const _0x380d6f=await _0x3c0cb4['izJum'](getFeatureReportMarkdown,_0x583568,{'style':_0x55ed3c['style']}),_0x56decf=_0x55ed3c[_0x188164(0xa7)]||_0x3c0cb4[_0x188164(0x10f)](join,_0x3c0cb4['dvueM'](getRangerDir),_0x3c0cb4['SdPfZ'],_0x583568+'.md'),_0x5b3b4f=_0x3c0cb4[_0x188164(0x99)](join,_0x56decf,'..');!_0x3c0cb4['TxAJO'](existsSync,_0x5b3b4f)&&await mkdir(_0x5b3b4f,{'recursive':!![]}),await writeFile(_0x56decf,_0x380d6f,'utf-8'),console[_0x188164(0x153)](_0x188164(0x147)+_0x56decf);}function getScenarioResult(_0x41f5fc){const _0x3b901a=_0x5ccc84,_0x32d411={'AqFTv':function(_0x42877f,_0x620b96){return _0x42877f===_0x620b96;},'TwYzT':'closed','UTyhA':_0x3b901a(0x118),'FDcmr':_0x3b901a(0x105)};if(_0x32d411['AqFTv'](_0x41f5fc['status'],_0x3b901a(0xf9)))return _0x41f5fc[_0x3b901a(0xe0)]??_0x32d411[_0x3b901a(0x93)];if(_0x32d411[_0x3b901a(0x128)](_0x41f5fc[_0x3b901a(0xc5)],_0x32d411['UTyhA']))return _0x32d411[_0x3b901a(0xf3)];return _0x41f5fc['status'];}function _0x3995(){const _0xbd3780=['write','\x20\x20\x20Repository:\x20','VtuTa','split','active-feature.txt','toFixed','No\x20feature\x20review\x20ID\x20provided\x20and\x20no\x20active\x20feature\x20review\x20set.','currentSessionId','\x20blocked','\x0aNo\x20matching\x20active\x20feature\x20reviews\x20found.','\x0a✅\x20Report\x20generated:\x20','version','yluAJ','rkwQs','assetType','cUPWM','.png','mwZhW','domRef','iDfbZ','gitBranch','repeat','log','completed','json','KBMmJ','qKGJf','items','isTTY','RkKML','QpAEB','trim','MumEu','feedback-images','No\x20active\x20session\x20for\x20this\x20feature\x20review.','rNQNG','INokR','name','\x0a✅\x20Session\x20is\x20already\x20completed.','screenshotUrls','\x0a❌\x20Invalid\x20scenario\x20number(s):\x20','YVcwW','comment_','\x0a❌\x20All\x20scenarios\x20were\x20excluded.','find','completedAt','Cannot\x20add\x20scenario:\x20feature\x20review\x20has\x20an\x20active\x20review.\x20Please\x20finish\x20your\x20review\x20first:\x20','osfgm','NDEVP','JqdmV','OEFlN','NGDlL','\x0a❌\x20Invalid\x20scenario\x20index:\x20','get','DiEAN','\x20\x20\x20\x20\x20Progress:\x20','\x0a🗑️\x20\x20Deleted\x20feature\x20review:\x20','tWxHg','\x0a✅\x20Feature\x20review\x20created:\x20','any','ESRfl','\x20\x20\x20\x20\x20🎯\x20Element:\x20<','amsXT','mKQTK','huLLw','XiCZY','GQEEx','IOpnE','iykzt','GFONK','\x20\x20\x20\x20\x20ID:\x20','VhvWX','mYimd',':\x20\x22','oJGcb','scenarios','TwYzT','totalCount','storage','No\x20feature\x20review\x20ID\x20provided\x20and\x20no\x20active\x20feature\x20review\x20set.\x20Run:\x20ranger\x20resume\x20<id>\x20to\x20set\x20an\x20active\x20feature\x20review','replace','\x20\x20\x20\x20\x20📋\x20Selector:\x20','KoawY','all','\x20\x20\x20\x20\x20📍\x20Annotation:\x20point\x20at\x20(','\x0a📋\x20Feedback\x20for:\x20','HsHGR','etBsP','\x0aConcluding\x20session...','offset','EZqYN','\x0a📁\x20Sessions\x20for\x20feature\x20review:\x20','CLAUDE_SESSION_ID','379204eOGUmX','\x20\x20\x20Run\x20`ranger\x20get-review`\x20to\x20see\x20what\x20needs\x20to\x20be\x20fixed.','authorEmail','output','has','YeapK','UTXmJ','\x20\x20\x20Created:\x20','toLocaleString','\x1b[1m','\x20incomplete','stepName','/artifacts/','Run:\x20ranger\x20resume\x20<id>\x20to\x20set\x20an\x20active\x20feature\x20review','stats','\x0aAvailable\x20scenarios:','\x20—\x20','warn','list','stdin','git\x20remote\x20get-url\x20origin','Please\x20specify\x20the\x20feature\x20review\x20ID:\x20ranger\x20resume\x20<id>','\x20>\x20','\x20\x20\x20Description:\x20','description','toLocaleDateString','\x20[has\x20reviewer\x20feedback]','incompleteItems','\x20\x20\x20\x20','utf-8','join','6EtqDpe','\x1b[0m','status','short','jNbZg','\x0a✅\x20Resumed\x20feature\x20review:\x20','incompleteReason','canceledReason','OhteI','JkRKO','iteration','from','NClhD','dashboardUrl','pipe','length','timing','fkphW','blocked','IAeYE','Run:\x20ranger\x20create\x20\x22<name>\x22\x20to\x20create\x20a\x20new\x20feature\x20review','vnYbT','/api/v1/mcp/browser-sessions/','pZXQW','\x20\x20\x20\x20\x20Branch:\x20','scenario','NdRZT','\x20\x20💬\x20','currentBranch','terminalReason','\x0a⚠️\x20\x20','\x20\x20\x20▶️\x20Started\x20session\x20','createdAt','verified','tMAti','HklAG','IRRVg','VcPhp','\x20scenarios.','ready','\x20\x20\x20To\x20restore\x20it,\x20run:\x20ranger\x20restore\x20','content','1319648MVVAUj','\x0a➡️\x20\x20Set\x20as\x20active\x20feature\x20review','browserSessionId','\x20(v','jEmof','map','FDcmr','DqvKZ','notes','\x0aSearching\x20for\x20feature\x20reviews\x20matching:\x20','error','\x20\x20✅\x20No\x20feedback\x20to\x20address','closed','...','pop','oPXQW','rBLKm','mlIda','wIkgM','Scenario\x20','selector','limit','latestReview','canonicalFlow','in_progress','16rgfQmu','20708HyPcsE','kemjN','location','spatial','No\x20sessions\x20found.','stdout','Unknown','BcIJh','nmLid','\x0a❌\x20No\x20scenarios\x20found\x20to\x20edit.','5hugfnL','element','reports','jsRvJ','1250851sJrxwE','AFbnw','checklistItems','verification_in_progress','sessionId','dorGk','\x20\x20\x20ID:\x20','Showing\x20','ynZaJ','1034730HbmtPL','\x20feature\x20review(s)\x20found','\x20\x20\x20\x20\x20📍\x20Annotation:\x20','TvxPz','\x0a❌\x20Cannot\x20edit\x20scenario:\x20feature\x20review\x20has\x20an\x20active\x20review.','unaddressedComments','submittedAt','\x20\x20\x20\x20\x20\x20Incomplete:\x20','Not\x20in\x20a\x20git\x20repository.','textContent','AqFTv','slice','push','rOliH','2|3|4|0|1|5','screenshot','EYSur','RUIKM','2330415rBhLaG','3120860pwvbFO','Please\x20finish\x20your\x20review\x20first:','exit','filter','\x20--include-deleted','verificationInProgressItems','excludeScenarios','\x20\x20\x20The\x20feature\x20review\x20is\x20now\x20ready\x20for\x20human\x20review\x20on\x20the\x20Ranger\x20dashboard.','\x20\x20\x20Progress:\x20','blockedReason','gFyPs','\x20\x20\x20Updated\x20branch\x20to:\x20'];_0x3995=function(){return _0xbd3780;};return _0x3995();}function getScenarioRationale(_0x9dc01a,_0x143f36){const _0x24b301=_0x5ccc84,_0x4e4d1e='3|1|0|2|4|5'['split']('|');let _0x20c364=0x0;while(!![]){switch(_0x4e4d1e[_0x20c364++]){case'0':if(_0x9dc01a['incompleteReason'])return _0x9dc01a[_0x24b301(0xc9)];continue;case'1':if(_0x9dc01a[_0x24b301(0x13a)])return _0x9dc01a[_0x24b301(0x13a)];continue;case'2':if(_0x9dc01a[_0x24b301(0xca)])return _0x9dc01a[_0x24b301(0xca)];continue;case'3':if(_0x143f36)return _0x143f36;continue;case'4':if(_0x9dc01a[_0x24b301(0xf5)])return _0x9dc01a['notes'];continue;case'5':return null;}break;}}export async function featureReportPrDescription(_0x2701dd,_0x350dc9){const _0x5b1a0e=_0x5ccc84,_0x384d54={'NyElS':function(_0x20b643){return _0x20b643();},'HsHGR':function(_0x3c1bae,_0xbbfcab,_0x39a51b){return _0x3c1bae(_0xbbfcab,_0x39a51b);},'qKGJf':function(_0x5709da,_0x3dfce9){return _0x5709da===_0x3dfce9;},'TvxPz':function(_0x29a77c,_0x3780e3){return _0x29a77c>_0x3780e3;},'ESRfl':'\x0aAvailable\x20scenarios:','VZkxR':function(_0x1c0345,_0x22bdbb){return _0x1c0345<_0x22bdbb;}},_0x5ae0bf=_0x2701dd||await _0x384d54['NyElS'](getActiveFeatureId);if(!_0x5ae0bf)throw new Error(_0x5b1a0e(0x143));const _0x196d2d=await getFeature(_0x5ae0bf),_0x512bab=_0x196d2d[_0x5b1a0e(0x117)]||[],_0x25406f=_0x384d54[_0x5b1a0e(0x9d)](getCurrentSessionItems,_0x196d2d,_0x512bab);_0x384d54[_0x5b1a0e(0x157)](_0x25406f[_0x5b1a0e(0xd2)],0x0)&&(console[_0x5b1a0e(0xf7)]('\x0a❌\x20No\x20scenarios\x20found\x20to\x20include.'),process['exit'](0x1));const _0x5edae7=_0x350dc9[_0x5b1a0e(0x137)]??[],_0x5abf6d=_0x5edae7[_0x5b1a0e(0x134)](_0x12b486=>!Number['isInteger'](_0x12b486)||_0x12b486<0x1||_0x12b486>_0x25406f[_0x5b1a0e(0xd2)]);if(_0x384d54[_0x5b1a0e(0x121)](_0x5abf6d['length'],0x0)){console['error'](_0x5b1a0e(0x165)+_0x5abf6d[_0x5b1a0e(0xc2)](',\x20')),console[_0x5b1a0e(0x153)](_0x384d54[_0x5b1a0e(0x83)]);for(let _0x92927b=0x0;_0x384d54['VZkxR'](_0x92927b,_0x25406f['length']);_0x92927b++){console['log']('\x20\x20'+(_0x92927b+0x1)+'.\x20'+_0x25406f[_0x92927b]['description']);}process['exit'](0x1);}const _0x379698=new Set(_0x5edae7['map'](_0x260332=>_0x260332-0x1)),_0x38538f=_0x25406f[_0x5b1a0e(0x134)]((_0x315196,_0x414838)=>!_0x379698[_0x5b1a0e(0xa8)](_0x414838));_0x384d54[_0x5b1a0e(0x157)](_0x38538f['length'],0x0)&&(console[_0x5b1a0e(0xf7)](_0x5b1a0e(0x72)),process[_0x5b1a0e(0x133)](0x1));if(_0x350dc9[_0x5b1a0e(0x155)])await outputJsonReport(_0x5ae0bf,_0x196d2d,_0x38538f);else{const _0x5d5d13=await _0x384d54[_0x5b1a0e(0x9d)](getFeatureReportMarkdown,_0x5ae0bf,{'itemIds':_0x38538f[_0x5b1a0e(0xf2)](_0x3e7578=>_0x3e7578['id'])});process[_0x5b1a0e(0x10c)][_0x5b1a0e(0x13d)](_0x5d5d13['trimEnd']()+'\x0a');}}async function outputJsonReport(_0x1f2102,_0x3dcfc8,_0x2b291d){const _0x1eea6d=_0x5ccc84,_0x44763b={'Tuluw':function(_0x37b1ee,_0x5b27a3){return _0x37b1ee(_0x5b27a3);},'YFarC':function(_0x77a9a,_0x36a7f7){return _0x77a9a===_0x36a7f7;},'TvaQO':function(_0x273bcb,_0xc21b6f){return _0x273bcb(_0xc21b6f);}},_0x19f317=getApiBaseUrl(),_0x3bff3a=await _0x44763b['TvaQO'](getFeatureReport,_0x1f2102),_0x5db49a=new Map(_0x3bff3a[_0x1eea6d(0x117)][_0x1eea6d(0xf2)](_0x2ccbde=>[_0x2ccbde['id'],_0x2ccbde])),_0x1c9555=await Promise[_0x1eea6d(0x9a)](_0x2b291d['map'](async _0x395b12=>{const _0x2e4309=_0x1eea6d,_0x47774d=_0x5db49a[_0x2e4309(0x7c)](_0x395b12['id']),_0x1d8be2=_0x47774d?.['linkedSession']??null;let _0x57bce4=[];if(_0x395b12[_0x2e4309(0xef)])try{const {steps:_0x3eeba7}=await _0x44763b['Tuluw'](getBrowserSessionSteps,_0x395b12['browserSessionId']);_0x3eeba7[_0x2e4309(0xd2)]>0x0&&(_0x57bce4=_0x3eeba7['map'](_0x44913f=>{const _0x4e8c82=_0x2e4309,_0x8c3478=_0x44913f['assets'][_0x4e8c82(0x73)](_0x2852e7=>_0x2852e7[_0x4e8c82(0x14b)]===_0x4e8c82(0x12d)&&_0x2852e7[_0x4e8c82(0xd3)]==='after')??_0x44913f['assets']['find'](_0x343cd6=>_0x343cd6['assetType']==='screenshot');let _0x2a4e08=null,_0x2e1f78=null;if(_0x8c3478){const _0x194db1=_0x8c3478[_0x4e8c82(0x95)][_0x4e8c82(0x109)][_0x4e8c82(0x140)]('/')[_0x4e8c82(0xfb)]();_0x2a4e08=_0x19f317+_0x4e8c82(0xd9)+_0x395b12[_0x4e8c82(0xef)]+_0x4e8c82(0xb0)+_0x194db1,_0x194db1&&(_0x2e1f78=_0x194db1['replace'](/\.\w+$/,'')[_0x4e8c82(0x97)](/^(key_)?\d+_/,'')[_0x4e8c82(0x97)](/[-_]/g,'\x20'));}return{'description':_0x2e1f78||_0x44913f['description']||_0x44913f[_0x4e8c82(0xaf)]||'Step\x20'+_0x44913f['position'],'screenshot':_0x2a4e08,'is_key_step':_0x44913f['isKeyStep']};}));}catch{}return _0x44763b['YFarC'](_0x57bce4['length'],0x0)&&_0x1d8be2?.[_0x2e4309(0x164)]&&(_0x57bce4=_0x1d8be2[_0x2e4309(0x164)]['map']((_0xe892ee,_0x337ad5)=>({'description':'Screenshot\x20'+(_0x337ad5+0x1),'screenshot':_0xe892ee,'is_key_step':![]}))),{'description':_0x395b12['description'],'result':_0x44763b['Tuluw'](getScenarioResult,_0x395b12),'rationale':getScenarioRationale(_0x395b12,_0x1d8be2?.['agentResponse']),'steps':_0x57bce4};})),_0x774183={'url':_0x3dcfc8[_0x1eea6d(0xd0)],'scenarios':_0x1c9555};process['stdout'][_0x1eea6d(0x13d)](JSON['stringify'](_0x774183,null,0x2)+'\x0a');}export async function featureConcludeSession(_0x319674){const _0x1f1a27=_0x5ccc84,_0x2e9c61={'nfabf':function(_0xf7853d,_0x4dca16){return _0xf7853d(_0x4dca16);},'dorGk':_0x1f1a27(0x15f),'gfFOC':function(_0x4de3b0,_0x532de4){return _0x4de3b0(_0x532de4);},'fMdTN':'Current\x20session\x20not\x20found.','tMAti':_0x1f1a27(0x163),'OEFlN':function(_0x18cace,_0x42de00){return _0x18cace!==_0x42de00;},'mVNLl':'in_progress'},_0x4bd3f6=_0x319674||await getActiveFeatureId();if(!_0x4bd3f6)throw new Error(_0x1f1a27(0x96));const _0x13a42e=await _0x2e9c61['nfabf'](getFeature,_0x4bd3f6);if(!_0x13a42e[_0x1f1a27(0x144)])throw new Error(_0x2e9c61[_0x1f1a27(0x11a)]);const {sessions:_0x11df0f}=await _0x2e9c61['gfFOC'](listFeatureSessions,_0x4bd3f6),_0x5ea0a3=_0x11df0f['find'](_0x5b4e2c=>_0x5b4e2c['id']===_0x13a42e['currentSessionId']);if(!_0x5ea0a3)throw new Error(_0x2e9c61['fMdTN']);if(_0x5ea0a3['status']===_0x1f1a27(0x154)){console[_0x1f1a27(0x153)](_0x2e9c61[_0x1f1a27(0xe5)]);return;}if(_0x2e9c61[_0x1f1a27(0x79)](_0x5ea0a3['status'],_0x2e9c61['mVNLl']))throw new Error('Cannot\x20conclude\x20session\x20with\x20status:\x20'+_0x5ea0a3[_0x1f1a27(0xc5)]);console['log'](_0x1f1a27(0x9f)),await concludeSession(_0x4bd3f6,_0x13a42e['currentSessionId']),console['log']('\x0a✅\x20Session\x20'+_0x5ea0a3[_0x1f1a27(0xcd)]+'\x20concluded.'),console['log'](_0x1f1a27(0x138));}export async function featureSessions(_0x3f61df){const _0x4c1cf7=_0x5ccc84,_0x13abfb={'Rjqcd':function(_0x2abfd0){return _0x2abfd0();},'wIkgM':function(_0x10288a,_0x569c66){return _0x10288a(_0x569c66);},'IjeVt':_0x4c1cf7(0x154)},_0x2a7d49=_0x3f61df||await _0x13abfb['Rjqcd'](getActiveFeatureId);if(!_0x2a7d49)throw new Error('No\x20feature\x20review\x20ID\x20provided\x20and\x20no\x20active\x20feature\x20review\x20set.');const _0x3be47c=await getFeature(_0x2a7d49);console['log'](_0x4c1cf7(0xa2)+_0x3be47c['name']+'\x0a');const {sessions:_0x132fce}=await _0x13abfb[_0x4c1cf7(0xff)](listFeatureSessions,_0x2a7d49);if(_0x132fce['length']===0x0){console['log'](_0x4c1cf7(0x10b));return;}for(const _0x213e1d of _0x132fce){const _0x4a1f6d=_0x213e1d['status']===_0x13abfb['IjeVt']?'✅':_0x213e1d['status']===_0x4c1cf7(0x105)?'🔄':'▶️';console['log'](_0x4a1f6d+'\x20Session\x20'+_0x213e1d[_0x4c1cf7(0xcd)]+'\x20('+_0x213e1d['id']+')'),console[_0x4c1cf7(0x153)]('\x20\x20\x20Status:\x20'+_0x213e1d['status']),console['log']('\x20\x20\x20Created:\x20'+new Date(_0x213e1d[_0x4c1cf7(0xe3)])['toLocaleString']()),_0x213e1d[_0x4c1cf7(0x74)]&&console['log']('\x20\x20\x20Completed:\x20'+new Date(_0x213e1d[_0x4c1cf7(0x74)])['toLocaleString']()),console[_0x4c1cf7(0x153)]('');}}export async function featureAddScenario(_0x4f7dd9,_0x2b9229){const _0x15e48c=_0x5ccc84,_0x3ee17b={'dUmTZ':function(_0x4470f5){return _0x4470f5();},'GQEEx':function(_0x24ad60,_0x4709be){return _0x24ad60(_0x4709be);}},_0x55b367=_0x2b9229||await _0x3ee17b['dUmTZ'](getActiveFeatureId);if(!_0x55b367)throw new Error(_0x15e48c(0x96));const _0x3b39e9=await _0x3ee17b['GQEEx'](getFeature,_0x55b367);if(_0x3b39e9['latestReview']&&!_0x3b39e9['latestReview'][_0x15e48c(0x124)])throw new Error(_0x15e48c(0x75)+_0x3b39e9[_0x15e48c(0xd0)]);await createChecklistItem(_0x55b367,_0x4f7dd9);const _0x2b9ee9=await _0x3ee17b[_0x15e48c(0x89)](getFeature,_0x55b367);console['log']('\x0a✅\x20Scenario\x20added'),displayFeature(_0x2b9ee9,_0x2b9ee9[_0x15e48c(0x117)]);}export async function featureEditScenario(_0x27a49f,_0x552480){const _0x2c570b=_0x5ccc84,_0x455efd={'oPXQW':'\x0a❌\x20No\x20feature\x20review\x20ID\x20provided\x20and\x20no\x20active\x20feature\x20review\x20set.','tnBLE':_0x2c570b(0xb1),'uaiHG':function(_0xc61f45,_0x7532e6){return _0xc61f45(_0x7532e6);},'mlIda':_0x2c570b(0x122),'NYqlt':function(_0x51e36f,_0x159682){return _0x51e36f===_0x159682;},'vnYbT':'\x0a❌\x20No\x20scenario\x20number\x20provided.\x20Use\x20--scenario\x20<number>.','VWWoz':function(_0x27f338,_0x306cea){return _0x27f338<_0x306cea;},'EZqYN':function(_0x5b19f0,_0x4a6706){return _0x5b19f0+_0x4a6706;},'YVcwW':function(_0xb89011,_0x2df9be){return _0xb89011-_0x2df9be;},'fjUtk':function(_0x474981,_0xb65e4e){return _0x474981>=_0xb65e4e;},'KBMmJ':function(_0x1b2260,_0x426550){return _0x1b2260+_0x426550;},'uHlsw':function(_0xf7af1d,_0x436c8d,_0x2dc625){return _0xf7af1d(_0x436c8d,_0x2dc625);}},_0x15e1c3=_0x552480['id']||await getActiveFeatureId();!_0x15e1c3&&(console['error'](_0x455efd[_0x2c570b(0xfc)]),console[_0x2c570b(0xf7)](_0x455efd['tnBLE']),process['exit'](0x1));const _0x20c0ba=await _0x455efd['uaiHG'](getFeature,_0x15e1c3);_0x20c0ba[_0x2c570b(0x103)]&&!_0x20c0ba[_0x2c570b(0x103)]['submittedAt']&&(console[_0x2c570b(0xf7)](_0x455efd[_0x2c570b(0xfe)]),console[_0x2c570b(0xf7)](_0x2c570b(0x132)),console[_0x2c570b(0xf7)]('\x20\x20'+_0x20c0ba[_0x2c570b(0xd0)]),process['exit'](0x1));const _0x9167d1=_0x20c0ba['checklistItems']||[];_0x455efd['NYqlt'](_0x9167d1[_0x2c570b(0xd2)],0x0)&&(console[_0x2c570b(0xf7)](_0x2c570b(0x110)),process['exit'](0x1));if(_0x552480[_0x2c570b(0xdc)]===undefined){console[_0x2c570b(0xf7)](_0x455efd[_0x2c570b(0xd8)]),console['log']('\x0aAvailable\x20scenarios:');for(let _0xddc6d9=0x0;_0x455efd['VWWoz'](_0xddc6d9,_0x9167d1[_0x2c570b(0xd2)]);_0xddc6d9++){console[_0x2c570b(0x153)]('\x20\x20'+_0x455efd[_0x2c570b(0xa1)](_0xddc6d9,0x1)+'.\x20'+_0x9167d1[_0xddc6d9][_0x2c570b(0xbc)]);}process['exit'](0x1);}const _0xdb1bd8=_0x455efd[_0x2c570b(0x70)](_0x552480['scenario'],0x1);if(_0xdb1bd8<0x0||_0x455efd['fjUtk'](_0xdb1bd8,_0x9167d1['length'])){console['error'](_0x2c570b(0x7b)+_0x552480[_0x2c570b(0xdc)]+'.\x20Feature\x20review\x20has\x20'+_0x9167d1['length']+_0x2c570b(0xe9)),console[_0x2c570b(0x153)](_0x2c570b(0xb3));for(let _0x44ca67=0x0;_0x455efd['VWWoz'](_0x44ca67,_0x9167d1[_0x2c570b(0xd2)]);_0x44ca67++){console['log']('\x20\x20'+_0x455efd[_0x2c570b(0x156)](_0x44ca67,0x1)+'.\x20'+_0x9167d1[_0x44ca67]['description']);}process[_0x2c570b(0x133)](0x1);}const _0x541667=_0x9167d1[_0xdb1bd8];await updateChecklistItem(_0x15e1c3,_0x541667['id'],{'description':_0x27a49f});const _0x4e4bb9=await _0x455efd['uaiHG'](getFeature,_0x15e1c3);console['log']('\x0a✅\x20Scenario\x20updated'),_0x455efd['uHlsw'](displayFeature,_0x4e4bb9,_0x4e4bb9['checklistItems']);}async function downloadFeedbackImage(_0x5bd1d0,_0x39a7c6){const _0x5eb4d8=_0x5ccc84,_0x1158d0={'DqvKZ':function(_0x45f636,_0x25855e,_0x1a8cd8){return _0x45f636(_0x25855e,_0x1a8cd8);},'mKQTK':function(_0x278fb7){return _0x278fb7();},'ynZaJ':_0x5eb4d8(0x15e),'RkKML':function(_0x1f154b,_0xfb67d3,_0x53fcb6){return _0x1f154b(_0xfb67d3,_0x53fcb6);},'IOpnE':function(_0x2900fa,_0x4f0fee){return _0x2900fa(_0x4f0fee);}};try{const _0x5b24b2=_0x1158d0[_0x5eb4d8(0xf4)](join,_0x1158d0[_0x5eb4d8(0x86)](getRangerDir),_0x1158d0[_0x5eb4d8(0x11d)]);await mkdir(_0x5b24b2,{'recursive':!![]});const _0xc0c7a1=_0x1158d0[_0x5eb4d8(0x15a)](join,_0x5b24b2,_0x5eb4d8(0x71)+_0x39a7c6+_0x5eb4d8(0x14d)),_0x18c715=await _0x1158d0[_0x5eb4d8(0x8a)](fetch,_0x5bd1d0);if(!_0x18c715['ok'])return null;const _0x39b1e4=Buffer[_0x5eb4d8(0xce)](await _0x18c715['arrayBuffer']());return await _0x1158d0[_0x5eb4d8(0xf4)](writeFile,_0xc0c7a1,_0x39b1e4),_0xc0c7a1;}catch{return null;}}export async function featureGetReview(_0x334bbd){const _0x5e3af8=_0x5ccc84,_0x53dbb8={'VcPhp':function(_0x54810e){return _0x54810e();},'rkwQs':_0x5e3af8(0x96),'UYHYE':function(_0x56fcec,_0x4ed33d){return _0x56fcec(_0x4ed33d);},'osfgm':function(_0x2b786b,_0x4635f2){return _0x2b786b(_0x4635f2);},'kemjN':function(_0x5b330e,_0x10aa1c){return _0x5b330e>_0x10aa1c;},'IFgJb':function(_0x411bdc,_0x18a20b,_0x2c3de8){return _0x411bdc(_0x18a20b,_0x2c3de8);},'INokR':function(_0x4d5bb4,_0x3257f5){return _0x4d5bb4+_0x3257f5;},'sCbia':'en-US','XiCZY':'numeric','AFbnw':_0x5e3af8(0x10d),'jNbZg':_0x5e3af8(0xba),'BcIJh':_0x5e3af8(0x112),'jsRvJ':function(_0x4c0602,_0x267b2e){return _0x4c0602===_0x267b2e;},'qfyNh':'point'},_0x13486f=_0x334bbd||await _0x53dbb8[_0x5e3af8(0xe8)](getActiveFeatureId);if(!_0x13486f)throw new Error(_0x53dbb8[_0x5e3af8(0x14a)]);const _0x53f3fb=await _0x53dbb8['UYHYE'](getFeature,_0x13486f),{items:_0x3a96b3}=await _0x53dbb8[_0x5e3af8(0x76)](getActionItems,_0x13486f);console['log'](_0x5e3af8(0x9c)+_0x53f3fb['name']+'\x20('+_0x53f3fb['id']+')\x0a');if(_0x3a96b3[_0x5e3af8(0xd2)]===0x0){console['log']('No\x20scenarios\x20found.');return;}for(let _0x525741=0x0;_0x525741<_0x3a96b3['length'];_0x525741++){const _0x9e77b4=_0x3a96b3[_0x525741],_0x16918b=_0x53dbb8['kemjN'](_0x9e77b4[_0x5e3af8(0x148)],0x1)?'\x20(v'+_0x9e77b4[_0x5e3af8(0x148)]+')':'',_0x4931b3=await _0x53dbb8['IFgJb'](getItemFeedback,_0x13486f,_0x9e77b4['id']);if(_0x53dbb8[_0x5e3af8(0x108)](_0x4931b3[_0x5e3af8(0x123)][_0x5e3af8(0xd2)],0x0)){console['log'](_0x5e3af8(0x100)+_0x53dbb8[_0x5e3af8(0x161)](_0x525741,0x1)+_0x5e3af8(0x90)+_0x9e77b4[_0x5e3af8(0xbc)]+'\x22'+_0x16918b+_0x5e3af8(0xb4)+_0x4931b3['unaddressedComments']['length']+'\x20unaddressed\x20comment(s)');for(const _0x4dc86f of _0x4931b3[_0x5e3af8(0x123)]){const _0x4f6338=new Date(_0x4dc86f[_0x5e3af8(0xe3)])['toLocaleDateString'](_0x53dbb8['sCbia'],{'month':_0x5e3af8(0xc6),'day':_0x53dbb8[_0x5e3af8(0x88)]}),_0x8964a=_0x4dc86f['authorName']||_0x4dc86f[_0x5e3af8(0xa6)]||_0x53dbb8[_0x5e3af8(0x116)];console[_0x5e3af8(0x153)](_0x5e3af8(0xde)+_0x8964a+'\x20('+_0x4f6338+'):\x20\x22'+_0x4dc86f[_0x5e3af8(0xec)]+'\x22');if(_0x4dc86f['assetUrl']){const _0x45721d=await _0x53dbb8['IFgJb'](downloadFeedbackImage,_0x4dc86f['assetUrl'],_0x4dc86f['id']);_0x45721d&&console['log']('\x20\x20\x20\x20\x20📷\x20Screenshot:\x20'+_0x45721d);}if(_0x4dc86f[_0x5e3af8(0x14f)]){const _0x1691fd=_0x4dc86f['domRef'][_0x5e3af8(0x101)][_0x5e3af8(0x140)](_0x53dbb8[_0x5e3af8(0xc7)])['pop']()?.[_0x5e3af8(0x140)](':')[0x0]||_0x53dbb8[_0x5e3af8(0x10e)],_0xa29c5d=_0x4dc86f['domRef'][_0x5e3af8(0x127)]?'\x20\x22'+_0x4dc86f['domRef']['textContent'][_0x5e3af8(0x129)](0x0,0x3c)+'\x22':'';console['log'](_0x5e3af8(0x84)+_0x1691fd+'>'+_0xa29c5d),console[_0x5e3af8(0x153)](_0x5e3af8(0x98)+_0x4dc86f[_0x5e3af8(0x14f)]['selector']);}else{if(_0x4dc86f[_0x5e3af8(0x10a)]){const _0x121f30=_0x4dc86f[_0x5e3af8(0x10a)]['coordinates'];_0x53dbb8[_0x5e3af8(0x114)](_0x4dc86f[_0x5e3af8(0x10a)]['type'],_0x53dbb8['qfyNh'])&&_0x121f30['length']>=0x2?console['log'](_0x5e3af8(0x9b)+_0x121f30[0x0][_0x5e3af8(0x142)](0x2)+',\x20'+_0x121f30[0x1][_0x5e3af8(0x142)](0x2)+')'):console['log'](_0x5e3af8(0x120)+_0x4dc86f[_0x5e3af8(0x10a)]['type']+'\x20at\x20['+_0x121f30['map'](_0x2601cd=>_0x2601cd[_0x5e3af8(0x142)](0x2))[_0x5e3af8(0xc2)](',\x20')+']');}}}if(_0x4931b3[_0x5e3af8(0x104)]){console[_0x5e3af8(0x153)]('\x20\x20Expected\x20flow:');for(const _0x4058b1 of _0x4931b3[_0x5e3af8(0x104)]['split']('\x0a')){console[_0x5e3af8(0x153)](_0x5e3af8(0xc0)+_0x4058b1);}}}else console[_0x5e3af8(0x153)]('Scenario\x20'+(_0x525741+0x1)+_0x5e3af8(0x90)+_0x9e77b4['description']+'\x22'+_0x16918b+'\x20—\x20no\x20comments'),console[_0x5e3af8(0x153)](_0x5e3af8(0xf8));console['log']('');}}export async function featureDelete(_0x189a7b){const _0x15f4f3=_0x5ccc84,_0x20f768={'OhteI':function(_0xa76016,_0x4fa9a7){return _0xa76016(_0x4fa9a7);},'NDEVP':_0x15f4f3(0xeb)},_0x5cea3b=_0x189a7b||await getActiveFeatureId();if(!_0x5cea3b)throw new Error('No\x20feature\x20review\x20ID\x20provided\x20and\x20no\x20active\x20feature\x20review\x20set.\x20Run:\x20ranger\x20resume\x20<id>\x20to\x20set\x20an\x20active\x20feature\x20review');const _0x1a1633=await getFeature(_0x5cea3b);await _0x20f768[_0x15f4f3(0xcb)](softDeleteFeature,_0x5cea3b),console['log'](_0x15f4f3(0x7f)+_0x1a1633[_0x15f4f3(0x162)]+'\x20('+_0x5cea3b+')'),console[_0x15f4f3(0x153)](_0x20f768[_0x15f4f3(0x77)]+_0x5cea3b);}export async function featureRestore(_0x146ca6){const _0x5c0b62=_0x5ccc84,_0x200e94={'VhvWX':function(_0x1434cb,_0x41eb0d){return _0x1434cb(_0x41eb0d);},'RUIKM':function(_0x442574,_0x36bb19,_0x17323b){return _0x442574(_0x36bb19,_0x17323b);}};await _0x200e94[_0x5c0b62(0x8e)](restoreFeature,_0x146ca6);const _0x3a5213=await getFeature(_0x146ca6);console[_0x5c0b62(0x153)]('\x0a✅\x20Restored\x20feature\x20review:\x20'+_0x3a5213['name']+'\x20('+_0x146ca6+')'),_0x200e94[_0x5c0b62(0x12f)](displayFeature,_0x3a5213,_0x3a5213[_0x5c0b62(0x117)]);}
@@ -1 +1 @@
1
- (function(_0x277dfb,_0x411e6c){const _0x4a664b=_0x293c,_0x4e091d=_0x277dfb();while(!![]){try{const _0x1dce23=-parseInt(_0x4a664b(0x8d))/0x1*(parseInt(_0x4a664b(0x88))/0x2)+-parseInt(_0x4a664b(0x8b))/0x3+-parseInt(_0x4a664b(0x87))/0x4*(parseInt(_0x4a664b(0x89))/0x5)+-parseInt(_0x4a664b(0x7b))/0x6*(-parseInt(_0x4a664b(0x84))/0x7)+parseInt(_0x4a664b(0x82))/0x8*(parseInt(_0x4a664b(0x80))/0x9)+-parseInt(_0x4a664b(0x81))/0xa*(parseInt(_0x4a664b(0x7e))/0xb)+-parseInt(_0x4a664b(0x8c))/0xc;if(_0x1dce23===_0x411e6c)break;else _0x4e091d['push'](_0x4e091d['shift']());}catch(_0x267860){_0x4e091d['push'](_0x4e091d['shift']());}}}(_0x84f6,0x9174f));import{sessionStart,sessionEnd,preCompact,postEdit,planStart,planReminder,exitPlanMode,stopHook,enable,disable,autoPrompt}from'./hooks/index.js';function _0x293c(_0x59ebb2,_0x210d20){_0x59ebb2=_0x59ebb2-0x7a;const _0x84f680=_0x84f6();let _0x293c8a=_0x84f680[_0x59ebb2];return _0x293c8a;}const HOOKS={'session-start':sessionStart,'session-end':sessionEnd,'pre-compact':preCompact,'post-edit':postEdit,'plan-start':planStart,'plan-reminder':planReminder,'exit-plan-mode':exitPlanMode,'stop':stopHook,'enable':enable,'disable':disable,'auto-prompt':autoPrompt};function _0x84f6(){const _0x5190ce=['17882YKfoqS','SIGINT','10518eiQRZs','once','error','22nPrwHA','exit','27zYyxuu','2082340Pknomt','1538008iHqdEK','keys','4193xyDjhe','Valid\x20hooks:\x20','SIGTERM','4wcYMGv','8IPffac','714335KAfxTF','join','240984dLKSie','3837816RrrrMs'];_0x84f6=function(){return _0x5190ce;};return _0x84f6();}let cancellationHandlersInstalled=![];function installCancellationHandlers(){const _0x4c216c=_0x293c,_0x327317={'XNDbs':'SIGHUP'};if(cancellationHandlersInstalled)return;const _0x4d674b=()=>{const _0x2276d4=_0x293c;process[_0x2276d4(0x7f)](0x0);};process[_0x4c216c(0x7c)](_0x4c216c(0x7a),_0x4d674b),process[_0x4c216c(0x7c)](_0x4c216c(0x86),_0x4d674b),process[_0x4c216c(0x7c)](_0x327317['XNDbs'],_0x4d674b),cancellationHandlersInstalled=!![];}export async function hook(_0x37f6f6,_0x33f6e4){const _0x3966d9=_0x293c,_0x46c4c7={'nnCUv':function(_0xf1c9e3){return _0xf1c9e3();}};_0x46c4c7['nnCUv'](installCancellationHandlers);const _0x373f81=HOOKS[_0x37f6f6];if(!_0x373f81){const _0xae750c=Object[_0x3966d9(0x83)](HOOKS)[_0x3966d9(0x8a)](',\x20');console[_0x3966d9(0x7d)]('Unknown\x20hook:\x20'+_0x37f6f6),console[_0x3966d9(0x7d)](_0x3966d9(0x85)+_0xae750c),process[_0x3966d9(0x7f)](0x1);}await _0x373f81(_0x33f6e4);}
1
+ function _0x3b2b(_0x16647b,_0x3d8b64){_0x16647b=_0x16647b-0x188;const _0x34462e=_0x3446();let _0x3b2b90=_0x34462e[_0x16647b];return _0x3b2b90;}(function(_0x396140,_0x1c9d30){const _0x27f691=_0x3b2b,_0x262518=_0x396140();while(!![]){try{const _0x158799=parseInt(_0x27f691(0x195))/0x1+parseInt(_0x27f691(0x198))/0x2*(parseInt(_0x27f691(0x193))/0x3)+-parseInt(_0x27f691(0x19a))/0x4*(parseInt(_0x27f691(0x194))/0x5)+-parseInt(_0x27f691(0x199))/0x6+-parseInt(_0x27f691(0x197))/0x7+-parseInt(_0x27f691(0x189))/0x8*(-parseInt(_0x27f691(0x191))/0x9)+parseInt(_0x27f691(0x18b))/0xa;if(_0x158799===_0x1c9d30)break;else _0x262518['push'](_0x262518['shift']());}catch(_0x2c8b2e){_0x262518['push'](_0x262518['shift']());}}}(_0x3446,0x6e60b));import{sessionStart,sessionEnd,preCompact,postEdit,planStart,planReminder,exitPlanMode,stopHook,enable,disable,autoPrompt}from'./hooks/index.js';const HOOKS={'session-start':sessionStart,'session-end':sessionEnd,'pre-compact':preCompact,'post-edit':postEdit,'plan-start':planStart,'plan-reminder':planReminder,'exit-plan-mode':exitPlanMode,'stop':stopHook,'enable':enable,'disable':disable,'auto-prompt':autoPrompt};function _0x3446(){const _0x1fb1d1=['998417KQLowE','18Itdpdr','5161680eMgiYQ','40vixXzV','once','8BjAdYG','exit','4678590XWeFVc','keys','join','SIGINT','SIGHUP','error','6534963PLGAzi','SmiBt','103419LjxXWi','164870iJcXKK','280535lJsZEu','Valid\x20hooks:\x20'];_0x3446=function(){return _0x1fb1d1;};return _0x3446();}let cancellationHandlersInstalled=![];function installCancellationHandlers(){const _0x530e02=_0x3b2b,_0x57a43d={'Wymus':_0x530e02(0x18f)};if(cancellationHandlersInstalled)return;const _0xd62a=()=>{const _0x20446f=_0x530e02;process[_0x20446f(0x18a)](0x0);};process['once'](_0x530e02(0x18e),_0xd62a),process[_0x530e02(0x188)]('SIGTERM',_0xd62a),process[_0x530e02(0x188)](_0x57a43d['Wymus'],_0xd62a),cancellationHandlersInstalled=!![];}export async function hook(_0x34571d,_0xc544d2){const _0x25836e=_0x3b2b,_0x55e9f7={'SmiBt':function(_0x2905e1,_0x37810a){return _0x2905e1(_0x37810a);}};installCancellationHandlers();const _0x5f3a26=HOOKS[_0x34571d];if(!_0x5f3a26){const _0x40a01c=Object[_0x25836e(0x18c)](HOOKS)[_0x25836e(0x18d)](',\x20');console[_0x25836e(0x190)]('Unknown\x20hook:\x20'+_0x34571d),console[_0x25836e(0x190)](_0x25836e(0x196)+_0x40a01c),process[_0x25836e(0x18a)](0x1);}await _0x55e9f7[_0x25836e(0x192)](_0x5f3a26,_0xc544d2);}