@ranger-testing/ranger-cli 3.1.3-alpha.e1ca941-42 → 3.1.4-alpha.fb796e7-45

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 (85) hide show
  1. package/build/cli.js +1 -1
  2. package/build/commands/addEnv.js +1 -1
  3. package/build/commands/authEncrypt.js +1 -1
  4. package/build/commands/clean.js +1 -1
  5. package/build/commands/config.js +1 -1
  6. package/build/commands/deleteProfile.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/migrateProfile.js +1 -1
  27. package/build/commands/setup/claude.js +1 -1
  28. package/build/commands/setup/opencode.js +1 -1
  29. package/build/commands/setupCi.js +1 -1
  30. package/build/commands/skillup.js +1 -1
  31. package/build/commands/start.js +1 -1
  32. package/build/commands/status.js +1 -1
  33. package/build/commands/update.js +1 -1
  34. package/build/commands/updateEnv.js +1 -1
  35. package/build/commands/useEnv.js +1 -1
  36. package/build/commands/utils/activeProfile.js +1 -1
  37. package/build/commands/utils/agentEnv.js +1 -1
  38. package/build/commands/utils/browserSessionsApi.js +1 -1
  39. package/build/commands/utils/claudeConfig.js +1 -1
  40. package/build/commands/utils/claudeOverrideSettings.js +1 -1
  41. package/build/commands/utils/claudePlugin.js +1 -1
  42. package/build/commands/utils/cloudProfile.js +1 -1
  43. package/build/commands/utils/cloudProfileSession.js +1 -1
  44. package/build/commands/utils/crypto.js +1 -1
  45. package/build/commands/utils/desirePathLog.js +1 -1
  46. package/build/commands/utils/deviceAuth.js +1 -1
  47. package/build/commands/utils/environment.js +1 -1
  48. package/build/commands/utils/featureApi.js +1 -1
  49. package/build/commands/utils/fixWebmDuration.js +1 -1
  50. package/build/commands/utils/gitTracked.js +1 -1
  51. package/build/commands/utils/keychain.js +1 -1
  52. package/build/commands/utils/legacyWarning.js +1 -1
  53. package/build/commands/utils/localAgentInstallationsApi.js +1 -1
  54. package/build/commands/utils/matchAuthEnvironment.js +1 -1
  55. package/build/commands/utils/mcpImageBase64.js +1 -1
  56. package/build/commands/utils/model.js +1 -1
  57. package/build/commands/utils/novaActCli.js +1 -1
  58. package/build/commands/utils/opencodeConfig.js +1 -1
  59. package/build/commands/utils/organizationEnvApi.js +1 -1
  60. package/build/commands/utils/playwrightCli.js +1 -1
  61. package/build/commands/utils/profileMessages.js +1 -1
  62. package/build/commands/utils/profileSetupBanner.js +1 -1
  63. package/build/commands/utils/projectsConfig.js +1 -1
  64. package/build/commands/utils/rangerConfig.js +1 -1
  65. package/build/commands/utils/rangerRoot.js +1 -1
  66. package/build/commands/utils/rangerwrightCli.js +1 -1
  67. package/build/commands/utils/resolveProfileContext.js +1 -1
  68. package/build/commands/utils/resolveProfileUrl.js +1 -1
  69. package/build/commands/utils/retry.js +1 -1
  70. package/build/commands/utils/sessionCache.js +1 -1
  71. package/build/commands/utils/settings.js +1 -1
  72. package/build/commands/utils/skillContent.js +1 -1
  73. package/build/commands/utils/skills.js +1 -1
  74. package/build/commands/utils/stitchWebmFiles.js +1 -1
  75. package/build/commands/utils/telemetry.js +1 -1
  76. package/build/commands/utils/tokenRefresh.js +1 -1
  77. package/build/commands/utils/traceSnapshotMapper.js +1 -1
  78. package/build/commands/utils/tunnelClient.js +1 -1
  79. package/build/commands/utils/userApi.js +1 -1
  80. package/build/commands/utils/version.js +1 -1
  81. package/build/commands/verifyFeature.js +1 -1
  82. package/build/commands/verifyFeatureCli.js +1 -1
  83. package/build/commands/verifyFeatureNovaCli.js +1 -1
  84. package/build/commands/verifyFeatureRangerwrightCli.js +1 -1
  85. package/package.json +2 -2
@@ -1 +1 @@
1
- (function(_0x354464,_0xe5bd38){const _0x377245=_0x8dce,_0x116703=_0x354464();while(!![]){try{const _0x23765b=-parseInt(_0x377245(0x117))/0x1*(-parseInt(_0x377245(0xf4))/0x2)+-parseInt(_0x377245(0x107))/0x3*(-parseInt(_0x377245(0x15c))/0x4)+-parseInt(_0x377245(0xe8))/0x5*(parseInt(_0x377245(0xe4))/0x6)+-parseInt(_0x377245(0x142))/0x7*(parseInt(_0x377245(0x114))/0x8)+-parseInt(_0x377245(0x138))/0x9*(parseInt(_0x377245(0x10b))/0xa)+-parseInt(_0x377245(0x11f))/0xb+parseInt(_0x377245(0x131))/0xc;if(_0x23765b===_0xe5bd38)break;else _0x116703['push'](_0x116703['shift']());}catch(_0x3eb535){_0x116703['push'](_0x116703['shift']());}}}(_0x1520,0x267aa));import{readdir,rm}from'fs/promises';import{join}from'path';import{existsSync}from'fs';import _0x176ead from'inquirer';import{getRangerDir,getRangerHomeDir}from'./utils/rangerRoot.js';import{writeActiveProfileName}from'./utils/activeProfile.js';import{fetchAuthConfig,createCloudProfile,manualBrowserLogin,ApiError}from'./utils/cloudProfile.js';function _0x8dce(_0x473d14,_0x40eee5){_0x473d14=_0x473d14-0xe0;const _0x15203e=_0x1520();let _0x8dceab=_0x15203e[_0x473d14];return _0x8dceab;}import{isInteractive}from'./utils/cloudProfileSession.js';import{matchAuthEnvironment}from'./utils/matchAuthEnvironment.js';import{isPathGitTracked}from'./utils/gitTracked.js';import{setProfileOverride}from'./utils/projectsConfig.js';const CLOUD_PROFILE_SHARING_WARNING='This\x20account\x20will\x20be\x20shared\x20with\x20everyone\x20at\x20your\x20organization';function warnCloudProfileSharedInOrg(){const _0x212485=_0x8dce;if(!process[_0x212485(0xf1)]['isTTY'])return;console[_0x212485(0x109)](CLOUD_PROFILE_SHARING_WARNING);}async function checkUrlReachability(_0x4627cc){const _0x30d6b1=_0x8dce,_0x49f36b={'jANMw':function(_0x2cf012,_0x230d72,_0x7efb07){return _0x2cf012(_0x230d72,_0x7efb07);},'SItWR':function(_0x4fc795,_0x11b078){return _0x4fc795(_0x11b078);},'vVImQ':function(_0x25e62b,_0x54b9fa){return _0x25e62b===_0x54b9fa;},'SnrBy':'TypeError'};try{const _0x245469=new AbortController(),_0x43ca13=setTimeout(()=>_0x245469['abort'](),0x1388),_0x265cf9={'method':_0x30d6b1(0x147),'signal':_0x245469['signal'],'redirect':'manual'};/^https:\/\/localhost(:\d+)?/i[_0x30d6b1(0x118)](_0x4627cc)&&(process['env']['NODE_TLS_REJECT_UNAUTHORIZED']='0');const _0x31c3c4=await _0x49f36b['jANMw'](fetch,_0x4627cc,_0x265cf9);delete process[_0x30d6b1(0x10a)]['NODE_TLS_REJECT_UNAUTHORIZED'],clearTimeout(_0x43ca13);if(_0x31c3c4['status']<0x190)return{'ok':!![]};return{'ok':![],'error':_0x30d6b1(0x13d)+_0x31c3c4[_0x30d6b1(0xfc)]};}catch(_0x266173){delete process[_0x30d6b1(0x10a)]['NODE_TLS_REJECT_UNAUTHORIZED'];const _0x5c64b3=_0x266173,_0xee5de=_0x5c64b3[_0x30d6b1(0x102)]||_0x49f36b[_0x30d6b1(0x137)](String,_0x266173),_0x5d6331=_0xee5de['includes']('Invalid\x20URL')||_0x49f36b[_0x30d6b1(0x101)](_0x5c64b3[_0x30d6b1(0x12a)],_0x49f36b['SnrBy'])||_0xee5de[_0x30d6b1(0x145)](_0x30d6b1(0xec));return{'ok':![],'error':_0xee5de,'isProtocolError':_0x5d6331};}}async function sweepOrphanLocalProfile(_0x294522,_0x58ffca,_0x313211){const _0x2eaf93=_0x8dce,_0x13fac8={'MUKAV':_0x2eaf93(0x129),'LoAae':function(_0x4ad0fb,_0x17a6f4){return _0x4ad0fb(_0x17a6f4);},'GOewt':function(_0x1233f9,_0x4d0948){return _0x1233f9(_0x4d0948);},'CcZhP':function(_0x1c5ac6,_0x5d2396,_0x415974){return _0x1c5ac6(_0x5d2396,_0x415974);}},_0x3d3148=join(_0x58ffca,_0x13fac8['MUKAV']),_0x1a6d83=join(_0x3d3148,_0x294522);_0x13fac8[_0x2eaf93(0x14a)](existsSync,_0x1a6d83)&&(_0x313211&&await _0x13fac8['GOewt'](isPathGitTracked,_0x1a6d83)?console['log'](_0x2eaf93(0x162)+_0x1a6d83+'\x20—\x20not\x20removing.\x20Delete\x20manually\x20if\x20you\x20want\x20it\x20gone.'):(await rm(_0x1a6d83,{'recursive':!![],'force':!![]}),console[_0x2eaf93(0x160)](_0x2eaf93(0x141)+_0x1a6d83)));if(existsSync(_0x3d3148)){let _0x4b12ab=[];try{_0x4b12ab=await readdir(_0x3d3148);}catch{return;}const _0x39772e='.tmp-'+_0x294522+'-';for(const _0x34081d of _0x4b12ab){if(!_0x34081d['startsWith'](_0x39772e))continue;const _0x3e1e85=_0x13fac8[_0x2eaf93(0x139)](join,_0x3d3148,_0x34081d);await rm(_0x3e1e85,{'recursive':!![],'force':!![]}),console['log'](_0x2eaf93(0x141)+_0x3e1e85);}}}async function sweepOrphansBestEffort(_0x221a44){const _0x220f85=_0x8dce,_0x5391da={'ZUStg':function(_0x2f6f21,_0x4eb8ad,_0x31218a,_0x195c04){return _0x2f6f21(_0x4eb8ad,_0x31218a,_0x195c04);},'RBsCH':function(_0x1a5685){return _0x1a5685();},'EHmhV':function(_0x626dad,_0x4e24bc){return _0x626dad(_0x4e24bc);}};try{await _0x5391da['ZUStg'](sweepOrphanLocalProfile,_0x221a44,_0x5391da[_0x220f85(0xe6)](getRangerHomeDir),![]);const _0x414322=getRangerDir();_0x414322!==_0x5391da['RBsCH'](getRangerHomeDir)&&await sweepOrphanLocalProfile(_0x221a44,_0x414322,!![]);}catch(_0x455277){console['log'](_0x220f85(0x135)+(_0x455277 instanceof Error?_0x455277['message']:_0x5391da['EHmhV'](String,_0x455277))+').');}}async function markActive(_0x20a3a8){const _0x5b7aaf=_0x8dce;try{await writeActiveProfileName(_0x20a3a8),console['log']('\x20\x20Set\x20active\x20profile:\x20'+_0x20a3a8);}catch{console['log'](_0x5b7aaf(0x111));}}function _0x1520(){const _0x11629b=['prompt','warn','env','2620UCrkPS','ncxWz','hapHe','no_auth_config','\x20\x20When\x20you\x27re\x20ready\x20to\x20log\x20in,\x20run\x20`ranger\x20profile\x20add\x20','mcgTP','Warning:\x20Profile\x20created,\x20but\x20failed\x20to\x20mark\x20it\x20as\x20active.','wevpG','http://localhost:3000','2106296JRXNiZ','Enter\x20a\x20different\x20URL','error','152746qGUgar','test','✓\x20Profile\x20\x27','Automated\x20login\x20isn\x27t\x20set\x20up\x20for\x20your\x20team.\x20Capture\x20a\x20session\x20via\x20a\x20headed\x20browser\x20instead?','RltbF','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','\x20\x20Next:\x20ranger\x20go\x20--profile\x20','user_declined','576477ONLpNk','setupHeader','\x27\x20to\x20the\x20cloud?','TiIYm','keys','\x20\x20https://docs.ranger.net/main/concepts/profiles','\x0a\x20\x20(domains:\x20','\x0a🌐\x20Profile\x20Setup\x0a','\x0a✓\x20Profile\x20\x27','http://','local','name','TyXnX','BOwON','isElectron','ReMrQ','UmgDU','\x0aMake\x20sure\x20your\x20app\x20is\x20running,\x20then\x20try\x20again.\x20To\x20skip\x20this\x20check,\x20pass\x20--force.','3495492ZQMWWV','For\x20CI\x20/\x20background\x20agents\x20and\x20other\x20setup\x20options,\x20see:\x0a','\x0a\x20\x20Declined.\x20Re-run\x20with\x20--skip-auth\x20to\x20create\x20a\x20profile\x20without\x20a\x20session,\x0a','confirm','\x20\x20Note:\x20cloud\x20profile\x20created,\x20but\x20failed\x20to\x20sweep\x20orphan\x20local\x20dirs\x20(','✓\x20Cloud\x20profile\x20\x27','SItWR','27NkTEGP','CcZhP','NlGhW','zvtqg','.\x20Configured\x20envs:\x20','HTTP\x20','iDUSn','HnNOa','force','\x20\x20Cleaned\x20up\x20orphan\x20local\x20profile\x20at\x20','7ebssEK','BihkZ','\x22\x20already\x20exists.\x20To\x20refresh\x20its\x20session,\x20run:\x0a','includes','BbvTT','HEAD','aMgaC','wJrEa','LoAae','\x20\x20\x20\x20\x20\x20ranger\x20profile\x20update\x20','\x20\x20Workaround\x20for\x20now:\x20create\x20a\x20profile\x20without\x20a\x20captured\x20session\x20and\x20supply\x20one\x20later:\x0a','slice','\x20\x20ranger\x20profile\x20add\x20<name>\x0a','\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','RkMQm','environments','QhOLp','mLCtP','input','\x20\x20Did\x20you\x20mean\x20','retry','origin','indexOf','exit','Ugtpe','XeggJ','584DXKhtI','PksCP','\x27\x20created.\x0a','setupHeaders','log','\x0a\x20\x20Could\x20not\x20fetch\x20this\x20org\x27s\x20auth\x20config:\x20','\x20\x20Note:\x20found\x20git-tracked\x20local\x20profile\x20at\x20','GcjpM','JJHFw','yes','isProtocolError','1173102WltPIf','xMmKo','RBsCH','\x0a\x20\x20Declined.\x20Re-run\x20with\x20--skip-auth\x20to\x20create\x20a\x20profile\x20without\x20a\x20cloud-managed\x20session.','5zfjlmf','uTqgv','lMNIm','ZlzCv','fetch\x20failed','join','trim','url','--url\x20and\x20--cdp-endpoint\x20are\x20mutually\x20exclusive.\x20Use\x20--url\x20for\x20web\x20apps\x20or\x20--cdp-endpoint\x20for\x20Electron/CDP\x20apps,\x20not\x20both.','stdout','skipAuth','profile.add.autoRouted','2dLjDte','trackPhaseEnd','\x0a\x20\x20A\x20profile\x20named\x20\x22','Enter\x20a\x20new\x20URL\x20(or\x20press\x20enter\x20to\x20keep\x20current):','lDQXN','The\x20--ci\x20flag\x20is\x20no\x20longer\x20supported.\x20Ranger\x20now\x20manages\x20session\x20state\x0a','\x0a🔌\x20CDP\x20Profile\x20Setup\x0a','Wpecw','status','Invalid\x20--setup-header\x20format:\x20\x22','\x22.\x20Expected\x20\x22Name:\x20Value\x22.','emDaK','\x20\x20Ranger\x20will\x20use\x20it\x20to\x20look\x20up\x20the\x20right\x20cloud\x20auth\x20env\x20to\x20attach.\x0a','vVImQ','message','action','cwd','length','profile.add.autoRouteSkipped','4635YlbZdm'];_0x1520=function(){return _0x11629b;};return _0x1520();}async function tryAutoRouteCloudProfile(_0x15472c,_0x3e5bef,_0xae2d48,_0x5c97bc,_0x2015ca){const _0xccc5c6=_0x8dce,_0x3546b3={'XeggJ':function(_0x4f9ebf,_0x3364e4){return _0x4f9ebf===_0x3364e4;},'BihkZ':function(_0x358643){return _0x358643();},'LEnqU':function(_0x174a26,_0x40c14){return _0x174a26 instanceof _0x40c14;},'UmgDU':function(_0x4fd7b8,_0x3c3ae7,_0x1f5406,_0x5b6190,_0x19c133){return _0x4fd7b8(_0x3c3ae7,_0x1f5406,_0x5b6190,_0x19c133);},'mLCtP':_0xccc5c6(0x106),'BOwON':_0xccc5c6(0x10e),'mcgTP':function(_0x20dae7,_0x5bf3e2){return _0x20dae7+_0x5bf3e2;},'QhOLp':function(_0x2fa8a7,_0x5b4c57){return _0x2fa8a7+_0x5b4c57;},'TiIYm':function(_0x3f50b6,_0x359e55){return _0x3f50b6+_0x359e55;},'lDQXN':_0xccc5c6(0x14f),'JJHFw':'no_match','rXpmT':_0xccc5c6(0x134),'lMNIm':'saveToCloud','zvtqg':_0xccc5c6(0xe7),'gsTdg':function(_0x4e091b,_0x543879,_0xde0174,_0x44861a){return _0x4e091b(_0x543879,_0xde0174,_0x44861a);},'xMmKo':function(_0x3a1b78,_0x7362f3){return _0x3a1b78 instanceof _0x7362f3;},'uTqgv':function(_0x21e8f0,_0x1f8318){return _0x21e8f0+_0x1f8318;}};let _0x506833;try{_0x506833=await _0x3546b3['BihkZ'](fetchAuthConfig);}catch(_0x48d7ba){return _0x2015ca?.[_0xccc5c6(0xf5)]('profile.add.autoRouteSkipped',{'reason':'no_auth_config','profileName':_0x15472c}),console['error'](_0xccc5c6(0x161)+(_0x3546b3['LEnqU'](_0x48d7ba,Error)?_0x48d7ba['message']:String(_0x48d7ba))),![];}if(!_0x506833||!_0x506833['environments']||Object[_0xccc5c6(0x123)](_0x506833['environments'])[_0xccc5c6(0x105)]===0x0){if(_0x5c97bc)return await _0x3546b3[_0xccc5c6(0x12f)](captureEnvLessProfile,_0x15472c,_0x3e5bef,_0xae2d48,_0x2015ca);return _0x2015ca?.[_0xccc5c6(0xf5)](_0x3546b3[_0xccc5c6(0x153)],{'reason':_0x3546b3[_0xccc5c6(0x12c)],'profileName':_0x15472c}),console['error'](_0x3546b3[_0xccc5c6(0x110)](_0x3546b3['QhOLp'](_0x3546b3['TiIYm'](_0x3546b3[_0xccc5c6(0x122)](_0x3546b3[_0xccc5c6(0xf8)],'\x0a')+_0xccc5c6(0x14c),'\x20\x20\x20\x20\x20\x20ranger\x20profile\x20add\x20'+_0x15472c+'\x20--url\x20'+_0x3e5bef+'\x20--skip-auth\x0a'),'\x0a')+'\x20\x20To\x20get\x20automated\x20login\x20set\x20up\x20for\x20your\x20team\x20(a\x20one-time\x20call):\x20eng@ranger.net\x0a','\x20\x20Details:\x20https://docs.ranger.net/main/concepts/profiles#automated-login')),![];}const _0x499d47=matchAuthEnvironment(_0x3e5bef,_0x506833);if(!_0x499d47)return _0x2015ca?.[_0xccc5c6(0xf5)](_0x3546b3['mLCtP'],{'reason':_0x3546b3[_0xccc5c6(0xe1)],'profileName':_0x15472c}),console[_0xccc5c6(0x116)]('\x0a\x20\x20No\x20auth\x20env\x20matches\x20'+_0x3e5bef+_0xccc5c6(0x13c)+Object['keys'](_0x506833['environments'])[_0xccc5c6(0xed)](',\x20')+'.'),![];const _0x13c43d=_0x506833[_0xccc5c6(0x151)][_0x499d47],_0x253704=_0x13c43d?.['domains']??[];if(_0x5c97bc&&!_0xae2d48['yes']){const {saveToCloud:_0x1d1965}=await _0x176ead['prompt']([{'type':_0x3546b3['rXpmT'],'name':_0x3546b3[_0xccc5c6(0xea)],'message':'Found\x20auth\x20environment\x20\x27'+_0x499d47+'\x27\x20matching\x20'+_0x3e5bef+_0xccc5c6(0x125)+_0x253704['join'](',\x20')+')\x0a\x20\x20Save\x20\x27'+_0x15472c+_0xccc5c6(0x121),'default':!![]}]);if(!_0x1d1965)return _0x2015ca?.['trackPhaseEnd']('profile.add.autoRouteSkipped',{'reason':_0xccc5c6(0x11e),'profileName':_0x15472c}),console['error'](_0x3546b3[_0xccc5c6(0x13b)]),![];}const _0x2d5c26=_0x253704['some'](_0x4f7348=>{const _0x387d07=_0xccc5c6;try{return _0x3546b3['XeggJ'](new URL(_0x4f7348)[_0x387d07(0x157)],new URL(_0x3e5bef)['origin']);}catch{return![];}}),_0x1e0849={};!_0x2d5c26&&(_0x1e0849['baseUrl']=_0x3e5bef);try{await _0x3546b3['gsTdg'](createCloudProfile,_0x15472c,_0x499d47,{'settings':_0x1e0849}),_0x3546b3[_0xccc5c6(0x143)](warnCloudProfileSharedInOrg);}catch(_0x3db91e){if(_0x3546b3[_0xccc5c6(0xe5)](_0x3db91e,ApiError)&&_0x3546b3[_0xccc5c6(0x15b)](_0x3db91e[_0xccc5c6(0xfc)],0x199)){console['error'](_0x3546b3[_0xccc5c6(0x152)](_0xccc5c6(0xf6)+_0x15472c+_0xccc5c6(0x144),'\x20\x20\x20\x20\x20\x20ranger\x20profile\x20update\x20'+_0x15472c));throw _0x3db91e;}throw _0x3db91e;}return console[_0xccc5c6(0x160)](_0x3546b3[_0xccc5c6(0xe9)](_0xccc5c6(0x119)+_0x15472c+_0xccc5c6(0x15e),'\x20\x20Next:\x20ranger\x20go\x20--profile\x20'+_0x15472c)),await sweepOrphansBestEffort(_0x15472c),_0x2015ca?.[_0xccc5c6(0xf5)](_0xccc5c6(0xf3),{'envKey':_0x499d47,'profileName':_0x15472c}),!![];}async function createUnconfiguredCloudProfile(_0x4dc91a,_0x1d969c){const _0x547695=_0x8dce,_0x5482c4={'PksCP':function(_0xa5bc75,_0x1e3829,_0x4fdff8,_0x5e9d38){return _0xa5bc75(_0x1e3829,_0x4fdff8,_0x5e9d38);},'gWCqZ':function(_0x2892ce,_0x146429){return _0x2892ce===_0x146429;}};try{await _0x5482c4[_0x547695(0x15d)](createCloudProfile,_0x4dc91a,undefined,{'settings':_0x1d969c}),warnCloudProfileSharedInOrg();}catch(_0x1179ad){_0x1179ad instanceof ApiError&&_0x5482c4['gWCqZ'](_0x1179ad['status'],0x199)&&console['error']('\x0a\x20\x20A\x20profile\x20named\x20\x22'+_0x4dc91a+_0x547695(0x144)+('\x20\x20\x20\x20\x20\x20ranger\x20profile\x20update\x20'+_0x4dc91a));throw _0x1179ad;}}async function captureEnvLessProfile(_0x7f8b3f,_0x13607e,_0x3dfbc8,_0xcb67b7){const _0x37400b=_0x8dce,_0xd38004={'wevpG':_0x37400b(0x134),'iDUSn':_0x37400b(0x11a),'GcjpM':'user_declined','BbvTT':function(_0x10d366,_0x548eed){return _0x10d366+_0x548eed;},'Wpecw':function(_0x2ee512,_0x4eba13){return _0x2ee512>_0x4eba13;},'OFpqu':function(_0x26ad7c){return _0x26ad7c();},'VUNWr':function(_0x5a12d5,_0x238acc){return _0x5a12d5 instanceof _0x238acc;},'HFGfC':function(_0x1e4364,_0x20393b){return _0x1e4364+_0x20393b;}};if(!_0x3dfbc8[_0x37400b(0xe2)]){const {capture:_0x171385}=await _0x176ead[_0x37400b(0x108)]([{'type':_0xd38004[_0x37400b(0x112)],'name':'capture','message':_0xd38004[_0x37400b(0x13e)],'default':!![]}]);if(!_0x171385)return _0xcb67b7?.[_0x37400b(0xf5)](_0x37400b(0x106),{'reason':_0xd38004[_0x37400b(0xe0)],'profileName':_0x7f8b3f}),console['error'](_0xd38004[_0x37400b(0x146)](_0x37400b(0x133),'\x20\x20or\x20contact\x20eng@ranger.net\x20to\x20set\x20up\x20automated\x20login\x20for\x20your\x20team.')),![];}const _0x55f447={};if(_0x3dfbc8[_0x37400b(0x120)])for(const _0x4de4d3 of _0x3dfbc8['setupHeader']){const _0x53e3fb=_0x4de4d3[_0x37400b(0x158)](':');if(_0x53e3fb===-0x1)continue;_0x55f447[_0x4de4d3[_0x37400b(0x14d)](0x0,_0x53e3fb)[_0x37400b(0xee)]()]=_0x4de4d3['slice'](_0x53e3fb+0x1)['trim']();}const _0x5edda6={'baseUrl':_0x13607e};_0xd38004[_0x37400b(0xfb)](Object['keys'](_0x55f447)['length'],0x0)&&(_0x5edda6['setupHeaders']=_0x55f447);let _0x37bcb8;try{_0x37bcb8=await createCloudProfile(_0x7f8b3f,undefined,{'settings':_0x5edda6}),_0xd38004['OFpqu'](warnCloudProfileSharedInOrg);}catch(_0x32a819){_0xd38004['VUNWr'](_0x32a819,ApiError)&&_0x32a819['status']===0x199&&console['error']('\x0a\x20\x20A\x20profile\x20named\x20\x22'+_0x7f8b3f+_0x37400b(0x144)+(_0x37400b(0x14b)+_0x7f8b3f));throw _0x32a819;}return await manualBrowserLogin(_0x37bcb8,{'key':'','domains':[_0x13607e],'setupHeaders':_0xd38004['Wpecw'](Object['keys'](_0x55f447)[_0x37400b(0x105)],0x0)?_0x55f447:undefined}),console['log'](_0xd38004['HFGfC'](_0x37400b(0x127)+_0x7f8b3f+'\x27\x20created\x20with\x20a\x20captured\x20session.\x0a',_0x37400b(0x11d)+_0x7f8b3f)),await sweepOrphansBestEffort(_0x7f8b3f),_0xcb67b7?.[_0x37400b(0xf5)]('profile.add.autoRouted',{'envKey':null,'profileName':_0x7f8b3f}),!![];}export async function addEnv(_0x47cc63,_0x347a02={},_0x5949d5){const _0x57c060=_0x8dce,_0x45d103={'hYzMC':function(_0x54a7cb,_0x5c4dc9){return _0x54a7cb+_0x5c4dc9;},'lyppF':function(_0x316f13,_0x41d003){return _0x316f13+_0x41d003;},'ncxWz':function(_0x47d60f,_0x416c0d){return _0x47d60f+_0x416c0d;},'HnNOa':_0x57c060(0x14e),'CMxYF':_0x57c060(0x132),'TyXnX':_0x57c060(0x124),'ReMrQ':function(_0x4afa44,_0x21faab){return _0x4afa44!==_0x21faab;},'NlGhW':function(_0x5b4387,_0x14c73b){return _0x5b4387===_0x14c73b;},'Ugtpe':function(_0x4b2913,_0x29f6b8){return _0x4b2913(_0x29f6b8);},'sMBSf':_0x57c060(0x11c),'BfCpC':_0x57c060(0xfa),'QlDBR':function(_0x3dc3c8,_0x4a2d15,_0x2c8681){return _0x3dc3c8(_0x4a2d15,_0x2c8681);},'PKaLo':function(_0x5c6721,_0x4ba5bf,_0x429ac0,_0x30f8e4,_0x5d9dea){return _0x5c6721(_0x4ba5bf,_0x429ac0,_0x30f8e4,_0x5d9dea);},'RltbF':function(_0x2d8e27,_0x3e648f){return _0x2d8e27(_0x3e648f);},'RkMQm':_0x57c060(0x126),'aMgaC':'\x20\x20Make\x20sure\x20your\x20app\x20is\x20running\x20locally\x20before\x20continuing.','emDaK':_0x57c060(0xf7),'xtdeP':'What\x20is\x20the\x20URL\x20of\x20your\x20running\x20app?','wJrEa':_0x57c060(0x103),'SxJJS':'What\x20would\x20you\x20like\x20to\x20do?','hapHe':_0x57c060(0x115),'rKLvL':_0x57c060(0x156),'Ptuhj':'Continue\x20anyway','ZlzCv':'continue','zynjm':function(_0x332b14,_0x385786){return _0x332b14(_0x385786);}};_0x347a02['ci']&&(console['error'](_0x45d103['hYzMC'](_0x45d103['lyppF'](_0x45d103[_0x57c060(0x10c)](_0x57c060(0xf9)+'for\x20you,\x20so\x20the\x20encrypted-CI\x20flow\x20is\x20unnecessary.\x0a'+'\x0a','To\x20set\x20up\x20a\x20profile,\x20run:\x0a')+_0x45d103[_0x57c060(0x13f)],'\x0a')+_0x45d103['CMxYF'],_0x45d103[_0x57c060(0x12b)])),process[_0x57c060(0x159)](0x1));const _0x4d1e00={};if(_0x347a02[_0x57c060(0x120)])for(const _0xaf5661 of _0x347a02[_0x57c060(0x120)]){const _0x2c2ed1=_0xaf5661['indexOf'](':');if(_0x2c2ed1===-0x1)throw new Error(_0x57c060(0xfd)+_0xaf5661+_0x57c060(0xfe));const _0x89420f=_0xaf5661['slice'](0x0,_0x2c2ed1)['trim'](),_0x328ce5=_0xaf5661[_0x57c060(0x14d)](_0x45d103['lyppF'](_0x2c2ed1,0x1))['trim']();_0x4d1e00[_0x89420f]=_0x328ce5;}if(_0x45d103[_0x57c060(0x12e)](_0x347a02['cdpEndpoint'],undefined)&&_0x45d103[_0x57c060(0x13a)](_0x347a02['cdpEndpoint'][_0x57c060(0xee)](),''))throw new Error('--cdp-endpoint\x20must\x20not\x20be\x20empty.\x20Provide\x20the\x20CDP\x20URL,\x20e.g.\x20--cdp-endpoint\x20http://localhost:9222');if(_0x347a02['cdpEndpoint']&&_0x347a02['url'])throw new Error(_0x57c060(0xf0));const _0xa413a8=_0x45d103['Ugtpe'](Boolean,_0x347a02['cdpEndpoint']),_0x556e03=isInteractive();if(!_0x556e03&&!_0x347a02['url']&&!_0xa413a8&&!_0x347a02[_0x57c060(0xf2)])throw new Error(_0x45d103['sMBSf']);if(_0xa413a8){const _0x221704=_0x347a02['cdpEndpoint'];console[_0x57c060(0x160)](_0x45d103['BfCpC']),console[_0x57c060(0x160)]('\x20\x20Configuring\x20Ranger\x20to\x20connect\x20to:\x20'+_0x221704);const _0x289f89={'cdpEndpoint':_0x221704,'isElectron':!![]};Object['keys'](_0x4d1e00)['length']>0x0&&(_0x289f89['setupHeaders']=_0x4d1e00);await _0x45d103['QlDBR'](createUnconfiguredCloudProfile,_0x47cc63,_0x289f89);try{setProfileOverride(process['cwd'](),_0x47cc63,'cdpEndpoint',_0x221704),_0x45d103['PKaLo'](setProfileOverride,process[_0x57c060(0x104)](),_0x47cc63,_0x57c060(0x12d),!![]);}catch(_0x1442c6){console['error']('\x0a\x20\x20Cloud\x20profile\x20created,\x20but\x20failed\x20to\x20write\x20per-cwd\x20CDP\x20override\x20to\x20projects.json:\x20'+(_0x1442c6 instanceof Error?_0x1442c6[_0x57c060(0x102)]:_0x45d103[_0x57c060(0x15a)](String,_0x1442c6)));}console[_0x57c060(0x160)](_0x57c060(0x136)+_0x47cc63+'\x27\x20created\x20(CDP).'),await _0x45d103[_0x57c060(0x15a)](sweepOrphansBestEffort,_0x47cc63),await _0x45d103[_0x57c060(0x11b)](markActive,_0x47cc63);return;}if(_0x347a02[_0x57c060(0xf2)]){const _0x287d94={};_0x347a02['url']&&(_0x287d94['baseUrl']=_0x347a02['url']);Object['keys'](_0x4d1e00)['length']>0x0&&(_0x287d94[_0x57c060(0x15f)]=_0x4d1e00);await createUnconfiguredCloudProfile(_0x47cc63,_0x287d94),console['log'](_0x57c060(0x119)+_0x47cc63+'\x27\x20created\x20(no\x20session).\x0a'+(_0x57c060(0x10f)+_0x47cc63+'`\x20again\x20without\x20--skip-auth.')),await sweepOrphansBestEffort(_0x47cc63),await markActive(_0x47cc63);return;}if(_0x347a02[_0x57c060(0xef)]){const _0x3a9f68=_0x347a02[_0x57c060(0xef)],_0x1f7805=await checkUrlReachability(_0x3a9f68);if(!_0x1f7805['ok']&&!_0x347a02['force'])throw new Error('Could\x20not\x20reach\x20'+_0x3a9f68+':\x20'+_0x1f7805['error']+_0x57c060(0x130));!_0x1f7805['ok']&&_0x347a02[_0x57c060(0x140)]&&console[_0x57c060(0x160)]('⚠\x20Could\x20not\x20reach\x20'+_0x3a9f68+':\x20'+_0x1f7805[_0x57c060(0x116)]+'\x20(continuing\x20with\x20--force)');}else{console['log'](_0x45d103[_0x57c060(0x150)]),console['log'](_0x45d103[_0x57c060(0x148)]),console['log'](_0x57c060(0x100));let _0x4a85f4='',_0x27b772=![];while(!![]){const _0x408629=await _0x176ead[_0x57c060(0x108)]([{'type':_0x57c060(0x154),'name':'baseUrl','message':_0x27b772?_0x45d103[_0x57c060(0xff)]:_0x45d103['xtdeP'],'default':_0x4a85f4||_0x57c060(0x113)}]);_0x4a85f4=_0x408629['baseUrl'];const _0x52119c=await checkUrlReachability(_0x4a85f4);if(_0x52119c['ok'])break;const _0x22e4e9=/^[a-zA-Z][\w+.-]*:\/\//['test'](_0x4a85f4),_0x1ee97f=_0x52119c[_0x57c060(0xe3)]&&!_0x22e4e9,_0x5b7c94=_0x1ee97f?_0x57c060(0x128)+_0x4a85f4:null;_0x27b772=!![],console[_0x57c060(0x160)]('\x0a\x20\x20Could\x20not\x20reach\x20'+_0x4a85f4+':\x20'+_0x52119c['error']);_0x5b7c94&&console['log'](_0x57c060(0x155)+_0x5b7c94+'?');const {action:_0xae5448}=await _0x176ead[_0x57c060(0x108)]([{'type':'list','name':_0x45d103[_0x57c060(0x149)],'message':_0x45d103['SxJJS'],'choices':[..._0x5b7c94?[{'name':'Use\x20'+_0x5b7c94,'value':'use_suggestion'}]:[],{'name':_0x45d103[_0x57c060(0x10d)],'value':_0x45d103['rKLvL']},{'name':_0x45d103['Ptuhj'],'value':'continue'}]}]);if(_0x45d103['NlGhW'](_0xae5448,'use_suggestion')&&_0x5b7c94){_0x4a85f4=_0x5b7c94;const _0x321b61=await checkUrlReachability(_0x4a85f4);if(_0x321b61['ok'])break;console['log']('\x0a\x20\x20Still\x20could\x20not\x20reach\x20'+_0x4a85f4+':\x20'+_0x321b61[_0x57c060(0x116)]);}else{if(_0xae5448===_0x45d103[_0x57c060(0xeb)])break;}}_0x347a02={..._0x347a02,'url':_0x4a85f4};}let _0xa30ad4=![];try{_0xa30ad4=await tryAutoRouteCloudProfile(_0x47cc63,_0x347a02[_0x57c060(0xef)],_0x347a02,_0x556e03,_0x5949d5);}catch(_0x573799){console[_0x57c060(0x116)]('\x0a\x20\x20Failed\x20to\x20create\x20cloud\x20profile\x20\x22'+_0x47cc63+'\x22:\x20'+(_0x573799 instanceof Error?_0x573799['message']:_0x45d103[_0x57c060(0x11b)](String,_0x573799))),process['exit'](0x1);}!_0xa30ad4&&process[_0x57c060(0x159)](0x1),await _0x45d103['zynjm'](markActive,_0x47cc63);}
1
+ const _0x1c611c=_0x50a7;(function(_0x55444,_0x1a52d5){const _0x43937b=_0x50a7,_0x56a93c=_0x55444();while(!![]){try{const _0x276ab6=-parseInt(_0x43937b(0xe5))/0x1*(parseInt(_0x43937b(0xd0))/0x2)+parseInt(_0x43937b(0xf3))/0x3*(parseInt(_0x43937b(0xfd))/0x4)+-parseInt(_0x43937b(0xe7))/0x5*(-parseInt(_0x43937b(0xc0))/0x6)+parseInt(_0x43937b(0xcf))/0x7+-parseInt(_0x43937b(0xf6))/0x8+-parseInt(_0x43937b(0xf5))/0x9*(parseInt(_0x43937b(0xc1))/0xa)+-parseInt(_0x43937b(0x128))/0xb*(-parseInt(_0x43937b(0xb9))/0xc);if(_0x276ab6===_0x1a52d5)break;else _0x56a93c['push'](_0x56a93c['shift']());}catch(_0x389496){_0x56a93c['push'](_0x56a93c['shift']());}}}(_0x5ee3,0x32f0a));import{readdir,rm}from'fs/promises';import{join}from'path';import{existsSync}from'fs';import _0x471a2b 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{isInteractive}from'./utils/cloudProfileSession.js';import{matchAuthEnvironment}from'./utils/matchAuthEnvironment.js';import{isPathGitTracked}from'./utils/gitTracked.js';import{setProfileOverride}from'./utils/projectsConfig.js';function _0x5ee3(){const _0x17b74e=['cdpEndpoint','domains','isTTY','profile.add.autoRouteSkipped','\x27\x20to\x20the\x20cloud?','skipAuth','ZfUeo','HbMoK','VfRAO','Pvyns','IfdFF','\x22\x20already\x20exists.\x20To\x20refresh\x20its\x20session,\x20run:\x0a','\x20--url\x20','profile.add.autoRouted','signal','message','\x20\x20To\x20get\x20automated\x20login\x20set\x20up\x20for\x20your\x20team\x20(a\x20one-time\x20call):\x20eng@ranger.net\x0a','2651snkRWw','This\x20account\x20will\x20be\x20shared\x20with\x20everyone\x20at\x20your\x20organization','pOgUI','includes','OHIvW','OXoie','\x20\x20Set\x20active\x20profile:\x20','keys','\x22.\x20Expected\x20\x22Name:\x20Value\x22.','setupHeader','HEAD','zsxgt','indexOf','27156RMlsEv','KkBDu','oGthY','no_auth_config','action','continue','status','442044mPnfPH','20vYwcUG','origin','OqzOp','Invalid\x20--setup-header\x20format:\x20\x22',')\x0a\x20\x20Save\x20\x27','input','yes','length','force','EgcbW','gRFzG','osOYm','\x0a\x20\x20Could\x20not\x20fetch\x20this\x20org\x27s\x20auth\x20config:\x20','cwd','748643SjNnUE','28LmMnUR','\x20\x20or\x20contact\x20eng@ranger.net\x20to\x20set\x20up\x20automated\x20login\x20for\x20your\x20team.','fcMtK','\x20\x20Cleaned\x20up\x20orphan\x20local\x20profile\x20at\x20','test','\x27\x20matching\x20','To\x20set\x20up\x20a\x20profile,\x20run:\x0a','\x0a\x20\x20Still\x20could\x20not\x20reach\x20','isElectron','\x0a\x20\x20Could\x20not\x20reach\x20','HTmqJ','QlWpZ','wKnzz','error','Found\x20auth\x20environment\x20\x27','fiaFy','setupHeaders','✓\x20Profile\x20\x27','xFkZp','.\x20Configured\x20envs:\x20','env','10357mwZOrp','retry','10WqjUVi','trackPhaseEnd','VrhTg','JXlJs','\x0a🔌\x20CDP\x20Profile\x20Setup\x0a','\x20\x20https://docs.ranger.net/main/concepts/profiles','\x0a\x20\x20A\x20profile\x20named\x20\x22','mcteK','ZryKm','For\x20CI\x20/\x20background\x20agents\x20and\x20other\x20setup\x20options,\x20see:\x0a','join','qlHOs','324195kUHkXC','list','1195191uuitzC','2307992lLhJNI','\x20\x20Next:\x20ranger\x20go\x20--profile\x20','http://localhost:3000','url','\x20\x20\x20\x20\x20\x20ranger\x20profile\x20update\x20','KICcz','prompt','4mXLePm','baseUrl','TypeError','jPqNu','Could\x20not\x20reach\x20','Continue\x20anyway','UyUaR','log','\x0a\x20\x20Failed\x20to\x20create\x20cloud\x20profile\x20\x22','local','✓\x20Cloud\x20profile\x20\x27','sJNPv','zAvbQ','NODE_TLS_REJECT_UNAUTHORIZED','environments','NNoVk','Automated\x20login\x20isn\x27t\x20set\x20up\x20for\x20your\x20team.\x20Capture\x20a\x20session\x20via\x20a\x20headed\x20browser\x20instead?','user_declined','\x0a\x20\x20Declined.\x20Re-run\x20with\x20--skip-auth\x20to\x20create\x20a\x20profile\x20without\x20a\x20session,\x0a','\x27\x20created\x20(no\x20session).\x0a','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','trim','warn','slice','\x20\x20Make\x20sure\x20your\x20app\x20is\x20running\x20locally\x20before\x20continuing.','ZTbJi'];_0x5ee3=function(){return _0x17b74e;};return _0x5ee3();}const CLOUD_PROFILE_SHARING_WARNING=_0x1c611c(0x129);function warnCloudProfileSharedInOrg(){const _0x3b6273=_0x1c611c;if(!process['stdout'][_0x3b6273(0x119)])return;console[_0x3b6273(0x113)](CLOUD_PROFILE_SHARING_WARNING);}async function checkUrlReachability(_0x3d13af){const _0x10a114=_0x1c611c,_0x52ba33={'SxXCB':function(_0x15eb73,_0x294326,_0xc60753){return _0x15eb73(_0x294326,_0xc60753);},'rFDsp':_0x10a114(0xb6),'HTmqJ':function(_0x2cc892,_0xb5d0af){return _0x2cc892<_0xb5d0af;},'pOgUI':function(_0x109ef4,_0x35edb8){return _0x109ef4===_0x35edb8;},'QDOfv':_0x10a114(0xff)};try{const _0x1158a2=new AbortController(),_0x1fe3a4=_0x52ba33['SxXCB'](setTimeout,()=>_0x1158a2['abort'](),0x1388),_0x206c86={'method':_0x52ba33['rFDsp'],'signal':_0x1158a2[_0x10a114(0x125)],'redirect':'manual'};/^https:\/\/localhost(:\d+)?/i[_0x10a114(0xd4)](_0x3d13af)&&(process['env'][_0x10a114(0x10a)]='0');const _0x3d5a1b=await fetch(_0x3d13af,_0x206c86);delete process['env']['NODE_TLS_REJECT_UNAUTHORIZED'],clearTimeout(_0x1fe3a4);if(_0x52ba33[_0x10a114(0xda)](_0x3d5a1b['status'],0x190))return{'ok':!![]};return{'ok':![],'error':'HTTP\x20'+_0x3d5a1b['status']};}catch(_0x2b4e3c){delete process[_0x10a114(0xe4)][_0x10a114(0x10a)];const _0x42eae8=_0x2b4e3c,_0x22fe7b=_0x42eae8['message']||String(_0x2b4e3c),_0x1b1c3f=_0x22fe7b[_0x10a114(0x12b)]('Invalid\x20URL')||_0x52ba33[_0x10a114(0x12a)](_0x42eae8['name'],_0x52ba33['QDOfv'])||_0x22fe7b['includes']('fetch\x20failed');return{'ok':![],'error':_0x22fe7b,'isProtocolError':_0x1b1c3f};}}async function sweepOrphanLocalProfile(_0x17ac67,_0x4ca641,_0x22c31a){const _0x5d686c=_0x1c611c,_0x23be95={'pFhvf':_0x5d686c(0x106),'sJNPv':function(_0x1d1c01,_0x4dfd6d,_0x5722d7){return _0x1d1c01(_0x4dfd6d,_0x5722d7);},'eYiZG':function(_0x2ccf46,_0x34f631){return _0x2ccf46(_0x34f631);},'zzDWg':function(_0x26c503,_0x3a825b,_0x57848f){return _0x26c503(_0x3a825b,_0x57848f);},'FiNRX':function(_0x300b53,_0x239509){return _0x300b53(_0x239509);}},_0x183fe4=join(_0x4ca641,_0x23be95['pFhvf']),_0x17210b=_0x23be95[_0x5d686c(0x108)](join,_0x183fe4,_0x17ac67);_0x23be95['eYiZG'](existsSync,_0x17210b)&&(_0x22c31a&&await isPathGitTracked(_0x17210b)?console['log']('\x20\x20Note:\x20found\x20git-tracked\x20local\x20profile\x20at\x20'+_0x17210b+'\x20—\x20not\x20removing.\x20Delete\x20manually\x20if\x20you\x20want\x20it\x20gone.'):(await _0x23be95['zzDWg'](rm,_0x17210b,{'recursive':!![],'force':!![]}),console['log']('\x20\x20Cleaned\x20up\x20orphan\x20local\x20profile\x20at\x20'+_0x17210b)));if(existsSync(_0x183fe4)){let _0x36812e=[];try{_0x36812e=await _0x23be95['FiNRX'](readdir,_0x183fe4);}catch{return;}const _0x5d1b54='.tmp-'+_0x17ac67+'-';for(const _0x5f1285 of _0x36812e){if(!_0x5f1285['startsWith'](_0x5d1b54))continue;const _0x3b4273=join(_0x183fe4,_0x5f1285);await _0x23be95['sJNPv'](rm,_0x3b4273,{'recursive':!![],'force':!![]}),console[_0x5d686c(0x104)](_0x5d686c(0xd3)+_0x3b4273);}}}async function sweepOrphansBestEffort(_0x378037){const _0x42749c={'oCFed':function(_0x19a58a,_0x58814e,_0x520c18,_0x2a5cd0){return _0x19a58a(_0x58814e,_0x520c18,_0x2a5cd0);},'sqsoj':function(_0xc76596){return _0xc76596();},'hJDuK':function(_0xe17a21,_0x66a3e5,_0x5248f3,_0x5abb05){return _0xe17a21(_0x66a3e5,_0x5248f3,_0x5abb05);},'MWFHP':function(_0x3c6a83,_0x117e12){return _0x3c6a83(_0x117e12);}};try{await _0x42749c['oCFed'](sweepOrphanLocalProfile,_0x378037,_0x42749c['sqsoj'](getRangerHomeDir),![]);const _0x139c9d=getRangerDir();_0x139c9d!==getRangerHomeDir()&&await _0x42749c['hJDuK'](sweepOrphanLocalProfile,_0x378037,_0x139c9d,!![]);}catch(_0x6742b5){console['log']('\x20\x20Note:\x20cloud\x20profile\x20created,\x20but\x20failed\x20to\x20sweep\x20orphan\x20local\x20dirs\x20('+(_0x6742b5 instanceof Error?_0x6742b5['message']:_0x42749c['MWFHP'](String,_0x6742b5))+').');}}async function markActive(_0x1dee8c){const _0x4b6164=_0x1c611c,_0x5304bb={'IfdFF':'Warning:\x20Profile\x20created,\x20but\x20failed\x20to\x20mark\x20it\x20as\x20active.'};try{await writeActiveProfileName(_0x1dee8c),console['log'](_0x4b6164(0xb2)+_0x1dee8c);}catch{console['log'](_0x5304bb[_0x4b6164(0x121)]);}}function _0x50a7(_0x4400c1,_0xebb5b2){_0x4400c1=_0x4400c1-0xb1;const _0x5ee30c=_0x5ee3();let _0x50a7bc=_0x5ee30c[_0x4400c1];return _0x50a7bc;}async function tryAutoRouteCloudProfile(_0x54802a,_0x24c65e,_0x29c90c,_0x34fd7f,_0x4cc5a1){const _0x46f46e=_0x1c611c,_0x4698c3={'zAvbQ':function(_0x6b66af){return _0x6b66af();},'fcMtK':function(_0x1d3006,_0x31d5ad){return _0x1d3006(_0x31d5ad);},'OqzOp':function(_0x573b66,_0x17c413){return _0x573b66===_0x17c413;},'Pvyns':function(_0x57f72b,_0x12d4ee){return _0x57f72b+_0x12d4ee;},'zsxgt':function(_0x44a7b,_0x2d1696){return _0x44a7b+_0x2d1696;},'bRZfU':function(_0x4bcdf2,_0x52af03){return _0x4bcdf2+_0x52af03;},'QlWpZ':function(_0x4be7b8,_0x545a41){return _0x4be7b8+_0x545a41;},'KkBDu':'\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','yaojt':'\x20\x20Workaround\x20for\x20now:\x20create\x20a\x20profile\x20without\x20a\x20captured\x20session\x20and\x20supply\x20one\x20later:\x0a','jPqNu':_0x46f46e(0x127),'wwIgK':'\x20\x20Details:\x20https://docs.ranger.net/main/concepts/profiles#automated-login','NlntW':'confirm','ukiXM':'user_declined','ANjle':function(_0x1de93a,_0x3c6f8f,_0x4dff75,_0x3a1fe6){return _0x1de93a(_0x3c6f8f,_0x4dff75,_0x3a1fe6);},'mLbgl':function(_0x1dcbe6,_0x177dd9){return _0x1dcbe6 instanceof _0x177dd9;},'RYWEq':function(_0x5b3a7a,_0x18135b){return _0x5b3a7a(_0x18135b);}};let _0x8c302e;try{_0x8c302e=await _0x4698c3['zAvbQ'](fetchAuthConfig);}catch(_0x395503){return _0x4cc5a1?.['trackPhaseEnd'](_0x46f46e(0x11a),{'reason':_0x46f46e(0xbc),'profileName':_0x54802a}),console['error'](_0x46f46e(0xcd)+(_0x395503 instanceof Error?_0x395503[_0x46f46e(0x126)]:_0x4698c3[_0x46f46e(0xd2)](String,_0x395503))),![];}if(!_0x8c302e||!_0x8c302e['environments']||_0x4698c3[_0x46f46e(0xc3)](Object[_0x46f46e(0xb3)](_0x8c302e['environments'])['length'],0x0)){if(_0x34fd7f)return await captureEnvLessProfile(_0x54802a,_0x24c65e,_0x29c90c,_0x4cc5a1);return _0x4cc5a1?.['trackPhaseEnd']('profile.add.autoRouteSkipped',{'reason':_0x46f46e(0xbc),'profileName':_0x54802a}),console[_0x46f46e(0xdd)](_0x4698c3[_0x46f46e(0x120)](_0x4698c3['Pvyns'](_0x4698c3[_0x46f46e(0x120)](_0x4698c3[_0x46f46e(0xb7)](_0x4698c3['bRZfU'](_0x4698c3[_0x46f46e(0xdb)](_0x4698c3[_0x46f46e(0xba)],'\x0a'),_0x4698c3['yaojt']),'\x20\x20\x20\x20\x20\x20ranger\x20profile\x20add\x20'+_0x54802a+_0x46f46e(0x123)+_0x24c65e+'\x20--skip-auth\x0a'),'\x0a'),_0x4698c3[_0x46f46e(0x100)]),_0x4698c3['wwIgK'])),![];}const _0x990be7=matchAuthEnvironment(_0x24c65e,_0x8c302e);if(!_0x990be7)return _0x4cc5a1?.[_0x46f46e(0xe8)](_0x46f46e(0x11a),{'reason':'no_match','profileName':_0x54802a}),console[_0x46f46e(0xdd)]('\x0a\x20\x20No\x20auth\x20env\x20matches\x20'+_0x24c65e+_0x46f46e(0xe3)+Object[_0x46f46e(0xb3)](_0x8c302e[_0x46f46e(0x10b)])[_0x46f46e(0xf1)](',\x20')+'.'),![];const _0x456ac7=_0x8c302e['environments'][_0x990be7],_0xd91488=_0x456ac7?.[_0x46f46e(0x118)]??[];if(_0x34fd7f&&!_0x29c90c['yes']){const {saveToCloud:_0x10936}=await _0x471a2b[_0x46f46e(0xfc)]([{'type':_0x4698c3['NlntW'],'name':'saveToCloud','message':_0x46f46e(0xde)+_0x990be7+_0x46f46e(0xd5)+_0x24c65e+'\x0a\x20\x20(domains:\x20'+_0xd91488['join'](',\x20')+_0x46f46e(0xc5)+_0x54802a+_0x46f46e(0x11b),'default':!![]}]);if(!_0x10936)return _0x4cc5a1?.[_0x46f46e(0xe8)](_0x46f46e(0x11a),{'reason':_0x4698c3['ukiXM'],'profileName':_0x54802a}),console['error']('\x0a\x20\x20Declined.\x20Re-run\x20with\x20--skip-auth\x20to\x20create\x20a\x20profile\x20without\x20a\x20cloud-managed\x20session.'),![];}const _0x417f4b=_0xd91488['some'](_0x1f1a96=>{const _0x26e96d=_0x46f46e;try{return new URL(_0x1f1a96)[_0x26e96d(0xc2)]===new URL(_0x24c65e)[_0x26e96d(0xc2)];}catch{return![];}}),_0x50f7cb={};!_0x417f4b&&(_0x50f7cb['baseUrl']=_0x24c65e);try{await _0x4698c3['ANjle'](createCloudProfile,_0x54802a,_0x990be7,{'settings':_0x50f7cb}),_0x4698c3[_0x46f46e(0x109)](warnCloudProfileSharedInOrg);}catch(_0x51ba95){if(_0x4698c3['mLbgl'](_0x51ba95,ApiError)&&_0x51ba95['status']===0x199){console['error'](_0x4698c3[_0x46f46e(0xb7)](_0x46f46e(0xed)+_0x54802a+_0x46f46e(0x122),'\x20\x20\x20\x20\x20\x20ranger\x20profile\x20update\x20'+_0x54802a));throw _0x51ba95;}throw _0x51ba95;}return console['log']('✓\x20Profile\x20\x27'+_0x54802a+'\x27\x20created.\x0a'+(_0x46f46e(0xf7)+_0x54802a)),await _0x4698c3['RYWEq'](sweepOrphansBestEffort,_0x54802a),_0x4cc5a1?.['trackPhaseEnd']('profile.add.autoRouted',{'envKey':_0x990be7,'profileName':_0x54802a}),!![];}async function createUnconfiguredCloudProfile(_0x1b3e83,_0x5f4ab4){const _0x4f363d=_0x1c611c,_0x40f9c3={'NesYf':function(_0x283daf){return _0x283daf();}};try{await createCloudProfile(_0x1b3e83,undefined,{'settings':_0x5f4ab4}),_0x40f9c3['NesYf'](warnCloudProfileSharedInOrg);}catch(_0x5e9edb){_0x5e9edb instanceof ApiError&&_0x5e9edb['status']===0x199&&console['error'](_0x4f363d(0xed)+_0x1b3e83+_0x4f363d(0x122)+(_0x4f363d(0xfa)+_0x1b3e83));throw _0x5e9edb;}}async function captureEnvLessProfile(_0x3b8599,_0x15f367,_0x5d70cd,_0x3aa0cf){const _0xefd1ae=_0x1c611c,_0x4c038d={'yzSAF':'confirm','oGthY':'capture','ZryKm':_0xefd1ae(0x10d),'JXlJs':'profile.add.autoRouteSkipped','ZTbJi':function(_0x5b27d9,_0x19d8b2){return _0x5b27d9===_0x19d8b2;},'aippH':function(_0x29ad53,_0x2b0536){return _0x29ad53===_0x2b0536;},'qMcda':function(_0x1403a0,_0x1587db){return _0x1403a0+_0x1587db;},'tHshZ':function(_0x6578fb,_0x2ceae0){return _0x6578fb>_0x2ceae0;},'HgUgw':_0xefd1ae(0x124)};if(!_0x5d70cd[_0xefd1ae(0xc7)]){const {capture:_0x2a36ec}=await _0x471a2b[_0xefd1ae(0xfc)]([{'type':_0x4c038d['yzSAF'],'name':_0x4c038d[_0xefd1ae(0xbb)],'message':_0x4c038d[_0xefd1ae(0xef)],'default':!![]}]);if(!_0x2a36ec)return _0x3aa0cf?.[_0xefd1ae(0xe8)](_0x4c038d[_0xefd1ae(0xea)],{'reason':_0xefd1ae(0x10e),'profileName':_0x3b8599}),console['error'](_0xefd1ae(0x10f)+_0xefd1ae(0xd1)),![];}const _0x2a4887={};if(_0x5d70cd['setupHeader'])for(const _0x30306f of _0x5d70cd['setupHeader']){const _0x563eed=_0x30306f[_0xefd1ae(0xb8)](':');if(_0x4c038d[_0xefd1ae(0x116)](_0x563eed,-0x1))continue;_0x2a4887[_0x30306f['slice'](0x0,_0x563eed)['trim']()]=_0x30306f['slice'](_0x563eed+0x1)['trim']();}const _0x349147={'baseUrl':_0x15f367};Object['keys'](_0x2a4887)[_0xefd1ae(0xc8)]>0x0&&(_0x349147[_0xefd1ae(0xe0)]=_0x2a4887);let _0x4466a2;try{_0x4466a2=await createCloudProfile(_0x3b8599,undefined,{'settings':_0x349147}),warnCloudProfileSharedInOrg();}catch(_0x398dd4){_0x398dd4 instanceof ApiError&&_0x4c038d['aippH'](_0x398dd4[_0xefd1ae(0xbf)],0x199)&&console['error'](_0x4c038d['qMcda'](_0xefd1ae(0xed)+_0x3b8599+'\x22\x20already\x20exists.\x20To\x20refresh\x20its\x20session,\x20run:\x0a','\x20\x20\x20\x20\x20\x20ranger\x20profile\x20update\x20'+_0x3b8599));throw _0x398dd4;}return await manualBrowserLogin(_0x4466a2,{'key':'','domains':[_0x15f367],'setupHeaders':_0x4c038d['tHshZ'](Object[_0xefd1ae(0xb3)](_0x2a4887)['length'],0x0)?_0x2a4887:undefined}),console['log']('\x0a✓\x20Profile\x20\x27'+_0x3b8599+'\x27\x20created\x20with\x20a\x20captured\x20session.\x0a'+(_0xefd1ae(0xf7)+_0x3b8599)),await sweepOrphansBestEffort(_0x3b8599),_0x3aa0cf?.[_0xefd1ae(0xe8)](_0x4c038d['HgUgw'],{'envKey':null,'profileName':_0x3b8599}),!![];}export async function addEnv(_0x2556d3,_0x4bc6c6={},_0x3e8684){const _0x20e68e=_0x1c611c,_0x40e98b={'KICcz':function(_0x5549ca,_0x293cbc){return _0x5549ca+_0x293cbc;},'qlHOs':function(_0x51f4bd,_0x17f467){return _0x51f4bd+_0x17f467;},'ZfUeo':'The\x20--ci\x20flag\x20is\x20no\x20longer\x20supported.\x20Ranger\x20now\x20manages\x20session\x20state\x0a','YnPPp':'for\x20you,\x20so\x20the\x20encrypted-CI\x20flow\x20is\x20unnecessary.\x0a','VfRAO':_0x20e68e(0xd6),'osOYm':'\x20\x20ranger\x20profile\x20add\x20<name>\x0a','UyUaR':function(_0x5461c4,_0x5f4901){return _0x5461c4!==_0x5f4901;},'OXoie':'--cdp-endpoint\x20must\x20not\x20be\x20empty.\x20Provide\x20the\x20CDP\x20URL,\x20e.g.\x20--cdp-endpoint\x20http://localhost:9222','xlmeJ':'--url\x20and\x20--cdp-endpoint\x20are\x20mutually\x20exclusive.\x20Use\x20--url\x20for\x20web\x20apps\x20or\x20--cdp-endpoint\x20for\x20Electron/CDP\x20apps,\x20not\x20both.','VrhTg':function(_0x1418e8,_0x37af7a){return _0x1418e8(_0x37af7a);},'XJVEP':function(_0x45b94f){return _0x45b94f();},'HbMoK':function(_0x586e31,_0x511a51,_0x3d34d0){return _0x586e31(_0x511a51,_0x3d34d0);},'NNoVk':function(_0x245516,_0x1e4662,_0x60a8ad,_0xc91b54,_0x4cc5a6){return _0x245516(_0x1e4662,_0x60a8ad,_0xc91b54,_0x4cc5a6);},'DocJR':_0x20e68e(0x117),'EgcbW':_0x20e68e(0xd8),'xFkZp':function(_0x476a7a,_0x13466d){return _0x476a7a instanceof _0x13466d;},'KfesU':function(_0x1c7073,_0x3fa1d1){return _0x1c7073(_0x3fa1d1);},'fiaFy':function(_0x41493f,_0x63f4cc){return _0x41493f(_0x63f4cc);},'qmVmp':'\x0a🌐\x20Profile\x20Setup\x0a','kpOms':_0x20e68e(0xc6),'OHIvW':'What\x20is\x20the\x20URL\x20of\x20your\x20running\x20app?','UYprH':function(_0x2479fb,_0x5c87b9){return _0x2479fb||_0x5c87b9;},'gRFzG':function(_0xcb145b,_0x387035){return _0xcb145b(_0x387035);},'VJoFr':_0x20e68e(0xf4),'wKnzz':_0x20e68e(0xbd),'OEyQI':'What\x20would\x20you\x20like\x20to\x20do?','mcteK':'use_suggestion','eRMXm':'Enter\x20a\x20different\x20URL','aCfvJ':function(_0x136cf0,_0x129052){return _0x136cf0===_0x129052;},'GTcPB':_0x20e68e(0xbe),'DZBFl':function(_0x3a7994,_0x30c41a,_0x536235,_0x215c04,_0x218d83,_0x57b457){return _0x3a7994(_0x30c41a,_0x536235,_0x215c04,_0x218d83,_0x57b457);}};_0x4bc6c6['ci']&&(console[_0x20e68e(0xdd)](_0x40e98b[_0x20e68e(0xfb)](_0x40e98b[_0x20e68e(0xf2)](_0x40e98b[_0x20e68e(0x11d)]+_0x40e98b['YnPPp'],'\x0a')+_0x40e98b[_0x20e68e(0x11f)]+_0x40e98b[_0x20e68e(0xcc)]+'\x0a',_0x20e68e(0xf0))+_0x20e68e(0xec)),process['exit'](0x1));const _0x13e73e={};if(_0x4bc6c6['setupHeader'])for(const _0x42000b of _0x4bc6c6[_0x20e68e(0xb5)]){const _0xc4ca54=_0x42000b['indexOf'](':');if(_0xc4ca54===-0x1)throw new Error(_0x20e68e(0xc4)+_0x42000b+_0x20e68e(0xb4));const _0x2530f9=_0x42000b[_0x20e68e(0x114)](0x0,_0xc4ca54)['trim'](),_0x813f7c=_0x42000b[_0x20e68e(0x114)](_0xc4ca54+0x1)['trim']();_0x13e73e[_0x2530f9]=_0x813f7c;}if(_0x40e98b[_0x20e68e(0x103)](_0x4bc6c6[_0x20e68e(0x117)],undefined)&&_0x4bc6c6[_0x20e68e(0x117)][_0x20e68e(0x112)]()==='')throw new Error(_0x40e98b[_0x20e68e(0xb1)]);if(_0x4bc6c6[_0x20e68e(0x117)]&&_0x4bc6c6['url'])throw new Error(_0x40e98b['xlmeJ']);const _0x1cf87e=_0x40e98b['VrhTg'](Boolean,_0x4bc6c6['cdpEndpoint']),_0x2d39c1=_0x40e98b['XJVEP'](isInteractive);if(!_0x2d39c1&&!_0x4bc6c6['url']&&!_0x1cf87e&&!_0x4bc6c6[_0x20e68e(0x11c)])throw new Error(_0x20e68e(0x111));if(_0x1cf87e){const _0x1ab809=_0x4bc6c6[_0x20e68e(0x117)];console[_0x20e68e(0x104)](_0x20e68e(0xeb)),console['log']('\x20\x20Configuring\x20Ranger\x20to\x20connect\x20to:\x20'+_0x1ab809);const _0x565c8f={'cdpEndpoint':_0x1ab809,'isElectron':!![]};Object['keys'](_0x13e73e)[_0x20e68e(0xc8)]>0x0&&(_0x565c8f['setupHeaders']=_0x13e73e);await _0x40e98b[_0x20e68e(0x11e)](createUnconfiguredCloudProfile,_0x2556d3,_0x565c8f);try{_0x40e98b['NNoVk'](setProfileOverride,process[_0x20e68e(0xce)](),_0x2556d3,_0x40e98b['DocJR'],_0x1ab809),_0x40e98b[_0x20e68e(0x10c)](setProfileOverride,process['cwd'](),_0x2556d3,_0x40e98b[_0x20e68e(0xca)],!![]);}catch(_0x4c1e71){console['error']('\x0a\x20\x20Cloud\x20profile\x20created,\x20but\x20failed\x20to\x20write\x20per-cwd\x20CDP\x20override\x20to\x20projects.json:\x20'+(_0x40e98b[_0x20e68e(0xe2)](_0x4c1e71,Error)?_0x4c1e71['message']:_0x40e98b[_0x20e68e(0xe9)](String,_0x4c1e71)));}console['log'](_0x20e68e(0x107)+_0x2556d3+'\x27\x20created\x20(CDP).'),await _0x40e98b['KfesU'](sweepOrphansBestEffort,_0x2556d3),await markActive(_0x2556d3);return;}if(_0x4bc6c6[_0x20e68e(0x11c)]){const _0x48292d={};_0x4bc6c6[_0x20e68e(0xf9)]&&(_0x48292d['baseUrl']=_0x4bc6c6[_0x20e68e(0xf9)]);Object['keys'](_0x13e73e)['length']>0x0&&(_0x48292d['setupHeaders']=_0x13e73e);await _0x40e98b[_0x20e68e(0x11e)](createUnconfiguredCloudProfile,_0x2556d3,_0x48292d),console[_0x20e68e(0x104)](_0x20e68e(0xe1)+_0x2556d3+_0x20e68e(0x110)+('\x20\x20When\x20you\x27re\x20ready\x20to\x20log\x20in,\x20run\x20`ranger\x20profile\x20add\x20'+_0x2556d3+'`\x20again\x20without\x20--skip-auth.')),await _0x40e98b['KfesU'](sweepOrphansBestEffort,_0x2556d3),await markActive(_0x2556d3);return;}if(_0x4bc6c6['url']){const _0x1936b4=_0x4bc6c6[_0x20e68e(0xf9)],_0x52ea61=await _0x40e98b[_0x20e68e(0xdf)](checkUrlReachability,_0x1936b4);if(!_0x52ea61['ok']&&!_0x4bc6c6[_0x20e68e(0xc9)])throw new Error(_0x20e68e(0x101)+_0x1936b4+':\x20'+_0x52ea61[_0x20e68e(0xdd)]+'\x0aMake\x20sure\x20your\x20app\x20is\x20running,\x20then\x20try\x20again.\x20To\x20skip\x20this\x20check,\x20pass\x20--force.');!_0x52ea61['ok']&&_0x4bc6c6['force']&&console['log']('⚠\x20Could\x20not\x20reach\x20'+_0x1936b4+':\x20'+_0x52ea61['error']+'\x20(continuing\x20with\x20--force)');}else{console[_0x20e68e(0x104)](_0x40e98b['qmVmp']),console['log'](_0x20e68e(0x115)),console['log']('\x20\x20Ranger\x20will\x20use\x20it\x20to\x20look\x20up\x20the\x20right\x20cloud\x20auth\x20env\x20to\x20attach.\x0a');let _0x5cd91f='',_0x530d2f=![];while(!![]){const _0x55440d=await _0x471a2b[_0x20e68e(0xfc)]([{'type':_0x40e98b['kpOms'],'name':'baseUrl','message':_0x530d2f?'Enter\x20a\x20new\x20URL\x20(or\x20press\x20enter\x20to\x20keep\x20current):':_0x40e98b[_0x20e68e(0x12c)],'default':_0x40e98b['UYprH'](_0x5cd91f,_0x20e68e(0xf8))}]);_0x5cd91f=_0x55440d[_0x20e68e(0xfe)];const _0x3ec82a=await _0x40e98b[_0x20e68e(0xcb)](checkUrlReachability,_0x5cd91f);if(_0x3ec82a['ok'])break;const _0x2dce33=/^[a-zA-Z][\w+.-]*:\/\//['test'](_0x5cd91f),_0x2879c3=_0x3ec82a['isProtocolError']&&!_0x2dce33,_0xdf0723=_0x2879c3?'http://'+_0x5cd91f:null;_0x530d2f=!![],console[_0x20e68e(0x104)](_0x20e68e(0xd9)+_0x5cd91f+':\x20'+_0x3ec82a[_0x20e68e(0xdd)]);_0xdf0723&&console['log']('\x20\x20Did\x20you\x20mean\x20'+_0xdf0723+'?');const {action:_0x20705d}=await _0x471a2b[_0x20e68e(0xfc)]([{'type':_0x40e98b['VJoFr'],'name':_0x40e98b[_0x20e68e(0xdc)],'message':_0x40e98b['OEyQI'],'choices':[..._0xdf0723?[{'name':'Use\x20'+_0xdf0723,'value':_0x40e98b['mcteK']}]:[],{'name':_0x40e98b['eRMXm'],'value':_0x20e68e(0xe6)},{'name':_0x20e68e(0x102),'value':_0x20e68e(0xbe)}]}]);if(_0x20705d===_0x40e98b[_0x20e68e(0xee)]&&_0xdf0723){_0x5cd91f=_0xdf0723;const _0x1f7bfd=await checkUrlReachability(_0x5cd91f);if(_0x1f7bfd['ok'])break;console['log'](_0x20e68e(0xd7)+_0x5cd91f+':\x20'+_0x1f7bfd['error']);}else{if(_0x40e98b['aCfvJ'](_0x20705d,_0x40e98b['GTcPB']))break;}}_0x4bc6c6={..._0x4bc6c6,'url':_0x5cd91f};}let _0xe47456=![];try{_0xe47456=await _0x40e98b['DZBFl'](tryAutoRouteCloudProfile,_0x2556d3,_0x4bc6c6['url'],_0x4bc6c6,_0x2d39c1,_0x3e8684);}catch(_0x503bd6){console[_0x20e68e(0xdd)](_0x20e68e(0x105)+_0x2556d3+'\x22:\x20'+(_0x40e98b[_0x20e68e(0xe2)](_0x503bd6,Error)?_0x503bd6['message']:String(_0x503bd6))),process['exit'](0x1);}!_0xe47456&&process['exit'](0x1),await _0x40e98b['gRFzG'](markActive,_0x2556d3);}
@@ -1 +1 @@
1
- function _0x19cc(_0x27521d,_0xde8045){_0x27521d=_0x27521d-0x1af;var _0x25896f=_0x2589();var _0x19ccaf=_0x25896f[_0x27521d];return _0x19ccaf;}(function(_0x5ba5df,_0x41fef7){var _0x4d26d1=_0x19cc,_0x64066a=_0x5ba5df();while(!![]){try{var _0x35ce72=parseInt(_0x4d26d1(0x1b6))/0x1*(parseInt(_0x4d26d1(0x1b3))/0x2)+parseInt(_0x4d26d1(0x1ba))/0x3*(-parseInt(_0x4d26d1(0x1c0))/0x4)+parseInt(_0x4d26d1(0x1b7))/0x5+-parseInt(_0x4d26d1(0x1af))/0x6*(-parseInt(_0x4d26d1(0x1b1))/0x7)+parseInt(_0x4d26d1(0x1bb))/0x8+-parseInt(_0x4d26d1(0x1b9))/0x9+parseInt(_0x4d26d1(0x1bf))/0xa*(-parseInt(_0x4d26d1(0x1bc))/0xb);if(_0x35ce72===_0x41fef7)break;else _0x64066a['push'](_0x64066a['shift']());}catch(_0x430c6f){_0x64066a['push'](_0x64066a['shift']());}}}(_0x2589,0x2ae97));function _0x2589(){var _0x320193=['363027kOIJLO','\x20\x20ranger\x20profile\x20add\x20<name>\x0a','278ztuqjN','\x20\x20https://docs.ranger.net/main/concepts/profiles','gqidG','6HGsFax','1219115BXMElB','For\x20CI\x20/\x20background\x20agents\x20and\x20other\x20setup\x20options,\x20see:\x0a','442602qkfQeC','30cOaJVM','2323056IAmcsg','3575ozYYhD','tTfvt','To\x20set\x20up\x20a\x20fresh\x20profile,\x20run:\x0a','9410naHkcY','22452xbTcDR','6klCJLC','rcXma'];_0x2589=function(){return _0x320193;};return _0x2589();}export async function authEncrypt(_0x1184cc){var _0x4f7411=_0x19cc,_0x5b8f2d={'tRRWX':function(_0x2c0492,_0x9ccc9c){return _0x2c0492+_0x9ccc9c;},'LfBmS':function(_0x2f1b44,_0x583701){return _0x2f1b44+_0x583701;},'gqidG':function(_0xbf58e,_0x2aafbb){return _0xbf58e+_0x2aafbb;},'tTfvt':function(_0x39f18a,_0x2851d1){return _0x39f18a+_0x2851d1;},'rcXma':'session\x20state\x20for\x20you,\x20so\x20encrypted\x20on-disk\x20auth\x20is\x20unnecessary.\x0a'};console['error'](_0x5b8f2d['tRRWX'](_0x5b8f2d['LfBmS'](_0x5b8f2d[_0x4f7411(0x1b5)](_0x5b8f2d[_0x4f7411(0x1bd)]('ranger\x20profile\x20encrypt-auth\x20is\x20no\x20longer\x20supported.\x20Ranger\x20now\x20manages\x0a',_0x5b8f2d[_0x4f7411(0x1b0)])+'\x0a',_0x4f7411(0x1be))+_0x4f7411(0x1b2)+'\x0a',_0x4f7411(0x1b8)),_0x4f7411(0x1b4))),process['exit'](0x1);}
1
+ function _0x5654(_0x11bb5b,_0x2b6103){_0x11bb5b=_0x11bb5b-0x1d0;var _0xc0a3d9=_0xc0a3();var _0x565426=_0xc0a3d9[_0x11bb5b];return _0x565426;}(function(_0x65cede,_0x2d0f8f){var _0x1a263e=_0x5654,_0x1c9b26=_0x65cede();while(!![]){try{var _0x146e98=parseInt(_0x1a263e(0x1da))/0x1+parseInt(_0x1a263e(0x1d6))/0x2+parseInt(_0x1a263e(0x1d5))/0x3+parseInt(_0x1a263e(0x1dc))/0x4+-parseInt(_0x1a263e(0x1d2))/0x5+-parseInt(_0x1a263e(0x1d1))/0x6*(parseInt(_0x1a263e(0x1d8))/0x7)+-parseInt(_0x1a263e(0x1d7))/0x8;if(_0x146e98===_0x2d0f8f)break;else _0x1c9b26['push'](_0x1c9b26['shift']());}catch(_0x1a8fe5){_0x1c9b26['push'](_0x1c9b26['shift']());}}}(_0xc0a3,0xe8263));export async function authEncrypt(_0x557905){var _0x355aad=_0x5654,_0x450977={'gmdot':function(_0xcb278c,_0x4ecccc){return _0xcb278c+_0x4ecccc;},'nbGvE':'ranger\x20profile\x20encrypt-auth\x20is\x20no\x20longer\x20supported.\x20Ranger\x20now\x20manages\x0a','RRCpR':_0x355aad(0x1d4),'rKehA':'\x20\x20https://docs.ranger.net/main/concepts/profiles'};console[_0x355aad(0x1d0)](_0x450977['gmdot'](_0x450977['gmdot'](_0x450977[_0x355aad(0x1db)](_0x450977['nbGvE']+_0x355aad(0x1dd)+'\x0a',_0x450977[_0x355aad(0x1d3)]),_0x355aad(0x1d9))+'\x0a','For\x20CI\x20/\x20background\x20agents\x20and\x20other\x20setup\x20options,\x20see:\x0a')+_0x450977['rKehA']),process['exit'](0x1);}function _0xc0a3(){var _0x345cac=['gmdot','4354812AsVTFH','session\x20state\x20for\x20you,\x20so\x20encrypted\x20on-disk\x20auth\x20is\x20unnecessary.\x0a','error','1362NkDztV','6791660tBlggm','RRCpR','To\x20set\x20up\x20a\x20fresh\x20profile,\x20run:\x0a','3696858xeFhcx','2138812gmgXpq','10152584JUVzby','7882kkUMWl','\x20\x20ranger\x20profile\x20add\x20<name>\x0a','443495vAzlhI'];_0xc0a3=function(){return _0x345cac;};return _0xc0a3();}
@@ -1 +1 @@
1
- const _0x147f21=_0x34c9;(function(_0x5861a8,_0x3217b7){const _0x344920=_0x34c9,_0x39e487=_0x5861a8();while(!![]){try{const _0x56d5ee=-parseInt(_0x344920(0x1d6))/0x1*(parseInt(_0x344920(0x1c2))/0x2)+-parseInt(_0x344920(0x1ad))/0x3*(parseInt(_0x344920(0x1d5))/0x4)+-parseInt(_0x344920(0x1bc))/0x5*(-parseInt(_0x344920(0x1a5))/0x6)+parseInt(_0x344920(0x1cf))/0x7+parseInt(_0x344920(0x1da))/0x8*(parseInt(_0x344920(0x1c6))/0x9)+-parseInt(_0x344920(0x1ab))/0xa+-parseInt(_0x344920(0x1a7))/0xb*(-parseInt(_0x344920(0x1d7))/0xc);if(_0x56d5ee===_0x3217b7)break;else _0x39e487['push'](_0x39e487['shift']());}catch(_0x505116){_0x39e487['push'](_0x39e487['shift']());}}}(_0x4fb7,0xd06dc));import{rm,readFile,writeFile}from'fs/promises';import{join}from'path';function _0x34c9(_0x28c73d,_0x3f0f75){_0x28c73d=_0x28c73d-0x1a2;const _0x4fb7d8=_0x4fb7();let _0x34c9ef=_0x4fb7d8[_0x28c73d];return _0x34c9ef;}import{existsSync}from'fs';import{spawn}from'child_process';import{deleteAllCredentials}from'./utils/keychain.js';import{getProjectRoot,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=[_0x147f21(0x1cc),_0x147f21(0x1bf),'bug-bash',_0x147f21(0x1ba)],opencodePluginName='@ranger-testing/opencode-plugin';function parseJsonc(_0x26ee6a){const _0x16ec1f=_0x147f21,_0x47e685=_0x26ee6a[_0x16ec1f(0x1b6)](/\/\*[\s\S]*?\*\//g,''),_0x31dc51=_0x47e685['replace'](/^\s*\/\/.*$/gm,''),_0x722e5b=_0x31dc51['replace'](/,\s*([}\]])/g,'$1');return JSON[_0x16ec1f(0x1af)](_0x722e5b);}async function removeOpencodePluginConfig(_0x5a110c){const _0x1672c2=_0x147f21,_0x3fbc96={'bKHHd':function(_0x1beed2,_0x5d59b4){return _0x1beed2!==_0x5d59b4;},'aAidz':function(_0x468bf9,_0x53fefc){return _0x468bf9!==_0x53fefc;},'yCszN':function(_0x9a8fe,_0x5b2857,_0x65d948){return _0x9a8fe(_0x5b2857,_0x65d948);},'zFHLF':function(_0x301c69,_0x154a66){return _0x301c69===_0x154a66;},'iQBcW':function(_0x45fa49,_0x19784b){return _0x45fa49+_0x19784b;}};if(!existsSync(_0x5a110c))return![];let _0x3ab4a9;try{const _0x3c2148=await _0x3fbc96[_0x1672c2(0x1c3)](readFile,_0x5a110c,'utf-8');_0x3ab4a9=parseJsonc(_0x3c2148);}catch{return![];}const _0x4677c7=Array['isArray'](_0x3ab4a9['plugin'])?_0x3ab4a9['plugin']:[];if(_0x4677c7[_0x1672c2(0x1a9)]===0x0)return![];const _0x296899=_0x4677c7[_0x1672c2(0x1b0)](_0x3ca67f=>{const _0x43ccea=_0x1672c2;if(_0x3fbc96[_0x43ccea(0x1a6)](typeof _0x3ca67f,_0x43ccea(0x1b3)))return!![];return _0x3fbc96[_0x43ccea(0x1e0)](_0x3ca67f,opencodePluginName);});if(_0x296899[_0x1672c2(0x1a9)]===_0x4677c7[_0x1672c2(0x1a9)])return![];return _0x3fbc96[_0x1672c2(0x1ae)](_0x296899[_0x1672c2(0x1a9)],0x0)?delete _0x3ab4a9[_0x1672c2(0x1c1)]:_0x3ab4a9['plugin']=_0x296899,await _0x3fbc96[_0x1672c2(0x1c3)](writeFile,_0x5a110c,_0x3fbc96[_0x1672c2(0x1b7)](JSON['stringify'](_0x3ab4a9,null,0x2),'\x0a')),!![];}async function uninstallClaudePlugin(_0x32986c){const _0x390f23=_0x147f21,_0xc9aa01={'brqoz':'plugin','ImlcH':_0x390f23(0x1d8),'kieJE':_0x390f23(0x1d9),'LSwqE':_0x390f23(0x1b5),'BSBnt':function(_0x2cb8bb,_0x6ef478){return _0x2cb8bb===_0x6ef478;},'UIxfU':_0x390f23(0x1cd),'SWIzI':'close'};return new Promise(_0x55b96e=>{const _0x599d7d=_0x390f23,_0x28fb6a=[_0xc9aa01['brqoz'],_0xc9aa01[_0x599d7d(0x1c8)],'ranger@trailhead'];_0x32986c&&_0x28fb6a['push'](_0x599d7d(0x1b2),_0x32986c);const _0x5797de=spawn(_0xc9aa01['kieJE'],_0x28fb6a,{'stdio':['ignore',_0xc9aa01[_0x599d7d(0x1aa)],_0x599d7d(0x1b5)],'cwd':_0x32986c?getProjectRoot():undefined,'shell':_0xc9aa01[_0x599d7d(0x1e1)](process['platform'],_0xc9aa01[_0x599d7d(0x1c0)])});_0x5797de['on'](_0xc9aa01['SWIzI'],_0x16d89c=>{_0x55b96e(_0x16d89c===0x0);}),_0x5797de['on']('error',()=>{_0x55b96e(![]);});});}async function removeMarketplace(){const _0x489057=_0x147f21,_0x2be5b0={'JXrVx':'marketplace','Fdsrf':_0x489057(0x1d3),'woVfB':_0x489057(0x1a3),'vDTjx':_0x489057(0x1b5),'zBjnk':'win32','fcHMh':'close','gYPdV':_0x489057(0x1be)};return new Promise(_0x4a4882=>{const _0x389e56=_0x489057,_0x5ae101={'KKZHV':function(_0x1734a5,_0x149f7f){return _0x1734a5(_0x149f7f);},'PqQQB':function(_0x4f3647,_0x4334ff){return _0x4f3647===_0x4334ff;}},_0x28d262=spawn('claude',['plugin',_0x2be5b0['JXrVx'],_0x2be5b0['Fdsrf'],_0x2be5b0[_0x389e56(0x1c9)]],{'stdio':[_0x2be5b0[_0x389e56(0x1c4)],_0x389e56(0x1b5),_0x389e56(0x1b5)],'shell':process['platform']===_0x2be5b0[_0x389e56(0x1a4)]});_0x28d262['on'](_0x2be5b0['fcHMh'],_0x4eee47=>{const _0x26b104=_0x389e56;_0x5ae101[_0x26b104(0x1d4)](_0x4a4882,_0x5ae101['PqQQB'](_0x4eee47,0x0));}),_0x28d262['on'](_0x2be5b0[_0x389e56(0x1db)],()=>{_0x4a4882(![]);});});}function _0x4fb7(){const _0x4cc91a=['ImlcH','woVfB','✓\x20Removed\x20OpenCode\x20plugin\x20(user\x20config)','✓\x20Removed\x20OpenCode\x20plugin\x20(project\x20config)','ranger','win32','✓\x20Uninstalled\x20Claude\x20plugin\x20(user\x20scope)','7299089ACKSLe','user','pScqJ','opyPN','remove','KKZHV','2724360CCPDGg','149oPZiHm','1957992jHyjvp','uninstall','claude','40808UQftpp','gYPdV','log','✓\x20Removed\x20project\x20skill:\x20','✓\x20Removed\x20OpenCode\x20project\x20skill:\x20','✓\x20Removed\x20stored\x20credentials','aAidz','BSBnt','LQdic','trailhead','zBjnk','668292JhowdM','bKHHd','110BUpLJn','myuSy','length','LSwqE','4259050HshJTm','GzCBb','3NHenSg','zFHLF','parse','filter','✓\x20Removed\x20OpenCode\x20user\x20skill:\x20','--scope','string','YsZks','ignore','replace','iQBcW','✓\x20Removed\x20.ranger/\x20directory','yaVXL','e2e-test-recommender','Ltlrr','20lPCCES','✓\x20Uninstalled\x20Claude\x20plugin\x20(project\x20scope)','error','feature-tracker','UIxfU','plugin','18230VAchIN','yCszN','vDTjx','✓\x20Removed\x20user\x20skill:\x20','351vwPSOf','BZHJv'];_0x4fb7=function(){return _0x4cc91a;};return _0x4fb7();}export async function clean(){const _0x47c353=_0x147f21,_0x3d5d05={'GzCBb':function(_0x5e52d6,_0x1cf3fd){return _0x5e52d6(_0x1cf3fd);},'myuSy':function(_0x19fa36){return _0x19fa36();},'pScqJ':function(_0xf4a426,_0x62fbf,_0x14d67e){return _0xf4a426(_0x62fbf,_0x14d67e);},'mjAct':function(_0x2b12f8,_0x5e6730,_0x534387){return _0x2b12f8(_0x5e6730,_0x534387);},'fQnPP':function(_0x5211dd,_0x59bdbb){return _0x5211dd(_0x59bdbb);},'DrYrV':function(_0x95cf3,_0x5cc540){return _0x95cf3(_0x5cc540);},'yaVXL':_0x47c353(0x1d0),'LQdic':function(_0x8f90a1,_0x29147d,_0x22f14b){return _0x8f90a1(_0x29147d,_0x22f14b);},'BZHJv':function(_0x35e52f,_0x2a7240){return _0x35e52f(_0x2a7240);},'Ltlrr':'project','YsZks':'opencode.json','EUcoL':function(_0x4b6199,_0x5b25c0){return _0x4b6199(_0x5b25c0);},'Iqlmi':_0x47c353(0x1ce),'opyPN':'✓\x20Removed\x20trailhead\x20marketplace'};console[_0x47c353(0x1dc)]('\x0a🧹\x20Cleaning\x20up\x20Ranger\x20artifacts...\x0a');let _0x342b34=![];try{await deleteAllCredentials(),console['log'](_0x47c353(0x1df)),_0x342b34=!![];}catch{}const _0x4e4e44=getCacheFile();existsSync(_0x4e4e44)&&(await _0x3d5d05[_0x47c353(0x1ac)](rm,_0x4e4e44),_0x342b34=!![]);const _0xb24aea=_0x3d5d05[_0x47c353(0x1a8)](getRangerDir);existsSync(_0xb24aea)&&(await rm(_0xb24aea,{'recursive':!![]}),console['log'](_0x47c353(0x1b8)),_0x342b34=!![]);const _0x3b9ad4=getProjectSkillsDir();for(const _0x590e67 of skillsToRemove){const _0x5a2ca3=join(_0x3b9ad4,_0x590e67);existsSync(_0x5a2ca3)&&(await _0x3d5d05[_0x47c353(0x1d1)](rm,_0x5a2ca3,{'recursive':!![]}),console['log'](_0x47c353(0x1dd)+_0x590e67),_0x342b34=!![]);}const _0x3598c8=_0x3d5d05[_0x47c353(0x1a8)](getUserSkillsDir);for(const _0x1fe297 of skillsToRemove){const _0x491541=_0x3d5d05['mjAct'](join,_0x3598c8,_0x1fe297);_0x3d5d05['fQnPP'](existsSync,_0x491541)&&(await rm(_0x491541,{'recursive':!![]}),console[_0x47c353(0x1dc)](_0x47c353(0x1c5)+_0x1fe297),_0x342b34=!![]);}const _0x588370=getOpencodeSkillsDir('project');for(const _0x2e3a83 of skillsToRemove){const _0x1e9c3f=_0x3d5d05[_0x47c353(0x1d1)](join,_0x588370,_0x2e3a83);_0x3d5d05['DrYrV'](existsSync,_0x1e9c3f)&&(await rm(_0x1e9c3f,{'recursive':!![]}),console['log'](_0x47c353(0x1de)+_0x2e3a83),_0x342b34=!![]);}const _0x400857=_0x3d5d05['DrYrV'](getOpencodeSkillsDir,_0x3d5d05[_0x47c353(0x1b9)]);for(const _0x945c94 of skillsToRemove){const _0x189011=_0x3d5d05[_0x47c353(0x1d1)](join,_0x400857,_0x945c94);_0x3d5d05[_0x47c353(0x1ac)](existsSync,_0x189011)&&(await _0x3d5d05[_0x47c353(0x1a2)](rm,_0x189011,{'recursive':!![]}),console['log'](_0x47c353(0x1b1)+_0x945c94),_0x342b34=!![]);}const _0x4e76e7=_0x3d5d05[_0x47c353(0x1a2)](join,_0x3d5d05[_0x47c353(0x1c7)](getOpencodeConfigDir,_0x3d5d05[_0x47c353(0x1bb)]),_0x3d5d05[_0x47c353(0x1b4)]);await removeOpencodePluginConfig(_0x4e76e7)&&(console['log'](_0x47c353(0x1cb)),_0x342b34=!![]);const _0x1f51cd=join(_0x3d5d05['EUcoL'](getOpencodeConfigDir,_0x3d5d05['yaVXL']),_0x3d5d05['YsZks']);await removeOpencodePluginConfig(_0x1f51cd)&&(console[_0x47c353(0x1dc)](_0x47c353(0x1ca)),_0x342b34=!![]);const _0x529ddf=await uninstallClaudePlugin();_0x529ddf&&(console[_0x47c353(0x1dc)](_0x3d5d05['Iqlmi']),_0x342b34=!![]);const _0x58f14f=await _0x3d5d05['EUcoL'](uninstallClaudePlugin,_0x3d5d05[_0x47c353(0x1bb)]);_0x58f14f&&(console[_0x47c353(0x1dc)](_0x47c353(0x1bd)),_0x342b34=!![]);const _0x229738=await _0x3d5d05['myuSy'](removeMarketplace);_0x229738&&(console[_0x47c353(0x1dc)](_0x3d5d05[_0x47c353(0x1d2)]),_0x342b34=!![]),_0x342b34?console[_0x47c353(0x1dc)]('\x0a✅\x20Cleanup\x20complete!\x0a'):console['log']('Nothing\x20to\x20clean\x20up.\x0a');}
1
+ const _0x280190=_0x5757;(function(_0x581b8e,_0x10e079){const _0x419052=_0x5757,_0x40c930=_0x581b8e();while(!![]){try{const _0x29fe4f=parseInt(_0x419052(0x86))/0x1*(-parseInt(_0x419052(0x9a))/0x2)+-parseInt(_0x419052(0xa1))/0x3+-parseInt(_0x419052(0x9e))/0x4+parseInt(_0x419052(0x92))/0x5*(-parseInt(_0x419052(0xb5))/0x6)+parseInt(_0x419052(0x89))/0x7+-parseInt(_0x419052(0xb9))/0x8+parseInt(_0x419052(0xa0))/0x9*(parseInt(_0x419052(0x95))/0xa);if(_0x29fe4f===_0x10e079)break;else _0x40c930['push'](_0x40c930['shift']());}catch(_0x33b467){_0x40c930['push'](_0x40c930['shift']());}}}(_0x5ad3,0xebdd7));import{rm,readFile,writeFile}from'fs/promises';function _0x5ad3(){const _0x2fb3ad=['5771283OqWQaJ','close','✓\x20Removed\x20OpenCode\x20plugin\x20(project\x20config)','stringify','LxnUE','ohltW','RbPWI','TUPhP','uninstall','298585YxNnYN','sLfOr','marketplace','20aTkqrA','MaaZP','ignore','win32','✓\x20Removed\x20OpenCode\x20project\x20skill:\x20','12dcAwfM','ERAJU','bvJkL','replace','2849780QpjgRi','plugin','20605797HHkFkL','318771JBnScI','string','moqSP','zsEwv','log','error','✓\x20Removed\x20OpenCode\x20plugin\x20(user\x20config)','feature-tracker','length','parse','platform','bug-bash','vSBXR','wBuRb','utf-8','✓\x20Removed\x20user\x20skill:\x20','zJgXV','IZhMb','✓\x20Removed\x20trailhead\x20marketplace','PwFhK','138eKKDhn','project','uiOaZ','iRyJB','7478136DlZvsB','xAJsm','Mbplq','filter','218412GjxhXm','e2e-test-recommender','oCUcA'];_0x5ad3=function(){return _0x2fb3ad;};return _0x5ad3();}import{join}from'path';function _0x5757(_0x330f3e,_0x6045b6){_0x330f3e=_0x330f3e-0x85;const _0x5ad326=_0x5ad3();let _0x5757e7=_0x5ad326[_0x330f3e];return _0x5757e7;}import{existsSync}from'fs';import{spawn}from'child_process';import{deleteAllCredentials}from'./utils/keychain.js';import{getProjectRoot,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',_0x280190(0xa8),_0x280190(0xac),_0x280190(0x87)],opencodePluginName='@ranger-testing/opencode-plugin';function parseJsonc(_0x3729ad){const _0x171f8c=_0x280190,_0x52ca4b=_0x3729ad['replace'](/\/\*[\s\S]*?\*\//g,''),_0xacefa2=_0x52ca4b[_0x171f8c(0x9d)](/^\s*\/\/.*$/gm,''),_0x417ce0=_0xacefa2[_0x171f8c(0x9d)](/,\s*([}\]])/g,'$1');return JSON[_0x171f8c(0xaa)](_0x417ce0);}async function removeOpencodePluginConfig(_0x44e521){const _0x4650c9=_0x280190,_0x3da22f={'hBTOq':function(_0x16539f,_0x1f5bac){return _0x16539f===_0x1f5bac;},'aFMhx':function(_0x531854,_0x49faf3,_0x232b30){return _0x531854(_0x49faf3,_0x232b30);},'qZAQV':function(_0x7d0dcd,_0x43e773){return _0x7d0dcd+_0x43e773;}};if(!existsSync(_0x44e521))return![];let _0x1f20af;try{const _0x1a9cab=await readFile(_0x44e521,_0x4650c9(0xaf));_0x1f20af=parseJsonc(_0x1a9cab);}catch{return![];}const _0x496d1a=Array['isArray'](_0x1f20af[_0x4650c9(0x9f)])?_0x1f20af['plugin']:[];if(_0x496d1a['length']===0x0)return![];const _0x12c1fc=_0x496d1a[_0x4650c9(0x85)](_0x24a737=>{const _0x47af74=_0x4650c9;if(typeof _0x24a737!==_0x47af74(0xa2))return!![];return _0x24a737!==opencodePluginName;});if(_0x3da22f['hBTOq'](_0x12c1fc[_0x4650c9(0xa9)],_0x496d1a[_0x4650c9(0xa9)]))return![];return _0x3da22f['hBTOq'](_0x12c1fc[_0x4650c9(0xa9)],0x0)?delete _0x1f20af[_0x4650c9(0x9f)]:_0x1f20af[_0x4650c9(0x9f)]=_0x12c1fc,await _0x3da22f['aFMhx'](writeFile,_0x44e521,_0x3da22f['qZAQV'](JSON[_0x4650c9(0x8c)](_0x1f20af,null,0x2),'\x0a')),!![];}async function uninstallClaudePlugin(_0x472b6c){const _0x352e48=_0x280190,_0x1e2ab6={'IZhMb':function(_0x3d4f03,_0x24efec){return _0x3d4f03(_0x24efec);},'RiesY':function(_0x52401e,_0x151b4c){return _0x52401e===_0x151b4c;},'ieYwI':'ranger@trailhead','zsEwv':function(_0x5d1805,_0x2634b1,_0x1a0cbf,_0x5181e6){return _0x5d1805(_0x2634b1,_0x1a0cbf,_0x5181e6);},'vSBXR':'claude','sLfOr':_0x352e48(0x97),'bFgYn':function(_0x1086f2,_0x354695){return _0x1086f2===_0x354695;},'xdunw':_0x352e48(0x8a)};return new Promise(_0x3b7c60=>{const _0x4d383e=_0x352e48,_0x262aa5={'TUPhP':function(_0x1f7a69,_0x1628c5){return _0x1f7a69(_0x1628c5);}},_0x2d5347=['plugin',_0x4d383e(0x91),_0x1e2ab6['ieYwI']];_0x472b6c&&_0x2d5347['push']('--scope',_0x472b6c);const _0x1d6c69=_0x1e2ab6[_0x4d383e(0xa4)](spawn,_0x1e2ab6[_0x4d383e(0xad)],_0x2d5347,{'stdio':[_0x1e2ab6[_0x4d383e(0x93)],'ignore','ignore'],'cwd':_0x472b6c?getProjectRoot():undefined,'shell':_0x1e2ab6['bFgYn'](process[_0x4d383e(0xab)],_0x4d383e(0x98))});_0x1d6c69['on'](_0x1e2ab6['xdunw'],_0x75330e=>{const _0x1b87cc=_0x4d383e;_0x1e2ab6[_0x1b87cc(0xb2)](_0x3b7c60,_0x1e2ab6['RiesY'](_0x75330e,0x0));}),_0x1d6c69['on'](_0x4d383e(0xa6),()=>{const _0x52aadf=_0x4d383e;_0x262aa5[_0x52aadf(0x90)](_0x3b7c60,![]);});});}async function removeMarketplace(){const _0x454aaf=_0x280190,_0x1630d4={'fSQmm':function(_0x5b3601,_0xc1f432){return _0x5b3601===_0xc1f432;},'zJgXV':function(_0x3c1372,_0x8fc1ae,_0x63bf80,_0x8f507d){return _0x3c1372(_0x8fc1ae,_0x63bf80,_0x8f507d);},'RbPWI':'trailhead','PwFhK':_0x454aaf(0x97),'iRyJB':function(_0x49ddb5,_0x5c8020){return _0x49ddb5===_0x5c8020;},'UazUa':'win32','LxnUE':_0x454aaf(0x8a),'ohltW':_0x454aaf(0xa6)};return new Promise(_0x3b4450=>{const _0x396976=_0x454aaf,_0x30362d={'xAJsm':function(_0x30d974,_0x47bb14){return _0x30d974(_0x47bb14);}},_0x4e186a=_0x1630d4[_0x396976(0xb1)](spawn,'claude',['plugin',_0x396976(0x94),'remove',_0x1630d4[_0x396976(0x8f)]],{'stdio':[_0x1630d4[_0x396976(0xb4)],_0x396976(0x97),'ignore'],'shell':_0x1630d4[_0x396976(0xb8)](process[_0x396976(0xab)],_0x1630d4['UazUa'])});_0x4e186a['on'](_0x1630d4[_0x396976(0x8d)],_0x1f18e9=>{_0x3b4450(_0x1630d4['fSQmm'](_0x1f18e9,0x0));}),_0x4e186a['on'](_0x1630d4[_0x396976(0x8e)],()=>{const _0x13c524=_0x396976;_0x30362d[_0x13c524(0xba)](_0x3b4450,![]);});});}export async function clean(){const _0x26a193=_0x280190,_0x25be88={'oCUcA':function(_0x406b11){return _0x406b11();},'wBuRb':function(_0x3cd090,_0x159cec){return _0x3cd090(_0x159cec);},'MaaZP':function(_0x5efc71,_0xae3f77,_0x3b4e89){return _0x5efc71(_0xae3f77,_0x3b4e89);},'uiOaZ':function(_0xcf5182,_0x2c8284,_0x49a094){return _0xcf5182(_0x2c8284,_0x49a094);},'TwtaV':function(_0x5b3805,_0x1d487d){return _0x5b3805(_0x1d487d);},'EUgDB':function(_0xbb31c,_0x442233,_0x1b9ba3){return _0xbb31c(_0x442233,_0x1b9ba3);},'moqSP':function(_0x5506c1,_0x241330,_0x59bea8){return _0x5506c1(_0x241330,_0x59bea8);},'ERAJU':_0x26a193(0xb6),'QgieX':'opencode.json','DMnTI':'user','bvJkL':function(_0x34477c){return _0x34477c();},'BuaWv':_0x26a193(0xb3),'Mbplq':'\x0a✅\x20Cleanup\x20complete!\x0a'};console['log']('\x0a🧹\x20Cleaning\x20up\x20Ranger\x20artifacts...\x0a');let _0x1ef358=![];try{await _0x25be88['oCUcA'](deleteAllCredentials),console['log']('✓\x20Removed\x20stored\x20credentials'),_0x1ef358=!![];}catch{}const _0x2010fe=_0x25be88[_0x26a193(0x88)](getCacheFile);_0x25be88[_0x26a193(0xae)](existsSync,_0x2010fe)&&(await _0x25be88[_0x26a193(0xae)](rm,_0x2010fe),_0x1ef358=!![]);const _0x3beb86=getRangerDir();existsSync(_0x3beb86)&&(await rm(_0x3beb86,{'recursive':!![]}),console[_0x26a193(0xa5)]('✓\x20Removed\x20.ranger/\x20directory'),_0x1ef358=!![]);const _0x242988=getProjectSkillsDir();for(const _0x29c76a of skillsToRemove){const _0x1ff3a5=_0x25be88['MaaZP'](join,_0x242988,_0x29c76a);existsSync(_0x1ff3a5)&&(await rm(_0x1ff3a5,{'recursive':!![]}),console[_0x26a193(0xa5)]('✓\x20Removed\x20project\x20skill:\x20'+_0x29c76a),_0x1ef358=!![]);}const _0x1b6469=getUserSkillsDir();for(const _0x3b9906 of skillsToRemove){const _0x2013fa=_0x25be88[_0x26a193(0x96)](join,_0x1b6469,_0x3b9906);_0x25be88['wBuRb'](existsSync,_0x2013fa)&&(await _0x25be88[_0x26a193(0x96)](rm,_0x2013fa,{'recursive':!![]}),console[_0x26a193(0xa5)](_0x26a193(0xb0)+_0x3b9906),_0x1ef358=!![]);}const _0x2faeee=getOpencodeSkillsDir(_0x26a193(0xb6));for(const _0x399527 of skillsToRemove){const _0x4c724c=_0x25be88[_0x26a193(0x96)](join,_0x2faeee,_0x399527);existsSync(_0x4c724c)&&(await _0x25be88['MaaZP'](rm,_0x4c724c,{'recursive':!![]}),console[_0x26a193(0xa5)](_0x26a193(0x99)+_0x399527),_0x1ef358=!![]);}const _0x23a413=getOpencodeSkillsDir('user');for(const _0x40d69f of skillsToRemove){const _0x2d9549=_0x25be88[_0x26a193(0xb7)](join,_0x23a413,_0x40d69f);_0x25be88['TwtaV'](existsSync,_0x2d9549)&&(await _0x25be88['EUgDB'](rm,_0x2d9549,{'recursive':!![]}),console[_0x26a193(0xa5)]('✓\x20Removed\x20OpenCode\x20user\x20skill:\x20'+_0x40d69f),_0x1ef358=!![]);}const _0x1b865d=_0x25be88['moqSP'](join,getOpencodeConfigDir(_0x25be88[_0x26a193(0x9b)]),_0x25be88['QgieX']);await removeOpencodePluginConfig(_0x1b865d)&&(console['log'](_0x26a193(0x8b)),_0x1ef358=!![]);const _0x270898=_0x25be88[_0x26a193(0xa3)](join,getOpencodeConfigDir(_0x25be88['DMnTI']),'opencode.json');await removeOpencodePluginConfig(_0x270898)&&(console['log'](_0x26a193(0xa7)),_0x1ef358=!![]);const _0x4f0ffb=await _0x25be88['oCUcA'](uninstallClaudePlugin);_0x4f0ffb&&(console['log']('✓\x20Uninstalled\x20Claude\x20plugin\x20(user\x20scope)'),_0x1ef358=!![]);const _0x5d0394=await _0x25be88['wBuRb'](uninstallClaudePlugin,'project');_0x5d0394&&(console['log']('✓\x20Uninstalled\x20Claude\x20plugin\x20(project\x20scope)'),_0x1ef358=!![]);const _0x27c895=await _0x25be88[_0x26a193(0x9c)](removeMarketplace);_0x27c895&&(console['log'](_0x25be88['BuaWv']),_0x1ef358=!![]),_0x1ef358?console['log'](_0x25be88[_0x26a193(0xbb)]):console['log']('Nothing\x20to\x20clean\x20up.\x0a');}
@@ -1 +1 @@
1
- (function(_0x530202,_0x1a8cc2){const _0x1f1b7d=_0x3264,_0x42054c=_0x530202();while(!![]){try{const _0x282e67=-parseInt(_0x1f1b7d(0x208))/0x1+-parseInt(_0x1f1b7d(0x1fb))/0x2*(-parseInt(_0x1f1b7d(0x1f4))/0x3)+-parseInt(_0x1f1b7d(0x1ec))/0x4+-parseInt(_0x1f1b7d(0x1f2))/0x5+-parseInt(_0x1f1b7d(0x1ea))/0x6*(-parseInt(_0x1f1b7d(0x1fa))/0x7)+parseInt(_0x1f1b7d(0x1d8))/0x8*(-parseInt(_0x1f1b7d(0x1f5))/0x9)+parseInt(_0x1f1b7d(0x1db))/0xa;if(_0x282e67===_0x1a8cc2)break;else _0x42054c['push'](_0x42054c['shift']());}catch(_0x5a2b65){_0x42054c['push'](_0x42054c['shift']());}}}(_0x334c,0xbe5fe));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 _0x3264(_0x55a355,_0x12a98d){_0x55a355=_0x55a355-0x1d7;const _0x334cc2=_0x334c();let _0x326424=_0x334cc2[_0x55a355];return _0x326424;}const BOOLEAN_KEYS=['headless','allowInsecureLocalhost','forceLogin'];function parseLocalValue(_0x48fd2c,_0x22c992){const _0x19f5fa=_0x3264;if(BOOLEAN_KEYS[_0x19f5fa(0x1e3)](_0x48fd2c)){if(_0x22c992==='true')return!![];if(_0x22c992===_0x19f5fa(0x1e5))return![];throw new Error('Invalid\x20value\x20for\x20'+_0x48fd2c+':\x20expected\x20\x22true\x22\x20or\x20\x22false\x22');}return _0x22c992;}function parseOverrideValue(_0x3d1fbb){const _0x348e94=_0x3264,_0x67bfa0={'LlucI':'true','rnBUO':function(_0x93ab4e,_0x25d033){return _0x93ab4e===_0x25d033;},'fNLeq':function(_0x31fe6f,_0x46d7c1){return _0x31fe6f===_0x46d7c1;},'SWCGR':'null','bejpG':function(_0x43fd9f,_0x1b70a8){return _0x43fd9f===_0x1b70a8;},'cvkqY':function(_0x46c051,_0x341361){return _0x46c051(_0x341361);},'JkFOW':function(_0x2a024d,_0x52adad){return _0x2a024d(_0x52adad);}};if(_0x3d1fbb===_0x67bfa0[_0x348e94(0x203)])return!![];if(_0x67bfa0['rnBUO'](_0x3d1fbb,'false'))return![];if(_0x67bfa0['fNLeq'](_0x3d1fbb,_0x67bfa0[_0x348e94(0x1df)]))return null;if(_0x67bfa0['bejpG'](_0x3d1fbb,_0x348e94(0x1fe)))return undefined;if(/^-?\d+$/[_0x348e94(0x1e7)](_0x3d1fbb)){const _0x109554=_0x67bfa0['cvkqY'](Number,_0x3d1fbb);if(Number['isSafeInteger'](_0x109554))return _0x109554;}if(/^-?\d+\.\d+$/[_0x348e94(0x1e7)](_0x3d1fbb)){const _0x21962a=_0x67bfa0['JkFOW'](Number,_0x3d1fbb);if(!Number[_0x348e94(0x1e0)](_0x21962a))return _0x21962a;}const _0xc9d79c=_0x3d1fbb['trim']();if(_0xc9d79c['startsWith']('{')&&_0xc9d79c[_0x348e94(0x1da)]('}')||_0xc9d79c['startsWith']('[')&&_0xc9d79c['endsWith'](']'))try{return JSON[_0x348e94(0x1ed)](_0xc9d79c);}catch{}return _0x3d1fbb;}function _0x334c(){const _0x12edf3=['4796908sAKtNL','parse','(not\x20set)','\x22\x20also\x20exists\x20as\x20a\x20local\x20profile;\x20editing\x20the\x20cloud\x20profile.','RFPYe','\x20=\x20','3119415KwKtoW','utaQe','1599YpAXqs','9lZzlXt','eBZyt','hTyOD','Removed\x20','oeCLs','1043PkUJLz','4714PPKlcO','Set\x20','alsoExistsElsewhere','undefined','jttgQ','pcbPq','NBYoX','\x20<key>\x22\x20to\x20remove\x20individual\x20values.','LlucI','yzgeZ','Profile\x20\x22','yhbYK','\x20\x20Note:\x20\x22','45071eVnISE','log','Wuycg','1072696XYNTyF','stringify','endsWith','15068380zlZygv','\x20for\x20\x22','KOGUV','Key\x20\x22','SWCGR','isNaN','cloud','qjXMA','includes','CNwmj','false','No\x20configuration\x20set\x20for\x20\x22','test','\x22\x20and\x20cannot\x20be\x20unset;\x20the\x20legacy\x20tree\x20is\x20read-only\x20under\x20cloud\x20profiles.','settings','762JWNOcL','kind'];_0x334c=function(){return _0x12edf3;};return _0x334c();}async function resolveProfileTarget(_0x5ae394){const _0xa45446=_0x3264,_0x98362f={'yzgeZ':function(_0x3711fa,_0x33720f){return _0x3711fa(_0x33720f);},'oeCLs':'local'},_0x3436fd=existsSync(_0x98362f[_0xa45446(0x204)](getEnvDir,_0x5ae394));let _0x1944ae=![];try{const _0xc1d96c=await fetchCloudProfile(_0x5ae394);_0x1944ae=Boolean(_0xc1d96c);}catch{}if(_0x1944ae)return{'kind':_0xa45446(0x1e1),'alsoExistsElsewhere':_0x3436fd};if(_0x3436fd)return{'kind':_0x98362f[_0xa45446(0x1f9)],'alsoExistsElsewhere':![]};throw new Error(_0xa45446(0x205)+_0x5ae394+'\x22\x20does\x20not\x20exist.\x20Run:\x20ranger\x20profile\x20add\x20'+_0x5ae394);}function printDualExistsHint(_0x31faf8){const _0x45d6c7=_0x3264;console[_0x45d6c7(0x209)](_0x45d6c7(0x207)+_0x31faf8+_0x45d6c7(0x1ef));}function getProjectPath(){return process['cwd']();}async function loadEffectiveCloudSettings(_0x2833aa){const _0x15c3d8=_0x3264,_0x44ff5f={'eBZyt':function(_0x1959a4,_0x52ff2e){return _0x1959a4(_0x52ff2e);}},_0x4b2185=await _0x44ff5f[_0x15c3d8(0x1f6)](fetchCloudProfile,_0x2833aa),_0x2fb952=readProfileOverrides(getProjectPath(),_0x2833aa);return mergeCloudProfileSettings(_0x4b2185?.[_0x15c3d8(0x1e9)]??{},_0x2fb952??undefined);}export async function configSet(_0x3817db,_0x4d8428,_0xf69608){const _0x2c2cef=_0x3264,_0x1ec5f6={'Emnzf':'cloud','qjXMA':function(_0x2746b8,_0x5002e1){return _0x2746b8(_0x5002e1);},'ZyorC':function(_0x2e0707,_0x185a46){return _0x2e0707(_0x185a46);},'EjbTq':function(_0x3d9928){return _0x3d9928();},'GvMrd':function(_0x112fba,_0x2c1a8f,_0x4307ba){return _0x112fba(_0x2c1a8f,_0x4307ba);}},_0x54d937=await resolveProfileTarget(_0x3817db);if(_0x54d937[_0x2c2cef(0x1eb)]===_0x1ec5f6['Emnzf']){if(_0x54d937[_0x2c2cef(0x1fd)])_0x1ec5f6[_0x2c2cef(0x1e2)](printDualExistsHint,_0x3817db);const _0x1bf516=_0x1ec5f6['ZyorC'](parseOverrideValue,_0xf69608);setProfileOverride(_0x1ec5f6['EjbTq'](getProjectPath),_0x3817db,_0x4d8428,_0x1bf516),console['log'](_0x2c2cef(0x1fc)+_0x4d8428+'\x20=\x20'+JSON[_0x2c2cef(0x1d9)](_0x1bf516)+'\x20for\x20\x22'+_0x3817db+'\x22');return;}const _0x134dbc=_0x1ec5f6['GvMrd'](parseLocalValue,_0x4d8428,_0xf69608);setProfileOverride(getProjectPath(),_0x3817db,_0x4d8428,_0x134dbc),console['log'](_0x2c2cef(0x1fc)+_0x4d8428+_0x2c2cef(0x1f1)+_0x134dbc+_0x2c2cef(0x1dc)+_0x3817db+'\x22');}export async function configGet(_0x422303,_0x50a21f){const _0x9f3ebf=_0x3264,_0x40f527={'jttgQ':function(_0x1ac420,_0x12a42f){return _0x1ac420(_0x12a42f);},'pcbPq':function(_0x3a2218,_0x585fcd){return _0x3a2218===_0x585fcd;},'hTyOD':function(_0xd35572,_0x564638,_0x5e15b0){return _0xd35572(_0x564638,_0x5e15b0);},'oYwMp':'object','dBrPM':function(_0x238f07,_0x4b2c8f){return _0x238f07(_0x4b2c8f);}},_0x32a812=await _0x40f527[_0x9f3ebf(0x1ff)](resolveProfileTarget,_0x422303);if(_0x40f527[_0x9f3ebf(0x200)](_0x32a812[_0x9f3ebf(0x1eb)],_0x9f3ebf(0x1e1))){const _0x5f3da3=await loadEffectiveCloudSettings(_0x422303),_0x34bb3b=_0x40f527[_0x9f3ebf(0x1f7)](getNestedValue,_0x5f3da3,_0x50a21f);if(_0x40f527['pcbPq'](_0x34bb3b,undefined))console['log']('(not\x20set)');else typeof _0x34bb3b===_0x40f527['oYwMp']?console[_0x9f3ebf(0x209)](JSON['stringify'](_0x34bb3b,null,0x2)):console['log'](_0x34bb3b);return;}const _0x449a5a=await _0x40f527['dBrPM'](loadSettings,_0x422303),_0xe05a17=_0x40f527[_0x9f3ebf(0x1f7)](getNestedValue,_0x449a5a,_0x50a21f);if(_0x40f527['pcbPq'](_0xe05a17,undefined))console[_0x9f3ebf(0x209)](_0x9f3ebf(0x1ee));else typeof _0xe05a17===_0x40f527['oYwMp']?console['log'](JSON['stringify'](_0xe05a17,null,0x2)):console['log'](_0xe05a17);}export async function configList(_0x2a5bc5){const _0x44f747=_0x3264,_0x1dcf43={'NBYoX':function(_0x41ffc4,_0x3db74f){return _0x41ffc4===_0x3db74f;},'QqPum':_0x44f747(0x1e1),'RFPYe':function(_0x3cffd9,_0x17633a){return _0x3cffd9(_0x17633a);},'gcluY':function(_0x13fe3f,_0x2dbf85){return _0x13fe3f(_0x2dbf85);},'utaQe':function(_0x4b3edf,_0x8dee85){return _0x4b3edf(_0x8dee85);},'xYDXS':function(_0x1bddd4,_0x1dbc43){return _0x1bddd4(_0x1dbc43);}},_0x30ca07=await resolveProfileTarget(_0x2a5bc5);if(_0x1dcf43[_0x44f747(0x201)](_0x30ca07['kind'],_0x1dcf43['QqPum'])){const _0x4191e9=await _0x1dcf43[_0x44f747(0x1f0)](loadEffectiveCloudSettings,_0x2a5bc5);if(!_0x4191e9||Object['keys'](_0x4191e9)['length']===0x0){console['log'](_0x44f747(0x1e6)+_0x2a5bc5+'\x22');return;}console['log'](JSON[_0x44f747(0x1d9)](_0x4191e9,null,0x2));return;}const _0x365b8b=getSettingsPath(_0x2a5bc5);if(!_0x1dcf43['gcluY'](existsSync,_0x365b8b)){console[_0x44f747(0x209)](_0x44f747(0x1e6)+_0x2a5bc5+'\x22');return;}const _0x20487a=await _0x1dcf43[_0x44f747(0x1f3)](loadSettings,_0x2a5bc5),_0x2a2f38=_0x1dcf43['xYDXS'](formatSettings,_0x20487a);!_0x2a2f38?console[_0x44f747(0x209)]('No\x20configuration\x20set\x20for\x20\x22'+_0x2a5bc5+'\x22'):console['log'](_0x2a2f38);}export async function configUnset(_0x328707,_0x541657){const _0x3567fb=_0x3264,_0x1822fc={'Wuycg':function(_0x2fb091,_0x16691e){return _0x2fb091===_0x16691e;},'KipLf':function(_0x2cdcc8,_0x15f198){return _0x2cdcc8(_0x15f198);},'yhbYK':function(_0x425def,_0x5364ad,_0x520a1f,_0x3afbdf){return _0x425def(_0x5364ad,_0x520a1f,_0x3afbdf);},'CNwmj':function(_0x36fbb3){return _0x36fbb3();},'KOGUV':function(_0x785f6a,_0x13fa87){return _0x785f6a(_0x13fa87);}},_0x1cd5b3=await resolveProfileTarget(_0x328707);if(_0x1822fc[_0x3567fb(0x1d7)](_0x1cd5b3[_0x3567fb(0x1eb)],_0x3567fb(0x1e1))){if(_0x1cd5b3['alsoExistsElsewhere'])_0x1822fc['KipLf'](printDualExistsHint,_0x328707);const _0x438db7=unsetProfileOverride(getProjectPath(),_0x328707,_0x541657);_0x438db7?console['log'](_0x3567fb(0x1f8)+_0x541657+_0x3567fb(0x1dc)+_0x328707+'\x22'):console['log'](_0x3567fb(0x1de)+_0x541657+'\x22\x20not\x20found');return;}const _0x1507de=_0x1822fc[_0x3567fb(0x206)](unsetProfileOverride,_0x1822fc[_0x3567fb(0x1e4)](getProjectPath),_0x328707,_0x541657);if(_0x1507de){console[_0x3567fb(0x209)]('Removed\x20'+_0x541657);return;}const _0x42c6ad=await _0x1822fc[_0x3567fb(0x1dd)](loadSettings,_0x328707),_0xe66cd3=deleteNestedValue(_0x42c6ad,_0x541657);_0xe66cd3?console[_0x3567fb(0x209)](_0x3567fb(0x1de)+_0x541657+'\x22\x20lives\x20in\x20the\x20legacy\x20settings\x20file\x20for\x20\x22'+_0x328707+_0x3567fb(0x1e8)):console[_0x3567fb(0x209)]('Key\x20\x22'+_0x541657+'\x22\x20not\x20found');}export async function configReset(_0x523dc6){const _0x3bc41a=_0x3264,_0x4c9aea=await resolveProfileTarget(_0x523dc6);if(_0x4c9aea[_0x3bc41a(0x1eb)]==='cloud'){resetProfileOverrides(getProjectPath(),_0x523dc6),console[_0x3bc41a(0x209)]('Cleared\x20local\x20overrides\x20for\x20\x22'+_0x523dc6+'\x22');return;}console[_0x3bc41a(0x209)]('\x22'+_0x523dc6+'\x22\x20is\x20a\x20local\x20profile.\x20Use\x20\x22ranger\x20profile\x20config\x20unset\x20'+_0x523dc6+_0x3bc41a(0x202));}
1
+ function _0x16fa(){const _0x5a3741=['undefined','Key\x20\x22','obtCV','uDMYz','\x20=\x20','SGMfK',':\x20expected\x20\x22true\x22\x20or\x20\x22false\x22','endsWith','(not\x20set)','7304990pWbwsH','\x20<key>\x22\x20to\x20remove\x20individual\x20values.','9FrqdWY','isNaN','LKCYd','forceLogin','Removed\x20','\x20\x20Note:\x20\x22','log','bYeAR','mjqtv','keys','local','TPZCy','true','uRfSf','parse','Invalid\x20value\x20for\x20','7cMXesr','ooTSl','headless','PQciP','510590KkDVxM','pEOUd','18ezLJvt','jnUcY','5018804vlqcoV','8128648XffnLx','Set\x20','MjFse','kind','cloud','\x20for\x20\x22','uWpzV','PAyJC','stringify','rThbR','\x22\x20lives\x20in\x20the\x20legacy\x20settings\x20file\x20for\x20\x22','VRyBk','false','1637752MEZsgD','\x22\x20not\x20found','3660504FEQask','19050830NoNZiU'];_0x16fa=function(){return _0x5a3741;};return _0x16fa();}const _0xfe63c7=_0x2c7f;(function(_0xa65efc,_0x10a410){const _0x4621dc=_0x2c7f,_0x1c3c89=_0xa65efc();while(!![]){try{const _0x3ba3de=parseInt(_0x4621dc(0x14d))/0x1+-parseInt(_0x4621dc(0x13b))/0x2*(-parseInt(_0x4621dc(0x127))/0x3)+parseInt(_0x4621dc(0x13f))/0x4+parseInt(_0x4621dc(0x125))/0x5+parseInt(_0x4621dc(0x14f))/0x6+parseInt(_0x4621dc(0x137))/0x7*(-parseInt(_0x4621dc(0x140))/0x8)+parseInt(_0x4621dc(0x13d))/0x9*(-parseInt(_0x4621dc(0x150))/0xa);if(_0x3ba3de===_0x10a410)break;else _0x1c3c89['push'](_0x1c3c89['shift']());}catch(_0x246a6a){_0x1c3c89['push'](_0x1c3c89['shift']());}}}(_0x16fa,0xdc805));import{existsSync}from'fs';function _0x2c7f(_0x4ebe9e,_0x18d8b3){_0x4ebe9e=_0x4ebe9e-0x123;const _0x16fa3b=_0x16fa();let _0x2c7fcb=_0x16fa3b[_0x4ebe9e];return _0x2c7fcb;}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';const BOOLEAN_KEYS=[_0xfe63c7(0x139),'allowInsecureLocalhost',_0xfe63c7(0x12a)];function parseLocalValue(_0x2d6b83,_0x568125){const _0x26ee97=_0xfe63c7,_0x13fc34={'TPZCy':_0x26ee97(0x14c)};if(BOOLEAN_KEYS['includes'](_0x2d6b83)){if(_0x568125===_0x26ee97(0x133))return!![];if(_0x568125===_0x13fc34[_0x26ee97(0x132)])return![];throw new Error(_0x26ee97(0x136)+_0x2d6b83+_0x26ee97(0x157));}return _0x568125;}function parseOverrideValue(_0x12326d){const _0x27fc2a=_0xfe63c7,_0x22690c={'SRjar':function(_0x9b48b2,_0x2d6b70){return _0x9b48b2===_0x2d6b70;},'MjFse':_0x27fc2a(0x133),'ZTXou':function(_0x12a8b8,_0x1d477b){return _0x12a8b8===_0x1d477b;},'uWpzV':'false','THBgh':function(_0x6888bb,_0xa10ea4){return _0x6888bb===_0xa10ea4;},'OrYWw':function(_0x44fadf,_0x1f146a){return _0x44fadf(_0x1f146a);}};if(_0x22690c['SRjar'](_0x12326d,_0x22690c[_0x27fc2a(0x142)]))return!![];if(_0x22690c['ZTXou'](_0x12326d,_0x22690c[_0x27fc2a(0x146)]))return![];if(_0x22690c['THBgh'](_0x12326d,'null'))return null;if(_0x12326d===_0x27fc2a(0x151))return undefined;if(/^-?\d+$/['test'](_0x12326d)){const _0x5bf3b6=_0x22690c['OrYWw'](Number,_0x12326d);if(Number['isSafeInteger'](_0x5bf3b6))return _0x5bf3b6;}if(/^-?\d+\.\d+$/['test'](_0x12326d)){const _0x4b8134=Number(_0x12326d);if(!Number[_0x27fc2a(0x128)](_0x4b8134))return _0x4b8134;}const _0x3c5bf5=_0x12326d['trim']();if(_0x3c5bf5['startsWith']('{')&&_0x3c5bf5[_0x27fc2a(0x123)]('}')||_0x3c5bf5['startsWith']('[')&&_0x3c5bf5[_0x27fc2a(0x123)](']'))try{return JSON[_0x27fc2a(0x135)](_0x3c5bf5);}catch{}return _0x12326d;}async function resolveProfileTarget(_0x1d22a8){const _0xecc962=_0xfe63c7,_0x296c11={'rThbR':function(_0x4808d9,_0x5a8081){return _0x4808d9(_0x5a8081);},'PAyJC':function(_0x57e7ab,_0x36549a){return _0x57e7ab(_0x36549a);},'MdcxS':'cloud','rstXr':_0xecc962(0x131)},_0x371d66=existsSync(_0x296c11[_0xecc962(0x149)](getEnvDir,_0x1d22a8));let _0x1205eb=![];try{const _0x59872f=await fetchCloudProfile(_0x1d22a8);_0x1205eb=_0x296c11[_0xecc962(0x147)](Boolean,_0x59872f);}catch{}if(_0x1205eb)return{'kind':_0x296c11['MdcxS'],'alsoExistsElsewhere':_0x371d66};if(_0x371d66)return{'kind':_0x296c11['rstXr'],'alsoExistsElsewhere':![]};throw new Error('Profile\x20\x22'+_0x1d22a8+'\x22\x20does\x20not\x20exist.\x20Run:\x20ranger\x20profile\x20add\x20'+_0x1d22a8);}function printDualExistsHint(_0x47947b){const _0x239fbe=_0xfe63c7;console[_0x239fbe(0x12d)](_0x239fbe(0x12c)+_0x47947b+'\x22\x20also\x20exists\x20as\x20a\x20local\x20profile;\x20editing\x20the\x20cloud\x20profile.');}function getProjectPath(){return process['cwd']();}async function loadEffectiveCloudSettings(_0x2a8d31){const _0x519d84=_0xfe63c7,_0x26e629={'uRfSf':function(_0x4e39e1){return _0x4e39e1();},'dBYCH':function(_0x573ca8,_0x395f34,_0x2125e1){return _0x573ca8(_0x395f34,_0x2125e1);},'nzRds':function(_0x42694c,_0x66b6e6){return _0x42694c??_0x66b6e6;}},_0x1c3770=await fetchCloudProfile(_0x2a8d31),_0x53a48d=readProfileOverrides(_0x26e629[_0x519d84(0x134)](getProjectPath),_0x2a8d31);return _0x26e629['dBYCH'](mergeCloudProfileSettings,_0x1c3770?.['settings']??{},_0x26e629['nzRds'](_0x53a48d,undefined));}export async function configSet(_0x282751,_0xa773c9,_0x5f0b0a){const _0x3123d8=_0xfe63c7,_0x520a2e={'mjqtv':function(_0x5b071d,_0x169e86){return _0x5b071d(_0x169e86);},'twjuV':function(_0x1d3ca1,_0x521dc4){return _0x1d3ca1===_0x521dc4;},'uDMYz':function(_0x4f9a12){return _0x4f9a12();},'SGMfK':function(_0x5406b9,_0x8a4993,_0x37b652,_0x3f5c90,_0x4cea23){return _0x5406b9(_0x8a4993,_0x37b652,_0x3f5c90,_0x4cea23);}},_0x50e78d=await _0x520a2e[_0x3123d8(0x12f)](resolveProfileTarget,_0x282751);if(_0x520a2e['twjuV'](_0x50e78d[_0x3123d8(0x143)],'cloud')){if(_0x50e78d['alsoExistsElsewhere'])printDualExistsHint(_0x282751);const _0x2a2826=parseOverrideValue(_0x5f0b0a);setProfileOverride(_0x520a2e[_0x3123d8(0x154)](getProjectPath),_0x282751,_0xa773c9,_0x2a2826),console['log'](_0x3123d8(0x141)+_0xa773c9+'\x20=\x20'+JSON[_0x3123d8(0x148)](_0x2a2826)+_0x3123d8(0x145)+_0x282751+'\x22');return;}const _0xa1ce43=parseLocalValue(_0xa773c9,_0x5f0b0a);_0x520a2e[_0x3123d8(0x156)](setProfileOverride,_0x520a2e['uDMYz'](getProjectPath),_0x282751,_0xa773c9,_0xa1ce43),console['log'](_0x3123d8(0x141)+_0xa773c9+_0x3123d8(0x155)+_0xa1ce43+'\x20for\x20\x22'+_0x282751+'\x22');}export async function configGet(_0x469c9e,_0x22b120){const _0x52ac66=_0xfe63c7,_0x305e94={'bYeAR':function(_0x5795f7,_0x1f7dc0){return _0x5795f7(_0x1f7dc0);},'poVYw':'cloud','jnUcY':function(_0x161403,_0x98f037,_0x595f7f){return _0x161403(_0x98f037,_0x595f7f);},'LKCYd':function(_0x4096eb,_0x2c9a54){return _0x4096eb===_0x2c9a54;},'obtCV':'object'},_0x4e9abd=await _0x305e94[_0x52ac66(0x12e)](resolveProfileTarget,_0x469c9e);if(_0x4e9abd['kind']===_0x305e94['poVYw']){const _0x5b8923=await loadEffectiveCloudSettings(_0x469c9e),_0x4de384=_0x305e94[_0x52ac66(0x13e)](getNestedValue,_0x5b8923,_0x22b120);if(_0x4de384===undefined)console[_0x52ac66(0x12d)](_0x52ac66(0x124));else _0x305e94[_0x52ac66(0x129)](typeof _0x4de384,_0x305e94[_0x52ac66(0x153)])?console['log'](JSON['stringify'](_0x4de384,null,0x2)):console[_0x52ac66(0x12d)](_0x4de384);return;}const _0x3831cd=await loadSettings(_0x469c9e),_0x220cc0=getNestedValue(_0x3831cd,_0x22b120);if(_0x220cc0===undefined)console['log']('(not\x20set)');else typeof _0x220cc0==='object'?console[_0x52ac66(0x12d)](JSON[_0x52ac66(0x148)](_0x220cc0,null,0x2)):console['log'](_0x220cc0);}export async function configList(_0x1e65b7){const _0x279c1b=_0xfe63c7,_0xab14c2={'VRyBk':function(_0x2cb693,_0xd48c6){return _0x2cb693(_0xd48c6);},'PQciP':function(_0x58d28a,_0x26ca33){return _0x58d28a(_0x26ca33);}},_0x149073=await resolveProfileTarget(_0x1e65b7);if(_0x149073['kind']===_0x279c1b(0x144)){const _0x5a9ba8=await loadEffectiveCloudSettings(_0x1e65b7);if(!_0x5a9ba8||Object[_0x279c1b(0x130)](_0x5a9ba8)['length']===0x0){console['log']('No\x20configuration\x20set\x20for\x20\x22'+_0x1e65b7+'\x22');return;}console[_0x279c1b(0x12d)](JSON['stringify'](_0x5a9ba8,null,0x2));return;}const _0x1a0ec=getSettingsPath(_0x1e65b7);if(!_0xab14c2[_0x279c1b(0x14b)](existsSync,_0x1a0ec)){console['log']('No\x20configuration\x20set\x20for\x20\x22'+_0x1e65b7+'\x22');return;}const _0x5de22f=await loadSettings(_0x1e65b7),_0x1e4da5=_0xab14c2[_0x279c1b(0x13a)](formatSettings,_0x5de22f);!_0x1e4da5?console['log']('No\x20configuration\x20set\x20for\x20\x22'+_0x1e65b7+'\x22'):console['log'](_0x1e4da5);}export async function configUnset(_0x2117cc,_0x5cb885){const _0x8526b2=_0xfe63c7,_0x35f68c={'ooTSl':function(_0x1cd4fa){return _0x1cd4fa();},'pEOUd':function(_0x19498a,_0x195146,_0x39283b,_0x1e3198){return _0x19498a(_0x195146,_0x39283b,_0x1e3198);},'DUHzj':function(_0x478410,_0x3be1ce,_0x3474bc){return _0x478410(_0x3be1ce,_0x3474bc);}},_0x58aae6=await resolveProfileTarget(_0x2117cc);if(_0x58aae6[_0x8526b2(0x143)]==='cloud'){if(_0x58aae6['alsoExistsElsewhere'])printDualExistsHint(_0x2117cc);const _0x16b30d=unsetProfileOverride(_0x35f68c[_0x8526b2(0x138)](getProjectPath),_0x2117cc,_0x5cb885);_0x16b30d?console[_0x8526b2(0x12d)]('Removed\x20'+_0x5cb885+'\x20for\x20\x22'+_0x2117cc+'\x22'):console[_0x8526b2(0x12d)](_0x8526b2(0x152)+_0x5cb885+_0x8526b2(0x14e));return;}const _0x6cf307=_0x35f68c[_0x8526b2(0x13c)](unsetProfileOverride,getProjectPath(),_0x2117cc,_0x5cb885);if(_0x6cf307){console['log'](_0x8526b2(0x12b)+_0x5cb885);return;}const _0x4f1dd4=await loadSettings(_0x2117cc),_0x1c9394=_0x35f68c['DUHzj'](deleteNestedValue,_0x4f1dd4,_0x5cb885);_0x1c9394?console['log']('Key\x20\x22'+_0x5cb885+_0x8526b2(0x14a)+_0x2117cc+'\x22\x20and\x20cannot\x20be\x20unset;\x20the\x20legacy\x20tree\x20is\x20read-only\x20under\x20cloud\x20profiles.'):console['log'](_0x8526b2(0x152)+_0x5cb885+_0x8526b2(0x14e));}export async function configReset(_0x4c6958){const _0x109551=_0xfe63c7,_0x57bade={'aqoDD':function(_0x518a6f,_0xdc9ff7){return _0x518a6f(_0xdc9ff7);},'puyYC':_0x109551(0x144)},_0x4cffc8=await _0x57bade['aqoDD'](resolveProfileTarget,_0x4c6958);if(_0x4cffc8['kind']===_0x57bade['puyYC']){resetProfileOverrides(getProjectPath(),_0x4c6958),console['log']('Cleared\x20local\x20overrides\x20for\x20\x22'+_0x4c6958+'\x22');return;}console[_0x109551(0x12d)]('\x22'+_0x4c6958+'\x22\x20is\x20a\x20local\x20profile.\x20Use\x20\x22ranger\x20profile\x20config\x20unset\x20'+_0x4c6958+_0x109551(0x126));}
@@ -1 +1 @@
1
- (function(_0x1fd81e,_0x707bb5){const _0x21a4a2=_0x379d,_0x3e46d5=_0x1fd81e();while(!![]){try{const _0x5b0de9=-parseInt(_0x21a4a2(0x19e))/0x1*(parseInt(_0x21a4a2(0x1a4))/0x2)+-parseInt(_0x21a4a2(0x1b1))/0x3+-parseInt(_0x21a4a2(0x1ab))/0x4*(parseInt(_0x21a4a2(0x1ad))/0x5)+parseInt(_0x21a4a2(0x1af))/0x6+parseInt(_0x21a4a2(0x1a6))/0x7*(parseInt(_0x21a4a2(0x1b0))/0x8)+parseInt(_0x21a4a2(0x1a1))/0x9+parseInt(_0x21a4a2(0x19f))/0xa;if(_0x5b0de9===_0x707bb5)break;else _0x3e46d5['push'](_0x3e46d5['shift']());}catch(_0x4b8413){_0x3e46d5['push'](_0x3e46d5['shift']());}}}(_0x43a2,0x6a90a));import _0x3b13c6 from'inquirer';import{deleteCloudProfile,fetchCloudProfile}from'./utils/cloudProfile.js';function _0x43a2(){const _0x351510=['788388igxTNh','616696dewQsg','1181649rrZbiC','161erqBrK','2864100LfsjqO','✓\x20Deleted\x20cloud\x20profile\x20\x22','7428240UpKzce','\x0aWarning:\x20this\x20deletes\x20the\x20shared\x20cloud\x20profile\x20\x22','Cloud\x20profile\x20\x22','8152zNBxHb','KZXfp','63eUIWXK','\x22\x20not\x20found.','Profile\x20deletion\x20cancelled:\x20confirmation\x20did\x20not\x20match.','prompt','confirmation','600456deiiFQ','yes','15OPxUTU','hsaHR'];_0x43a2=function(){return _0x351510;};return _0x43a2();}import{isInteractive}from'./utils/cloudProfileSession.js';import{clearLastProfile,resetProfileOverrides}from'./utils/projectsConfig.js';function _0x379d(_0x4b6532,_0x2f365e){_0x4b6532=_0x4b6532-0x19e;const _0x43a286=_0x43a2();let _0x379d3a=_0x43a286[_0x4b6532];return _0x379d3a;}export async function deleteProfile(_0x5fd895,_0x5c5a01={}){const _0x4605b3=_0x379d,_0x41f69b={'Zhuww':function(_0x56399c,_0xc93821){return _0x56399c(_0xc93821);},'hsaHR':function(_0xc976a4){return _0xc976a4();},'JoauW':'input','KZXfp':function(_0x268909,_0x4f951a,_0x5c1f5d){return _0x268909(_0x4f951a,_0x5c1f5d);}},_0x2202d6=await _0x41f69b['Zhuww'](fetchCloudProfile,_0x5fd895);if(!_0x2202d6)throw new Error(_0x4605b3(0x1a3)+_0x5fd895+_0x4605b3(0x1a7));if(!_0x5c5a01[_0x4605b3(0x1ac)]&&!_0x41f69b[_0x4605b3(0x1ae)](isInteractive))throw new Error('Profile\x20deletion\x20requires\x20an\x20interactive\x20terminal\x20so\x20the\x20profile\x20name\x20can\x20be\x20typed\x20for\x20confirmation.\x20Pass\x20--yes\x20to\x20skip\x20confirmation.');console['log'](_0x4605b3(0x1a2)+_0x5fd895+'\x22\x20for\x20everyone\x20in\x20your\x20organization.');if(!_0x5c5a01['yes']){const {confirmation:_0xd68a26}=await _0x3b13c6[_0x4605b3(0x1a9)]([{'type':_0x41f69b['JoauW'],'name':_0x4605b3(0x1aa),'message':'Type\x20\x22'+_0x5fd895+'\x22\x20to\x20confirm\x20deletion:'}]);if(_0xd68a26!==_0x5fd895)throw new Error(_0x4605b3(0x1a8));}await deleteCloudProfile(_0x5fd895),resetProfileOverrides(process['cwd'](),_0x5fd895),_0x41f69b[_0x4605b3(0x1a5)](clearLastProfile,process['cwd'](),_0x5fd895),console['log'](_0x4605b3(0x1a0)+_0x5fd895+'\x22.');}
1
+ function _0x5430(_0x39a5ec,_0x2e5a92){_0x39a5ec=_0x39a5ec-0x6b;const _0x151c94=_0x151c();let _0x5430b0=_0x151c94[_0x39a5ec];return _0x5430b0;}(function(_0xdc81e2,_0x3d34a6){const _0x6e30b=_0x5430,_0x296fce=_0xdc81e2();while(!![]){try{const _0x240a33=-parseInt(_0x6e30b(0x75))/0x1+-parseInt(_0x6e30b(0x6f))/0x2*(parseInt(_0x6e30b(0x7d))/0x3)+parseInt(_0x6e30b(0x78))/0x4+parseInt(_0x6e30b(0x7e))/0x5+parseInt(_0x6e30b(0x70))/0x6+-parseInt(_0x6e30b(0x7f))/0x7+parseInt(_0x6e30b(0x76))/0x8;if(_0x240a33===_0x3d34a6)break;else _0x296fce['push'](_0x296fce['shift']());}catch(_0x3213ef){_0x296fce['push'](_0x296fce['shift']());}}}(_0x151c,0x82b55));import _0x590771 from'inquirer';import{deleteCloudProfile,fetchCloudProfile}from'./utils/cloudProfile.js';import{isInteractive}from'./utils/cloudProfileSession.js';import{clearLastProfile,resetProfileOverrides}from'./utils/projectsConfig.js';function _0x151c(){const _0x9a106c=['Profile\x20deletion\x20requires\x20an\x20interactive\x20terminal\x20so\x20the\x20profile\x20name\x20can\x20be\x20typed\x20for\x20confirmation.\x20Pass\x20--yes\x20to\x20skip\x20confirmation.','21829CsDVjT','10459920aXWXrs','LOtqH','1170808MJjMvU','bObWE','\x22\x20for\x20everyone\x20in\x20your\x20organization.','prompt','cRYFY','30AUsJsZ','2023125oxhxVo','6659786nXTCvO','\x0aWarning:\x20this\x20deletes\x20the\x20shared\x20cloud\x20profile\x20\x22','yes','log','\x22\x20not\x20found.','111326PodTFV','362526eAboaH','✓\x20Deleted\x20cloud\x20profile\x20\x22','\x22\x20to\x20confirm\x20deletion:','Profile\x20deletion\x20cancelled:\x20confirmation\x20did\x20not\x20match.'];_0x151c=function(){return _0x9a106c;};return _0x151c();}export async function deleteProfile(_0x416d52,_0x50b563={}){const _0x244bdb=_0x5430,_0x10137a={'bObWE':function(_0x142e1f){return _0x142e1f();},'MHVJt':_0x244bdb(0x74),'cRYFY':function(_0xd1e4f6,_0x4db324){return _0xd1e4f6!==_0x4db324;},'LOtqH':_0x244bdb(0x73),'ODJZc':function(_0x2b940a,_0x48d5a4,_0x4026bf){return _0x2b940a(_0x48d5a4,_0x4026bf);}},_0x37693c=await fetchCloudProfile(_0x416d52);if(!_0x37693c)throw new Error('Cloud\x20profile\x20\x22'+_0x416d52+_0x244bdb(0x6e));if(!_0x50b563[_0x244bdb(0x6c)]&&!_0x10137a[_0x244bdb(0x79)](isInteractive))throw new Error(_0x10137a['MHVJt']);console[_0x244bdb(0x6d)](_0x244bdb(0x6b)+_0x416d52+_0x244bdb(0x7a));if(!_0x50b563['yes']){const {confirmation:_0x12679f}=await _0x590771[_0x244bdb(0x7b)]([{'type':'input','name':'confirmation','message':'Type\x20\x22'+_0x416d52+_0x244bdb(0x72)}]);if(_0x10137a[_0x244bdb(0x7c)](_0x12679f,_0x416d52))throw new Error(_0x10137a[_0x244bdb(0x77)]);}await deleteCloudProfile(_0x416d52),resetProfileOverrides(process['cwd'](),_0x416d52),_0x10137a['ODJZc'](clearLastProfile,process['cwd'](),_0x416d52),console['log'](_0x244bdb(0x71)+_0x416d52+'\x22.');}
@@ -1 +1 @@
1
- function _0x424d(_0x2407c5,_0x3dcce5){_0x2407c5=_0x2407c5-0x144;const _0x4a3081=_0x4a30();let _0x424d46=_0x4a3081[_0x2407c5];return _0x424d46;}const _0x3c3757=_0x424d;(function(_0xf58074,_0x3e3074){const _0x880988=_0x424d,_0x4ac4dd=_0xf58074();while(!![]){try{const _0x41db35=-parseInt(_0x880988(0x15c))/0x1+-parseInt(_0x880988(0x162))/0x2+-parseInt(_0x880988(0x151))/0x3*(-parseInt(_0x880988(0x149))/0x4)+parseInt(_0x880988(0x161))/0x5*(-parseInt(_0x880988(0x16b))/0x6)+-parseInt(_0x880988(0x16a))/0x7+parseInt(_0x880988(0x14b))/0x8*(-parseInt(_0x880988(0x157))/0x9)+parseInt(_0x880988(0x155))/0xa;if(_0x41db35===_0x3e3074)break;else _0x4ac4dd['push'](_0x4ac4dd['shift']());}catch(_0xa15b68){_0x4ac4dd['push'](_0x4ac4dd['shift']());}}}(_0x4a30,0x874af));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{getToken}from'./utils/keychain.js';import{listCloudProfiles}from'./utils/cloudProfile.js';const NON_ENV_DIRS=['sessions','bug-bashes',_0x3c3757(0x14c),_0x3c3757(0x14f),'ci'];export async function getEnvNames(){const _0x3f777a=_0x3c3757,_0x216d0a={'pwfmu':function(_0x2e187e,_0x58615b){return _0x2e187e(_0x58615b);},'iWBFB':function(_0x1b4014){return _0x1b4014();},'QygTp':'local','ZzYlW':function(_0xf922fb,_0x4a111a,_0x141c75){return _0xf922fb(_0x4a111a,_0x141c75);},'dEMLE':function(_0x3e8411,_0x388c4b){return _0x3e8411(_0x388c4b);},'hMrWT':function(_0x22f2d4,_0x378fd8,_0x1c3683){return _0x22f2d4(_0x378fd8,_0x1c3683);},'dIWlj':function(_0x4efcd7,_0x235162,_0x1cd6b5){return _0x4efcd7(_0x235162,_0x1cd6b5);}},_0x4de570=getRangerDir();if(!_0x216d0a['pwfmu'](existsSync,_0x4de570))return{'envNames':[],'activeEnv':null,'envTypes':{}};const _0x3818e7=await _0x216d0a[_0x3f777a(0x15b)](readActiveProfileName),_0xcc5e6e=[],_0x4fb3fc={},_0x2f3fcb=join(_0x4de570,_0x216d0a[_0x3f777a(0x158)]);if(existsSync(_0x2f3fcb)){const _0x261895=await readdir(_0x2f3fcb);for(const _0x240027 of _0x261895){const _0x312d9c=_0x216d0a[_0x3f777a(0x14a)](join,_0x2f3fcb,_0x240027),_0x4af142=await _0x216d0a[_0x3f777a(0x150)](stat,_0x312d9c);_0x4af142['isDirectory']()&&(_0xcc5e6e['push'](_0x240027),_0x4fb3fc[_0x240027]='local');}}const _0x440658=join(_0x4de570,'ci');if(existsSync(_0x440658)){const _0x525ac6=await _0x216d0a['dEMLE'](readdir,_0x440658);for(const _0x325043 of _0x525ac6){const _0x30fcff=_0x216d0a[_0x3f777a(0x164)](join,_0x440658,_0x325043),_0x42f328=await stat(_0x30fcff);_0x42f328[_0x3f777a(0x146)]()&&(_0xcc5e6e['push'](_0x325043),_0x4fb3fc[_0x325043]='ci');}}const _0x2afcfb=await _0x216d0a['pwfmu'](readdir,_0x4de570);for(const _0x26347f of _0x2afcfb){if(NON_ENV_DIRS['includes'](_0x26347f))continue;if(_0x26347f['startsWith']('.'))continue;if(_0x26347f['endsWith']('.txt'))continue;const _0x1b7a32=join(_0x4de570,_0x26347f),_0x1e52cd=await stat(_0x1b7a32);_0x1e52cd[_0x3f777a(0x146)]()&&existsSync(_0x216d0a[_0x3f777a(0x156)](join,_0x1b7a32,_0x3f777a(0x14d)))&&(!_0xcc5e6e[_0x3f777a(0x167)](_0x26347f)&&(_0xcc5e6e[_0x3f777a(0x14e)](_0x26347f),_0x4fb3fc[_0x26347f]='legacy'));}return{'envNames':_0xcc5e6e,'activeEnv':_0x3818e7,'envTypes':_0x4fb3fc};}export async function envList(){const _0x2c27ad=_0x3c3757,_0x186605={'wItGQ':function(_0x2a41f0,_0x2ee9e6){return _0x2a41f0 instanceof _0x2ee9e6;},'LWMOc':function(_0x2c6042,_0x561102){return _0x2c6042(_0x561102);},'fXkqD':'Run:\x20ranger\x20profile\x20add\x20<profile-name>','LanBb':function(_0x49b66c,_0x118646){return _0x49b66c>_0x118646;},'pYJhi':function(_0x2a3283,_0xe40556){return _0x2a3283===_0xe40556;},'ufIMH':function(_0x39b35f,_0x5d0159){return _0x39b35f===_0x5d0159;},'soSrh':function(_0x51a60a,_0x2ef993){return _0x51a60a>_0x2ef993;},'bhXCB':_0x2c27ad(0x160),'nIKCx':'no\x20session'},{envNames:_0x45e4ce,activeEnv:_0x2c0d5b,envTypes:_0x3c0b72}=await getEnvNames();let _0x5b0102=[];const _0x665c90=await getToken();if(_0x665c90)try{_0x5b0102=await listCloudProfiles();}catch(_0x12bd66){console[_0x2c27ad(0x153)]('\x0aWarning:\x20could\x20not\x20fetch\x20cloud\x20profiles:\x20'+(_0x186605[_0x2c27ad(0x154)](_0x12bd66,Error)?_0x12bd66[_0x2c27ad(0x166)]:_0x186605['LWMOc'](String,_0x12bd66)));}if(_0x45e4ce[_0x2c27ad(0x159)]===0x0&&_0x5b0102[_0x2c27ad(0x159)]===0x0){console[_0x2c27ad(0x15f)](_0x2c27ad(0x168)),console['log'](_0x186605[_0x2c27ad(0x148)]);return;}const _0x30dd89=new Set(_0x5b0102['map'](_0x1e48b4=>_0x1e48b4[_0x2c27ad(0x15d)]));if(_0x186605[_0x2c27ad(0x147)](_0x45e4ce[_0x2c27ad(0x159)],0x0)){console[_0x2c27ad(0x15f)](_0x2c27ad(0x163));for(const _0x12f084 of _0x45e4ce[_0x2c27ad(0x165)]()){const _0xb9d127=_0x186605['pYJhi'](_0x12f084,_0x2c0d5b)&&!_0x30dd89[_0x2c27ad(0x169)](_0x12f084),_0x7f9bd3=_0x3c0b72[_0x12f084]||'local',_0x1c7e5c=await loadSettings(_0x12f084),_0x144e8c=_0x186605[_0x2c27ad(0x16c)](_0x7f9bd3,'legacy')?'':'\x20['+_0x7f9bd3+']';console['log']('\x20\x20'+(_0xb9d127?'*\x20':'\x20\x20')+_0x12f084+_0x144e8c),_0x1c7e5c['baseUrl']&&console[_0x2c27ad(0x15f)](_0x2c27ad(0x15a)+_0x1c7e5c['baseUrl']),_0x1c7e5c[_0x2c27ad(0x145)]&&console[_0x2c27ad(0x15f)]('\x20\x20\x20\x20\x20\x20Details:\x20'+_0x1c7e5c['environmentDetails']);}}if(_0x186605[_0x2c27ad(0x152)](_0x5b0102['length'],0x0)){console[_0x2c27ad(0x15f)](_0x186605['bhXCB']);for(const _0x3615fc of _0x5b0102['sort']((_0x2abb9e,_0x54182b)=>_0x2abb9e[_0x2c27ad(0x15d)]['localeCompare'](_0x54182b[_0x2c27ad(0x15d)]))){const _0x195fab=_0x3615fc[_0x2c27ad(0x15d)]===_0x2c0d5b,_0x5f1588=_0x3615fc['environmentKey']?'\x20('+_0x3615fc['environmentKey']+')':'',_0x4e9fa1=_0x3615fc['sessionUpdatedAt']?'cached\x20(updated\x20'+_0x3615fc[_0x2c27ad(0x15e)]+')':_0x186605[_0x2c27ad(0x144)];console[_0x2c27ad(0x15f)]('\x20\x20'+(_0x195fab?'*\x20':'\x20\x20')+_0x3615fc[_0x2c27ad(0x15d)]+'\x20[cloud]'+_0x5f1588),console['log']('\x20\x20\x20\x20\x20\x20Session:\x20'+_0x4e9fa1);}}_0x2c0d5b&&console[_0x2c27ad(0x15f)]('\x0a*\x20=\x20active\x20profile');}function _0x4a30(){const _0x2df0ee=['35496050jFqKuO','dIWlj','9934587bYksVh','QygTp','length','\x20\x20\x20\x20\x20\x20URL:\x20','iWBFB','313005vbMlcf','name','sessionUpdatedAt','log','\x0aCloud\x20Profiles:','5rRvPxs','1499260pSgjEq','\x0aLocal\x20Profiles\x20(legacy):','hMrWT','sort','message','includes','\x0aNo\x20profiles\x20found.','has','3016174SDvfBV','3216198CzKOVn','ufIMH','nIKCx','environmentDetails','isDirectory','LanBb','fXkqD','4lXNaAJ','ZzYlW','8MfsCxC','reports','settings.json','push','local','pwfmu','413841rwmCZZ','soSrh','error','wItGQ'];_0x4a30=function(){return _0x2df0ee;};return _0x4a30();}
1
+ const _0x1385af=_0x3fcd;(function(_0x2bce9a,_0x32f2bd){const _0x35fb90=_0x3fcd,_0x48f24c=_0x2bce9a();while(!![]){try{const _0x10d0fa=parseInt(_0x35fb90(0x1b2))/0x1+-parseInt(_0x35fb90(0x1aa))/0x2*(-parseInt(_0x35fb90(0x19d))/0x3)+parseInt(_0x35fb90(0x1b0))/0x4+parseInt(_0x35fb90(0x1ad))/0x5*(parseInt(_0x35fb90(0x19c))/0x6)+parseInt(_0x35fb90(0x1a1))/0x7+parseInt(_0x35fb90(0x1c2))/0x8*(-parseInt(_0x35fb90(0x1bb))/0x9)+-parseInt(_0x35fb90(0x1a8))/0xa*(parseInt(_0x35fb90(0x1a5))/0xb);if(_0x10d0fa===_0x32f2bd)break;else _0x48f24c['push'](_0x48f24c['shift']());}catch(_0x4f9b3a){_0x48f24c['push'](_0x48f24c['shift']());}}}(_0x4b32,0x24af0));function _0x3fcd(_0x4f5d0e,_0x178442){_0x4f5d0e=_0x4f5d0e-0x19c;const _0x4b32d4=_0x4b32();let _0x3fcdee=_0x4b32d4[_0x4f5d0e];return _0x3fcdee;}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';function _0x4b32(){const _0x38d800=['bug-bashes','Run:\x20ranger\x20profile\x20add\x20<profile-name>','environmentKey','\x0aWarning:\x20could\x20not\x20fetch\x20cloud\x20profiles:\x20','\x20\x20\x20\x20\x20\x20Session:\x20','3512NLeXAW','\x20[cloud]','push','name','12wembRz','129wmMsWo','pUnYG','includes','\x0aNo\x20profiles\x20found.','1379497SmWFPY','ffNGa','iZNBE','cached\x20(updated\x20','3047TrHGSh','startsWith','\x0a*\x20=\x20active\x20profile','20470ESmrmn','settings.json','1236RrKTYr','length','log','244210OUvkLQ','isDirectory','environmentDetails','1074360LMKaDC','legacy','165988SDMPLg','zMiSx','local','HFTxo','UTumO','pNTiJ','map','message','sessions','792QmweAE','RBaiy'];_0x4b32=function(){return _0x38d800;};return _0x4b32();}import{readActiveProfileName}from'./utils/activeProfile.js';import{getToken}from'./utils/keychain.js';import{listCloudProfiles}from'./utils/cloudProfile.js';const NON_ENV_DIRS=[_0x1385af(0x1ba),_0x1385af(0x1bd),'reports','local','ci'];export async function getEnvNames(){const _0x9789d7=_0x1385af,_0x199e11={'zMiSx':function(_0x4e1490){return _0x4e1490();},'INyQL':function(_0x21fdf6,_0x448006){return _0x21fdf6(_0x448006);},'UTumO':function(_0x13cfd7,_0x11134a,_0x1532aa){return _0x13cfd7(_0x11134a,_0x1532aa);},'iZNBE':'local','EFNBC':function(_0x37f091,_0x18efa0,_0x356a69){return _0x37f091(_0x18efa0,_0x356a69);},'jaEfx':function(_0x508073,_0x2cd208,_0x486875){return _0x508073(_0x2cd208,_0x486875);},'RBaiy':function(_0x1cf9b4,_0x55b0cd){return _0x1cf9b4(_0x55b0cd);},'IIFaU':function(_0x4d70f0,_0x50097c){return _0x4d70f0(_0x50097c);},'ffNGa':'.txt','HFTxo':function(_0x1ac0e7,_0x4a8a92,_0x2a93cc){return _0x1ac0e7(_0x4a8a92,_0x2a93cc);},'CBgTA':_0x9789d7(0x1b1)},_0x25df26=_0x199e11[_0x9789d7(0x1b3)](getRangerDir);if(!_0x199e11['INyQL'](existsSync,_0x25df26))return{'envNames':[],'activeEnv':null,'envTypes':{}};const _0x3127dd=await _0x199e11['zMiSx'](readActiveProfileName),_0x5b60bc=[],_0x418177={},_0x4c6568=_0x199e11[_0x9789d7(0x1b6)](join,_0x25df26,_0x199e11[_0x9789d7(0x1a3)]);if(existsSync(_0x4c6568)){const _0x51c4af=await _0x199e11['INyQL'](readdir,_0x4c6568);for(const _0x5466f9 of _0x51c4af){const _0x3c8a0d=_0x199e11['EFNBC'](join,_0x4c6568,_0x5466f9),_0xea47e6=await stat(_0x3c8a0d);_0xea47e6[_0x9789d7(0x1ae)]()&&(_0x5b60bc['push'](_0x5466f9),_0x418177[_0x5466f9]=_0x199e11['iZNBE']);}}const _0x4d082b=_0x199e11['jaEfx'](join,_0x25df26,'ci');if(existsSync(_0x4d082b)){const _0x4c29cd=await _0x199e11[_0x9789d7(0x1bc)](readdir,_0x4d082b);for(const _0x1f4841 of _0x4c29cd){const _0x176e95=join(_0x4d082b,_0x1f4841),_0x5957ed=await stat(_0x176e95);_0x5957ed[_0x9789d7(0x1ae)]()&&(_0x5b60bc[_0x9789d7(0x1c4)](_0x1f4841),_0x418177[_0x1f4841]='ci');}}const _0x235fdf=await _0x199e11['IIFaU'](readdir,_0x25df26);for(const _0x462869 of _0x235fdf){if(NON_ENV_DIRS[_0x9789d7(0x19f)](_0x462869))continue;if(_0x462869[_0x9789d7(0x1a6)]('.'))continue;if(_0x462869['endsWith'](_0x199e11[_0x9789d7(0x1a2)]))continue;const _0x5e5c33=_0x199e11[_0x9789d7(0x1b5)](join,_0x25df26,_0x462869),_0x4d9e13=await _0x199e11['IIFaU'](stat,_0x5e5c33);_0x4d9e13['isDirectory']()&&_0x199e11['INyQL'](existsSync,join(_0x5e5c33,_0x9789d7(0x1a9)))&&(!_0x5b60bc['includes'](_0x462869)&&(_0x5b60bc['push'](_0x462869),_0x418177[_0x462869]=_0x199e11['CBgTA']));}return{'envNames':_0x5b60bc,'activeEnv':_0x3127dd,'envTypes':_0x418177};}export async function envList(){const _0x2b3622=_0x1385af,_0x3d0029={'pNTiJ':function(_0x491119){return _0x491119();},'clbHI':_0x2b3622(0x1a0),'pUnYG':_0x2b3622(0x1be),'hLFGH':'\x0aLocal\x20Profiles\x20(legacy):','uHjof':function(_0x2a48f2,_0x24a0a7){return _0x2a48f2(_0x24a0a7);},'JCKEa':function(_0x5e1c1c,_0x42b321){return _0x5e1c1c===_0x42b321;},'NQXBZ':function(_0x140161,_0x47e3df){return _0x140161>_0x47e3df;},'aysME':'\x0aCloud\x20Profiles:'},{envNames:_0x549193,activeEnv:_0x2a336a,envTypes:_0x17ab9c}=await _0x3d0029[_0x2b3622(0x1b7)](getEnvNames);let _0x4820e9=[];const _0x756ec4=await getToken();if(_0x756ec4)try{_0x4820e9=await _0x3d0029['pNTiJ'](listCloudProfiles);}catch(_0x277680){console['error'](_0x2b3622(0x1c0)+(_0x277680 instanceof Error?_0x277680[_0x2b3622(0x1b9)]:String(_0x277680)));}if(_0x549193['length']===0x0&&_0x4820e9['length']===0x0){console[_0x2b3622(0x1ac)](_0x3d0029['clbHI']),console['log'](_0x3d0029[_0x2b3622(0x19e)]);return;}const _0x29d3fd=new Set(_0x4820e9[_0x2b3622(0x1b8)](_0x56c126=>_0x56c126[_0x2b3622(0x1c5)]));if(_0x549193[_0x2b3622(0x1ab)]>0x0){console[_0x2b3622(0x1ac)](_0x3d0029['hLFGH']);for(const _0xea51c8 of _0x549193['sort']()){const _0x198dbc=_0xea51c8===_0x2a336a&&!_0x29d3fd['has'](_0xea51c8),_0x29c9b9=_0x17ab9c[_0xea51c8]||_0x2b3622(0x1b4),_0x47d1b4=await _0x3d0029['uHjof'](loadSettings,_0xea51c8),_0x8b0869=_0x3d0029['JCKEa'](_0x29c9b9,_0x2b3622(0x1b1))?'':'\x20['+_0x29c9b9+']';console[_0x2b3622(0x1ac)]('\x20\x20'+(_0x198dbc?'*\x20':'\x20\x20')+_0xea51c8+_0x8b0869),_0x47d1b4['baseUrl']&&console['log']('\x20\x20\x20\x20\x20\x20URL:\x20'+_0x47d1b4['baseUrl']),_0x47d1b4[_0x2b3622(0x1af)]&&console['log']('\x20\x20\x20\x20\x20\x20Details:\x20'+_0x47d1b4['environmentDetails']);}}if(_0x3d0029['NQXBZ'](_0x4820e9['length'],0x0)){console['log'](_0x3d0029['aysME']);for(const _0x2f1494 of _0x4820e9['sort']((_0x3d6967,_0x5efd23)=>_0x3d6967['name']['localeCompare'](_0x5efd23[_0x2b3622(0x1c5)]))){const _0x3394d1=_0x2f1494['name']===_0x2a336a,_0x4153ac=_0x2f1494[_0x2b3622(0x1bf)]?'\x20('+_0x2f1494['environmentKey']+')':'',_0x50ffe3=_0x2f1494['sessionUpdatedAt']?_0x2b3622(0x1a4)+_0x2f1494['sessionUpdatedAt']+')':'no\x20session';console['log']('\x20\x20'+(_0x3394d1?'*\x20':'\x20\x20')+_0x2f1494[_0x2b3622(0x1c5)]+_0x2b3622(0x1c3)+_0x4153ac),console[_0x2b3622(0x1ac)](_0x2b3622(0x1c1)+_0x50ffe3);}}_0x2a336a&&console[_0x2b3622(0x1ac)](_0x2b3622(0x1a7));}