@ranger-testing/ranger-cli 2.1.3 → 2.1.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (66) hide show
  1. package/build/cli.js +1 -1
  2. package/build/commands/addEnv.js +1 -1
  3. package/build/commands/authEncrypt.js +1 -1
  4. package/build/commands/clean.js +1 -1
  5. package/build/commands/config.js +1 -1
  6. package/build/commands/env.js +1 -1
  7. package/build/commands/feature.js +1 -1
  8. package/build/commands/hook.js +1 -1
  9. package/build/commands/hooks/autoPrompt.js +1 -1
  10. package/build/commands/hooks/disable.js +1 -1
  11. package/build/commands/hooks/enable.js +1 -1
  12. package/build/commands/hooks/exitPlanMode.js +1 -1
  13. package/build/commands/hooks/index.js +1 -1
  14. package/build/commands/hooks/output.js +1 -1
  15. package/build/commands/hooks/planReminder.js +1 -1
  16. package/build/commands/hooks/planStart.js +1 -1
  17. package/build/commands/hooks/postEdit.js +1 -1
  18. package/build/commands/hooks/preCompact.js +1 -1
  19. package/build/commands/hooks/sessionEnd.js +1 -1
  20. package/build/commands/hooks/sessionStart.js +1 -1
  21. package/build/commands/hooks/stopHook.js +1 -1
  22. package/build/commands/index.js +1 -1
  23. package/build/commands/login.js +1 -1
  24. package/build/commands/setup/claude.js +1 -1
  25. package/build/commands/setup/opencode.js +1 -1
  26. package/build/commands/setupCi.js +1 -1
  27. package/build/commands/skillup.js +1 -1
  28. package/build/commands/start.js +1 -1
  29. package/build/commands/status.js +1 -1
  30. package/build/commands/update.js +1 -1
  31. package/build/commands/updateEnv.js +1 -1
  32. package/build/commands/useEnv.js +1 -1
  33. package/build/commands/utils/activeProfile.js +1 -1
  34. package/build/commands/utils/browserSessionsApi.js +1 -1
  35. package/build/commands/utils/claudeConfig.js +1 -1
  36. package/build/commands/utils/claudePlugin.js +1 -1
  37. package/build/commands/utils/crypto.js +1 -1
  38. package/build/commands/utils/desirePathLog.js +1 -1
  39. package/build/commands/utils/deviceAuth.js +1 -1
  40. package/build/commands/utils/environment.js +1 -1
  41. package/build/commands/utils/featureApi.js +1 -1
  42. package/build/commands/utils/featureReportGenerator.js +1 -1
  43. package/build/commands/utils/fixWebmDuration.js +1 -1
  44. package/build/commands/utils/git.js +1 -1
  45. package/build/commands/utils/keychain.js +1 -1
  46. package/build/commands/utils/localAgentInstallationsApi.js +1 -1
  47. package/build/commands/utils/mcpImageBase64.js +1 -1
  48. package/build/commands/utils/model.js +1 -1
  49. package/build/commands/utils/opencodeConfig.js +1 -1
  50. package/build/commands/utils/profileMessages.js +1 -1
  51. package/build/commands/utils/profileSetupBanner.js +1 -1
  52. package/build/commands/utils/rangerConfig.js +1 -1
  53. package/build/commands/utils/rangerRoot.js +1 -1
  54. package/build/commands/utils/reportGenerator.js +1 -1
  55. package/build/commands/utils/retry.js +1 -1
  56. package/build/commands/utils/sessionCache.js +1 -1
  57. package/build/commands/utils/settings.js +1 -1
  58. package/build/commands/utils/skillContent.js +1 -1
  59. package/build/commands/utils/skills.js +1 -1
  60. package/build/commands/utils/telemetry.js +1 -1
  61. package/build/commands/utils/traceSnapshotMapper.js +1 -1
  62. package/build/commands/utils/userApi.js +1 -1
  63. package/build/commands/utils/version.js +1 -1
  64. package/build/commands/verifyFeature.js +1 -1
  65. package/build/commands/verifyInBrowser.js +1 -1
  66. package/package.json +2 -2
@@ -1 +1 @@
1
- (function(_0x236201,_0x4e0aa5){const _0x10fcbf=_0x5f21,_0x243592=_0x236201();while(!![]){try{const _0x444797=parseInt(_0x10fcbf(0x10e))/0x1+-parseInt(_0x10fcbf(0x104))/0x2+-parseInt(_0x10fcbf(0x111))/0x3*(-parseInt(_0x10fcbf(0x102))/0x4)+parseInt(_0x10fcbf(0x113))/0x5*(parseInt(_0x10fcbf(0x10f))/0x6)+parseInt(_0x10fcbf(0x108))/0x7+parseInt(_0x10fcbf(0x11a))/0x8+parseInt(_0x10fcbf(0x106))/0x9*(-parseInt(_0x10fcbf(0xff))/0xa);if(_0x444797===_0x4e0aa5)break;else _0x243592['push'](_0x243592['shift']());}catch(_0x3f54f2){_0x243592['push'](_0x243592['shift']());}}}(_0x7e2b,0x2e8af));import{open}from'fs/promises';import{getToken}from'../utils/keychain.js';import{getFeature,concludeSession}from'../utils/featureApi.js';import{getSessionEntry}from'../utils/sessionCache.js';function _0x7e2b(){const _0x2cff2e=['fNJwm','815mAdwBS','name','size','Failed\x20to\x20conclude\x20Ranger\x20feature\x20review\x20session','input','utf8','`,\x20then\x20run\x20/exit\x20again.','2248056etROtB','currentSessionId','includes','trackCommandStart','close','Wdihz','hTPqx','transcript_path','xRVyw','featureId','success','430FwYrFz','MlZcK','RjyLF','1124QNoIrv','sessionId','725238hjMGKk','alloc','170757arWYPk','ombHH','1699215inRfoa','string','min','cBfQl','AHMwa','read','126653POuiOl','13722DOsgSa','hook:stop','3693awHHsd'];_0x7e2b=function(){return _0x2cff2e;};return _0x7e2b();}import{getEnabledHookContext}from'./output.js';import{createTelemetryCollector}from'../utils/telemetry.js';export async function stopHook(_0xc598ba){const _0x4f4430=_0x5f21,_0x48f318={'fNJwm':function(_0x302efa,_0x5280c7){return _0x302efa(_0x5280c7);},'cBfQl':function(_0x5e8c6a,_0x2e59eb){return _0x5e8c6a===_0x2e59eb;},'WOFVo':_0x4f4430(0x109),'RjyLF':function(_0x4d7716,_0x1d73a5){return _0x4d7716(_0x1d73a5);},'IiZKY':function(_0x1b75ac,_0x32e179,_0x1faa92,_0x2572af){return _0x1b75ac(_0x32e179,_0x1faa92,_0x2572af);},'ZFYGt':'RANGER_SKIP_VERIFICATION','bXeSD':function(_0x5873cd){return _0x5873cd();},'xRVyw':function(_0x3c4429,_0x50ea9d,_0x259ec7){return _0x3c4429(_0x50ea9d,_0x259ec7);},'ombHH':function(_0x3a8685,_0x19593f,_0x4bf38f){return _0x3a8685(_0x19593f,_0x4bf38f);},'XOVpq':function(_0x445025,_0x3f3f51){return _0x445025(_0x3f3f51);},'AHMwa':function(_0x43663d,_0x120c03){return _0x43663d&&_0x120c03;},'Wdihz':function(_0x33422,_0x33c363,_0x482f18,_0x44b7c2){return _0x33422(_0x33c363,_0x482f18,_0x44b7c2);}},_0x40e573=await _0x48f318[_0x4f4430(0x112)](getEnabledHookContext,_0xc598ba),_0x12866a=_0x40e573?.[_0x4f4430(0x103)]??null,_0x347768=Boolean(_0x40e573?.['input']?.['stop_hook_active']),_0x1db478=_0x48f318[_0x4f4430(0x10b)](typeof _0x40e573?.[_0x4f4430(0x117)]?.[_0x4f4430(0xfb)],_0x48f318['WOFVo'])?_0x40e573[_0x4f4430(0x117)]['transcript_path']:null;let _0xf21adf=!![];if(!_0x12866a){await trackStop(_0x12866a,![],_0xf21adf);return;}try{const _0x17f412=_0x48f318[_0x4f4430(0x101)](getSessionEntry,_0x12866a);if(!_0x17f412){await _0x48f318['IiZKY'](trackStop,_0x12866a,!![],_0xf21adf);return;}const _0x2f9d97='https://dashboard.ranger.net/features/'+_0x17f412[_0x4f4430(0xfd)],_0x2186b4=_0x48f318['ZFYGt'],_0xd8dae9=await _0x48f318['bXeSD'](getToken),_0xe0a887=!_0x347768;let _0x4f20a5=null,_0x59df07=null;const _0x5714d7=_0x347768&&await _0x48f318[_0x4f4430(0xfc)](transcriptHasToken,_0x1db478,_0x2186b4),_0x46ab4d=await _0x48f318[_0x4f4430(0x107)](transcriptHasToken,_0x1db478,_0x2f9d97);if(_0xd8dae9)try{const _0x28bd88=await _0x48f318['XOVpq'](getFeature,_0x17f412[_0x4f4430(0xfd)]);_0x4f20a5=_0x28bd88[_0x4f4430(0x114)]??null,_0x59df07=_0x28bd88[_0x4f4430(0x11b)]??null;}catch{}if(_0x48f318[_0x4f4430(0x10c)](_0xd8dae9,_0x59df07))try{await concludeSession(_0x17f412[_0x4f4430(0xfd)],_0x59df07);}catch(_0x3d4930){if(_0x5714d7){await _0x48f318[_0x4f4430(0xf9)](trackStop,_0x12866a,!![],_0xf21adf);return;}_0xf21adf=![];const _0x575abd=_0x3d4930 instanceof Error?_0x3d4930['message']:String(_0x3d4930),_0x210147={'decision':'block','reason':_0x4f4430(0x116)+(_0x4f20a5?'\x20for\x20\x22'+_0x4f20a5+'\x22':'')+':\x0a\x0a'+_0x575abd+'\x0a\x0aThis\x20is\x20most\x20likely\x20due\x20to\x20pending\x20scenarios\x20that\x20need\x20to\x20be\x20verified.\x20Please\x20resolve\x20the\x20issue\x20or\x20resume\x20later\x20with:\x0a\x20\x20ranger\x20resume\x0a\x0aIf\x20you\x20are\x20extremely\x20sure\x20this\x20is\x20the\x20user\x27s\x20requirement\x20and\x20want\x20to\x20skip\x20verification\x20for\x20now,\x20send\x20a\x20final\x20message\x20that\x20includes\x20the\x20feature\x20review\x20link\x20('+_0x2f9d97+')\x20and\x20the\x20token\x20`'+_0x2186b4+_0x4f4430(0x119)};console['log'](JSON['stringify'](_0x210147)),await trackStop(_0x12866a,!![],_0xf21adf);return;}await _0x48f318['IiZKY'](trackStop,_0x12866a,!![],_0xf21adf);return;}catch{await trackStop(_0x12866a,!![],_0xf21adf);return;}}function _0x5f21(_0x4293c1,_0x4eab0f){_0x4293c1=_0x4293c1-0xf8;const _0x7e2be5=_0x7e2b();let _0x5f2167=_0x7e2be5[_0x4293c1];return _0x5f2167;}async function trackStop(_0x2ec9da,_0x3be124,_0x5de40d){const _0x51e1e1=_0x5f21,_0x5210db={'hTPqx':function(_0x2af429,_0x3ebf33){return _0x2af429(_0x3ebf33);},'gONUn':_0x51e1e1(0xfe)};try{const _0x5d444a=_0x5210db[_0x51e1e1(0xfa)](createTelemetryCollector,_0x51e1e1(0x110));await _0x5d444a[_0x51e1e1(0x11d)]({'sessionId':_0x2ec9da??undefined,'hooksEnabled':_0x3be124,'stopAllowed':_0x5de40d}),await _0x5d444a['trackCommandEnd'](_0x5210db['gONUn']);}catch{}}async function transcriptHasToken(_0xf76b30,_0x2702f0){const _0x3d5232=_0x5f21,_0x552305={'MlZcK':function(_0x495df8,_0x21c179,_0x46db7c){return _0x495df8(_0x21c179,_0x46db7c);}};if(!_0xf76b30)return![];const _0x329f02=await _0x552305[_0x3d5232(0x100)](readTranscriptTail,_0xf76b30,0x30d40);return _0x329f02?_0x329f02[_0x3d5232(0x11c)](_0x2702f0):![];}async function readTranscriptTail(_0x2abf2a,_0x4b6eb2){const _0x280fce=_0x5f21;let _0x22aa67=null;try{_0x22aa67=await open(_0x2abf2a,'r');const _0x50269d=await _0x22aa67['stat'](),_0x33bb32=Math[_0x280fce(0x10a)](_0x50269d[_0x280fce(0x115)],_0x4b6eb2);if(_0x33bb32<=0x0)return'';const _0x1ce3d3=Buffer[_0x280fce(0x105)](_0x33bb32);return await _0x22aa67[_0x280fce(0x10d)](_0x1ce3d3,0x0,_0x33bb32,_0x50269d['size']-_0x33bb32),_0x1ce3d3['toString'](_0x280fce(0x118));}catch{return null;}finally{try{await _0x22aa67?.[_0x280fce(0xf8)]();}catch{}}}
1
+ (function(_0xf1c151,_0x1f9053){const _0x2a29f5=_0x1e27,_0x503f24=_0xf1c151();while(!![]){try{const _0x4456fb=parseInt(_0x2a29f5(0x1ba))/0x1*(-parseInt(_0x2a29f5(0x1a9))/0x2)+parseInt(_0x2a29f5(0x1b8))/0x3+parseInt(_0x2a29f5(0x19f))/0x4*(parseInt(_0x2a29f5(0x1a7))/0x5)+parseInt(_0x2a29f5(0x1a1))/0x6+parseInt(_0x2a29f5(0x1a3))/0x7*(parseInt(_0x2a29f5(0x1b7))/0x8)+-parseInt(_0x2a29f5(0x19e))/0x9*(parseInt(_0x2a29f5(0x1b3))/0xa)+-parseInt(_0x2a29f5(0x1ae))/0xb*(parseInt(_0x2a29f5(0x1a5))/0xc);if(_0x4456fb===_0x1f9053)break;else _0x503f24['push'](_0x503f24['shift']());}catch(_0x33042a){_0x503f24['push'](_0x503f24['shift']());}}}(_0x155f,0x53c2a));import{open}from'fs/promises';import{getToken}from'../utils/keychain.js';import{getFeature,concludeSession}from'../utils/featureApi.js';import{getSessionEntry}from'../utils/sessionCache.js';import{getEnabledHookContext}from'./output.js';import{createTelemetryCollector}from'../utils/telemetry.js';function _0x1e27(_0x17b03a,_0x1fda1c){_0x17b03a=_0x17b03a-0x198;const _0x155f67=_0x155f();let _0x1e271a=_0x155f67[_0x17b03a];return _0x1e271a;}export async function stopHook(_0x1d9e73){const _0x33d0e8=_0x1e27,_0x33940f={'jnLVZ':function(_0x27b1a7,_0x2e1506){return _0x27b1a7(_0x2e1506);},'WoEGb':function(_0x12b23d,_0x264706){return _0x12b23d===_0x264706;},'tEMbv':'string','TcFgc':function(_0x33e8f8,_0x90ecf1,_0x24c73c,_0x3c1324){return _0x33e8f8(_0x90ecf1,_0x24c73c,_0x3c1324);},'HvfWg':function(_0x1ff1c8,_0x56f670,_0x30fd79){return _0x1ff1c8(_0x56f670,_0x30fd79);},'FVwim':function(_0x4f77f2,_0x19f7a1,_0x91df7e){return _0x4f77f2(_0x19f7a1,_0x91df7e);},'LaqTV':function(_0x2a90dc,_0x38d1bb){return _0x2a90dc&&_0x38d1bb;},'bkqIr':_0x33d0e8(0x199),'oTDcN':function(_0x4ecb73,_0x3e65dc,_0x244554,_0x907581){return _0x4ecb73(_0x3e65dc,_0x244554,_0x907581);}},_0x138d60=await _0x33940f['jnLVZ'](getEnabledHookContext,_0x1d9e73),_0x15ef18=_0x138d60?.['sessionId']??null,_0x7c3f98=Boolean(_0x138d60?.['input']?.['stop_hook_active']),_0x4eaf56=_0x33940f[_0x33d0e8(0x1b2)](typeof _0x138d60?.[_0x33d0e8(0x1ad)]?.['transcript_path'],_0x33940f['tEMbv'])?_0x138d60['input']['transcript_path']:null;let _0x5b8bff=!![];if(!_0x15ef18){await trackStop(_0x15ef18,![],_0x5b8bff);return;}try{const _0x3a5490=getSessionEntry(_0x15ef18);if(!_0x3a5490){await _0x33940f[_0x33d0e8(0x1aa)](trackStop,_0x15ef18,!![],_0x5b8bff);return;}const _0x194625='https://dashboard.ranger.net/features/'+_0x3a5490['featureId'],_0x2dac25='RANGER_SKIP_VERIFICATION',_0xabf687=await getToken(),_0x57a58f=!_0x7c3f98;let _0x33184a=null,_0x215b69=null;const _0x5aa975=_0x7c3f98&&await _0x33940f[_0x33d0e8(0x1b6)](transcriptHasToken,_0x4eaf56,_0x2dac25),_0x349e2e=await _0x33940f[_0x33d0e8(0x1a0)](transcriptHasToken,_0x4eaf56,_0x194625);if(_0xabf687)try{const _0x277492=await getFeature(_0x3a5490[_0x33d0e8(0x1b9)]);_0x33184a=_0x277492['name']??null,_0x215b69=_0x277492['currentSessionId']??null;}catch{}if(_0x33940f['LaqTV'](_0xabf687,_0x215b69))try{await concludeSession(_0x3a5490[_0x33d0e8(0x1b9)],_0x215b69);}catch(_0x257c97){if(_0x5aa975){await _0x33940f[_0x33d0e8(0x1aa)](trackStop,_0x15ef18,!![],_0x5b8bff);return;}_0x5b8bff=![];const _0x3a6269=_0x257c97 instanceof Error?_0x257c97['message']:String(_0x257c97),_0x5abe42={'decision':_0x33940f[_0x33d0e8(0x19d)],'reason':_0x33d0e8(0x1b1)+(_0x33184a?'\x20for\x20\x22'+_0x33184a+'\x22':'')+_0x33d0e8(0x1af)+_0x3a6269+_0x33d0e8(0x1a2)+_0x194625+')\x20and\x20the\x20token\x20`'+_0x2dac25+_0x33d0e8(0x1b0)};console['log'](JSON['stringify'](_0x5abe42)),await _0x33940f['TcFgc'](trackStop,_0x15ef18,!![],_0x5b8bff);return;}await _0x33940f[_0x33d0e8(0x1ab)](trackStop,_0x15ef18,!![],_0x5b8bff);return;}catch{await trackStop(_0x15ef18,!![],_0x5b8bff);return;}}async function trackStop(_0x409a34,_0x1e55c8,_0x17c1b9){const _0x153df1=_0x1e27,_0x9703fb={'RBYPd':function(_0x275ee5,_0x1f45f6){return _0x275ee5??_0x1f45f6;}};try{const _0x698c2c=createTelemetryCollector(_0x153df1(0x1a6));await _0x698c2c[_0x153df1(0x19b)]({'sessionId':_0x9703fb['RBYPd'](_0x409a34,undefined),'hooksEnabled':_0x1e55c8,'stopAllowed':_0x17c1b9}),await _0x698c2c[_0x153df1(0x1b4)](_0x153df1(0x19a));}catch{}}function _0x155f(){const _0x400f9e=[':\x0a\x0a','`,\x20then\x20run\x20/exit\x20again.','Failed\x20to\x20conclude\x20Ranger\x20feature\x20review\x20session','WoEGb','70mDePxW','trackCommandEnd','toString','HvfWg','213544FrPdDN','1875999AmwICz','featureId','317494mKmEOD','stat','block','success','trackCommandStart','utf8','bkqIr','211419etLLUU','87508Costvf','FVwim','3539898PhzqLZ','\x0a\x0aThis\x20is\x20most\x20likely\x20due\x20to\x20pending\x20scenarios\x20that\x20need\x20to\x20be\x20verified.\x20Please\x20resolve\x20the\x20issue\x20or\x20resume\x20later\x20with:\x0a\x20\x20ranger\x20resume\x0a\x0aIf\x20you\x20are\x20extremely\x20sure\x20this\x20is\x20the\x20user\x27s\x20requirement\x20and\x20want\x20to\x20skip\x20verification\x20for\x20now,\x20send\x20a\x20final\x20message\x20that\x20includes\x20the\x20feature\x20review\x20link\x20(','70PnwoTq','close','192lRoZLs','hook:stop','15fSJrYQ','size','2RihgHh','TcFgc','oTDcN','alloc','input','496969EYyuQr'];_0x155f=function(){return _0x400f9e;};return _0x155f();}async function transcriptHasToken(_0x40f5fb,_0x1bd628){if(!_0x40f5fb)return![];const _0x3b2004=await readTranscriptTail(_0x40f5fb,0x30d40);return _0x3b2004?_0x3b2004['includes'](_0x1bd628):![];}async function readTranscriptTail(_0x2161ac,_0x49236b){const _0x162947=_0x1e27,_0x205a89={'BzQzO':function(_0x50492a,_0x497b33){return _0x50492a<=_0x497b33;},'neSbD':function(_0x310683,_0x58eacf){return _0x310683-_0x58eacf;},'fwZRo':_0x162947(0x19c)};let _0x47f8b0=null;try{_0x47f8b0=await open(_0x2161ac,'r');const _0x4fea06=await _0x47f8b0[_0x162947(0x198)](),_0x407108=Math['min'](_0x4fea06[_0x162947(0x1a8)],_0x49236b);if(_0x205a89['BzQzO'](_0x407108,0x0))return'';const _0x209e19=Buffer[_0x162947(0x1ac)](_0x407108);return await _0x47f8b0['read'](_0x209e19,0x0,_0x407108,_0x205a89['neSbD'](_0x4fea06['size'],_0x407108)),_0x209e19[_0x162947(0x1b5)](_0x205a89['fwZRo']);}catch{return null;}finally{try{await _0x47f8b0?.[_0x162947(0x1a4)]();}catch{}}}
@@ -1 +1 @@
1
- (function(_0x30f01a,_0x1fdb45){var _0x5b9e85=_0x1f44,_0x3bbec5=_0x30f01a();while(!![]){try{var _0x4db672=-parseInt(_0x5b9e85(0x13e))/0x1+parseInt(_0x5b9e85(0x143))/0x2+parseInt(_0x5b9e85(0x144))/0x3+-parseInt(_0x5b9e85(0x13f))/0x4+-parseInt(_0x5b9e85(0x142))/0x5*(-parseInt(_0x5b9e85(0x141))/0x6)+-parseInt(_0x5b9e85(0x140))/0x7+-parseInt(_0x5b9e85(0x145))/0x8;if(_0x4db672===_0x1fdb45)break;else _0x3bbec5['push'](_0x3bbec5['shift']());}catch(_0x375106){_0x3bbec5['push'](_0x3bbec5['shift']());}}}(_0x24d8,0x60e9a));export{addEnv}from'./addEnv.js';function _0x1f44(_0x1eb4ee,_0x362dd7){_0x1eb4ee=_0x1eb4ee-0x13e;var _0x24d816=_0x24d8();var _0x1f448e=_0x24d816[_0x1eb4ee];return _0x1f448e;}export{clean}from'./clean.js';export{login}from'./login.js';function _0x24d8(){var _0x877e22=['1367709KwYNEg','77160Ealakc','250TyHSCl','1039534eKMVIC','2043183cWmPDb','7587256zBIrLm','96863jlhkAx','824868JcNMFz'];_0x24d8=function(){return _0x877e22;};return _0x24d8();}export{start}from'./start.js';export{useEnv}from'./useEnv.js';export{updateEnv}from'./updateEnv.js';export{update}from'./update.js';export{skillup}from'./skillup.js';export{envList}from'./env.js';export{hook}from'./hook.js';export{setupCi}from'./setupCi.js';
1
+ (function(_0x45a93e,_0x3df5f8){var _0x54bfdc=_0x2688,_0x4e56b9=_0x45a93e();while(!![]){try{var _0x2b321d=parseInt(_0x54bfdc(0x106))/0x1*(-parseInt(_0x54bfdc(0x105))/0x2)+-parseInt(_0x54bfdc(0x102))/0x3+-parseInt(_0x54bfdc(0x104))/0x4*(-parseInt(_0x54bfdc(0x107))/0x5)+-parseInt(_0x54bfdc(0x109))/0x6+parseInt(_0x54bfdc(0x10a))/0x7+-parseInt(_0x54bfdc(0x103))/0x8*(parseInt(_0x54bfdc(0x101))/0x9)+parseInt(_0x54bfdc(0x108))/0xa;if(_0x2b321d===_0x3df5f8)break;else _0x4e56b9['push'](_0x4e56b9['shift']());}catch(_0x157c72){_0x4e56b9['push'](_0x4e56b9['shift']());}}}(_0x7a30,0x34c7a));export{addEnv}from'./addEnv.js';export{clean}from'./clean.js';export{login}from'./login.js';export{start}from'./start.js';export{useEnv}from'./useEnv.js';export{updateEnv}from'./updateEnv.js';export{update}from'./update.js';export{skillup}from'./skillup.js';function _0x2688(_0x47af05,_0x310be3){_0x47af05=_0x47af05-0x101;var _0x7a3076=_0x7a30();var _0x2688ad=_0x7a3076[_0x47af05];return _0x2688ad;}export{envList}from'./env.js';export{hook}from'./hook.js';export{setupCi}from'./setupCi.js';function _0x7a30(){var _0x4f9f9a=['445686TlophT','8tOaXCL','546328qjHMqx','40XEiCTI','1417nHSavy','5jvGEkX','9337610cBSgeq','2463486YnQfUu','1080128MWhPTp','3788802UxhPrK'];_0x7a30=function(){return _0x4f9f9a;};return _0x7a30();}
@@ -1 +1 @@
1
- (function(_0x30279c,_0x5e7f01){const _0x331ddc=_0x12c5,_0x2d9e78=_0x30279c();while(!![]){try{const _0x362e66=parseInt(_0x331ddc(0x185))/0x1*(parseInt(_0x331ddc(0x18e))/0x2)+parseInt(_0x331ddc(0x18d))/0x3*(parseInt(_0x331ddc(0x189))/0x4)+parseInt(_0x331ddc(0x181))/0x5*(parseInt(_0x331ddc(0x184))/0x6)+parseInt(_0x331ddc(0x183))/0x7*(-parseInt(_0x331ddc(0x186))/0x8)+parseInt(_0x331ddc(0x18f))/0x9+parseInt(_0x331ddc(0x182))/0xa+-parseInt(_0x331ddc(0x180))/0xb*(parseInt(_0x331ddc(0x187))/0xc);if(_0x362e66===_0x5e7f01)break;else _0x2d9e78['push'](_0x2d9e78['shift']());}catch(_0x553e50){_0x2d9e78['push'](_0x2d9e78['shift']());}}}(_0x2106,0x99084));import{runDeviceAuthFlow}from'./utils/deviceAuth.js';import{getCurrentUser}from'./utils/userApi.js';function _0x12c5(_0x343520,_0x5cc41b){_0x343520=_0x343520-0x180;const _0x21062c=_0x2106();let _0x12c52f=_0x21062c[_0x343520];return _0x12c52f;}function _0x2106(){const _0x5ac929=['785604zSzcYA','2040Fdryky','3900Toruzr','Login\x20failed:\x20','45592BnkwnJ','weUzb','\x0a✅\x20API\x20key\x20stored\x20successfully','log','177CNZmlq','2kRqKTW','4578723JvNHJI','\x0a✅\x20Logged\x20in\x20to\x20','organizationName','stdin','72545ANStWZ','2920585GFUqIV','3789630KzgkAL','20419obEGFp','12LqLwyD'];_0x2106=function(){return _0x5ac929;};return _0x2106();}export async function login(){const _0x5bfc9b=_0x12c5,_0xd6331b={'HAHvC':function(_0x15e055){return _0x15e055();},'weUzb':_0x5bfc9b(0x18b),'WVhzL':function(_0x31de83,_0xe115fb){return _0x31de83 instanceof _0xe115fb;}},_0x343b1e=process[_0x5bfc9b(0x192)]['isTTY']&&process['stdout']['isTTY'];if(!_0x343b1e)throw new Error('Login\x20requires\x20an\x20interactive\x20terminal.\x20In\x20CI,\x20use:\x20ranger\x20setup\x20[token]\x20or\x20set\x20RANGER_CLI_TOKEN.');try{const _0x2e5fbe=await _0xd6331b['HAHvC'](runDeviceAuthFlow),_0x2ad12b=await getCurrentUser(_0x2e5fbe);_0x2ad12b['success']?console['log'](_0x5bfc9b(0x190)+_0x2ad12b['user'][_0x5bfc9b(0x191)]):console[_0x5bfc9b(0x18c)](_0xd6331b[_0x5bfc9b(0x18a)]);}catch(_0x44dcba){throw new Error(_0x5bfc9b(0x188)+(_0xd6331b['WVhzL'](_0x44dcba,Error)?_0x44dcba['message']:_0x44dcba));}}
1
+ (function(_0x5ee335,_0x9e2409){const _0x3e4406=_0x5609,_0x3b91ca=_0x5ee335();while(!![]){try{const _0x983b08=-parseInt(_0x3e4406(0x190))/0x1*(-parseInt(_0x3e4406(0x197))/0x2)+parseInt(_0x3e4406(0x193))/0x3*(-parseInt(_0x3e4406(0x18f))/0x4)+-parseInt(_0x3e4406(0x18c))/0x5*(-parseInt(_0x3e4406(0x19a))/0x6)+-parseInt(_0x3e4406(0x18d))/0x7*(parseInt(_0x3e4406(0x188))/0x8)+parseInt(_0x3e4406(0x198))/0x9+-parseInt(_0x3e4406(0x192))/0xa*(parseInt(_0x3e4406(0x187))/0xb)+parseInt(_0x3e4406(0x196))/0xc;if(_0x983b08===_0x9e2409)break;else _0x3b91ca['push'](_0x3b91ca['shift']());}catch(_0x328c1e){_0x3b91ca['push'](_0x3b91ca['shift']());}}}(_0x1e1b,0x7b9a7));import{runDeviceAuthFlow}from'./utils/deviceAuth.js';function _0x5609(_0x4540dc,_0x4956b6){_0x4540dc=_0x4540dc-0x187;const _0x1e1bfa=_0x1e1b();let _0x56092b=_0x1e1bfa[_0x4540dc];return _0x56092b;}import{getCurrentUser}from'./utils/userApi.js';export async function login(){const _0x222303=_0x5609,_0x121c6e={'jVLBg':function(_0x44f22b){return _0x44f22b();},'egvOu':_0x222303(0x189),'cnhFT':function(_0x48afe,_0xd72e9c){return _0x48afe instanceof _0xd72e9c;}},_0x467f6e=process['stdin']['isTTY']&&process[_0x222303(0x195)][_0x222303(0x18a)];if(!_0x467f6e)throw new Error('Login\x20requires\x20an\x20interactive\x20terminal.\x20In\x20CI,\x20use:\x20ranger\x20setup\x20[token]\x20or\x20set\x20RANGER_CLI_TOKEN.');try{const _0x555391=await _0x121c6e['jVLBg'](runDeviceAuthFlow),_0x4e61d7=await getCurrentUser(_0x555391);_0x4e61d7[_0x222303(0x18b)]?console[_0x222303(0x18e)]('\x0a✅\x20Logged\x20in\x20to\x20'+_0x4e61d7[_0x222303(0x191)]['organizationName']):console['log'](_0x121c6e['egvOu']);}catch(_0x2da61e){throw new Error(_0x222303(0x199)+(_0x121c6e[_0x222303(0x19b)](_0x2da61e,Error)?_0x2da61e[_0x222303(0x194)]:_0x2da61e));}}function _0x1e1b(){const _0x3d7a81=['67085pGngJj','752948wzndtw','log','1048976jQFzsj','1138NAtSrX','user','40COscMg','6oQsNUx','message','stdout','13102056nhnMps','358DnTODQ','1631700YmcwAa','Login\x20failed:\x20','234cinQLT','cnhFT','3465RjMVcj','72qHBosj','\x0a✅\x20API\x20key\x20stored\x20successfully','isTTY','success'];_0x1e1b=function(){return _0x3d7a81;};return _0x1e1b();}
@@ -1 +1 @@
1
- (function(_0x124e3b,_0x3d34d2){const _0xcdedba=_0x3199,_0x17629a=_0x124e3b();while(!![]){try{const _0x30e35f=-parseInt(_0xcdedba(0xe1))/0x1+-parseInt(_0xcdedba(0x107))/0x2*(-parseInt(_0xcdedba(0xeb))/0x3)+-parseInt(_0xcdedba(0xed))/0x4+-parseInt(_0xcdedba(0xe6))/0x5*(-parseInt(_0xcdedba(0x10f))/0x6)+parseInt(_0xcdedba(0xe2))/0x7*(-parseInt(_0xcdedba(0x111))/0x8)+-parseInt(_0xcdedba(0xff))/0x9+parseInt(_0xcdedba(0xe3))/0xa*(parseInt(_0xcdedba(0xe0))/0xb);if(_0x30e35f===_0x3d34d2)break;else _0x17629a['push'](_0x17629a['shift']());}catch(_0x1a47ab){_0x17629a['push'](_0x17629a['shift']());}}}(_0x41e6,0x623e6));import{join}from'path';import{existsSync}from'fs';import _0x36aa18 from'inquirer';import{skillup}from'../skillup.js';function _0x41e6(){const _0xe219d5=['SKILL.md','FgERJ','already\x20enabled','❌\x20Failed\x20to\x20add\x20marketplace:','plugin','wwYot','548685JFLuiI','project','\x0aYou\x20can\x20install\x20manually\x20with:','Would\x20you\x20like\x20to\x20install\x20skills?','KfKAL','ygwdl','confirm','bZBaV','8318fwCaMP','success','SucmP','user','push','\x0aInstalling\x20Claude\x20Code\x20plugin\x20(','✓\x20Claude\x20Code\x20plugin\x20enabled','install','55794IPaKEb','GuZvC','278632NEsApZ','ranger@trailhead','error','ranger','hUrUM','UpyPk','prompt','NnCAw','mQXLC','log','2181817HkRyAW','41904KixMZd','133GSZKXL','50ATMpth','DJGOz','enable','105wtiYrw','wantsSkillup','\x20\x20claude\x20plugin\x20marketplace\x20add\x20ranger-testing/trailhead','ElION','CGwVM','51ZnRWbP','\x20\x20claude\x20plugin\x20install\x20ranger@trailhead\x20--scope\x20','362764ZowEyP','✓\x20Claude\x20Code\x20plugin\x20installed\x20successfully','Where\x20should\x20the\x20plugin\x20be\x20installed?','includes','.claude','✓\x20Ranger\x20skills\x20already\x20installed','pluginScope','add','Project\x20(shared\x20with\x20team\x20via\x20git)','EOkse','nmfVe','❌\x20Failed\x20to\x20install\x20plugin:'];_0x41e6=function(){return _0xe219d5;};return _0x41e6();}import{runClaudeCommand,isMarketplaceAdded,isPluginInstalled}from'../utils/claudePlugin.js';function _0x3199(_0x48e88f,_0x57caa0){_0x48e88f=_0x48e88f-0xd7;const _0x41e60b=_0x41e6();let _0x319933=_0x41e60b[_0x48e88f];return _0x319933;}import{getProjectRoot,getSkillsDir}from'../utils/claudeConfig.js';export async function ensureClaudePlugin(_0x123693){const _0x3e8412=_0x3199,_0x1e290c={'KfKAL':function(_0x29a277,_0x3487c9){return _0x29a277(_0x3487c9);},'ygwdl':function(_0x8651d5,_0x56dc88,_0x2e4da5){return _0x8651d5(_0x56dc88,_0x2e4da5);},'ElION':_0x3e8412(0xf1),'DJGOz':_0x3e8412(0x100),'hUrUM':'list','EOkse':_0x3e8412(0xef),'NkIqI':'User\x20(available\x20in\x20all\x20your\x20projects)','FgERJ':_0x3e8412(0xf5),'SucmP':'trailhead','hxDYm':_0x3e8412(0xfd),'krpTZ':'marketplace','ikBce':_0x3e8412(0xfc),'CGwVM':_0x3e8412(0xd7),'bZBaV':'--scope','mQXLC':_0x3e8412(0x101),'wwYot':_0x3e8412(0x10d)},_0x2e4327=await isPluginInstalled(_0x3e8412(0xd7));if(_0x2e4327)return console['log']('✓\x20Claude\x20Code\x20plugin\x20already\x20installed'),![];const _0x184a04=_0x1e290c[_0x3e8412(0x103)](existsSync,_0x1e290c[_0x3e8412(0x104)](join,getProjectRoot(),_0x1e290c[_0x3e8412(0xe9)]));let _0x3a459e;if(_0x123693)_0x3a459e=_0x123693;else{if(_0x184a04)_0x3a459e=_0x1e290c[_0x3e8412(0xe4)];else{console[_0x3e8412(0xdf)]('\x0a📦\x20Claude\x20Code\x20Plugin\x0a');const _0x102963=await _0x36aa18[_0x3e8412(0xdc)]([{'type':_0x1e290c[_0x3e8412(0xda)],'name':_0x3e8412(0xf3),'message':_0x1e290c[_0x3e8412(0xf6)],'choices':[{'name':_0x1e290c['NkIqI'],'value':_0x3e8412(0x10a)},{'name':_0x1e290c[_0x3e8412(0xfa)],'value':_0x1e290c['DJGOz']}],'default':_0x3e8412(0x10a)}]);_0x3a459e=_0x102963['pluginScope'];}}console['log'](_0x3e8412(0x10c)+_0x3a459e+'\x20level)...\x0a');const _0x5d6933=await isMarketplaceAdded(_0x1e290c[_0x3e8412(0x109)]);let _0xb10d88=_0x5d6933;if(_0x5d6933)console['log']('✓\x20Marketplace\x20already\x20added');else{const _0x37ba21=await runClaudeCommand([_0x1e290c['hxDYm'],_0x1e290c['krpTZ'],_0x3e8412(0xf4),'ranger-testing/trailhead']);!_0x37ba21[_0x3e8412(0x108)]?(console['error'](_0x1e290c['ikBce'],_0x37ba21['error']),console['log']('\x0aYou\x20can\x20install\x20manually\x20with:'),console[_0x3e8412(0xdf)](_0x3e8412(0xe8)),console['log'](_0x3e8412(0xec)+_0x3a459e)):_0xb10d88=!![];}if(_0xb10d88){const _0x22ba14=await runClaudeCommand(['plugin',_0x3e8412(0x10e),_0x1e290c[_0x3e8412(0xea)],_0x1e290c[_0x3e8412(0x106)],_0x3a459e]);if(!_0x22ba14[_0x3e8412(0x108)])console[_0x3e8412(0xd8)](_0x3e8412(0xf8),_0x22ba14['error']),console[_0x3e8412(0xdf)](_0x1e290c[_0x3e8412(0xde)]),console[_0x3e8412(0xdf)]('\x20\x20claude\x20plugin\x20install\x20ranger@trailhead\x20--scope\x20'+_0x3a459e);else{console['log'](_0x3e8412(0xee));const _0x95147a=[_0x1e290c['hxDYm'],_0x3e8412(0xe5),_0x1e290c[_0x3e8412(0xea)]];_0x3a459e===_0x1e290c[_0x3e8412(0xe4)]&&_0x95147a[_0x3e8412(0x10b)](_0x1e290c[_0x3e8412(0x106)],_0x1e290c[_0x3e8412(0xe4)]);const _0x1c050c=await runClaudeCommand(_0x95147a,{'captureOutput':!![]}),_0x1b14fc=_0x1c050c['output']?.[_0x3e8412(0xf0)](_0x3e8412(0xfb));!_0x1c050c['success']&&!_0x1b14fc?console['error']('⚠\x20Failed\x20to\x20enable\x20plugin:',_0x1c050c['error']):console[_0x3e8412(0xdf)](_0x1e290c[_0x3e8412(0xfe)]);}}return!![];}export async function ensureClaudeSkills(_0x3f5b01){const _0x4f657f=_0x3199,_0xf6618a={'GuZvC':function(_0x3ba752,_0x3cb5be,_0x237022,_0x48410b){return _0x3ba752(_0x3cb5be,_0x237022,_0x48410b);},'Uozqb':_0x4f657f(0xd9),'izBRo':_0x4f657f(0xf9),'WkaSj':function(_0x3e2173,_0x3000ab){return _0x3e2173||_0x3000ab;},'oPxLK':function(_0x285ee8,_0x2be24b){return _0x285ee8(_0x2be24b);},'NnCAw':'.claude','UpyPk':function(_0x40b739,_0x243eab){return _0x40b739(_0x243eab);},'AqwGU':_0x4f657f(0xe7),'lUHbA':_0x4f657f(0x102),'nmfVe':function(_0x31e169,_0x22a7dc){return _0x31e169(_0x22a7dc);}},_0x335af5=existsSync(_0xf6618a[_0x4f657f(0x110)](join,getSkillsDir('user'),_0xf6618a['Uozqb'],_0xf6618a['izBRo'])),_0x415f8f=existsSync(join(getSkillsDir(_0x4f657f(0x100)),'ranger','SKILL.md'));if(_0xf6618a['WkaSj'](_0x335af5,_0x415f8f))return console[_0x4f657f(0xdf)](_0x4f657f(0xf2)),![];const _0x2dd972=_0xf6618a['oPxLK'](existsSync,join(getProjectRoot(),_0xf6618a[_0x4f657f(0xdd)]));let _0x49220c=!![];if(_0x3f5b01)await _0xf6618a[_0x4f657f(0xdb)](skillup,{'autoInstall':_0x3f5b01,'suppressUsage':!![]});else{if(_0x2dd972)await skillup({'autoInstall':'project','suppressUsage':!![]});else{const _0x1db5c3=await _0x36aa18[_0x4f657f(0xdc)]([{'type':_0x4f657f(0x105),'name':_0xf6618a['AqwGU'],'message':_0xf6618a['lUHbA'],'default':!![]}]);_0x49220c=_0x1db5c3['wantsSkillup'],_0x49220c&&await _0xf6618a[_0x4f657f(0xf7)](skillup,{'suppressUsage':!![]});}}return _0x49220c;}
1
+ function _0x1d59(){const _0x2e6662=['prompt','5761854uYdghW','Project\x20(shared\x20with\x20team\x20via\x20git)','User\x20(available\x20in\x20all\x20your\x20projects)','add','trailhead','181132ERbGMd','success','EyIFj','3QWYiNa','error','output','--scope','Would\x20you\x20like\x20to\x20install\x20skills?','38025740szdWJg','\x0aYou\x20can\x20install\x20manually\x20with:','\x20\x20claude\x20plugin\x20marketplace\x20add\x20ranger-testing/trailhead','3972794YzkLOo','✓\x20Marketplace\x20already\x20added','1084IDctYb','install','user','eqtOk','8EUMiIJ','rZovv','log','aAlVh','⚠\x20Failed\x20to\x20enable\x20plugin:','wYbuk','project','plugin','1242210MrJaBe','McPTN','DlWPZ','Where\x20should\x20the\x20plugin\x20be\x20installed?','tBFBM','✓\x20Claude\x20Code\x20plugin\x20already\x20installed','18325uvsOFC','push','marketplace','✓\x20Ranger\x20skills\x20already\x20installed','15170805tJlqlx','already\x20enabled','XfAyn','\x20\x20claude\x20plugin\x20install\x20ranger@trailhead\x20--scope\x20'];_0x1d59=function(){return _0x2e6662;};return _0x1d59();}(function(_0x2c2edf,_0x156b66){const _0x40c511=_0x5616,_0xe5a6c2=_0x2c2edf();while(!![]){try{const _0x2e8972=parseInt(_0x40c511(0x129))/0x1+parseInt(_0x40c511(0x13d))/0x2*(parseInt(_0x40c511(0x140))/0x3)+-parseInt(_0x40c511(0x11d))/0x4*(parseInt(_0x40c511(0x12f))/0x5)+-parseInt(_0x40c511(0x138))/0x6+-parseInt(_0x40c511(0x148))/0x7+parseInt(_0x40c511(0x121))/0x8*(-parseInt(_0x40c511(0x133))/0x9)+parseInt(_0x40c511(0x145))/0xa;if(_0x2e8972===_0x156b66)break;else _0xe5a6c2['push'](_0xe5a6c2['shift']());}catch(_0x5d74e4){_0xe5a6c2['push'](_0xe5a6c2['shift']());}}}(_0x1d59,0xe2b7f));import{join}from'path';import{existsSync}from'fs';import _0x169265 from'inquirer';function _0x5616(_0x178c42,_0x3eb81f){_0x178c42=_0x178c42-0x11d;const _0x1d5989=_0x1d59();let _0x561632=_0x1d5989[_0x178c42];return _0x561632;}import{skillup}from'../skillup.js';import{runClaudeCommand,isMarketplaceAdded,isPluginInstalled}from'../utils/claudePlugin.js';import{getProjectRoot,getSkillsDir}from'../utils/claudeConfig.js';export async function ensureClaudePlugin(_0x477b9c){const _0x11f80f=_0x5616,_0x27b71e={'oBaiI':function(_0x89f577,_0x71f190){return _0x89f577(_0x71f190);},'tBFBM':'ranger@trailhead','rZovv':function(_0x2a6a52,_0x2147e3){return _0x2a6a52(_0x2147e3);},'jXinm':function(_0x364165,_0x3d6c98,_0x2c01df){return _0x364165(_0x3d6c98,_0x2c01df);},'rsovY':'.claude','MhzOF':_0x11f80f(0x127),'nbcGO':'list','OHzIt':_0x11f80f(0x13a),'XfAyn':'user','lkxsk':_0x11f80f(0x139),'rUZWY':function(_0x23fee5,_0x5ba764){return _0x23fee5(_0x5ba764);},'jHDLs':_0x11f80f(0x149),'TUtPG':'plugin','wPrDH':_0x11f80f(0x13b),'rPqzO':'ranger-testing/trailhead','bqiZw':function(_0x2e11b0,_0x4a7b9f){return _0x2e11b0(_0x4a7b9f);},'FXRfa':'❌\x20Failed\x20to\x20install\x20plugin:','aAlVh':'✓\x20Claude\x20Code\x20plugin\x20installed\x20successfully','OfNJd':function(_0x2c1364,_0x41eec0){return _0x2c1364===_0x41eec0;},'vOvzX':function(_0x5367f6,_0x228a76,_0x44e654){return _0x5367f6(_0x228a76,_0x44e654);},'uGKFc':_0x11f80f(0x125)},_0x4d04e1=await _0x27b71e['oBaiI'](isPluginInstalled,_0x27b71e[_0x11f80f(0x12d)]);if(_0x4d04e1)return console[_0x11f80f(0x123)](_0x11f80f(0x12e)),![];const _0x313c09=_0x27b71e[_0x11f80f(0x122)](existsSync,_0x27b71e['jXinm'](join,getProjectRoot(),_0x27b71e['rsovY']));let _0x1d1e53;if(_0x477b9c)_0x1d1e53=_0x477b9c;else{if(_0x313c09)_0x1d1e53=_0x27b71e['MhzOF'];else{console['log']('\x0a📦\x20Claude\x20Code\x20Plugin\x0a');const _0x4e789c=await _0x169265[_0x11f80f(0x137)]([{'type':_0x27b71e['nbcGO'],'name':'pluginScope','message':_0x11f80f(0x12c),'choices':[{'name':_0x27b71e['OHzIt'],'value':_0x27b71e[_0x11f80f(0x135)]},{'name':_0x27b71e['lkxsk'],'value':_0x11f80f(0x127)}],'default':_0x27b71e[_0x11f80f(0x135)]}]);_0x1d1e53=_0x4e789c['pluginScope'];}}console[_0x11f80f(0x123)]('\x0aInstalling\x20Claude\x20Code\x20plugin\x20('+_0x1d1e53+'\x20level)...\x0a');const _0x2c308a=await _0x27b71e['rUZWY'](isMarketplaceAdded,_0x11f80f(0x13c));let _0x502684=_0x2c308a;if(_0x2c308a)console[_0x11f80f(0x123)](_0x27b71e['jHDLs']);else{const _0x3ca0c3=await runClaudeCommand([_0x27b71e['TUtPG'],_0x11f80f(0x131),_0x27b71e['wPrDH'],_0x27b71e['rPqzO']]);!_0x3ca0c3['success']?(console[_0x11f80f(0x141)]('❌\x20Failed\x20to\x20add\x20marketplace:',_0x3ca0c3[_0x11f80f(0x141)]),console[_0x11f80f(0x123)](_0x11f80f(0x146)),console[_0x11f80f(0x123)](_0x11f80f(0x147)),console[_0x11f80f(0x123)]('\x20\x20claude\x20plugin\x20install\x20ranger@trailhead\x20--scope\x20'+_0x1d1e53)):_0x502684=!![];}if(_0x502684){const _0x281be3=await _0x27b71e['bqiZw'](runClaudeCommand,['plugin',_0x11f80f(0x11e),_0x27b71e[_0x11f80f(0x12d)],_0x11f80f(0x143),_0x1d1e53]);if(!_0x281be3[_0x11f80f(0x13e)])console['error'](_0x27b71e['FXRfa'],_0x281be3['error']),console['log']('\x0aYou\x20can\x20install\x20manually\x20with:'),console['log'](_0x11f80f(0x136)+_0x1d1e53);else{console['log'](_0x27b71e[_0x11f80f(0x124)]);const _0x23ba8c=[_0x11f80f(0x128),'enable',_0x27b71e['tBFBM']];_0x27b71e['OfNJd'](_0x1d1e53,_0x27b71e['MhzOF'])&&_0x23ba8c[_0x11f80f(0x130)]('--scope',_0x11f80f(0x127));const _0x214302=await _0x27b71e['vOvzX'](runClaudeCommand,_0x23ba8c,{'captureOutput':!![]}),_0x465140=_0x214302[_0x11f80f(0x142)]?.['includes'](_0x11f80f(0x134));!_0x214302[_0x11f80f(0x13e)]&&!_0x465140?console['error'](_0x27b71e['uGKFc'],_0x214302[_0x11f80f(0x141)]):console[_0x11f80f(0x123)]('✓\x20Claude\x20Code\x20plugin\x20enabled');}}return!![];}export async function ensureClaudeSkills(_0x58caa7){const _0xe5b3f4=_0x5616,_0x1fc88c={'VdrAh':function(_0x23d1cf,_0x4b7404,_0x52deca,_0x5461dd){return _0x23d1cf(_0x4b7404,_0x52deca,_0x5461dd);},'llMyi':_0xe5b3f4(0x11f),'eqtOk':'SKILL.md','McPTN':function(_0x2d0465,_0x6405){return _0x2d0465(_0x6405);},'AOJcg':'project','ymHZR':function(_0x475a0b,_0x39b797,_0x4b0226){return _0x475a0b(_0x39b797,_0x4b0226);},'HlRsK':function(_0xba3512){return _0xba3512();},'wYbuk':function(_0x347a5e,_0x4fd7fc){return _0x347a5e(_0x4fd7fc);},'DlWPZ':'confirm','kjcdV':'wantsSkillup','EyIFj':_0xe5b3f4(0x144)},_0x352e27=existsSync(_0x1fc88c['VdrAh'](join,getSkillsDir(_0x1fc88c['llMyi']),'ranger',_0x1fc88c['eqtOk'])),_0x4bef3f=existsSync(join(_0x1fc88c['McPTN'](getSkillsDir,_0x1fc88c['AOJcg']),'ranger',_0x1fc88c[_0xe5b3f4(0x120)]));if(_0x352e27||_0x4bef3f)return console['log'](_0xe5b3f4(0x132)),![];const _0x37ca29=existsSync(_0x1fc88c['ymHZR'](join,_0x1fc88c['HlRsK'](getProjectRoot),'.claude'));let _0x33ed67=!![];if(_0x58caa7)await _0x1fc88c[_0xe5b3f4(0x12a)](skillup,{'autoInstall':_0x58caa7,'suppressUsage':!![]});else{if(_0x37ca29)await _0x1fc88c[_0xe5b3f4(0x126)](skillup,{'autoInstall':_0xe5b3f4(0x127),'suppressUsage':!![]});else{const _0x884ec6=await _0x169265['prompt']([{'type':_0x1fc88c[_0xe5b3f4(0x12b)],'name':_0x1fc88c['kjcdV'],'message':_0x1fc88c[_0xe5b3f4(0x13f)],'default':!![]}]);_0x33ed67=_0x884ec6['wantsSkillup'],_0x33ed67&&await skillup({'suppressUsage':!![]});}}return _0x33ed67;}
@@ -1 +1 @@
1
- (function(_0x562492,_0x31f4f2){const _0x5def84=_0x3294,_0x44b8d4=_0x562492();while(!![]){try{const _0x37e59e=parseInt(_0x5def84(0xc7))/0x1+-parseInt(_0x5def84(0xa5))/0x2+-parseInt(_0x5def84(0xaf))/0x3*(parseInt(_0x5def84(0xa3))/0x4)+-parseInt(_0x5def84(0xb8))/0x5*(-parseInt(_0x5def84(0xb4))/0x6)+parseInt(_0x5def84(0xc6))/0x7+-parseInt(_0x5def84(0xbc))/0x8*(-parseInt(_0x5def84(0xa9))/0x9)+parseInt(_0x5def84(0xbb))/0xa*(-parseInt(_0x5def84(0xa8))/0xb);if(_0x37e59e===_0x31f4f2)break;else _0x44b8d4['push'](_0x44b8d4['shift']());}catch(_0x6899ee){_0x44b8d4['push'](_0x44b8d4['shift']());}}}(_0x235f,0x3eb20));import{join}from'path';function _0x3294(_0x32b893,_0x4f5c7a){_0x32b893=_0x32b893-0xa3;const _0x235f93=_0x235f();let _0x3294ac=_0x235f93[_0x32b893];return _0x3294ac;}function _0x235f(){const _0x1f8114=['147270QjquwZ','786512YotMBs','project','✓\x20OpenCode\x20plugin\x20configured','ueZcx','jljEX','https://opencode.ai/config.json','log','KiZSH','opencode.json','\x0a📦\x20OpenCode\x20Plugin\x0a','3111983lorUYv','321614pMXWlm','48TpDKXt','parse','255704SicTQg','error','Project\x20(shared\x20with\x20team\x20via\x20git)','517wJsICC','36lEcYdj','plugin','✓\x20OpenCode\x20plugin\x20already\x20configured','kDLgX','User\x20(available\x20in\x20all\x20your\x20projects)','@ranger-testing/opencode-plugin','79452AUoBJp','⚠\x20Failed\x20to\x20read\x20opencode.json.\x20Please\x20add\x20the\x20plugin\x20manually.','QECYJ','Failed\x20to\x20read\x20opencode.json','pluginScope','24330jNvzNn','user','list','RrnlI','290eIcvfQ','$schema','isArray'];_0x235f=function(){return _0x1f8114;};return _0x235f();}import{existsSync}from'fs';import{mkdir,readFile,writeFile}from'fs/promises';import _0x55567a from'inquirer';import{getOpencodeConfigDir}from'../utils/opencodeConfig.js';export async function ensureOpencodePluginConfig(_0x5286b8){const _0x58b98a=_0x3294,_0x425901={'QECYJ':function(_0x435315,_0x1d46d0,_0x429732){return _0x435315(_0x1d46d0,_0x429732);},'kDLgX':function(_0x48f866,_0x42674f){return _0x48f866(_0x42674f);},'KiZSH':'project','gcTww':_0x58b98a(0xc4),'LeVBR':_0x58b98a(0xb6),'gYxJe':'pluginScope','XqAYL':'user','Xxmcw':function(_0x43e12c,_0x27f91b){return _0x43e12c(_0x27f91b);},'RrnlI':_0x58b98a(0xae),'jljEX':_0x58b98a(0xb0),'ueZcx':_0x58b98a(0xb2),'dWbSK':_0x58b98a(0xab)},_0x39fab2=existsSync(_0x425901['QECYJ'](join,_0x425901[_0x58b98a(0xac)](getOpencodeConfigDir,_0x425901[_0x58b98a(0xc3)]),_0x425901['gcTww']));let _0x29252e;if(_0x5286b8)_0x29252e=_0x5286b8;else{if(_0x39fab2)_0x29252e=_0x425901['KiZSH'];else{console[_0x58b98a(0xc2)](_0x58b98a(0xc5));const _0x8761ba=await _0x55567a['prompt']([{'type':_0x425901['LeVBR'],'name':_0x425901['gYxJe'],'message':'Where\x20should\x20the\x20plugin\x20be\x20installed?','choices':[{'name':_0x58b98a(0xad),'value':_0x58b98a(0xb5)},{'name':_0x58b98a(0xa7),'value':_0x58b98a(0xbd)}],'default':_0x425901['XqAYL']}]);_0x29252e=_0x8761ba[_0x58b98a(0xb3)];}}const _0x119d65=join(_0x425901['Xxmcw'](getOpencodeConfigDir,_0x29252e),_0x425901['gcTww']),_0x240a43=_0x425901[_0x58b98a(0xb7)],_0x3c0aaf=_0x58b98a(0xc1);let _0x24d72c={};if(_0x425901[_0x58b98a(0xac)](existsSync,_0x119d65))try{const _0xf1557d=await readFile(_0x119d65,'utf-8');_0x24d72c=JSON[_0x58b98a(0xa4)](_0xf1557d);}catch(_0x1ac74f){return console[_0x58b98a(0xa6)](_0x425901[_0x58b98a(0xc0)]),{'configured':![],'scope':_0x29252e,'error':_0x425901[_0x58b98a(0xbf)],'details':_0x1ac74f};}const _0x161feb=Array[_0x58b98a(0xba)](_0x24d72c['plugin'])?_0x24d72c[_0x58b98a(0xaa)]:[];if(_0x161feb['includes'](_0x240a43))return console[_0x58b98a(0xc2)](_0x425901['dWbSK']),{'configured':![],'scope':_0x29252e};return _0x24d72c[_0x58b98a(0xb9)]=_0x24d72c[_0x58b98a(0xb9)]||_0x3c0aaf,_0x24d72c[_0x58b98a(0xaa)]=[..._0x161feb,_0x240a43],await _0x425901[_0x58b98a(0xb1)](mkdir,getOpencodeConfigDir(_0x29252e),{'recursive':!![]}),await writeFile(_0x119d65,JSON['stringify'](_0x24d72c,null,0x2)+'\x0a'),console['log'](_0x58b98a(0xbe)),{'configured':!![],'scope':_0x29252e};}
1
+ (function(_0x16c6fd,_0x2ce242){const _0x44f619=_0x21ae,_0x4f72ed=_0x16c6fd();while(!![]){try{const _0x1529ce=-parseInt(_0x44f619(0xfa))/0x1*(-parseInt(_0x44f619(0xf3))/0x2)+-parseInt(_0x44f619(0xf6))/0x3*(parseInt(_0x44f619(0x101))/0x4)+parseInt(_0x44f619(0xed))/0x5+parseInt(_0x44f619(0x103))/0x6*(-parseInt(_0x44f619(0xfc))/0x7)+parseInt(_0x44f619(0xe8))/0x8*(-parseInt(_0x44f619(0xec))/0x9)+-parseInt(_0x44f619(0x104))/0xa*(parseInt(_0x44f619(0xf0))/0xb)+parseInt(_0x44f619(0xf5))/0xc;if(_0x1529ce===_0x2ce242)break;else _0x4f72ed['push'](_0x4f72ed['shift']());}catch(_0x382a9f){_0x4f72ed['push'](_0x4f72ed['shift']());}}}(_0x3c95,0xbb4ee));import{join}from'path';function _0x21ae(_0x187eb6,_0x43de09){_0x187eb6=_0x187eb6-0xe7;const _0x3c95db=_0x3c95();let _0x21aea4=_0x3c95db[_0x187eb6];return _0x21aea4;}import{existsSync}from'fs';function _0x3c95(){const _0x42a506=['plugin','7800569ngNjWs','stringify','log','VoTMG','✓\x20OpenCode\x20plugin\x20already\x20configured','248156FfKDjl','opencode.json','6BDHwYJ','60EzIYML','LnmzC','cEHvG','7009048JwiKLy','User\x20(available\x20in\x20all\x20your\x20projects)','$schema','UqDKL','9fCuybY','5394145aDwWFD','⚠\x20Failed\x20to\x20read\x20opencode.json.\x20Please\x20add\x20the\x20plugin\x20manually.','user','1886137YVgqQD','includes','RKgBZ','10370KNWmtT','\x0a📦\x20OpenCode\x20Plugin\x0a','25330404bOWHPF','9TeICTS','utf-8','Failed\x20to\x20read\x20opencode.json','XBUGJ','151CTdMJS'];_0x3c95=function(){return _0x42a506;};return _0x3c95();}import{mkdir,readFile,writeFile}from'fs/promises';import _0x4a003f from'inquirer';import{getOpencodeConfigDir}from'../utils/opencodeConfig.js';export async function ensureOpencodePluginConfig(_0x26787b){const _0x18ca35=_0x21ae,_0x13bb7d={'WShQC':function(_0xf79ba4,_0x5c83f2,_0x10a210){return _0xf79ba4(_0x5c83f2,_0x10a210);},'eJiMm':'project','RKgBZ':_0x18ca35(0x102),'BMrOt':'list','QXWDD':'Where\x20should\x20the\x20plugin\x20be\x20installed?','UqDKL':_0x18ca35(0xe9),'VoTMG':_0x18ca35(0xef),'uBnYz':'Project\x20(shared\x20with\x20team\x20via\x20git)','LnmzC':function(_0x27a5fd,_0xb0bd38,_0x44478a){return _0x27a5fd(_0xb0bd38,_0x44478a);},'blGSJ':function(_0x218a86,_0x6c31b8){return _0x218a86(_0x6c31b8);},'cEHvG':function(_0x1a38c1,_0x30d71c,_0xfb8869){return _0x1a38c1(_0x30d71c,_0xfb8869);},'XBUGJ':_0x18ca35(0xee),'cQgAs':_0x18ca35(0x100),'fCXFC':function(_0x3273d5,_0x3c8e88,_0x6d47c6){return _0x3273d5(_0x3c8e88,_0x6d47c6);}},_0x2e044f=existsSync(_0x13bb7d['WShQC'](join,getOpencodeConfigDir(_0x13bb7d['eJiMm']),_0x13bb7d[_0x18ca35(0xf2)]));let _0x1b1947;if(_0x26787b)_0x1b1947=_0x26787b;else{if(_0x2e044f)_0x1b1947='project';else{console['log'](_0x18ca35(0xf4));const _0x562f06=await _0x4a003f['prompt']([{'type':_0x13bb7d['BMrOt'],'name':'pluginScope','message':_0x13bb7d['QXWDD'],'choices':[{'name':_0x13bb7d[_0x18ca35(0xeb)],'value':_0x13bb7d[_0x18ca35(0xff)]},{'name':_0x13bb7d['uBnYz'],'value':_0x13bb7d['eJiMm']}],'default':_0x13bb7d[_0x18ca35(0xff)]}]);_0x1b1947=_0x562f06['pluginScope'];}}const _0x2a09c2=_0x13bb7d[_0x18ca35(0x105)](join,getOpencodeConfigDir(_0x1b1947),_0x13bb7d['RKgBZ']),_0x562039='@ranger-testing/opencode-plugin',_0x58fae8='https://opencode.ai/config.json';let _0x598596={};if(_0x13bb7d['blGSJ'](existsSync,_0x2a09c2))try{const _0x30af29=await _0x13bb7d[_0x18ca35(0xe7)](readFile,_0x2a09c2,_0x18ca35(0xf7));_0x598596=JSON['parse'](_0x30af29);}catch(_0x3d92e5){return console['error'](_0x13bb7d[_0x18ca35(0xf9)]),{'configured':![],'scope':_0x1b1947,'error':_0x18ca35(0xf8),'details':_0x3d92e5};}const _0x244aca=Array['isArray'](_0x598596[_0x18ca35(0xfb)])?_0x598596['plugin']:[];if(_0x244aca[_0x18ca35(0xf1)](_0x562039))return console[_0x18ca35(0xfe)](_0x13bb7d['cQgAs']),{'configured':![],'scope':_0x1b1947};return _0x598596[_0x18ca35(0xea)]=_0x598596['$schema']||_0x58fae8,_0x598596[_0x18ca35(0xfb)]=[..._0x244aca,_0x562039],await _0x13bb7d['fCXFC'](mkdir,_0x13bb7d['blGSJ'](getOpencodeConfigDir,_0x1b1947),{'recursive':!![]}),await _0x13bb7d['fCXFC'](writeFile,_0x2a09c2,JSON[_0x18ca35(0xfd)](_0x598596,null,0x2)+'\x0a'),console[_0x18ca35(0xfe)]('✓\x20OpenCode\x20plugin\x20configured'),{'configured':!![],'scope':_0x1b1947};}
@@ -1 +1 @@
1
- (function(_0x37c130,_0x59d308){const _0x301ee1=_0x3601,_0x25ae98=_0x37c130();while(!![]){try{const _0x1cfc69=parseInt(_0x301ee1(0x1f8))/0x1*(parseInt(_0x301ee1(0x1c8))/0x2)+parseInt(_0x301ee1(0x1f6))/0x3*(parseInt(_0x301ee1(0x1c1))/0x4)+-parseInt(_0x301ee1(0x1dd))/0x5+-parseInt(_0x301ee1(0x1c2))/0x6*(-parseInt(_0x301ee1(0x1cf))/0x7)+parseInt(_0x301ee1(0x1e7))/0x8+parseInt(_0x301ee1(0x1cd))/0x9+-parseInt(_0x301ee1(0x1cb))/0xa;if(_0x1cfc69===_0x59d308)break;else _0x25ae98['push'](_0x25ae98['shift']());}catch(_0x39a4d0){_0x25ae98['push'](_0x25ae98['shift']());}}}(_0x5b63,0xdae12));import{mkdir,readFile,readdir}from'fs/promises';import{join}from'path';import{existsSync}from'fs';import{authenticate,ensureRangerDir,ensureChromium,writeRangerGitignore}from'./start.js';import{skillup}from'./skillup.js';import{getRangerDir}from'./utils/rangerRoot.js';import{writeActiveProfileName}from'./utils/activeProfile.js';function _0x3601(_0x350e0a,_0x3e520a){_0x350e0a=_0x350e0a-0x1bb;const _0x5b63b8=_0x5b63();let _0x3601dd=_0x5b63b8[_0x350e0a];return _0x3601dd;}import{saveSettings}from'./utils/settings.js';import{decrypt}from'./utils/crypto.js';function _0x5b63(){const _0xa43d1c=['plugin','6955348ihxmMw','6xIChCN','settings.json','path','BMivq','name','auth.json','2kKkXJu','Ugfol','OncLY','39540360zcQtXv','MzUNz','8964450xDwjQY','Auto-detected\x20CI\x20profile:\x20','9222535fNKCor','enybZ','Egogv','skills','baseUrl','Or\x20specify\x20a\x20profile\x20name\x20with\x20--profile\x20and\x20--base-url\x20to\x20create\x20one.','Failed\x20to\x20add\x20marketplace:','log','length','QAUEd','chromium','uoZEb','Ditof','lZPgg','3016110fWRicj','Failed\x20to\x20install\x20plugin:','NWkff','install','PApWW','map','success','OJCCf','bSQHJ','SQjgV','485352VoxFWW','Vtvgl','xkLbj','No\x20CI\x20profiles\x20found\x20in\x20.ranger/ci/.\x20Create\x20one\x20first\x20with:\x20ranger\x20profile\x20add\x20<name>\x20--ci\x0a','gQFCI','nMEAM','mrOYv','\x22\x20has\x20no\x20settings.json.\x20Use\x20--base-url\x20to\x20configure\x20it.','FFVCL','Installing\x20Claude\x20Code\x20plugin\x20(project\x20level)...','ranger-testing/trailhead','trackPhaseStart','--scope','Kxwpz','LYOrI','3chhRyR','trackPhaseEnd','1340727uebJmy','You\x20can\x20install\x20manually:\x20claude\x20plugin\x20install\x20ranger@trailhead\x20--scope\x20project','skipChromium','You\x20can\x20install\x20manually:\x20claude\x20plugin\x20marketplace\x20add\x20ranger-testing/trailhead','✓\x20Skipping\x20Chromium\x20check\x20(--skip-chromium)','profile_activate','profile'];_0x5b63=function(){return _0xa43d1c;};return _0x5b63();}import{getToken}from'./utils/keychain.js';import{runClaudeCommand,isMarketplaceAdded,isPluginInstalled}from'./utils/claudePlugin.js';async function findCiProfile(_0x13ded1){const _0x1a9325=_0x3601,_0x5b0bae={'OncLY':function(_0x27ddad){return _0x27ddad();},'ghbox':function(_0x22fc54,_0x8858b3,_0x2bd828){return _0x22fc54(_0x8858b3,_0x2bd828);},'JcbVc':function(_0x536109,_0x311aec,_0x16897c){return _0x536109(_0x311aec,_0x16897c);},'Ditof':_0x1a9325(0x1d4),'nMEAM':function(_0x2b6180,_0x27aa05){return _0x2b6180+_0x27aa05;},'ZWqlb':_0x1a9325(0x1ea),'QAUEd':function(_0x4bc2c2,_0x6831fe){return _0x4bc2c2===_0x6831fe;},'enybZ':function(_0x3031ec,_0x2fdae0,_0x42720f){return _0x3031ec(_0x2fdae0,_0x42720f);}},_0x26f15b=_0x5b0bae[_0x1a9325(0x1ca)](getRangerDir),_0x520312=_0x5b0bae['ghbox'](join,_0x26f15b,'ci');if(_0x13ded1){const _0x461f35=_0x5b0bae['JcbVc'](join,_0x520312,_0x13ded1);return{'name':_0x13ded1,'path':_0x461f35};}if(!existsSync(_0x520312))throw new Error('No\x20CI\x20profiles\x20found.\x20Create\x20one\x20first\x20with:\x20ranger\x20profile\x20add\x20<name>\x20--ci\x0a'+_0x5b0bae['Ditof']);const _0x3400db=await readdir(_0x520312,{'withFileTypes':!![]}),_0x43e6f5=_0x3400db['filter'](_0xec27b6=>_0xec27b6['isDirectory']())[_0x1a9325(0x1e2)](_0x1b29d2=>_0x1b29d2['name']);if(_0x43e6f5[_0x1a9325(0x1d7)]===0x0)throw new Error(_0x5b0bae[_0x1a9325(0x1ec)](_0x5b0bae['ZWqlb'],_0x5b0bae[_0x1a9325(0x1db)]));if(_0x5b0bae[_0x1a9325(0x1d8)](_0x43e6f5[_0x1a9325(0x1d7)],0x1)){const _0x25ab72=_0x43e6f5[0x0];return console[_0x1a9325(0x1d6)](_0x1a9325(0x1ce)+_0x25ab72),{'name':_0x25ab72,'path':_0x5b0bae[_0x1a9325(0x1d0)](join,_0x520312,_0x25ab72)};}throw new Error('Multiple\x20CI\x20profiles\x20found:\x20'+_0x43e6f5['join'](',\x20')+'.\x20Use\x20--profile\x20to\x20specify\x20which\x20one.');}async function installPluginNonInteractive(){const _0x10b7f1=_0x3601,_0x5067f1={'FFVCL':'ranger@trailhead','mrOYv':_0x10b7f1(0x1f0),'RINfB':function(_0x1aee36,_0x3283b9){return _0x1aee36(_0x3283b9);},'LYOrI':_0x10b7f1(0x1c0),'DUklz':'marketplace','uoZEb':'add','hDBlA':_0x10b7f1(0x1d5),'fuaet':_0x10b7f1(0x1f3),'lZPgg':'project','MzUNz':'✓\x20Claude\x20Code\x20plugin\x20installed'},_0x325e33=await isPluginInstalled(_0x5067f1['FFVCL']);if(_0x325e33)return console[_0x10b7f1(0x1d6)]('✓\x20Claude\x20Code\x20plugin\x20already\x20installed'),![];console[_0x10b7f1(0x1d6)](_0x5067f1[_0x10b7f1(0x1ed)]);const _0x21785c=await isMarketplaceAdded('trailhead');let _0x348f13=_0x21785c;if(_0x21785c)console[_0x10b7f1(0x1d6)]('✓\x20Marketplace\x20already\x20added');else{const _0xa680ff=await _0x5067f1['RINfB'](runClaudeCommand,[_0x5067f1[_0x10b7f1(0x1f5)],_0x5067f1['DUklz'],_0x5067f1[_0x10b7f1(0x1da)],_0x10b7f1(0x1f1)]);!_0xa680ff[_0x10b7f1(0x1e3)]?(console['error'](_0x5067f1['hDBlA'],_0xa680ff['error']),console[_0x10b7f1(0x1d6)](_0x10b7f1(0x1bc))):_0x348f13=!![];}if(_0x348f13){const _0x6201ce=await runClaudeCommand([_0x5067f1['LYOrI'],_0x10b7f1(0x1e0),_0x5067f1[_0x10b7f1(0x1ef)],_0x5067f1['fuaet'],_0x5067f1[_0x10b7f1(0x1dc)]]);!_0x6201ce[_0x10b7f1(0x1e3)]?(console['error'](_0x10b7f1(0x1de),_0x6201ce['error']),console[_0x10b7f1(0x1d6)](_0x10b7f1(0x1f9))):console[_0x10b7f1(0x1d6)](_0x5067f1[_0x10b7f1(0x1cc)]);}return!![];}export async function setupCi(_0x9ba4d4,_0x226f44,_0xff8700){const _0x35aa95=_0x3601,_0xf0a2f8={'Ugfol':'auth','Kxwpz':'dir_setup','bSQHJ':function(_0x16fcd2){return _0x16fcd2();},'Egogv':function(_0x152878,_0xeba4ff,_0x129680){return _0x152878(_0xeba4ff,_0x129680);},'BMivq':'sessions','NWkff':function(_0xe5b7bc,_0x41c057){return _0xe5b7bc(_0x41c057);},'PApWW':_0x35aa95(0x1d9),'gQFCI':_0x35aa95(0x1bd),'Vtvgl':'profile_activate','xkLbj':_0x35aa95(0x1c7),'qRJDa':'✓\x20Encrypted\x20auth\x20verified\x20(will\x20decrypt\x20at\x20runtime)','OJCCf':function(_0x35f171,_0x1b663f){return _0x35f171 instanceof _0x1b663f;},'yOaaF':'\x20\x20No\x20auth\x20state\x20found\x20(app\x20may\x20not\x20require\x20authentication)','SQjgV':'plugin'};console[_0x35aa95(0x1d6)]('\x0a🔧\x20Ranger\x20CI\x20Setup\x0a'),_0xff8700?.[_0x35aa95(0x1f2)](_0xf0a2f8[_0x35aa95(0x1c9)]),await authenticate(_0x9ba4d4),_0xff8700?.['trackPhaseEnd']('auth'),_0xff8700?.['trackPhaseStart'](_0xf0a2f8[_0x35aa95(0x1f4)]);const {path:_0x1de9af,installed:_0x54cf24}=await _0xf0a2f8[_0x35aa95(0x1e5)](ensureRangerDir);await writeRangerGitignore(_0x1de9af);const _0x552dde=_0xf0a2f8['Egogv'](join,_0x1de9af,_0xf0a2f8[_0x35aa95(0x1c5)]);!_0xf0a2f8['NWkff'](existsSync,_0x552dde)&&await mkdir(_0x552dde,{'recursive':!![]});_0xff8700?.['trackPhaseEnd'](_0xf0a2f8[_0x35aa95(0x1f4)],{'installed':_0x54cf24}),_0xff8700?.['trackPhaseStart'](_0xf0a2f8[_0x35aa95(0x1e1)]);let _0x1a0ff5=![];_0x226f44?.[_0x35aa95(0x1bb)]?console['log'](_0xf0a2f8[_0x35aa95(0x1eb)]):_0x1a0ff5=await _0xf0a2f8[_0x35aa95(0x1e5)](ensureChromium);_0xff8700?.[_0x35aa95(0x1f7)](_0x35aa95(0x1d9),{'installed':_0x1a0ff5,'skipped':!!_0x226f44?.['skipChromium']}),_0xff8700?.['trackPhaseStart'](_0xf0a2f8[_0x35aa95(0x1e8)]);const _0x2cabcf=await findCiProfile(_0x226f44?.[_0x35aa95(0x1bf)]);let _0x2d58ba=![];_0x226f44?.['baseUrl']&&(await _0xf0a2f8['Egogv'](mkdir,_0x2cabcf[_0x35aa95(0x1c4)],{'recursive':!![]}),await saveSettings(_0x2cabcf[_0x35aa95(0x1c6)],{'baseUrl':_0x226f44['baseUrl'],'headless':!![]}),console[_0x35aa95(0x1d6)]('✓\x20Created\x20profile\x20settings:\x20baseUrl='+_0x226f44[_0x35aa95(0x1d3)]),_0x2d58ba=!![]);const _0x8c084e=join(_0x2cabcf['path'],_0x35aa95(0x1c3));if(!existsSync(_0x8c084e)&&!_0x2d58ba)throw new Error('CI\x20profile\x20\x22'+_0x2cabcf['name']+_0x35aa95(0x1ee));const _0x4b51ad=join(_0x2cabcf[_0x35aa95(0x1c4)],_0xf0a2f8[_0x35aa95(0x1e9)]),_0x2d4a0e=join(_0x2cabcf[_0x35aa95(0x1c4)],'auth.json.enc'),_0x21147f=existsSync(_0x4b51ad),_0x171788=existsSync(_0x2d4a0e);if(_0x171788)try{const _0x26685d=await _0xf0a2f8['bSQHJ'](getToken);if(!_0x26685d)throw new Error('No\x20API\x20token\x20available\x20for\x20decryption');const _0x9dfc5b=await readFile(_0x2d4a0e);_0xf0a2f8[_0x35aa95(0x1d1)](decrypt,_0x9dfc5b,_0x26685d),console['log'](_0xf0a2f8['qRJDa']);}catch(_0x2de941){const _0x42deea=_0xf0a2f8[_0x35aa95(0x1e4)](_0x2de941,Error)?_0x2de941['message']:_0xf0a2f8['NWkff'](String,_0x2de941);throw new Error('Failed\x20to\x20verify\x20encrypted\x20auth\x20for\x20profile\x20\x22'+_0x2cabcf['name']+'\x22:\x20'+_0x42deea);}else _0x21147f?console[_0x35aa95(0x1d6)]('✓\x20Auth\x20state\x20found'):console['log'](_0xf0a2f8['yOaaF']);await _0xf0a2f8[_0x35aa95(0x1df)](writeActiveProfileName,_0x2cabcf['name']),console['log']('✓\x20Active\x20profile:\x20'+_0x2cabcf[_0x35aa95(0x1c6)]),_0xff8700?.['trackPhaseEnd'](_0x35aa95(0x1be),{'profileName':_0x2cabcf['name'],'hasAuth':_0x21147f,'hasEncryptedAuth':_0x171788,'createdSettings':_0x2d58ba}),_0xff8700?.[_0x35aa95(0x1f2)](_0xf0a2f8[_0x35aa95(0x1e6)]);const _0x3031fe=await _0xf0a2f8[_0x35aa95(0x1e5)](installPluginNonInteractive);_0xff8700?.['trackPhaseEnd']('plugin',{'installed':_0x3031fe}),_0xff8700?.['trackPhaseStart'](_0x35aa95(0x1d2)),await _0xf0a2f8['NWkff'](skillup,{'autoInstall':'project'}),_0xff8700?.[_0x35aa95(0x1f7)](_0x35aa95(0x1d2)),console['log']('\x0a✅\x20Ranger\x20CI\x20setup\x20complete!\x0a');}
1
+ (function(_0x38db59,_0x1d3101){const _0xa605ff=_0x4f8f,_0x1b6efa=_0x38db59();while(!![]){try{const _0x5922cf=-parseInt(_0xa605ff(0xfb))/0x1+-parseInt(_0xa605ff(0x11c))/0x2+-parseInt(_0xa605ff(0x104))/0x3+-parseInt(_0xa605ff(0xfd))/0x4*(-parseInt(_0xa605ff(0x11f))/0x5)+parseInt(_0xa605ff(0x102))/0x6+-parseInt(_0xa605ff(0x109))/0x7+parseInt(_0xa605ff(0x111))/0x8;if(_0x5922cf===_0x1d3101)break;else _0x1b6efa['push'](_0x1b6efa['shift']());}catch(_0x4caa99){_0x1b6efa['push'](_0x1b6efa['shift']());}}}(_0x25bf,0xe95b2));import{mkdir,readFile,readdir}from'fs/promises';import{join}from'path';import{existsSync}from'fs';import{authenticate,ensureRangerDir,ensureChromium,writeRangerGitignore}from'./start.js';import{skillup}from'./skillup.js';import{getRangerDir}from'./utils/rangerRoot.js';import{writeActiveProfileName}from'./utils/activeProfile.js';function _0x25bf(){const _0xdb8106=['XDuSr','236ejhGEa','tdmAP','trackPhaseEnd','You\x20can\x20install\x20manually:\x20claude\x20plugin\x20marketplace\x20add\x20ranger-testing/trailhead','skills','5363670lciiGB','rsHMX','5488995RpqlQO','KEfPG','project','mTsjF','name','7298949wqbBDF','log','aKdih','tLALC','message','isDirectory','nHeav','You\x20can\x20install\x20manually:\x20claude\x20plugin\x20install\x20ranger@trailhead\x20--scope\x20project','33654264ktlqOn','success','ljidU','dir_setup','plugin','ZUMFT','map','KaZke','trackPhaseStart','path','filter','2312026hfheLU','chromium','✓\x20Created\x20profile\x20settings:\x20baseUrl=','79545XaEnwy','baseUrl','Or\x20specify\x20a\x20profile\x20name\x20with\x20--profile\x20and\x20--base-url\x20to\x20create\x20one.','zsjmZ','zTetB','No\x20API\x20token\x20available\x20for\x20decryption','bVARZ','auth','profile_activate','hebPR','auth.json.enc','length','install','✓\x20Claude\x20Code\x20plugin\x20installed','ranger@trailhead','\x22\x20has\x20no\x20settings.json.\x20Use\x20--base-url\x20to\x20configure\x20it.','vewUt','skipChromium','sessions','UuCsn','qphEX','\x22:\x20','error','1055148kAtPWD'];_0x25bf=function(){return _0xdb8106;};return _0x25bf();}import{saveSettings}from'./utils/settings.js';import{decrypt}from'./utils/crypto.js';import{getToken}from'./utils/keychain.js';import{runClaudeCommand,isMarketplaceAdded,isPluginInstalled}from'./utils/claudePlugin.js';async function findCiProfile(_0x3f1fc6){const _0x4e140c=_0x4f8f,_0x39d695={'GJrmH':function(_0x6b1215,_0x4be84e,_0x46b60e){return _0x6b1215(_0x4be84e,_0x46b60e);},'mTsjF':'No\x20CI\x20profiles\x20found.\x20Create\x20one\x20first\x20with:\x20ranger\x20profile\x20add\x20<name>\x20--ci\x0a','mpDsd':function(_0x2f75ee,_0x4cd84e,_0x574a08){return _0x2f75ee(_0x4cd84e,_0x574a08);}},_0x279f5f=getRangerDir(),_0x8cd722=_0x39d695['GJrmH'](join,_0x279f5f,'ci');if(_0x3f1fc6){const _0xe0c1ff=join(_0x8cd722,_0x3f1fc6);return{'name':_0x3f1fc6,'path':_0xe0c1ff};}if(!existsSync(_0x8cd722))throw new Error(_0x39d695[_0x4e140c(0x107)]+_0x4e140c(0x121));const _0x185d70=await readdir(_0x8cd722,{'withFileTypes':!![]}),_0x4ac4f7=_0x185d70[_0x4e140c(0x11b)](_0x40cddf=>_0x40cddf[_0x4e140c(0x10e)]())[_0x4e140c(0x117)](_0x152273=>_0x152273[_0x4e140c(0x108)]);if(_0x4ac4f7[_0x4e140c(0xef)]===0x0)throw new Error('No\x20CI\x20profiles\x20found\x20in\x20.ranger/ci/.\x20Create\x20one\x20first\x20with:\x20ranger\x20profile\x20add\x20<name>\x20--ci\x0a'+_0x4e140c(0x121));if(_0x4ac4f7['length']===0x1){const _0x338892=_0x4ac4f7[0x0];return console['log']('Auto-detected\x20CI\x20profile:\x20'+_0x338892),{'name':_0x338892,'path':_0x39d695['mpDsd'](join,_0x8cd722,_0x338892)};}throw new Error('Multiple\x20CI\x20profiles\x20found:\x20'+_0x4ac4f7['join'](',\x20')+'.\x20Use\x20--profile\x20to\x20specify\x20which\x20one.');}async function installPluginNonInteractive(){const _0x5ef23d=_0x4f8f,_0x5510cd={'XDuSr':function(_0x10ca29,_0x1e22f6){return _0x10ca29(_0x1e22f6);},'BDxGu':_0x5ef23d(0xf2),'tLALC':'Installing\x20Claude\x20Code\x20plugin\x20(project\x20level)...','zTetB':'trailhead','zsjmZ':'✓\x20Marketplace\x20already\x20added','luJIb':function(_0x641471,_0x3232b5){return _0x641471(_0x3232b5);},'ljidU':'add','ZUMFT':'ranger-testing/trailhead','mGJIW':'Failed\x20to\x20add\x20marketplace:','LoQSo':_0x5ef23d(0xf1)},_0x27774a=await _0x5510cd['XDuSr'](isPluginInstalled,_0x5510cd['BDxGu']);if(_0x27774a)return console['log']('✓\x20Claude\x20Code\x20plugin\x20already\x20installed'),![];console['log'](_0x5510cd[_0x5ef23d(0x10c)]);const _0x301624=await _0x5510cd['XDuSr'](isMarketplaceAdded,_0x5510cd[_0x5ef23d(0xe8)]);let _0x14cd9b=_0x301624;if(_0x301624)console[_0x5ef23d(0x10a)](_0x5510cd[_0x5ef23d(0xe7)]);else{const _0x54a990=await _0x5510cd['luJIb'](runClaudeCommand,['plugin','marketplace',_0x5510cd[_0x5ef23d(0x113)],_0x5510cd[_0x5ef23d(0x116)]]);!_0x54a990[_0x5ef23d(0x112)]?(console['error'](_0x5510cd['mGJIW'],_0x54a990[_0x5ef23d(0xfa)]),console[_0x5ef23d(0x10a)](_0x5ef23d(0x100))):_0x14cd9b=!![];}if(_0x14cd9b){const _0x4c94a3=await _0x5510cd[_0x5ef23d(0xfc)](runClaudeCommand,[_0x5ef23d(0x115),_0x5ef23d(0xf0),'ranger@trailhead','--scope',_0x5ef23d(0x106)]);!_0x4c94a3['success']?(console[_0x5ef23d(0xfa)]('Failed\x20to\x20install\x20plugin:',_0x4c94a3[_0x5ef23d(0xfa)]),console[_0x5ef23d(0x10a)](_0x5ef23d(0x110))):console[_0x5ef23d(0x10a)](_0x5510cd['LoQSo']);}return!![];}function _0x4f8f(_0x113d13,_0x1fe693){_0x113d13=_0x113d13-0xe7;const _0x25bfe5=_0x25bf();let _0x4f8fc0=_0x25bfe5[_0x113d13];return _0x4f8fc0;}export async function setupCi(_0x1fab1d,_0x3e9f49,_0x3c8588){const _0x16fbc9=_0x4f8f,_0x86b5f8={'UuCsn':'\x0a🔧\x20Ranger\x20CI\x20Setup\x0a','KEfPG':function(_0x56dedc,_0x3a72cf){return _0x56dedc(_0x3a72cf);},'hebPR':_0x16fbc9(0x114),'qphEX':function(_0x3808b5,_0x592d1d,_0x42791a){return _0x3808b5(_0x592d1d,_0x42791a);},'Thrrn':_0x16fbc9(0xf6),'bVARZ':_0x16fbc9(0x11d),'mniUL':function(_0x3bd14d){return _0x3bd14d();},'efioi':function(_0x19715b,_0x594ecc){return _0x19715b(_0x594ecc);},'aKdih':'settings.json','vwWtL':_0x16fbc9(0xee),'rsHMX':function(_0x30f38e,_0x48e903){return _0x30f38e(_0x48e903);},'OArXA':function(_0x16f2c6){return _0x16f2c6();},'vewUt':'✓\x20Encrypted\x20auth\x20verified\x20(will\x20decrypt\x20at\x20runtime)','QXtGA':function(_0x2edc83,_0xecca99){return _0x2edc83(_0xecca99);},'qGBzX':_0x16fbc9(0xec),'nHeav':_0x16fbc9(0x115),'tdmAP':function(_0x1ede2f,_0x2c9df9){return _0x1ede2f(_0x2c9df9);},'KaZke':_0x16fbc9(0x106),'VCsZR':'skills'};console[_0x16fbc9(0x10a)](_0x86b5f8[_0x16fbc9(0xf7)]),_0x3c8588?.['trackPhaseStart'](_0x16fbc9(0xeb)),await _0x86b5f8['KEfPG'](authenticate,_0x1fab1d),_0x3c8588?.['trackPhaseEnd'](_0x16fbc9(0xeb)),_0x3c8588?.[_0x16fbc9(0x119)](_0x86b5f8[_0x16fbc9(0xed)]);const {path:_0x1b84d6,installed:_0x698623}=await ensureRangerDir();await _0x86b5f8['KEfPG'](writeRangerGitignore,_0x1b84d6);const _0xa84ff5=_0x86b5f8['qphEX'](join,_0x1b84d6,_0x86b5f8['Thrrn']);!_0x86b5f8['KEfPG'](existsSync,_0xa84ff5)&&await _0x86b5f8[_0x16fbc9(0xf8)](mkdir,_0xa84ff5,{'recursive':!![]});_0x3c8588?.[_0x16fbc9(0xff)](_0x86b5f8['hebPR'],{'installed':_0x698623}),_0x3c8588?.[_0x16fbc9(0x119)](_0x86b5f8[_0x16fbc9(0xea)]);let _0x3d6535=![];_0x3e9f49?.['skipChromium']?console[_0x16fbc9(0x10a)]('✓\x20Skipping\x20Chromium\x20check\x20(--skip-chromium)'):_0x3d6535=await _0x86b5f8['mniUL'](ensureChromium);_0x3c8588?.['trackPhaseEnd'](_0x86b5f8['bVARZ'],{'installed':_0x3d6535,'skipped':!!_0x3e9f49?.[_0x16fbc9(0xf5)]}),_0x3c8588?.['trackPhaseStart']('profile_activate');const _0x32b57b=await _0x86b5f8['efioi'](findCiProfile,_0x3e9f49?.['profile']);let _0x3e8eec=![];_0x3e9f49?.['baseUrl']&&(await mkdir(_0x32b57b['path'],{'recursive':!![]}),await saveSettings(_0x32b57b['name'],{'baseUrl':_0x3e9f49[_0x16fbc9(0x120)],'headless':!![]}),console['log'](_0x16fbc9(0x11e)+_0x3e9f49['baseUrl']),_0x3e8eec=!![]);const _0xb17569=join(_0x32b57b[_0x16fbc9(0x11a)],_0x86b5f8[_0x16fbc9(0x10b)]);if(!_0x86b5f8['KEfPG'](existsSync,_0xb17569)&&!_0x3e8eec)throw new Error('CI\x20profile\x20\x22'+_0x32b57b[_0x16fbc9(0x108)]+_0x16fbc9(0xf3));const _0x527555=join(_0x32b57b['path'],'auth.json'),_0xdf6e05=_0x86b5f8['qphEX'](join,_0x32b57b[_0x16fbc9(0x11a)],_0x86b5f8['vwWtL']),_0x5e9568=existsSync(_0x527555),_0x214c65=_0x86b5f8[_0x16fbc9(0x103)](existsSync,_0xdf6e05);if(_0x214c65)try{const _0x15563b=await _0x86b5f8['OArXA'](getToken);if(!_0x15563b)throw new Error(_0x16fbc9(0xe9));const _0x2ee2d2=await _0x86b5f8[_0x16fbc9(0x105)](readFile,_0xdf6e05);_0x86b5f8[_0x16fbc9(0xf8)](decrypt,_0x2ee2d2,_0x15563b),console['log'](_0x86b5f8[_0x16fbc9(0xf4)]);}catch(_0xbbd6f0){const _0xb512a1=_0xbbd6f0 instanceof Error?_0xbbd6f0[_0x16fbc9(0x10d)]:String(_0xbbd6f0);throw new Error('Failed\x20to\x20verify\x20encrypted\x20auth\x20for\x20profile\x20\x22'+_0x32b57b[_0x16fbc9(0x108)]+_0x16fbc9(0xf9)+_0xb512a1);}else _0x5e9568?console[_0x16fbc9(0x10a)]('✓\x20Auth\x20state\x20found'):console[_0x16fbc9(0x10a)]('\x20\x20No\x20auth\x20state\x20found\x20(app\x20may\x20not\x20require\x20authentication)');await _0x86b5f8['QXtGA'](writeActiveProfileName,_0x32b57b['name']),console['log']('✓\x20Active\x20profile:\x20'+_0x32b57b[_0x16fbc9(0x108)]),_0x3c8588?.[_0x16fbc9(0xff)](_0x86b5f8['qGBzX'],{'profileName':_0x32b57b[_0x16fbc9(0x108)],'hasAuth':_0x5e9568,'hasEncryptedAuth':_0x214c65,'createdSettings':_0x3e8eec}),_0x3c8588?.[_0x16fbc9(0x119)](_0x86b5f8['nHeav']);const _0x34bd9d=await installPluginNonInteractive();_0x3c8588?.[_0x16fbc9(0xff)](_0x86b5f8[_0x16fbc9(0x10f)],{'installed':_0x34bd9d}),_0x3c8588?.[_0x16fbc9(0x119)](_0x16fbc9(0x101)),await _0x86b5f8[_0x16fbc9(0xfe)](skillup,{'autoInstall':_0x86b5f8[_0x16fbc9(0x118)]}),_0x3c8588?.[_0x16fbc9(0xff)](_0x86b5f8['VCsZR']),console[_0x16fbc9(0x10a)]('\x0a✅\x20Ranger\x20CI\x20setup\x20complete!\x0a');}
@@ -1 +1 @@
1
- (function(_0xc57c64,_0x1baf08){const _0x42fcd6=_0x3682,_0x40c168=_0xc57c64();while(!![]){try{const _0x3049af=-parseInt(_0x42fcd6(0x21a))/0x1*(-parseInt(_0x42fcd6(0x20b))/0x2)+-parseInt(_0x42fcd6(0x221))/0x3+-parseInt(_0x42fcd6(0x204))/0x4+parseInt(_0x42fcd6(0x1fc))/0x5*(parseInt(_0x42fcd6(0x1f8))/0x6)+-parseInt(_0x42fcd6(0x1f7))/0x7+parseInt(_0x42fcd6(0x200))/0x8+parseInt(_0x42fcd6(0x222))/0x9*(parseInt(_0x42fcd6(0x211))/0xa);if(_0x3049af===_0x1baf08)break;else _0x40c168['push'](_0x40c168['shift']());}catch(_0x32908a){_0x40c168['push'](_0x40c168['shift']());}}}(_0x48e2,0xb58b5));import{basename}from'path';function _0x48e2(){const _0x13770d=['133269JIUtqu','/.claude/skills/','\x20\x20-\x20Open\x20Claude\x20Code\x20in\x20plan\x20mode\x20and\x20run\x20/ranger:enable.\x20Plan\x20out\x20a\x20UI\x20feature\x20with\x20Ranger\x20and\x20watch\x20Ranger\x20test\x20it\x20for\x20you!','KtsYf','claude','user-level','project-level','4080849tZkekQ','9MHXRHT','HHwuk','Heuwc','All\x20projects\x20(','Non-interactive\x20mode:\x20Installing\x20skills\x20at\x20project\x20level\x20(','aamwp','4|1|2|3|5|0','installLevel','10242372NqfuBt','385998xarpaN','opencode','warn','Ydfog','45BCiDwe','To\x20use:','yeGtV','\x0a⚠️\x20\x20No\x20skills\x20were\x20installed.\x0a','382632JcukBm','\x20--opencode','log','/skills/','1106404nGPXMX','tYfik','\x20<your-api-token>','Where\x20should\x20skills\x20be\x20installed?','\x20\x203.\x20Run:\x20ranger\x20skillup','ZzeqS','❌\x20No\x20Ranger\x20API\x20token\x20found.\x0a','8CpfKjj','gvWQW','platform','prompt','stdin','ORtMA','26837830xdWKmv','\x20\x202.\x20Run:\x20ranger\x20setup','ucIFT','project','isTTY','split','\x20\x20-\x20Start\x20OpenCode\x20and\x20run\x20the\x20`ranger_enable`\x20tool\x20to\x20enable\x20hooks.','user','\x20skill'];_0x48e2=function(){return _0x13770d;};return _0x48e2();}import _0x22133a from'inquirer';import{getToken}from'./utils/keychain.js';import{installSkill}from'./utils/skills.js';import{getCurrentVersion}from'./utils/version.js';function _0x3682(_0x20b7ab,_0x15941e){_0x20b7ab=_0x20b7ab-0x1f0;const _0x48e2d1=_0x48e2();let _0x36828a=_0x48e2d1[_0x20b7ab];return _0x36828a;}import{getClaudeConfigDir,getProjectRoot}from'./utils/claudeConfig.js';import{getOpencodeConfigDir}from'./utils/opencodeConfig.js';export async function skillup(_0xbd5123={}){const _0x299f3d=_0x3682,_0x25f49b={'JupzN':'\x0a🎯\x20Ranger\x20Skill\x20Setup\x0a','ZzeqS':function(_0x5ef6dc){return _0x5ef6dc();},'kWnnk':_0x299f3d(0x1f5),'Heuwc':'To\x20get\x20started:','XVhPe':function(_0x335865,_0x5db0a1){return _0x335865===_0x5db0a1;},'ucIFT':_0x299f3d(0x1f9),'yeGtV':'\x20--opencode','pNvgf':function(_0x55da14){return _0x55da14();},'ORtMA':function(_0x305150,_0x3305a5){return _0x305150(_0x3305a5);},'HHwuk':_0x299f3d(0x218),'Ydfog':function(_0x35adad,_0x1b9916){return _0x35adad===_0x1b9916;},'gvWQW':'list','OGyWz':'project','KtsYf':'\x20\x20Failed\x20to\x20install\x20ranger\x20skill:','tYfik':function(_0x2af2b6,_0x19eb5d){return _0x2af2b6 instanceof _0x19eb5d;},'aamwp':_0x299f3d(0x21f),'lKvwn':function(_0x99a60a,_0x3da6d8){return _0x99a60a>_0x3da6d8;},'fdgPF':function(_0x490258,_0x29741a){return _0x490258===_0x29741a;}};console[_0x299f3d(0x202)](_0x25f49b['JupzN']);const _0x1be94c=_0xbd5123[_0x299f3d(0x20d)]??_0x299f3d(0x21e),_0x4048e3=await _0x25f49b[_0x299f3d(0x209)](getToken);if(!_0x4048e3){const _0x4ae764=_0x25f49b['kWnnk'][_0x299f3d(0x216)]('|');let _0x481c3d=0x0;while(!![]){switch(_0x4ae764[_0x481c3d++]){case'0':return;case'1':console[_0x299f3d(0x202)](_0x25f49b[_0x299f3d(0x1f1)]);continue;case'2':console['log']('\x20\x201.\x20Get\x20your\x20API\x20token\x20from\x20https://dashboard.ranger.net/cli');continue;case'3':console[_0x299f3d(0x202)](_0x299f3d(0x212)+(_0x25f49b['XVhPe'](_0x1be94c,_0x299f3d(0x1f9))?_0x299f3d(0x201):'')+_0x299f3d(0x206));continue;case'4':console['log'](_0x299f3d(0x20a));continue;case'5':console['log'](_0x299f3d(0x208)+(_0x1be94c===_0x25f49b['ucIFT']?_0x25f49b[_0x299f3d(0x1fe)]:'')+'\x0a');continue;}break;}}console['log']('✓\x20Found\x20API\x20token');const _0x422114=_0x25f49b['pNvgf'](getProjectRoot),_0x4edbbd=_0x25f49b[_0x299f3d(0x210)](basename,_0x422114),_0x20d457=_0x1be94c===_0x25f49b[_0x299f3d(0x213)]?getOpencodeConfigDir(_0x25f49b['HHwuk'])+'/skills/':getClaudeConfigDir()+_0x299f3d(0x203),_0x4ccdaf=_0x25f49b[_0x299f3d(0x1fb)](_0x1be94c,_0x25f49b[_0x299f3d(0x213)])?_0x422114+'/.opencode/skills/':_0x422114+_0x299f3d(0x21b),_0x1c9fe5=process[_0x299f3d(0x20f)][_0x299f3d(0x215)]&&process['stdout']['isTTY'];let _0x5b00dd;if(_0xbd5123['autoInstall'])_0x5b00dd=_0xbd5123['autoInstall'];else{if(_0x1c9fe5){const _0x19739d=await _0x22133a[_0x299f3d(0x20e)]([{'type':_0x25f49b[_0x299f3d(0x20c)],'name':_0x299f3d(0x1f6),'message':_0x299f3d(0x207),'choices':[{'name':_0x299f3d(0x1f2)+_0x20d457+')','value':_0x299f3d(0x218)},{'name':'This\x20project\x20only\x20('+_0x4ccdaf+')','value':_0x299f3d(0x214)}]}]);_0x5b00dd=_0x19739d['installLevel'];}else _0x5b00dd=_0x25f49b['OGyWz'],console['log'](_0x299f3d(0x1f3)+_0x4ccdaf+')');}let _0x49ad2b=0x0;const _0x3eee6c=getCurrentVersion();console[_0x299f3d(0x202)]('\x0a📦\x20Installing\x20skills...\x0a');try{const _0x407dab=await installSkill('ranger',{'cliVersion':_0x3eee6c,'level':_0x5b00dd,'platform':_0x1be94c});_0x407dab&&_0x49ad2b++;}catch(_0x4973e9){console[_0x299f3d(0x1fa)](_0x25f49b[_0x299f3d(0x21d)],_0x25f49b[_0x299f3d(0x205)](_0x4973e9,Error)?_0x4973e9['message']:_0x4973e9);}if(_0x49ad2b>0x0){const _0x86a2cd=_0x25f49b[_0x299f3d(0x1fb)](_0x5b00dd,_0x25f49b[_0x299f3d(0x1f0)])?_0x25f49b[_0x299f3d(0x1f4)]:_0x299f3d(0x220);console[_0x299f3d(0x202)]('\x0a✅\x20Installed\x20'+_0x49ad2b+'\x20'+_0x86a2cd+_0x299f3d(0x219)+(_0x25f49b['lKvwn'](_0x49ad2b,0x1)?'s':'')+'\x20successfully!\x0a'),!_0xbd5123['suppressUsage']&&(console['log'](_0x299f3d(0x1fd)),_0x25f49b['fdgPF'](_0x1be94c,_0x25f49b['ucIFT'])?console[_0x299f3d(0x202)](_0x299f3d(0x217)):console[_0x299f3d(0x202)](_0x299f3d(0x21c)));}else console[_0x299f3d(0x202)](_0x299f3d(0x1ff));}
1
+ (function(_0xe6a7f2,_0x2cbf5c){const _0x85b9da=_0x5015,_0x276de3=_0xe6a7f2();while(!![]){try{const _0x348089=-parseInt(_0x85b9da(0x132))/0x1*(-parseInt(_0x85b9da(0x137))/0x2)+parseInt(_0x85b9da(0x12e))/0x3+-parseInt(_0x85b9da(0x12b))/0x4+-parseInt(_0x85b9da(0x12a))/0x5*(-parseInt(_0x85b9da(0x12f))/0x6)+-parseInt(_0x85b9da(0x14e))/0x7+-parseInt(_0x85b9da(0x158))/0x8*(parseInt(_0x85b9da(0x129))/0x9)+parseInt(_0x85b9da(0x133))/0xa;if(_0x348089===_0x2cbf5c)break;else _0x276de3['push'](_0x276de3['shift']());}catch(_0x1784f8){_0x276de3['push'](_0x276de3['shift']());}}}(_0x1b2a,0xc4ab6));function _0x1b2a(){const _0x49da5a=['328743OXHyOK','2175fRwhVu','4836120binjeO','\x0a⚠️\x20\x20No\x20skills\x20were\x20installed.\x0a','✓\x20Found\x20API\x20token','1632318wkzewp','13434coTiqj','Non-interactive\x20mode:\x20Installing\x20skills\x20at\x20project\x20level\x20(','\x20\x202.\x20Run:\x20ranger\x20setup','1CTNxwz','20017420ayXsTZ','To\x20get\x20started:','HhEHA','/.claude/skills/','1281746USFHtw','LmwXg','fWCTK','suppressUsage','All\x20projects\x20(','\x20successfully!\x0a','whSDT','autoInstall','YWuZv','prompt','\x20<your-api-token>','opencode','/skills/','\x20\x20Failed\x20to\x20install\x20ranger\x20skill:','waQEy','\x20\x20-\x20Open\x20Claude\x20Code\x20in\x20plan\x20mode\x20and\x20run\x20/ranger:enable.\x20Plan\x20out\x20a\x20UI\x20feature\x20with\x20Ranger\x20and\x20watch\x20Ranger\x20test\x20it\x20for\x20you!','\x20\x203.\x20Run:\x20ranger\x20skillup','\x0a✅\x20Installed\x20','WMRrB','oOHUK','DEmhx','\x0a🎯\x20Ranger\x20Skill\x20Setup\x0a','log','5050815VXKvpU','message','user-level','platform','user','stdin','installLevel','\x20\x20-\x20Start\x20OpenCode\x20and\x20run\x20the\x20`ranger_enable`\x20tool\x20to\x20enable\x20hooks.','project','\x20\x201.\x20Get\x20your\x20API\x20token\x20from\x20https://dashboard.ranger.net/cli','312pFroaD'];_0x1b2a=function(){return _0x49da5a;};return _0x1b2a();}import{basename}from'path';import _0x5eb7b5 from'inquirer';import{getToken}from'./utils/keychain.js';import{installSkill}from'./utils/skills.js';import{getCurrentVersion}from'./utils/version.js';import{getClaudeConfigDir,getProjectRoot}from'./utils/claudeConfig.js';function _0x5015(_0x243825,_0x30b4d8){_0x243825=_0x243825-0x129;const _0x1b2ae2=_0x1b2a();let _0x5015af=_0x1b2ae2[_0x243825];return _0x5015af;}import{getOpencodeConfigDir}from'./utils/opencodeConfig.js';export async function skillup(_0x3247cc={}){const _0x5d6c74=_0x5015,_0x32e985={'fwlTZ':_0x5d6c74(0x14c),'YWuZv':function(_0x1a2dfc){return _0x1a2dfc();},'nTMJj':_0x5d6c74(0x157),'YEtqQ':function(_0x14a55d,_0x4b4d8c){return _0x14a55d===_0x4b4d8c;},'whSDT':'opencode','fWCTK':'\x20--opencode','DEmhx':_0x5d6c74(0x152),'HhEHA':'Where\x20should\x20skills\x20be\x20installed?','vyABs':_0x5d6c74(0x156),'oOHUK':function(_0xe72be6){return _0xe72be6();},'WMRrB':_0x5d6c74(0x144),'LmwXg':function(_0x4c8cf5,_0x6e5f7c){return _0x4c8cf5 instanceof _0x6e5f7c;},'dhtDb':function(_0x2c4e41,_0x2e2d49){return _0x2c4e41>_0x2e2d49;},'TzPmV':'project-level','waQEy':'To\x20use:','CZkQT':_0x5d6c74(0x12c)};console[_0x5d6c74(0x14d)](_0x32e985['fwlTZ']);const _0x290902=_0x3247cc[_0x5d6c74(0x151)]??'claude',_0x194014=await _0x32e985[_0x5d6c74(0x13f)](getToken);if(!_0x194014){console['log']('❌\x20No\x20Ranger\x20API\x20token\x20found.\x0a'),console[_0x5d6c74(0x14d)](_0x5d6c74(0x134)),console['log'](_0x32e985['nTMJj']),console[_0x5d6c74(0x14d)](_0x5d6c74(0x131)+(_0x32e985['YEtqQ'](_0x290902,_0x32e985[_0x5d6c74(0x13d)])?'\x20--opencode':'')+_0x5d6c74(0x141)),console[_0x5d6c74(0x14d)](_0x5d6c74(0x147)+(_0x290902==='opencode'?_0x32e985[_0x5d6c74(0x139)]:'')+'\x0a');return;}console[_0x5d6c74(0x14d)](_0x5d6c74(0x12d));const _0x46100f=getProjectRoot(),_0x2284de=basename(_0x46100f),_0x527d82=_0x290902===_0x5d6c74(0x142)?getOpencodeConfigDir(_0x32e985[_0x5d6c74(0x14b)])+_0x5d6c74(0x143):getClaudeConfigDir()+_0x5d6c74(0x143),_0x2b8535=_0x290902==='opencode'?_0x46100f+'/.opencode/skills/':_0x46100f+_0x5d6c74(0x136),_0x5dbc62=process[_0x5d6c74(0x153)]['isTTY']&&process['stdout']['isTTY'];let _0x9bfb22;if(_0x3247cc[_0x5d6c74(0x13e)])_0x9bfb22=_0x3247cc[_0x5d6c74(0x13e)];else{if(_0x5dbc62){const _0x494c90=await _0x5eb7b5[_0x5d6c74(0x140)]([{'type':'list','name':_0x5d6c74(0x154),'message':_0x32e985[_0x5d6c74(0x135)],'choices':[{'name':_0x5d6c74(0x13b)+_0x527d82+')','value':_0x32e985[_0x5d6c74(0x14b)]},{'name':'This\x20project\x20only\x20('+_0x2b8535+')','value':_0x5d6c74(0x156)}]}]);_0x9bfb22=_0x494c90['installLevel'];}else _0x9bfb22=_0x32e985['vyABs'],console['log'](_0x5d6c74(0x130)+_0x2b8535+')');}let _0x11a77c=0x0;const _0xf38a16=_0x32e985[_0x5d6c74(0x14a)](getCurrentVersion);console[_0x5d6c74(0x14d)]('\x0a📦\x20Installing\x20skills...\x0a');try{const _0x19bdc1=await installSkill('ranger',{'cliVersion':_0xf38a16,'level':_0x9bfb22,'platform':_0x290902});_0x19bdc1&&_0x11a77c++;}catch(_0x5533dc){console['warn'](_0x32e985[_0x5d6c74(0x149)],_0x32e985[_0x5d6c74(0x138)](_0x5533dc,Error)?_0x5533dc[_0x5d6c74(0x14f)]:_0x5533dc);}if(_0x32e985['dhtDb'](_0x11a77c,0x0)){const _0x2ac4a8=_0x9bfb22==='user'?_0x5d6c74(0x150):_0x32e985['TzPmV'];console['log'](_0x5d6c74(0x148)+_0x11a77c+'\x20'+_0x2ac4a8+'\x20skill'+(_0x11a77c>0x1?'s':'')+_0x5d6c74(0x13c)),!_0x3247cc[_0x5d6c74(0x13a)]&&(console[_0x5d6c74(0x14d)](_0x32e985[_0x5d6c74(0x145)]),_0x290902===_0x32e985[_0x5d6c74(0x13d)]?console['log'](_0x5d6c74(0x155)):console['log'](_0x5d6c74(0x146)));}else console['log'](_0x32e985['CZkQT']);}
@@ -1 +1 @@
1
- (function(_0x2cd5af,_0x24be13){const _0x8c677f=_0x3183,_0x563f94=_0x2cd5af();while(!![]){try{const _0x1ca228=parseInt(_0x8c677f(0x20c))/0x1+-parseInt(_0x8c677f(0x242))/0x2*(-parseInt(_0x8c677f(0x1f9))/0x3)+-parseInt(_0x8c677f(0x202))/0x4+parseInt(_0x8c677f(0x247))/0x5*(parseInt(_0x8c677f(0x23f))/0x6)+-parseInt(_0x8c677f(0x225))/0x7*(-parseInt(_0x8c677f(0x1de))/0x8)+parseInt(_0x8c677f(0x23a))/0x9+parseInt(_0x8c677f(0x211))/0xa*(-parseInt(_0x8c677f(0x249))/0xb);if(_0x1ca228===_0x24be13)break;else _0x563f94['push'](_0x563f94['shift']());}catch(_0x21d77d){_0x563f94['push'](_0x563f94['shift']());}}}(_0x1915,0x5a47e));import{mkdir,writeFile}from'fs/promises';import{join}from'path';import{existsSync}from'fs';import{createRequire}from'module';import{spawn}from'child_process';import _0x3810f3 from'inquirer';import{getToken,storeToken}from'./utils/keychain.js';import{getCurrentUser}from'./utils/userApi.js';import{chromium}from'playwright';function _0x3183(_0x46eb96,_0x5eb1c9){_0x46eb96=_0x46eb96-0x1d8;const _0x191525=_0x1915();let _0x318356=_0x191525[_0x46eb96];return _0x318356;}import{addEnv}from'./addEnv.js';import{getRangerDir,findGitRoot}from'./utils/rangerRoot.js';import{runDeviceAuthFlow}from'./utils/deviceAuth.js';import{findExistingEnv}from'./utils/settings.js';import{getCurrentVersion}from'./utils/version.js';import{ensureClaudePlugin,ensureClaudeSkills}from'./setup/claude.js';import{ensureOpencodePluginConfig}from'./setup/opencode.js';import{installSkill}from'./utils/skills.js';const require=createRequire(import.meta.url),bold=_0x4088c0=>'\x1b[1m'+_0x4088c0+'\x1b[0m';function getPlaywrightVersion(){const _0x43357f=_0x3183,_0x3f7980={'rsclM':_0x43357f(0x217),'TGbrg':function(_0x4a6e48,_0x5bdb48){return _0x4a6e48(_0x5bdb48);}};try{const _0x43708d=require[_0x43357f(0x1dc)](_0x3f7980['rsclM']),_0x28ef43=_0x3f7980['TGbrg'](require,_0x43708d);return _0x28ef43[_0x43357f(0x1f0)];}catch{return null;}}function installChromiumBinary(_0x72c984){const _0x26aaf5=_0x3183,_0x43dd0a={'TloqV':function(_0x348052,_0x58450f){return _0x348052===_0x58450f;},'hJwkg':function(_0x10712b){return _0x10712b();},'snEur':'chromium','cWJOm':_0x26aaf5(0x210),'olGgd':'install','UaINi':function(_0x5aff1e,_0x4d9848,_0x32eac1,_0x4e8272){return _0x5aff1e(_0x4d9848,_0x32eac1,_0x4e8272);},'zhuKr':_0x26aaf5(0x20f),'bvVIZ':_0x26aaf5(0x23b),'YGdNj':_0x26aaf5(0x230)};return new Promise((_0x5522e2,_0x55d299)=>{const _0x207a6b=_0x26aaf5,_0x383b0c=_0x72c984?[_0x207a6b(0x23e)+_0x72c984,_0x207a6b(0x20a),_0x43dd0a['snEur']]:[_0x43dd0a['cWJOm'],_0x43dd0a[_0x207a6b(0x245)],_0x43dd0a[_0x207a6b(0x1ec)]],_0x390f8c=_0x43dd0a['UaINi'](spawn,_0x207a6b(0x22c),_0x383b0c,{'stdio':'inherit','shell':process[_0x207a6b(0x1da)]===_0x43dd0a[_0x207a6b(0x213)]});_0x390f8c['on'](_0x43dd0a['bvVIZ'],_0xf3a09=>{const _0x307ad7=_0x207a6b;_0x43dd0a['TloqV'](_0xf3a09,0x0)?_0x43dd0a['hJwkg'](_0x5522e2):_0x55d299(new Error(_0x307ad7(0x23d)+_0xf3a09));}),_0x390f8c['on'](_0x43dd0a['YGdNj'],_0x4c9c9c=>{_0x55d299(_0x4c9c9c);});});}export async function authenticate(_0x3c61b1){const _0x24b4e2=_0x3183,_0x2f9b36={'EGMPG':function(_0x348aff,_0x1c08c9){return _0x348aff(_0x1c08c9);},'SUWlM':'existing_token','aTpkh':function(_0x1468c8,_0x1a82bc){return _0x1468c8 instanceof _0x1a82bc;},'eCaSR':_0x24b4e2(0x1f1),'WxNOS':function(_0x1a27b0,_0x2639e6){return _0x1a27b0(_0x2639e6);},'VnpFf':'✓\x20Stored\x20credentials\x20locally','rZJIR':_0x24b4e2(0x241)};if(!_0x3c61b1){const _0x98ca31=await getToken();if(_0x98ca31){const _0x1bfed9=await _0x2f9b36[_0x24b4e2(0x1f6)](getCurrentUser,_0x98ca31);if(_0x1bfed9[_0x24b4e2(0x20e)])return console['log'](_0x24b4e2(0x1f8)+_0x1bfed9['user']['organizationName']),{'token':_0x98ca31,'method':_0x2f9b36[_0x24b4e2(0x229)]};}try{_0x3c61b1=await runDeviceAuthFlow();}catch(_0x5b09e0){throw new Error(_0x24b4e2(0x212)+(_0x2f9b36[_0x24b4e2(0x22f)](_0x5b09e0,Error)?_0x5b09e0['message']:_0x5b09e0));}const _0x3350e3=await getCurrentUser(_0x3c61b1);if(!_0x3350e3[_0x24b4e2(0x20e)])throw new Error('Failed\x20to\x20validate\x20provisioned\x20API\x20key:\x20'+_0x3350e3[_0x24b4e2(0x230)]);return console[_0x24b4e2(0x22d)](_0x24b4e2(0x1ef)+_0x3350e3['user']['organizationName']),{'token':_0x3c61b1,'method':'device_auth'};}console[_0x24b4e2(0x22d)](_0x2f9b36['eCaSR']);const _0x43ae79=await _0x2f9b36['WxNOS'](getCurrentUser,_0x3c61b1);if(!_0x43ae79['success']){if(_0x43ae79[_0x24b4e2(0x235)])throw new Error('Authentication\x20failed:\x20'+_0x43ae79[_0x24b4e2(0x230)]+_0x24b4e2(0x1ea));else throw new Error(_0x24b4e2(0x22b)+_0x43ae79['error']+_0x24b4e2(0x222));}return console['log']('✓\x20Authenticated\x20to\x20'+_0x43ae79[_0x24b4e2(0x1e6)][_0x24b4e2(0x1e5)]),await _0x2f9b36[_0x24b4e2(0x1f6)](storeToken,_0x3c61b1),console['log'](process[_0x24b4e2(0x236)][_0x24b4e2(0x204)]?_0x24b4e2(0x1fd):_0x2f9b36['VnpFf']),{'token':_0x3c61b1,'method':_0x2f9b36['rZJIR']};}export async function ensureRangerDir(){const _0x4d78e2=_0x3183,_0x585912={'peWWZ':function(_0x12eac5){return _0x12eac5();},'AlfTS':function(_0x4ba613,_0x1b3bb3,_0x281c14){return _0x4ba613(_0x1b3bb3,_0x281c14);},'IAbzH':'.ranger','NOyKT':function(_0x21d492){return _0x21d492();},'TaoZk':'✓\x20.ranger/\x20directory\x20already\x20exists'},_0x11ea06=_0x585912['peWWZ'](findGitRoot),_0x1f21c6=_0x11ea06?_0x585912[_0x4d78e2(0x1f4)](join,_0x11ea06,_0x585912['IAbzH']):_0x585912['NOyKT'](getRangerDir);return!existsSync(_0x1f21c6)?(await mkdir(_0x1f21c6,{'recursive':!![]}),console[_0x4d78e2(0x22d)](_0x4d78e2(0x21b)),{'path':_0x1f21c6,'installed':!![]}):(console['log'](_0x585912['TaoZk']),{'path':_0x1f21c6,'installed':![]});}export async function ensureChromium(){const _0x24c44a=_0x3183,_0x5762a7={'bLhDp':'✓\x20Playwright\x20Chromium\x20browser\x20found','RzvnG':'confirm','TbDvu':'install','zKNnt':_0x24c44a(0x1fa),'WTELj':'\x0a❌\x20Failed\x20to\x20install\x20Chromium:','prnHe':function(_0x3f1157,_0x5b64b8){return _0x3f1157 instanceof _0x5b64b8;},'MBxdr':_0x24c44a(0x205),'KwJyM':'\x20\x20npx\x20playwright\x20install\x20chromium','NWyRW':'You\x20will\x20need\x20to\x20install\x20it\x20before\x20using\x20Ranger:'};let _0x1055ca=![];try{const _0x232adb=chromium[_0x24c44a(0x1e1)]();_0x1055ca=existsSync(_0x232adb);}catch{_0x1055ca=![];}if(_0x1055ca)return console['log'](_0x5762a7['bLhDp']),![];const _0x6f7002=getPlaywrightVersion(),_0x5a2711=process['stdin'][_0x24c44a(0x240)]&&process[_0x24c44a(0x1e4)][_0x24c44a(0x240)];let _0x5ada7e=!![];if(_0x5a2711){const {install:_0x2a7cbb}=await _0x3810f3[_0x24c44a(0x1e9)]([{'type':_0x5762a7['RzvnG'],'name':_0x5762a7['TbDvu'],'message':_0x6f7002?'The\x20required\x20version\x20('+_0x6f7002+')\x20of\x20the\x20Playwright\x20Chromium\x20browser\x20is\x20not\x20installed.\x20Install\x20it\x20now?':_0x5762a7[_0x24c44a(0x1f3)],'default':!![]}]);_0x5ada7e=_0x2a7cbb;}else console[_0x24c44a(0x22d)]('\x0aNon-interactive\x20mode:\x20Auto-installing\x20Playwright\x20Chromium'+(_0x6f7002?'\x20'+_0x6f7002:'')+'...');if(_0x5ada7e){console[_0x24c44a(0x22d)](_0x24c44a(0x22a));try{await installChromiumBinary(_0x6f7002),console['log']('\x0a✓\x20Playwright\x20Chromium\x20installed\x20successfully');}catch(_0x3e9a64){console['error'](_0x5762a7[_0x24c44a(0x226)],_0x5762a7[_0x24c44a(0x228)](_0x3e9a64,Error)?_0x3e9a64['message']:_0x3e9a64),console[_0x24c44a(0x22d)](_0x5762a7['MBxdr']),_0x6f7002?console[_0x24c44a(0x22d)](_0x24c44a(0x24a)+_0x6f7002+'\x20install\x20chromium'):console[_0x24c44a(0x22d)](_0x5762a7[_0x24c44a(0x1f5)]);}}else console[_0x24c44a(0x22d)]('\x0a⚠\x20Skipping\x20Chromium\x20installation.'),console['log'](_0x5762a7['NWyRW']),_0x6f7002?console['log'](_0x24c44a(0x24a)+_0x6f7002+'\x20install\x20chromium'):console['log'](_0x5762a7[_0x24c44a(0x1f5)]);return!![];}export async function writeRangerGitignore(_0x2cc3cb){const _0x4e09a4=_0x3183,_0x256f68={'XIZPj':'✓\x20Created\x20.ranger/.gitignore'},_0x1bfd37=join(_0x2cc3cb,'.gitignore'),_0x1e7a2f='\x0a\x0a#\x20Ignore\x20local-only\x20directories\x0alocal/\x0asessions/\x0abug-bashes/\x0areports/\x0afeedback-images/\x0a\x0aactive-profile.txt\x0aactive-feature.txt\x0a.gitignore\x0a\x0a#\x20Ignore\x20plaintext\x20auth\x20files\x20(encrypted\x20.enc\x20files\x20are\x20safe\x20to\x20commit)\x0a**/auth.json\x0a';await writeFile(_0x1bfd37,_0x1e7a2f),console[_0x4e09a4(0x22d)](_0x256f68[_0x4e09a4(0x1ee)]);}function _0x1915(){const _0x20033c=['force','GITHUB_ENV','You\x20can\x20install\x20it\x20manually\x20by\x20running:','BZXne','url','JqGRd','FiBhL','install','ivJMS','642495WpNNNW','mTwWn','success','win32','playwright','88090wfhZaW','Authentication\x20failed:\x20','zhuKr','Make\x20sure\x20your\x20app\x20is\x20running\x20before\x20you\x20start.\x0a','skipChromium','plugin','playwright/package.json','\x0aagent\x20like\x20usual.\x20Claude\x20will\x20create\x20a\x20feature\x20review\x20with','No\x20git\x20repository\x20found.\x20Please\x20run\x20`ranger\x20setup`\x20from\x20inside\x20your\x20project\x20directory.','ranger\x20profile\x20add\x20local','✓\x20Created\x20.ranger/\x20directory','maXio','diDFr','use\x20until\x20the\x20session\x20expires.\x0a','kDHAI','stdin','✓\x20Skipping\x20Chromium\x20check\x20(--skip-chromium)','.\x20Please\x20check\x20your\x20network\x20connection\x20and\x20server\x20URL.','bbXJv','Would\x20you\x20like\x20to\x20set\x20up\x20the\x20profile\x20now?','15729ccwVkV','WTELj','\x0a❌\x20Profile\x20setup\x20failed:','prnHe','SUWlM','\x0aInstalling\x20Chromium\x20browser...\x0a','Failed\x20to\x20connect\x20to\x20MCP\x20server:\x20','npx','log','scope','aTpkh','error','\x20\x20Failed\x20to\x20install\x20OpenCode\x20skill:','trackPhaseStart','KKgwM','method','status','env','warn','message','ghGSS','6029487kqrBXw','close','and\x20prompt\x20the\x20agent\x20like\x20usual.\x20Ranger\x20will\x20create\x20a\x20feature\x20review','Installation\x20failed\x20with\x20exit\x20code\x20','playwright@','126KCarRu','isTTY','provided_token','544cELMlr','XdMBu','No\x20git\x20repository\x20found','olGgd','CNwkA','91550iaBRpw','local','1529aSEqHK','\x20\x20npx\x20playwright@','BFmRf','trackPhaseEnd','skills','platform','oxRZm','resolve','PrpqI','472kQFsOw','\x0aIn\x20OpenCode,\x20enable\x20Ranger\x20hooks\x20(run\x20the\x20`ranger_enable`\x20tool)','XuhAw','executablePath','auth,\x20you\x20can\x20log\x20in\x20and\x20we\x27ll\x20save\x20the\x20session\x20state\x20for\x20Ranger\x20to','UlLHs','stdout','organizationName','user','confirm','Nzvtf','prompt','.\x20Please\x20check\x20your\x20API\x20token\x20and\x20try\x20again.','honzH','snEur','trackPhaseError','XIZPj','✓\x20Authenticated\x20to\x20','version','Validating\x20API\x20token...','chromium','zKNnt','AlfTS','KwJyM','EGMPG','skipped','✓\x20Already\x20authenticated\x20to\x20','3468xxhBgH','The\x20required\x20Playwright\x20Chromium\x20browser\x20is\x20not\x20installed.\x20Install\x20it\x20now?','bhfzd','nzFdW','✓\x20Exported\x20credentials\x20for\x20CI','WoOPl','\x0averification\x20to\x20check\x20its\x20work\x20as\x20it\x20builds.','ranger','kUUJO','2198848mBIFFX'];_0x1915=function(){return _0x20033c;};return _0x1915();}function printProfileSetupLaterInstructions(){const _0x1a966e=_0x3183,_0x65697a={'VKdIa':'\x0aIn\x20order\x20for\x20Ranger\x20to\x20verify\x20your\x20work,\x20you\x27ll\x20need\x20to\x20set\x20up\x20a\x20profile\x20later\x20with:','WoOPl':function(_0x4cf52f,_0x2ea96d){return _0x4cf52f(_0x2ea96d);},'kDHAI':_0x1a966e(0x21a),'alKPm':_0x1a966e(0x214)};console['log'](_0x65697a['VKdIa']),console['log']('\x20\x20'+_0x65697a[_0x1a966e(0x1fe)](bold,_0x65697a[_0x1a966e(0x21f)])),console[_0x1a966e(0x22d)](_0x65697a['alKPm']);}async function ensureLocalEnv(_0x155701,_0x5f23ab){const _0x61b9d5=_0x3183,_0x582f3d={'diDFr':'⚠\x20No\x20git\x20repository\x20found.\x20Run\x20`ranger\x20profile\x20add\x20local`\x20from\x20your\x20project\x20directory.','ghGSS':function(_0x992ca3,_0x595f0f,_0x4be9e9){return _0x992ca3(_0x595f0f,_0x4be9e9);},'CrwyK':'✓\x20Local\x20profile\x20already\x20exists','mRsDp':_0x61b9d5(0x1e2),'kUUJO':_0x61b9d5(0x1e7),'bhfzd':_0x61b9d5(0x224),'kbsmq':function(_0x1b23a9,_0x4a02a4,_0x4906dd,_0x1076d9){return _0x1b23a9(_0x4a02a4,_0x4906dd,_0x1076d9);},'XuhAw':function(_0x212a10,_0x34fa5e){return _0x212a10 instanceof _0x34fa5e;},'diXYo':function(_0x5d457b){return _0x5d457b();}};if(!findGitRoot())return console[_0x61b9d5(0x22d)](_0x582f3d[_0x61b9d5(0x21d)]),{'ready':![],'skipped':!![]};if(_0x582f3d[_0x61b9d5(0x239)](findExistingEnv,_0x61b9d5(0x248),{'locations':['local']}))return console['log'](_0x582f3d['CrwyK']),{'ready':!![],'skipped':![]};const _0x12edee=process['stdin']['isTTY']&&process[_0x61b9d5(0x1e4)][_0x61b9d5(0x240)];if(_0x12edee&&!_0x155701?.['url']){console[_0x61b9d5(0x22d)]('\x0aA\x20profile\x20gives\x20Ranger\x27s\x20browser\x20agent\x20information\x20about\x20how'),console['log']('to\x20access\x20your\x20app.\x20If\x20the\x20part\x20of\x20your\x20app\x20you\x20want\x20to\x20test\x20is\x20behind'),console['log'](_0x582f3d['mRsDp']),console[_0x61b9d5(0x22d)](_0x61b9d5(0x21e)),console[_0x61b9d5(0x22d)]('You\x27ll\x20need\x20the\x20app\x20to\x20be\x20running\x20to\x20set\x20up\x20the\x20profile.');const {wantsProfile:_0x4933ea}=await _0x3810f3['prompt']([{'type':_0x582f3d[_0x61b9d5(0x201)],'name':'wantsProfile','message':_0x582f3d[_0x61b9d5(0x1fb)],'default':!![]}]);if(!_0x4933ea)return printProfileSetupLaterInstructions(),{'ready':![],'skipped':!![]};}try{return await _0x582f3d['kbsmq'](addEnv,_0x61b9d5(0x248),{'url':_0x155701?.[_0x61b9d5(0x207)],'force':_0x155701?.[_0x61b9d5(0x203)]},_0x5f23ab),{'ready':!![],'skipped':![]};}catch(_0x2cbe39){return console['error'](_0x61b9d5(0x227),_0x582f3d[_0x61b9d5(0x1e0)](_0x2cbe39,Error)?_0x2cbe39['message']:_0x2cbe39),_0x582f3d['diXYo'](printProfileSetupLaterInstructions),{'ready':![],'skipped':![]};}}export async function start(_0x54a2c0,_0x2af1c6,_0x27449a){const _0xcd18ea=_0x3183,_0xf41d16={'CNwkA':'git_check','ivJMS':_0xcd18ea(0x244),'PrpqI':_0xcd18ea(0x219),'BZXne':function(_0x3bf599){return _0x3bf599();},'nzFdW':'auth','KKgwM':_0xcd18ea(0x1f2),'Jizhj':_0xcd18ea(0x221),'BFmRf':function(_0x2ae2d6,_0x1658b3){return _0x2ae2d6(_0x1658b3);},'XcSOj':function(_0x2452d6,_0x9a9d7a){return _0x2452d6(_0x9a9d7a);},'oxRZm':_0xcd18ea(0x216),'FiBhL':'skills','XdMBu':_0xcd18ea(0x200),'kMrEl':'opencode','maXio':function(_0xa0d3b1,_0x13f71f){return _0xa0d3b1(_0x13f71f);},'KgZKS':'Non-interactive\x20mode:\x20Skipping\x20profile\x20setup.\x20To\x20set\x20up\x20a\x20profile,\x20pass\x20--url\x20or\x20run\x20later:','JqGRd':function(_0x4b4a7c,_0x1d6861){return _0x4b4a7c(_0x1d6861);},'mTwWn':'profile','UlLHs':function(_0x1af596,_0xe6a21f,_0x3562de){return _0x1af596(_0xe6a21f,_0x3562de);},'tVBrI':_0xcd18ea(0x23c),'Nzvtf':'with\x20scenarios\x20describing\x20what\x20to\x20verify\x20and\x20then\x20run\x20browser','honzH':'verification\x20to\x20check\x20its\x20work\x20as\x20it\x20builds.','VEdqM':function(_0x18af9e,_0x3683c0){return _0x18af9e(_0x3683c0);},'bbXJv':function(_0xf9f8a4,_0x423c72){return _0xf9f8a4+_0x423c72;}};console['log']('\x0a🚀\x20Ranger\x20Setup\x0a');const _0xda3353=process[_0xcd18ea(0x220)][_0xcd18ea(0x240)]&&process[_0xcd18ea(0x1e4)]['isTTY'];!_0xda3353&&!_0x2af1c6?.[_0xcd18ea(0x22e)]&&(console[_0xcd18ea(0x22d)]('Non-interactive\x20mode:\x20No\x20--scope\x20provided,\x20defaulting\x20to\x20user.'),_0x2af1c6={..._0x2af1c6,'scope':'user'});_0x27449a?.['trackPhaseStart'](_0xf41d16['CNwkA']);if(!findGitRoot()){await _0x27449a?.[_0xcd18ea(0x1ed)](_0xf41d16[_0xcd18ea(0x246)],new Error(_0xf41d16[_0xcd18ea(0x20b)]));throw new Error(_0xf41d16[_0xcd18ea(0x1dd)]);}_0x27449a?.[_0xcd18ea(0x1d8)](_0xf41d16[_0xcd18ea(0x246)]);const _0xdbf3c2=!existsSync(_0xf41d16[_0xcd18ea(0x206)](getRangerDir)),{path:_0x4172c8}=await ensureRangerDir();_0x27449a?.['trackPhaseStart']('auth');const _0x3f83fc=await authenticate(_0x54a2c0);_0x27449a?.[_0xcd18ea(0x1d8)](_0xf41d16[_0xcd18ea(0x1fc)],{'isFirstRun':_0xdbf3c2,'method':_0x3f83fc[_0xcd18ea(0x234)]}),_0x27449a?.['trackPhaseStart'](_0xf41d16[_0xcd18ea(0x233)]);_0x2af1c6?.[_0xcd18ea(0x215)]?console['log'](_0xf41d16['Jizhj']):await _0xf41d16[_0xcd18ea(0x206)](ensureChromium);_0x27449a?.[_0xcd18ea(0x1d8)](_0xcd18ea(0x1f2),{'isFirstRun':_0xdbf3c2,'skipped':!!_0x2af1c6?.['skipChromium']}),await _0xf41d16['BFmRf'](writeRangerGitignore,_0x4172c8),console['log']('\x0a✅\x20Ranger\x20setup\x20complete!\x0a');const _0x39cca5=_0x2af1c6?.['scope'],_0x1df1db=_0x2af1c6?.['opencode']??![];let _0x4d8c18=null;_0x1df1db?(_0x27449a?.[_0xcd18ea(0x232)]('plugin'),_0x4d8c18=await _0xf41d16['XcSOj'](ensureOpencodePluginConfig,_0x39cca5),_0x27449a?.['trackPhaseEnd']('plugin',{'isFirstRun':_0xdbf3c2,'opencode':!![]})):(_0x27449a?.['trackPhaseStart'](_0xf41d16[_0xcd18ea(0x1db)]),await _0xf41d16[_0xcd18ea(0x24b)](ensureClaudePlugin,_0x39cca5),_0x27449a?.['trackPhaseEnd'](_0xcd18ea(0x216),{'isFirstRun':_0xdbf3c2}));if(_0x1df1db&&_0x4d8c18){_0x27449a?.[_0xcd18ea(0x232)](_0xf41d16[_0xcd18ea(0x209)]);try{await installSkill(_0xf41d16[_0xcd18ea(0x243)],{'level':_0x4d8c18[_0xcd18ea(0x22e)],'cliVersion':_0xf41d16['BZXne'](getCurrentVersion),'platform':_0xf41d16['kMrEl']}),_0x27449a?.['trackPhaseEnd'](_0xf41d16['FiBhL'],{'isFirstRun':_0xdbf3c2,'opencode':!![]});}catch(_0x3338be){console[_0xcd18ea(0x237)](_0xcd18ea(0x231),_0x3338be instanceof Error?_0x3338be[_0xcd18ea(0x238)]:_0x3338be),_0x27449a?.[_0xcd18ea(0x1d8)](_0xf41d16['FiBhL'],{'isFirstRun':_0xdbf3c2,'opencode':!![],'failed':!![]});}}else _0x27449a?.['trackPhaseStart'](_0xcd18ea(0x1d9)),await _0xf41d16[_0xcd18ea(0x21c)](ensureClaudeSkills,_0x39cca5),_0x27449a?.[_0xcd18ea(0x1d8)](_0xf41d16[_0xcd18ea(0x209)],{'isFirstRun':_0xdbf3c2});if(!_0xda3353&&!_0x2af1c6?.[_0xcd18ea(0x207)])console[_0xcd18ea(0x22d)](_0xf41d16['KgZKS']),console[_0xcd18ea(0x22d)]('\x20\x20'+_0xf41d16[_0xcd18ea(0x208)](bold,_0xcd18ea(0x21a))+'\x0a');else{_0x27449a?.['trackPhaseStart'](_0xf41d16[_0xcd18ea(0x20d)]);const _0x2152d6=await _0xf41d16[_0xcd18ea(0x1e3)](ensureLocalEnv,{'url':_0x2af1c6?.['url'],'force':_0x2af1c6?.[_0xcd18ea(0x203)]},_0x27449a);_0x27449a?.[_0xcd18ea(0x1d8)](_0xf41d16[_0xcd18ea(0x20d)],{'isFirstRun':_0xdbf3c2,'profileReady':_0x2152d6['ready'],'userSkipped':_0x2152d6[_0xcd18ea(0x1f7)]}),_0x2152d6['ready']&&console['log']('\x0a✅\x20You\x27re\x20ready\x20to\x20start\x20using\x20Ranger\x20Feature\x20Review.');}if(_0x1df1db)console[_0xcd18ea(0x22d)](_0xcd18ea(0x1df)),console[_0xcd18ea(0x22d)](_0xf41d16['tVBrI']),console[_0xcd18ea(0x22d)](_0xf41d16[_0xcd18ea(0x1e8)]),console[_0xcd18ea(0x22d)](_0xf41d16[_0xcd18ea(0x1eb)]);else{const _0x5eda96=_0xf41d16['VEdqM'](bold,'/ranger:enable');console[_0xcd18ea(0x22d)](_0xf41d16[_0xcd18ea(0x223)]('\x0aIn\x20Claude\x20Code,\x20run\x20'+_0x5eda96+'\x20and\x20prompt\x20the\x20coding'+_0xcd18ea(0x218),'\x0ascenarios\x20describing\x20what\x20to\x20verify\x20and\x20then\x20run\x20browser')+_0xcd18ea(0x1ff));}}
1
+ const _0x933dd=_0x416b;(function(_0x1e0e24,_0x30b43b){const _0x25b535=_0x416b,_0x4451c6=_0x1e0e24();while(!![]){try{const _0x33f5cc=parseInt(_0x25b535(0x102))/0x1*(-parseInt(_0x25b535(0xc9))/0x2)+-parseInt(_0x25b535(0xc4))/0x3*(-parseInt(_0x25b535(0xf3))/0x4)+-parseInt(_0x25b535(0xc7))/0x5*(parseInt(_0x25b535(0x110))/0x6)+-parseInt(_0x25b535(0xbc))/0x7+parseInt(_0x25b535(0xcf))/0x8+parseInt(_0x25b535(0x118))/0x9+parseInt(_0x25b535(0xc0))/0xa*(parseInt(_0x25b535(0xcc))/0xb);if(_0x33f5cc===_0x30b43b)break;else _0x4451c6['push'](_0x4451c6['shift']());}catch(_0x5da4d4){_0x4451c6['push'](_0x4451c6['shift']());}}}(_0x121c,0x9664c));import{mkdir,writeFile}from'fs/promises';import{join}from'path';import{existsSync}from'fs';import{createRequire}from'module';import{spawn}from'child_process';import _0x1f261d from'inquirer';import{getToken,storeToken}from'./utils/keychain.js';import{getCurrentUser}from'./utils/userApi.js';import{chromium}from'playwright';import{addEnv}from'./addEnv.js';import{getRangerDir,findGitRoot}from'./utils/rangerRoot.js';import{runDeviceAuthFlow}from'./utils/deviceAuth.js';import{findExistingEnv}from'./utils/settings.js';import{getCurrentVersion}from'./utils/version.js';import{ensureClaudePlugin,ensureClaudeSkills}from'./setup/claude.js';import{ensureOpencodePluginConfig}from'./setup/opencode.js';import{installSkill}from'./utils/skills.js';const require=createRequire(import.meta.url),bold=_0x2fd3e2=>'\x1b[1m'+_0x2fd3e2+_0x933dd(0xcb);function _0x416b(_0x1d92e3,_0x3c7d97){_0x1d92e3=_0x1d92e3-0xbc;const _0x121ca5=_0x121c();let _0x416b39=_0x121ca5[_0x1d92e3];return _0x416b39;}function getPlaywrightVersion(){const _0x2fe9d2=_0x933dd,_0x2a8914={'sQFmU':function(_0x58df48,_0x2666ac){return _0x58df48(_0x2666ac);}};try{const _0x56d2ff=require[_0x2fe9d2(0x131)](_0x2fe9d2(0xf7)),_0xc445e2=_0x2a8914[_0x2fe9d2(0x11d)](require,_0x56d2ff);return _0xc445e2['version'];}catch{return null;}}function installChromiumBinary(_0x572643){const _0x1f0b96=_0x933dd,_0x2d8147={'Voptm':function(_0x536d80,_0x7f6010){return _0x536d80===_0x7f6010;},'cKkSe':function(_0x1ac169,_0x1f3d2d){return _0x1ac169(_0x1f3d2d);},'uQEDV':'chromium','lskRJ':'install','uxXDn':function(_0x50a2c9,_0x54bb35,_0x3dcdbe,_0x2b08e6){return _0x50a2c9(_0x54bb35,_0x3dcdbe,_0x2b08e6);},'jRIiO':_0x1f0b96(0x121),'gDwSE':_0x1f0b96(0x129),'ipHoc':'close','wkCdo':'error'};return new Promise((_0x1bf2d8,_0x505776)=>{const _0x2c4509=_0x1f0b96,_0x3a5b53={'ErNkx':function(_0x2e28a5,_0x58d72b){const _0x4cb999=_0x416b;return _0x2d8147[_0x4cb999(0xf6)](_0x2e28a5,_0x58d72b);},'eIpvW':function(_0xad8d67,_0x59e178){const _0x18834e=_0x416b;return _0x2d8147[_0x18834e(0xc8)](_0xad8d67,_0x59e178);}},_0x231f65=_0x572643?['playwright@'+_0x572643,_0x2c4509(0x10c),_0x2d8147[_0x2c4509(0x133)]]:['playwright',_0x2d8147[_0x2c4509(0x123)],_0x2d8147[_0x2c4509(0x133)]],_0x3a36b8=_0x2d8147[_0x2c4509(0xe7)](spawn,'npx',_0x231f65,{'stdio':_0x2d8147[_0x2c4509(0x10b)],'shell':process[_0x2c4509(0xe3)]===_0x2d8147[_0x2c4509(0xee)]});_0x3a36b8['on'](_0x2d8147[_0x2c4509(0x119)],_0x85ef93=>{const _0x1a22a9=_0x2c4509;_0x3a5b53[_0x1a22a9(0x12c)](_0x85ef93,0x0)?_0x1bf2d8():_0x505776(new Error(_0x1a22a9(0xce)+_0x85ef93));}),_0x3a36b8['on'](_0x2d8147['wkCdo'],_0x53b0b1=>{const _0x27d32f=_0x2c4509;_0x3a5b53[_0x27d32f(0xe0)](_0x505776,_0x53b0b1);});});}export async function authenticate(_0x5cc769){const _0x300406=_0x933dd,_0x12a019={'JORjk':function(_0xf02add,_0x3eabe7){return _0xf02add(_0x3eabe7);},'QfZwn':'existing_token','CtQii':function(_0x11ed16){return _0x11ed16();},'yXbLm':function(_0x558f1a,_0x5ca1f6){return _0x558f1a(_0x5ca1f6);},'IWiMb':_0x300406(0xbe),'WXsRQ':'provided_token'};if(!_0x5cc769){const _0x172bbd=await getToken();if(_0x172bbd){const _0x484d5c=await _0x12a019['JORjk'](getCurrentUser,_0x172bbd);if(_0x484d5c['success'])return console['log'](_0x300406(0x11f)+_0x484d5c[_0x300406(0x109)][_0x300406(0xbf)]),{'token':_0x172bbd,'method':_0x12a019['QfZwn']};}try{_0x5cc769=await _0x12a019['CtQii'](runDeviceAuthFlow);}catch(_0x18cd9c){throw new Error(_0x300406(0x124)+(_0x18cd9c instanceof Error?_0x18cd9c[_0x300406(0xcd)]:_0x18cd9c));}const _0x130cec=await _0x12a019[_0x300406(0x11e)](getCurrentUser,_0x5cc769);if(!_0x130cec['success'])throw new Error(_0x300406(0x12b)+_0x130cec['error']);return console[_0x300406(0x103)](_0x300406(0x108)+_0x130cec[_0x300406(0x109)][_0x300406(0xbf)]),{'token':_0x5cc769,'method':'device_auth'};}console[_0x300406(0x103)](_0x300406(0xdd));const _0x2ce1f4=await _0x12a019[_0x300406(0xd7)](getCurrentUser,_0x5cc769);if(!_0x2ce1f4[_0x300406(0xfe)]){if(_0x2ce1f4['status'])throw new Error(_0x300406(0x124)+_0x2ce1f4[_0x300406(0x11b)]+_0x300406(0x101));else throw new Error('Failed\x20to\x20connect\x20to\x20MCP\x20server:\x20'+_0x2ce1f4['error']+_0x300406(0xd8));}return console[_0x300406(0x103)]('✓\x20Authenticated\x20to\x20'+_0x2ce1f4['user']['organizationName']),await storeToken(_0x5cc769),console[_0x300406(0x103)](process['env']['GITHUB_ENV']?_0x300406(0xc3):_0x12a019[_0x300406(0x127)]),{'token':_0x5cc769,'method':_0x12a019[_0x300406(0x106)]};}export async function ensureRangerDir(){const _0x528535=_0x933dd,_0x427a90={'crGPe':function(_0x5d9830){return _0x5d9830();},'KVOqV':'.ranger','Jrgsw':function(_0x5d6506){return _0x5d6506();},'DyPAA':function(_0x219d43,_0x5e23e7,_0x4b16e6){return _0x219d43(_0x5e23e7,_0x4b16e6);}},_0x14251a=_0x427a90['crGPe'](findGitRoot),_0x1d9bbc=_0x14251a?join(_0x14251a,_0x427a90[_0x528535(0xe5)]):_0x427a90[_0x528535(0x112)](getRangerDir);return!existsSync(_0x1d9bbc)?(await _0x427a90[_0x528535(0xc1)](mkdir,_0x1d9bbc,{'recursive':!![]}),console[_0x528535(0x103)](_0x528535(0xc2)),{'path':_0x1d9bbc,'installed':!![]}):(console['log']('✓\x20.ranger/\x20directory\x20already\x20exists'),{'path':_0x1d9bbc,'installed':![]});}export async function ensureChromium(){const _0xe41a5c=_0x933dd,_0x53bdc5={'zVZvJ':_0xe41a5c(0x12f),'tTehA':'install','JahIX':_0xe41a5c(0x11a),'fCJEW':'You\x20can\x20install\x20it\x20manually\x20by\x20running:','OJISF':_0xe41a5c(0x113),'ukmeu':'\x0a⚠\x20Skipping\x20Chromium\x20installation.','ujeSf':_0xe41a5c(0xf5)};let _0xe81186=![];try{const _0xe6389b=chromium[_0xe41a5c(0x105)]();_0xe81186=existsSync(_0xe6389b);}catch{_0xe81186=![];}if(_0xe81186)return console['log'](_0x53bdc5[_0xe41a5c(0x132)]),![];const _0xe82fc5=getPlaywrightVersion(),_0x239a9c=process[_0xe41a5c(0x126)][_0xe41a5c(0xdb)]&&process['stdout']['isTTY'];let _0x2b39bf=!![];if(_0x239a9c){const {install:_0x508279}=await _0x1f261d[_0xe41a5c(0x107)]([{'type':'confirm','name':_0x53bdc5['tTehA'],'message':_0xe82fc5?_0xe41a5c(0xeb)+_0xe82fc5+_0xe41a5c(0x111):_0x53bdc5['JahIX'],'default':!![]}]);_0x2b39bf=_0x508279;}else console['log']('\x0aNon-interactive\x20mode:\x20Auto-installing\x20Playwright\x20Chromium'+(_0xe82fc5?'\x20'+_0xe82fc5:'')+'...');if(_0x2b39bf){console[_0xe41a5c(0x103)](_0xe41a5c(0xe8));try{await installChromiumBinary(_0xe82fc5),console[_0xe41a5c(0x103)]('\x0a✓\x20Playwright\x20Chromium\x20installed\x20successfully');}catch(_0x440320){console[_0xe41a5c(0x11b)]('\x0a❌\x20Failed\x20to\x20install\x20Chromium:',_0x440320 instanceof Error?_0x440320['message']:_0x440320),console[_0xe41a5c(0x103)](_0x53bdc5['fCJEW']),_0xe82fc5?console['log']('\x20\x20npx\x20playwright@'+_0xe82fc5+'\x20install\x20chromium'):console[_0xe41a5c(0x103)](_0x53bdc5[_0xe41a5c(0xfa)]);}}else console['log'](_0x53bdc5['ukmeu']),console['log'](_0x53bdc5['ujeSf']),_0xe82fc5?console[_0xe41a5c(0x103)]('\x20\x20npx\x20playwright@'+_0xe82fc5+'\x20install\x20chromium'):console[_0xe41a5c(0x103)](_0xe41a5c(0x113));return!![];}export async function writeRangerGitignore(_0x66f2da){const _0x5e0c91=_0x933dd,_0x5588b8={'YGXOu':_0x5e0c91(0xd6),'buRdp':function(_0x430b53,_0x23cd79,_0x286388){return _0x430b53(_0x23cd79,_0x286388);}},_0x488a39=join(_0x66f2da,_0x5588b8['YGXOu']),_0xd31860='\x0a\x0a#\x20Ignore\x20local-only\x20directories\x0alocal/\x0asessions/\x0abug-bashes/\x0areports/\x0afeedback-images/\x0a\x0aactive-profile.txt\x0aactive-feature.txt\x0a.gitignore\x0a\x0a#\x20Ignore\x20plaintext\x20auth\x20files\x20(encrypted\x20.enc\x20files\x20are\x20safe\x20to\x20commit)\x0a**/auth.json\x0a';await _0x5588b8['buRdp'](writeFile,_0x488a39,_0xd31860),console['log'](_0x5e0c91(0x115));}function _0x121c(){const _0x581b32=['lskRJ','Authentication\x20failed:\x20','stdout','stdin','IWiMb','use\x20until\x20the\x20session\x20expires.\x0a','win32','✓\x20Local\x20profile\x20already\x20exists','Failed\x20to\x20validate\x20provisioned\x20API\x20key:\x20','ErNkx','Non-interactive\x20mode:\x20No\x20--scope\x20provided,\x20defaulting\x20to\x20user.','No\x20git\x20repository\x20found','✓\x20Playwright\x20Chromium\x20browser\x20found','qOoUk','resolve','zVZvJ','uQEDV','6056491MPvluG','Non-interactive\x20mode:\x20Skipping\x20profile\x20setup.\x20To\x20set\x20up\x20a\x20profile,\x20pass\x20--url\x20or\x20run\x20later:','✓\x20Stored\x20credentials\x20locally','organizationName','2650120Zlxdek','DyPAA','✓\x20Created\x20.ranger/\x20directory','✓\x20Exported\x20credentials\x20for\x20CI','3CcgzmV','local','skipped','5XEjDkx','cKkSe','2WStYIg','No\x20git\x20repository\x20found.\x20Please\x20run\x20`ranger\x20setup`\x20from\x20inside\x20your\x20project\x20directory.','\x1b[0m','55uwNxnk','message','Installation\x20failed\x20with\x20exit\x20code\x20','6097824smNJFL','\x0aA\x20profile\x20gives\x20Ranger\x27s\x20browser\x20agent\x20information\x20about\x20how','Make\x20sure\x20your\x20app\x20is\x20running\x20before\x20you\x20start.\x0a','LMjUk','\x0a🚀\x20Ranger\x20Setup\x0a','alGmi','trackPhaseError','.gitignore','yXbLm','.\x20Please\x20check\x20your\x20network\x20connection\x20and\x20server\x20URL.','qsbdU','⚠\x20No\x20git\x20repository\x20found.\x20Run\x20`ranger\x20profile\x20add\x20local`\x20from\x20your\x20project\x20directory.','isTTY','with\x20scenarios\x20describing\x20what\x20to\x20verify\x20and\x20then\x20run\x20browser','Validating\x20API\x20token...','\x0aIn\x20OpenCode,\x20enable\x20Ranger\x20hooks\x20(run\x20the\x20`ranger_enable`\x20tool)','\x0averification\x20to\x20check\x20its\x20work\x20as\x20it\x20builds.','eIpvW','trackPhaseStart','✓\x20Skipping\x20Chromium\x20check\x20(--skip-chromium)','platform','profile','KVOqV','ranger\x20profile\x20add\x20local','uxXDn','\x0aInstalling\x20Chromium\x20browser...\x0a','\x20\x20Failed\x20to\x20install\x20OpenCode\x20skill:','skills','The\x20required\x20version\x20(','\x0ascenarios\x20describing\x20what\x20to\x20verify\x20and\x20then\x20run\x20browser','icGWC','gDwSE','ranger','/ranger:enable','force','zMusc','1202956eGtRPC','\x0aIn\x20Claude\x20Code,\x20run\x20','You\x20will\x20need\x20to\x20install\x20it\x20before\x20using\x20Ranger:','Voptm','playwright/package.json','skipChromium','iCKIs','OJISF','vFdij','plugin','VYSey','success','trackPhaseEnd','method','.\x20Please\x20check\x20your\x20API\x20token\x20and\x20try\x20again.','992183dLKyOY','log','scope','executablePath','WXsRQ','prompt','✓\x20Authenticated\x20to\x20','user','rKBdy','jRIiO','install','wantsProfile','OrgKE','rHXyS','4294518Ozaztq',')\x20of\x20the\x20Playwright\x20Chromium\x20browser\x20is\x20not\x20installed.\x20Install\x20it\x20now?','Jrgsw','\x20\x20npx\x20playwright\x20install\x20chromium','You\x27ll\x20need\x20the\x20app\x20to\x20be\x20running\x20to\x20set\x20up\x20the\x20profile.','✓\x20Created\x20.ranger/.gitignore','verification\x20to\x20check\x20its\x20work\x20as\x20it\x20builds.','url','7210206TpoGjd','ipHoc','The\x20required\x20Playwright\x20Chromium\x20browser\x20is\x20not\x20installed.\x20Install\x20it\x20now?','error','chromium','sQFmU','JORjk','✓\x20Already\x20authenticated\x20to\x20','sGLJU','inherit','warn'];_0x121c=function(){return _0x581b32;};return _0x121c();}function printProfileSetupLaterInstructions(){const _0x274ba6=_0x933dd,_0x4fd1b7={'kwRgA':function(_0x326f49,_0x2f9c66){return _0x326f49(_0x2f9c66);},'vFdij':_0x274ba6(0xe6)};console['log']('\x0aIn\x20order\x20for\x20Ranger\x20to\x20verify\x20your\x20work,\x20you\x27ll\x20need\x20to\x20set\x20up\x20a\x20profile\x20later\x20with:'),console['log']('\x20\x20'+_0x4fd1b7['kwRgA'](bold,_0x4fd1b7[_0x274ba6(0xfb)])),console[_0x274ba6(0x103)](_0x274ba6(0xd1));}async function ensureLocalEnv(_0x4dfdd0,_0x40e9cd){const _0x3b56f8=_0x933dd,_0x2f02b6={'XAHiG':function(_0x2ffda6,_0x5324b0,_0x189073){return _0x2ffda6(_0x5324b0,_0x189073);},'rKBdy':_0x3b56f8(0xc5),'zMusc':_0x3b56f8(0x12a),'elfjy':'to\x20access\x20your\x20app.\x20If\x20the\x20part\x20of\x20your\x20app\x20you\x20want\x20to\x20test\x20is\x20behind','TQZcn':'auth,\x20you\x20can\x20log\x20in\x20and\x20we\x27ll\x20save\x20the\x20session\x20state\x20for\x20Ranger\x20to','icGWC':_0x3b56f8(0x128),'Eksnp':_0x3b56f8(0x114),'sGLJU':function(_0x3185d2){return _0x3185d2();},'nYCBK':'\x0a❌\x20Profile\x20setup\x20failed:','VYSey':function(_0x5e2aad){return _0x5e2aad();}};if(!findGitRoot())return console['log'](_0x3b56f8(0xda)),{'ready':![],'skipped':!![]};if(_0x2f02b6['XAHiG'](findExistingEnv,_0x2f02b6[_0x3b56f8(0x10a)],{'locations':[_0x2f02b6['rKBdy']]}))return console['log'](_0x2f02b6[_0x3b56f8(0xf2)]),{'ready':!![],'skipped':![]};const _0x4734fe=process[_0x3b56f8(0x126)][_0x3b56f8(0xdb)]&&process['stdout']['isTTY'];if(_0x4734fe&&!_0x4dfdd0?.[_0x3b56f8(0x117)]){console['log'](_0x3b56f8(0xd0)),console['log'](_0x2f02b6['elfjy']),console['log'](_0x2f02b6['TQZcn']),console['log'](_0x2f02b6[_0x3b56f8(0xed)]),console[_0x3b56f8(0x103)](_0x2f02b6['Eksnp']);const {wantsProfile:_0x5e01fa}=await _0x1f261d['prompt']([{'type':'confirm','name':_0x3b56f8(0x10d),'message':'Would\x20you\x20like\x20to\x20set\x20up\x20the\x20profile\x20now?','default':!![]}]);if(!_0x5e01fa)return _0x2f02b6[_0x3b56f8(0x120)](printProfileSetupLaterInstructions),{'ready':![],'skipped':!![]};}try{return await addEnv('local',{'url':_0x4dfdd0?.['url'],'force':_0x4dfdd0?.['force']},_0x40e9cd),{'ready':!![],'skipped':![]};}catch(_0xe60c72){return console[_0x3b56f8(0x11b)](_0x2f02b6['nYCBK'],_0xe60c72 instanceof Error?_0xe60c72[_0x3b56f8(0xcd)]:_0xe60c72),_0x2f02b6[_0x3b56f8(0xfd)](printProfileSetupLaterInstructions),{'ready':![],'skipped':![]};}}export async function start(_0x3716d9,_0x24b9da,_0x3887ae){const _0x27ff84=_0x933dd,_0x16e583={'TDMoO':_0x27ff84(0xd3),'cpQPF':_0x27ff84(0x12d),'PzasF':'git_check','qsbdU':function(_0x5b6fcd){return _0x5b6fcd();},'nbcrd':_0x27ff84(0x12e),'MFPMC':_0x27ff84(0xca),'rHXyS':'auth','dHDUY':function(_0x4fbb93,_0x5c24bb){return _0x4fbb93(_0x5c24bb);},'sPRTA':_0x27ff84(0x11c),'eBkKk':_0x27ff84(0xe2),'OrgKE':'plugin','qOoUk':function(_0x3d96c9,_0xcfd9ff,_0xc8ff9f){return _0x3d96c9(_0xcfd9ff,_0xc8ff9f);},'XFPve':function(_0x232536,_0x57fbef){return _0x232536 instanceof _0x57fbef;},'iCKIs':'skills','LMjUk':_0x27ff84(0xe4),'alGmi':_0x27ff84(0x116),'skmes':_0x27ff84(0xf0)};console['log'](_0x16e583['TDMoO']);const _0x44a21e=process['stdin'][_0x27ff84(0xdb)]&&process[_0x27ff84(0x125)][_0x27ff84(0xdb)];!_0x44a21e&&!_0x24b9da?.[_0x27ff84(0x104)]&&(console[_0x27ff84(0x103)](_0x16e583['cpQPF']),_0x24b9da={..._0x24b9da,'scope':'user'});_0x3887ae?.[_0x27ff84(0xe1)](_0x16e583['PzasF']);if(!_0x16e583[_0x27ff84(0xd9)](findGitRoot)){await _0x3887ae?.[_0x27ff84(0xd5)]('git_check',new Error(_0x16e583['nbcrd']));throw new Error(_0x16e583['MFPMC']);}_0x3887ae?.[_0x27ff84(0xff)](_0x16e583['PzasF']);const _0x8dd532=!existsSync(getRangerDir()),{path:_0x4cdbf4}=await _0x16e583['qsbdU'](ensureRangerDir);_0x3887ae?.['trackPhaseStart'](_0x16e583[_0x27ff84(0x10f)]);const _0x3a64b3=await _0x16e583['dHDUY'](authenticate,_0x3716d9);_0x3887ae?.['trackPhaseEnd'](_0x16e583[_0x27ff84(0x10f)],{'isFirstRun':_0x8dd532,'method':_0x3a64b3[_0x27ff84(0x100)]}),_0x3887ae?.['trackPhaseStart'](_0x16e583['sPRTA']);_0x24b9da?.[_0x27ff84(0xf8)]?console['log'](_0x16e583['eBkKk']):await ensureChromium();_0x3887ae?.[_0x27ff84(0xff)](_0x27ff84(0x11c),{'isFirstRun':_0x8dd532,'skipped':!!_0x24b9da?.[_0x27ff84(0xf8)]}),await writeRangerGitignore(_0x4cdbf4),console[_0x27ff84(0x103)]('\x0a✅\x20Ranger\x20setup\x20complete!\x0a');const _0x1c0b46=_0x24b9da?.[_0x27ff84(0x104)],_0x5bf95f=_0x24b9da?.['opencode']??![];let _0xb09d23=null;_0x5bf95f?(_0x3887ae?.[_0x27ff84(0xe1)](_0x27ff84(0xfc)),_0xb09d23=await _0x16e583['dHDUY'](ensureOpencodePluginConfig,_0x1c0b46),_0x3887ae?.['trackPhaseEnd'](_0x16e583[_0x27ff84(0x10e)],{'isFirstRun':_0x8dd532,'opencode':!![]})):(_0x3887ae?.[_0x27ff84(0xe1)](_0x27ff84(0xfc)),await ensureClaudePlugin(_0x1c0b46),_0x3887ae?.['trackPhaseEnd'](_0x27ff84(0xfc),{'isFirstRun':_0x8dd532}));if(_0x5bf95f&&_0xb09d23){_0x3887ae?.['trackPhaseStart'](_0x27ff84(0xea));try{await _0x16e583['qOoUk'](installSkill,_0x27ff84(0xef),{'level':_0xb09d23[_0x27ff84(0x104)],'cliVersion':getCurrentVersion(),'platform':'opencode'}),_0x3887ae?.['trackPhaseEnd']('skills',{'isFirstRun':_0x8dd532,'opencode':!![]});}catch(_0x55ef95){console[_0x27ff84(0x122)](_0x27ff84(0xe9),_0x16e583['XFPve'](_0x55ef95,Error)?_0x55ef95['message']:_0x55ef95),_0x3887ae?.[_0x27ff84(0xff)](_0x27ff84(0xea),{'isFirstRun':_0x8dd532,'opencode':!![],'failed':!![]});}}else _0x3887ae?.['trackPhaseStart'](_0x16e583[_0x27ff84(0xf9)]),await _0x16e583['dHDUY'](ensureClaudeSkills,_0x1c0b46),_0x3887ae?.[_0x27ff84(0xff)](_0x27ff84(0xea),{'isFirstRun':_0x8dd532});if(!_0x44a21e&&!_0x24b9da?.[_0x27ff84(0x117)])console[_0x27ff84(0x103)](_0x27ff84(0xbd)),console[_0x27ff84(0x103)]('\x20\x20'+_0x16e583['dHDUY'](bold,_0x27ff84(0xe6))+'\x0a');else{_0x3887ae?.['trackPhaseStart'](_0x16e583['LMjUk']);const _0x1b6c64=await _0x16e583[_0x27ff84(0x130)](ensureLocalEnv,{'url':_0x24b9da?.[_0x27ff84(0x117)],'force':_0x24b9da?.[_0x27ff84(0xf1)]},_0x3887ae);_0x3887ae?.[_0x27ff84(0xff)](_0x16e583[_0x27ff84(0xd2)],{'isFirstRun':_0x8dd532,'profileReady':_0x1b6c64['ready'],'userSkipped':_0x1b6c64[_0x27ff84(0xc6)]}),_0x1b6c64['ready']&&console[_0x27ff84(0x103)]('\x0a✅\x20You\x27re\x20ready\x20to\x20start\x20using\x20Ranger\x20Feature\x20Review.');}if(_0x5bf95f)console[_0x27ff84(0x103)](_0x27ff84(0xde)),console['log']('and\x20prompt\x20the\x20agent\x20like\x20usual.\x20Ranger\x20will\x20create\x20a\x20feature\x20review'),console['log'](_0x27ff84(0xdc)),console[_0x27ff84(0x103)](_0x16e583[_0x27ff84(0xd4)]);else{const _0x3b4661=_0x16e583['dHDUY'](bold,_0x16e583['skmes']);console['log'](_0x27ff84(0xf4)+_0x3b4661+'\x20and\x20prompt\x20the\x20coding'+'\x0aagent\x20like\x20usual.\x20Claude\x20will\x20create\x20a\x20feature\x20review\x20with'+_0x27ff84(0xec)+_0x27ff84(0xdf));}}
@@ -1 +1 @@
1
- const _0x40e51a=_0x332c;function _0x3415(){const _0x48751a=['hLFFN','configured','YXTzh','fwagZ','none','not_configured','CzoxU','not_installed','rwQmL','user','cMinP','success','cwd','YazTW','sljAi','LiUBQ','PLkZU','SoBAM','494933nbyLex','some','\x20\x20OpenCode\x20not\x20installed\x20or\x20not\x20available','HgJzQ','\x20\x20Run:\x20ranger\x20profile\x20add\x20<profile-name>','isArray','\x0a📊\x20Ranger\x20Status\x0a','disabled','path','includes','\x20\x20Run:\x20ranger\x20setup\x20--opencode','\x0a---\x20Claude\x20Code\x20Plugin\x20---','3TUTCsP','stderr','32748TCpLqc','status','\x1b[0m','\x20\x20\x20\x20','\x20\x20Run:\x20ranger\x20setup\x20[token]\x20\x20(includes\x20plugin\x20installation)','7860349KinOzc','\x0a---\x20OpenCode\x20Plugin\x20---','DIEKZ','GtLFY','55tqtRwI','RtZfs','displayName','\x1b[1m','iNfCa','DEaIU','ifhEe','mrejl','99400jhEowo','name','DEBUG','1460324tVCIps','NfQuR','QsbVX','settingsPath','auth.json','utf-8','nOtXo','plugin','cKUBW','string','\x20\x20Run:\x20ranger\x20setup\x20[token]\x0a','tHKMV','details','\x20\x20Not\x20configured',':\x20installed\x20(','\x20\x20User-level:','filter','\x20\x20Run:\x20ranger\x20setup\x20[token]','length','\x0aRanger\x20has\x20not\x20been\x20initialized\x20in\x20this\x20directory.','NjZpq','SJNHr','toString','SKILL.md','cwHnx','\x20(latest:\x20','(not\x20found)','KoOvh','map','hasEncryptedAuth','DjPeR','@ranger-testing/opencode-plugin','TWeBU','pipe','error','vIvVg','JVyQN','\x20\x20\x20\x20Auth:\x20','wudaF','parse','ukKlP','\x20\x20Not\x20installed','enabled','\x0a---\x20Profiles\x20---','\x0a---\x20Skills\x20---','log','\x20\x20Run:\x20ranger\x20profile\x20use\x20<profile-name>\x20\x20(available:\x20','zzvLf','910gnFqmo','lzHqK','hasPlaintextAuth','621TGgmmX','1053650AsmEWS','Version:\x20','2JCyoSs','\x20plugin(s)\x20configured','Root:\x20','nwfhq','1208352NFxvlp','encrypted'];_0x3415=function(){return _0x48751a;};return _0x3415();}(function(_0x57243c,_0x131d1c){const _0xdf0e70=_0x332c,_0x5a78df=_0x57243c();while(!![]){try{const _0x42090a=parseInt(_0xdf0e70(0x1b4))/0x1*(-parseInt(_0xdf0e70(0x19c))/0x2)+parseInt(_0xdf0e70(0x1c0))/0x3*(parseInt(_0xdf0e70(0x166))/0x4)+-parseInt(_0xdf0e70(0x196))/0x5*(-parseInt(_0xdf0e70(0x1c2))/0x6)+parseInt(_0xdf0e70(0x1c7))/0x7+parseInt(_0xdf0e70(0x163))/0x8*(-parseInt(_0xdf0e70(0x199))/0x9)+parseInt(_0xdf0e70(0x19a))/0xa*(-parseInt(_0xdf0e70(0x15b))/0xb)+parseInt(_0xdf0e70(0x1a0))/0xc;if(_0x42090a===_0x131d1c)break;else _0x5a78df['push'](_0x5a78df['shift']());}catch(_0x19ca17){_0x5a78df['push'](_0x5a78df['shift']());}}}(_0x3415,0xab9ed));import{readFile,readdir}from'fs/promises';import{join,basename}from'path';import{existsSync}from'fs';import{getToken}from'./utils/keychain.js';import{getCurrentVersion,getLatestVersion}from'./utils/version.js';import{getApiBaseUrl,getCurrentEnvironment}from'./utils/environment.js';import{getProjectSkillsDir,getUserSkillsDir}from'./utils/claudeConfig.js';import{getEnvNames}from'./env.js';import{getCurrentUser}from'./utils/userApi.js';import{getRangerDir}from'./utils/rangerRoot.js';import{getEnvDir}from'./utils/settings.js';import{getPluginInfo}from'./utils/claudePlugin.js';import{RANGER_MANAGED_SKILLS}from'./utils/skills.js';import{spawn}from'child_process';function _0x332c(_0x235967,_0x1dbfb3){_0x235967=_0x235967-0x15b;const _0x34158a=_0x3415();let _0x332c50=_0x34158a[_0x235967];return _0x332c50;}const bold=_0x2f1bbc=>_0x40e51a(0x15e)+_0x2f1bbc+_0x40e51a(0x1c4),link=(_0x2684dd,_0x2d63ff)=>'\x1b]8;;file://'+_0x2684dd+'\x07'+(_0x2d63ff||_0x2684dd)+'\x1b]8;;\x07';async function getOpencodePluginStatus(){const _0xb0566d=_0x40e51a,_0x578b80={'nOtXo':_0xb0566d(0x1a9),'Viirt':function(_0x561394,_0x3b38b0){return _0x561394(_0x3b38b0);},'YazTW':_0xb0566d(0x1a7),'DjPeR':function(_0x55fe8b,_0x57f642,_0x1c604c,_0x44e1dc){return _0x55fe8b(_0x57f642,_0x1c604c,_0x44e1dc);},'LiUBQ':'config','RtZfs':_0xb0566d(0x187),'HgJzQ':'data','ifhEe':'close'};return new Promise(_0x491012=>{const _0x5430de=_0xb0566d,_0x23ae20={'tHKMV':function(_0x54b84f,_0x452942){return _0x54b84f(_0x452942);},'vIvVg':function(_0x36f022,_0x50fbe0){return _0x578b80['Viirt'](_0x36f022,_0x50fbe0);},'isQxu':_0x5430de(0x1a3),'pNWpc':_0x578b80[_0x5430de(0x1af)]},_0x4ae283=_0x578b80[_0x5430de(0x184)](spawn,'opencode',['debug',_0x578b80[_0x5430de(0x1b1)]],{'stdio':['ignore',_0x578b80[_0x5430de(0x15c)],_0x5430de(0x187)]});let _0x38977f='';_0x4ae283['stdout']?.['on']('data',_0x36740e=>{const _0x5b7011=_0x5430de;_0x38977f+=_0x36740e[_0x5b7011(0x17c)]();}),_0x4ae283[_0x5430de(0x1c1)]?.['on'](_0x578b80[_0x5430de(0x1b7)],_0x535e37=>{_0x38977f+=_0x535e37['toString']();}),_0x4ae283['on'](_0x5430de(0x188),()=>{const _0x358689=_0x5430de;_0x491012({'status':_0x578b80[_0x358689(0x16c)]});}),_0x4ae283['on'](_0x578b80[_0x5430de(0x161)],_0x502e14=>{const _0x2ec4e6=_0x5430de,_0x105793={'vMtSq':_0x2ec4e6(0x16f)};if(_0x502e14!==0x0){_0x23ae20['tHKMV'](_0x491012,{'status':'not_installed'});return;}const _0x489a27=_0x38977f['trim']();let _0x549a3d=null;if(_0x489a27)try{_0x549a3d=JSON[_0x2ec4e6(0x18d)](_0x489a27);}catch{const _0x59ce0c=_0x489a27['match'](/\{[\s\S]*\}$/);if(_0x59ce0c)try{_0x549a3d=JSON['parse'](_0x59ce0c[0x0]);}catch{_0x549a3d=null;}}const _0x4c7a3e=Array[_0x2ec4e6(0x1b9)](_0x549a3d?.[_0x2ec4e6(0x16d)])?_0x549a3d?.['plugin']:[],_0x58ff8d=_0x4c7a3e[_0x2ec4e6(0x1b5)](_0x2d0760=>{const _0x3c07ce=_0x2ec4e6;if(typeof _0x2d0760!==_0x105793['vMtSq'])return![];return _0x2d0760['includes'](_0x3c07ce(0x185))||_0x2d0760['includes']('opencode-plugin');});if(_0x58ff8d){_0x23ae20['vIvVg'](_0x491012,{'status':_0x23ae20['isQxu'],'details':_0x4c7a3e[_0x2ec4e6(0x178)]>0x0?_0x4c7a3e[_0x2ec4e6(0x178)]+'\x20plugin(s)\x20configured':undefined});return;}if(_0x4c7a3e[_0x2ec4e6(0x178)]>0x0){_0x23ae20[_0x2ec4e6(0x189)](_0x491012,{'status':_0x23ae20['pNWpc'],'details':_0x4c7a3e['length']+_0x2ec4e6(0x19d)});return;}_0x23ae20[_0x2ec4e6(0x171)](_0x491012,{'status':'not_configured'});});});}async function getSkillsFromDir(_0x5f2287,_0x5c083c){const _0x460237=_0x40e51a,_0x18a002={'wudaF':function(_0x3efb58,_0x43e653){return _0x3efb58(_0x43e653);},'aaCnx':function(_0x5bb82c,_0xaa19d4,_0x248135){return _0x5bb82c(_0xaa19d4,_0x248135);}};if(!_0x18a002[_0x460237(0x18c)](existsSync,_0x5f2287))return[];const _0x48690b=[];try{const _0x2fb374=await _0x18a002['aaCnx'](readdir,_0x5f2287,{'withFileTypes':!![]});for(const _0x1829b7 of _0x2fb374){if(_0x1829b7['isDirectory']()){const _0x2cb73c=join(_0x5f2287,_0x1829b7[_0x460237(0x164)],_0x460237(0x17d));if(existsSync(_0x2cb73c)){let _0x5cc7e5=_0x1829b7[_0x460237(0x164)];try{const _0x4f4ac9=await _0x18a002['aaCnx'](readFile,_0x2cb73c,_0x460237(0x16b)),_0x669fc6=_0x4f4ac9['match'](/name:\s*(.+)/);_0x669fc6&&(_0x5cc7e5=_0x669fc6[0x1]['trim']());}catch{}_0x48690b['push']({'name':_0x1829b7[_0x460237(0x164)],'displayName':_0x5cc7e5,'path':_0x2cb73c,'level':_0x5c083c});}}}}catch{return[];}return _0x48690b;}async function getInstalledSkills(){const _0x47d0cc=_0x40e51a,_0x304661={'JVyQN':function(_0x16fcbb,_0x33777d,_0x7fa99d){return _0x16fcbb(_0x33777d,_0x7fa99d);},'iNfCa':function(_0x413ef2){return _0x413ef2();},'SJNHr':'project','YZwqY':_0x47d0cc(0x1ab)},[_0x31042d,_0x235850]=await Promise['all']([_0x304661['JVyQN'](getSkillsFromDir,_0x304661[_0x47d0cc(0x15f)](getProjectSkillsDir),_0x304661[_0x47d0cc(0x17b)]),_0x304661[_0x47d0cc(0x18a)](getSkillsFromDir,getUserSkillsDir(),_0x304661['YZwqY'])]);return{'project':_0x31042d,'user':_0x235850};}async function getEnvironments(){const _0x56e0e3=_0x40e51a,_0x3e54f7={'cKUBW':'settings.json','nwfhq':function(_0x15d696,_0x256a74,_0x563e59){return _0x15d696(_0x256a74,_0x563e59);},'TWeBU':_0x56e0e3(0x16a),'PLkZU':function(_0x4ab7cb,_0x2db50f,_0x53abc4){return _0x4ab7cb(_0x2db50f,_0x53abc4);},'DEaIU':function(_0x361107){return _0x361107();}},{envNames:_0x369020,activeEnv:_0x4b630c}=await getEnvNames(),_0x445f78=_0x3e54f7[_0x56e0e3(0x160)](getRangerDir);if(!existsSync(_0x445f78))return{'envs':[],'activeEnv':null};const _0x66f99=_0x369020['map'](_0x1d9891=>{const _0x2f2ec8=_0x56e0e3,_0x2e108f=getEnvDir(_0x1d9891),_0x4dd5bc=join(_0x2e108f,_0x3e54f7[_0x2f2ec8(0x16e)]),_0x4c8264=_0x3e54f7[_0x2f2ec8(0x19f)](join,_0x2e108f,_0x3e54f7[_0x2f2ec8(0x186)]),_0x14ba06=_0x3e54f7[_0x2f2ec8(0x1b2)](join,_0x2e108f,'auth.json.enc');return{'name':_0x1d9891,'settingsPath':existsSync(_0x4dd5bc)?_0x4dd5bc:_0x2f2ec8(0x180),'hasPlaintextAuth':existsSync(_0x4c8264),'hasEncryptedAuth':existsSync(_0x14ba06),'isActive':_0x1d9891===_0x4b630c};});return{'envs':_0x66f99,'activeEnv':_0x4b630c};}export async function status(){const _0x3218aa=_0x40e51a,_0x275839={'zzvLf':function(_0x65127b){return _0x65127b();},'BzTKz':function(_0x257a1e,_0x3765ed){return _0x257a1e(_0x3765ed);},'YXTzh':function(_0x47c909,_0x148080){return _0x47c909(_0x148080);},'NfQuR':function(_0x188293,_0x2441d8,_0x4c6c88){return _0x188293(_0x2441d8,_0x4c6c88);},'KoOvh':function(_0x288f8c){return _0x288f8c();},'sljAi':function(_0x43e437,_0x53c9cc){return _0x43e437!==_0x53c9cc;},'fwagZ':function(_0x5553db,_0x18e991){return _0x5553db(_0x18e991);},'QsbVX':'@ranger-testing/opencode-plugin','UttCb':_0x3218aa(0x1a7),'DIEKZ':_0x3218aa(0x173),'WUEmD':_0x3218aa(0x1be),'lzHqK':_0x3218aa(0x1bf),'ukKlP':'enabled','hLFFN':_0x3218aa(0x1bb),'lUwaU':'ranger@trailhead','rwQmL':_0x3218aa(0x18f),'jmoWK':_0x3218aa(0x192),'NjZpq':function(_0xaeda){return _0xaeda();},'mrejl':function(_0x57a56f,_0x264939){return _0x57a56f===_0x264939;},'CzoxU':'No\x20skills\x20installed','gkOsc':function(_0x50a1c7,_0x191583){return _0x50a1c7>_0x191583;},'kqHMv':function(_0x56d14e,_0x5b57e,_0x12f9e4){return _0x56d14e(_0x5b57e,_0x12f9e4);},'SoBAM':_0x3218aa(0x175),'EMcWw':_0x3218aa(0x191),'IaYbT':function(_0x2fb0d0){return _0x2fb0d0();},'cMinP':_0x3218aa(0x1a1),'qVGYY':'plaintext','cwHnx':_0x3218aa(0x1a6),'GtLFY':_0x3218aa(0x180)};console[_0x3218aa(0x193)](_0x3218aa(0x1ba));const _0x3dffff=process[_0x3218aa(0x1ae)](),_0x52e1bd=_0x275839[_0x3218aa(0x195)](getRangerDir);if(!_0x275839['BzTKz'](existsSync,_0x52e1bd)){console['log'](_0x3218aa(0x19e)+link(_0x3dffff,_0x275839['YXTzh'](bold,basename(_0x3dffff)))),console[_0x3218aa(0x193)](_0x3218aa(0x179)),console['log'](_0x3218aa(0x170));return;}console['log'](_0x3218aa(0x19e)+_0x275839[_0x3218aa(0x167)](link,_0x3dffff,bold(_0x275839[_0x3218aa(0x1a4)](basename,_0x3dffff))));const _0x39f33a=getCurrentVersion(),_0x4347fd=_0x275839[_0x3218aa(0x181)](getLatestVersion);if(_0x4347fd&&_0x275839[_0x3218aa(0x1b0)](_0x4347fd,_0x39f33a))console['log'](_0x3218aa(0x19b)+_0x39f33a+_0x3218aa(0x17f)+_0x4347fd+')'),console['log']('\x20\x20Run:\x20ranger\x20update');else _0x4347fd?console[_0x3218aa(0x193)](_0x3218aa(0x19b)+_0x39f33a+'\x20(up\x20to\x20date)'):console['log']('Version:\x20'+_0x39f33a);const _0x1d9f97=await getToken();if(_0x1d9f97){const _0x4b951a=await getCurrentUser(_0x1d9f97);_0x4b951a[_0x3218aa(0x1ad)]?console[_0x3218aa(0x193)]('Organization:\x20'+bold(_0x4b951a['user']['organizationName'])):(console['log']('API\x20Token:\x20✓\x20Found\x20but\x20invalid\x20or\x20expired'),console[_0x3218aa(0x193)](_0x3218aa(0x177)));}else console['log']('API\x20Token:\x20✗\x20Not\x20found'),console[_0x3218aa(0x193)](_0x3218aa(0x177));process['env'][_0x3218aa(0x165)]&&(console['log']('API\x20Environment:\x20'+_0x275839['zzvLf'](getCurrentEnvironment)),console[_0x3218aa(0x193)]('API\x20URL:\x20'+getApiBaseUrl()));console[_0x3218aa(0x193)](_0x3218aa(0x1c8));const _0x328cb8=await _0x275839[_0x3218aa(0x195)](getOpencodePluginStatus);if(_0x328cb8['status']==='configured')console[_0x3218aa(0x193)]('\x20\x20'+_0x275839[_0x3218aa(0x1a5)](bold,_0x275839[_0x3218aa(0x168)])+':\x20configured'),_0x328cb8[_0x3218aa(0x172)]&&console[_0x3218aa(0x193)]('\x20\x20'+_0x328cb8['details']);else _0x328cb8[_0x3218aa(0x1c3)]===_0x275839['UttCb']?(console['log'](_0x275839[_0x3218aa(0x1c9)]),_0x328cb8[_0x3218aa(0x172)]&&console['log']('\x20\x20'+_0x328cb8['details']),console['log'](_0x275839['WUEmD'])):console['log'](_0x3218aa(0x1b6));console['log'](_0x275839[_0x3218aa(0x197)]);const _0x16515d=await getPluginInfo('ranger@trailhead');if(_0x16515d){const _0x4995a0=_0x16515d['scope']||'unknown',_0x1b011a=_0x16515d[_0x3218aa(0x190)]?_0x275839[_0x3218aa(0x18e)]:_0x275839[_0x3218aa(0x1a2)];console['log']('\x20\x20'+bold(_0x275839['lUwaU'])+_0x3218aa(0x174)+_0x4995a0+',\x20'+_0x1b011a+')');}else console[_0x3218aa(0x193)](_0x275839[_0x3218aa(0x1aa)]),console['log'](_0x3218aa(0x1c6));console['log'](_0x275839['jmoWK']);const {project:_0x999349,user:_0x3f7750}=await _0x275839[_0x3218aa(0x17a)](getInstalledSkills),_0x258fd0=_0x999349[_0x3218aa(0x176)](_0x30d2a8=>RANGER_MANAGED_SKILLS['includes'](_0x30d2a8['name'])),_0x20a2da=_0x3f7750[_0x3218aa(0x176)](_0x1cda3a=>RANGER_MANAGED_SKILLS[_0x3218aa(0x1bd)](_0x1cda3a[_0x3218aa(0x164)])),_0x20b3b5=_0x258fd0['length']+_0x20a2da['length'];if(_0x275839[_0x3218aa(0x162)](_0x20b3b5,0x0))console[_0x3218aa(0x193)](_0x275839[_0x3218aa(0x1a8)]),console[_0x3218aa(0x193)]('\x20\x20Run:\x20ranger\x20skillup');else{if(_0x275839['gkOsc'](_0x258fd0['length'],0x0)){console[_0x3218aa(0x193)]('\x20\x20Project-level:');for(const _0x314d09 of _0x258fd0){console['log'](_0x3218aa(0x1c5)+bold(_0x314d09[_0x3218aa(0x15d)])+':\x20'+_0x275839['kqHMv'](link,_0x314d09[_0x3218aa(0x1bc)],basename(_0x314d09[_0x3218aa(0x1bc)])));}}if(_0x275839['gkOsc'](_0x20a2da['length'],0x0)){console[_0x3218aa(0x193)](_0x275839[_0x3218aa(0x1b3)]);for(const _0x4ab420 of _0x20a2da){console['log']('\x20\x20\x20\x20'+bold(_0x4ab420['displayName'])+':\x20'+link(_0x4ab420['path'],basename(_0x4ab420['path'])));}}}console[_0x3218aa(0x193)](_0x275839['EMcWw']);const {envs:_0x402eb3,activeEnv:_0x688cdb}=await _0x275839['IaYbT'](getEnvironments);if(_0x275839['mrejl'](_0x402eb3[_0x3218aa(0x178)],0x0))console['log']('No\x20profiles\x20configured'),console[_0x3218aa(0x193)](_0x3218aa(0x1b8));else{for(const _0x1a8bcd of _0x402eb3){const _0x410ff2=_0x1a8bcd['isActive']?'\x20(active)':'',_0x25bc4f=_0x1a8bcd[_0x3218aa(0x183)]?_0x275839[_0x3218aa(0x1ac)]:_0x1a8bcd[_0x3218aa(0x198)]?_0x275839['qVGYY']:_0x275839[_0x3218aa(0x17e)];console[_0x3218aa(0x193)]('\x20\x20'+bold(_0x1a8bcd[_0x3218aa(0x164)])+_0x410ff2),console[_0x3218aa(0x193)](_0x3218aa(0x18b)+_0x25bc4f),_0x1a8bcd['settingsPath']!==_0x275839[_0x3218aa(0x1ca)]&&console[_0x3218aa(0x193)]('\x20\x20\x20\x20Settings:\x20'+_0x275839['kqHMv'](link,_0x1a8bcd[_0x3218aa(0x169)],basename(_0x1a8bcd['settingsPath'])));}!_0x688cdb&&(console[_0x3218aa(0x193)]('\x0a\x20\x20No\x20active\x20profile\x20set'),console[_0x3218aa(0x193)](_0x3218aa(0x194)+_0x402eb3[_0x3218aa(0x182)](_0x36f0ac=>_0x36f0ac['name'])['join'](',\x20')+')'));}console['log']('');}
1
+ const _0x4e2ecf=_0x1aa3;(function(_0x3a5014,_0x3ce99e){const _0x350576=_0x1aa3,_0x2d0194=_0x3a5014();while(!![]){try{const _0x2e2322=parseInt(_0x350576(0xd2))/0x1+-parseInt(_0x350576(0x10e))/0x2*(-parseInt(_0x350576(0xfa))/0x3)+parseInt(_0x350576(0x117))/0x4+-parseInt(_0x350576(0xfb))/0x5*(-parseInt(_0x350576(0xcc))/0x6)+-parseInt(_0x350576(0x101))/0x7*(-parseInt(_0x350576(0xe3))/0x8)+-parseInt(_0x350576(0x109))/0x9+-parseInt(_0x350576(0xb9))/0xa*(parseInt(_0x350576(0xbe))/0xb);if(_0x2e2322===_0x3ce99e)break;else _0x2d0194['push'](_0x2d0194['shift']());}catch(_0x21a339){_0x2d0194['push'](_0x2d0194['shift']());}}}(_0x45ad,0x72fd5));import{readFile,readdir}from'fs/promises';import{join,basename}from'path';import{existsSync}from'fs';import{getToken}from'./utils/keychain.js';import{getCurrentVersion,getLatestVersion}from'./utils/version.js';import{getApiBaseUrl,getCurrentEnvironment}from'./utils/environment.js';import{getProjectSkillsDir,getUserSkillsDir}from'./utils/claudeConfig.js';import{getEnvNames}from'./env.js';import{getCurrentUser}from'./utils/userApi.js';import{getRangerDir}from'./utils/rangerRoot.js';import{getEnvDir}from'./utils/settings.js';function _0x1aa3(_0x2bba6c,_0x6cb708){_0x2bba6c=_0x2bba6c-0xaf;const _0x45ada0=_0x45ad();let _0x1aa30d=_0x45ada0[_0x2bba6c];return _0x1aa30d;}import{getPluginInfo}from'./utils/claudePlugin.js';import{RANGER_MANAGED_SKILLS}from'./utils/skills.js';import{spawn}from'child_process';const bold=_0x4b26f3=>'\x1b[1m'+_0x4b26f3+_0x4e2ecf(0xf5),link=(_0xfea85d,_0x3b2887)=>'\x1b]8;;file://'+_0xfea85d+'\x07'+(_0x3b2887||_0xfea85d)+'\x1b]8;;\x07';async function getOpencodePluginStatus(){const _0x4776bd=_0x4e2ecf,_0x40bf3b={'NbqAw':function(_0x1b6a81,_0xcbc62e){return _0x1b6a81(_0xcbc62e);},'JNYza':'not_configured','mRmFl':_0x4776bd(0xdc),'Opnyv':function(_0x57b74b,_0x1d8e32,_0x16e863,_0x3f7c9b){return _0x57b74b(_0x1d8e32,_0x16e863,_0x3f7c9b);},'vAtCO':'opencode','OLamI':'config','kzyta':_0x4776bd(0x10a),'YQFoH':_0x4776bd(0xc9)};return new Promise(_0x5e16d3=>{const _0x480ca3=_0x4776bd,_0x511604={'FMrhy':_0x40bf3b[_0x480ca3(0xd6)]},_0x328e0a=_0x40bf3b[_0x480ca3(0x115)](spawn,_0x40bf3b['vAtCO'],['debug',_0x40bf3b['OLamI']],{'stdio':[_0x480ca3(0xf7),'pipe','pipe']});let _0x5b5e1a='';_0x328e0a[_0x480ca3(0xd0)]?.['on']('data',_0x2a28b9=>{const _0x380640=_0x480ca3;_0x5b5e1a+=_0x2a28b9[_0x380640(0x10f)]();}),_0x328e0a[_0x480ca3(0x118)]?.['on'](_0x480ca3(0xcd),_0x328b35=>{const _0x3a76dd=_0x480ca3;_0x5b5e1a+=_0x328b35[_0x3a76dd(0x10f)]();}),_0x328e0a['on'](_0x40bf3b['kzyta'],()=>{_0x5e16d3({'status':_0x511604['FMrhy']});}),_0x328e0a['on'](_0x40bf3b['YQFoH'],_0x14220a=>{const _0x543dce=_0x480ca3,_0x1b4c88={'coMdu':_0x543dce(0x111)};if(_0x14220a!==0x0){_0x5e16d3({'status':_0x543dce(0xdc)});return;}const _0x52cb77=_0x5b5e1a['trim']();let _0x49e9d5=null;if(_0x52cb77)try{_0x49e9d5=JSON['parse'](_0x52cb77);}catch{const _0x4daf1e=_0x52cb77[_0x543dce(0xb4)](/\{[\s\S]*\}$/);if(_0x4daf1e)try{_0x49e9d5=JSON[_0x543dce(0xb0)](_0x4daf1e[0x0]);}catch{_0x49e9d5=null;}}const _0x179344=Array[_0x543dce(0xbc)](_0x49e9d5?.[_0x543dce(0xf3)])?_0x49e9d5?.['plugin']:[],_0x4f56fa=_0x179344['some'](_0x577ff8=>{const _0x3aaf64=_0x543dce;if(typeof _0x577ff8!=='string')return![];return _0x577ff8['includes']('@ranger-testing/opencode-plugin')||_0x577ff8['includes'](_0x1b4c88[_0x3aaf64(0x114)]);});if(_0x4f56fa){_0x40bf3b['NbqAw'](_0x5e16d3,{'status':_0x543dce(0xf2),'details':_0x179344['length']>0x0?_0x179344[_0x543dce(0x107)]+_0x543dce(0xfd):undefined});return;}if(_0x179344['length']>0x0){_0x40bf3b[_0x543dce(0xf0)](_0x5e16d3,{'status':_0x40bf3b[_0x543dce(0xeb)],'details':_0x179344['length']+_0x543dce(0xfd)});return;}_0x40bf3b[_0x543dce(0xf0)](_0x5e16d3,{'status':'not_configured'});});});}async function getSkillsFromDir(_0x24342d,_0x5483c6){const _0x188a55=_0x4e2ecf,_0x4c03d5={'uYeQO':function(_0x54ead9,_0x5cc9fb){return _0x54ead9(_0x5cc9fb);},'oKVsp':function(_0x283999,_0x359b75,_0x4c619f,_0x304580){return _0x283999(_0x359b75,_0x4c619f,_0x304580);},'CCnet':'SKILL.md','kveXJ':function(_0x26b14f,_0x455c2d,_0x276c9a){return _0x26b14f(_0x455c2d,_0x276c9a);}};if(!_0x4c03d5['uYeQO'](existsSync,_0x24342d))return[];const _0x4d0e14=[];try{const _0x1cd9ef=await readdir(_0x24342d,{'withFileTypes':!![]});for(const _0x371c7e of _0x1cd9ef){if(_0x371c7e[_0x188a55(0xb8)]()){const _0x21760b=_0x4c03d5[_0x188a55(0xb7)](join,_0x24342d,_0x371c7e[_0x188a55(0xdb)],_0x4c03d5[_0x188a55(0x102)]);if(existsSync(_0x21760b)){let _0x3d0196=_0x371c7e[_0x188a55(0xdb)];try{const _0x207ee4=await _0x4c03d5[_0x188a55(0xd3)](readFile,_0x21760b,'utf-8'),_0x5c93b5=_0x207ee4[_0x188a55(0xb4)](/name:\s*(.+)/);_0x5c93b5&&(_0x3d0196=_0x5c93b5[0x1]['trim']());}catch{}_0x4d0e14['push']({'name':_0x371c7e[_0x188a55(0xdb)],'displayName':_0x3d0196,'path':_0x21760b,'level':_0x5483c6});}}}}catch{return[];}return _0x4d0e14;}function _0x45ad(){const _0x392141=['uJtBH','project','encrypted','disabled','length','\x20\x20Run:\x20ranger\x20profile\x20use\x20<profile-name>\x20\x20(available:\x20','1121427WcuFFA','error','zoUoi','thEPF','details','1237526vVVapk','toString','\x20\x20Run:\x20ranger\x20update','opencode-plugin','rLEUe','No\x20profiles\x20configured','coMdu','Opnyv','\x20\x20\x20\x20Settings:\x20','432528fdBaUv','stderr','ocjTj','includes','parse','mNblU','ZAeuv','himZd','match','\x20(latest:\x20','CvqeE','oKVsp','isDirectory','16322270uSJsWx','cwd','user','isArray','path','11YcspBi','Version:\x20','ewlwA','ranger@trailhead','kWvbl','No\x20skills\x20installed','filter','OOCtg','Organization:\x20','\x0a\x20\x20No\x20active\x20profile\x20set','lyowf','close','log',':\x20configured','636SzjaHc','data','\x20\x20Run:\x20ranger\x20profile\x20add\x20<profile-name>','map','stdout','eaHjg','543350UvyCpC','kveXJ','isActive','status','mRmFl','\x0a---\x20Skills\x20---','\x20\x20\x20\x20Auth:\x20','kWELz','API\x20Environment:\x20','name','not_installed','CQBYl','\x20\x20OpenCode\x20not\x20installed\x20or\x20not\x20available','settingsPath','\x20\x20Run:\x20ranger\x20skillup','\x20\x20Run:\x20ranger\x20setup\x20[token]\x0a','vfExH','32YoTnYw','displayName','JnORv','\x20\x20Not\x20installed','hasPlaintextAuth','\x20\x20Run:\x20ranger\x20setup\x20--opencode','\x20\x20Not\x20configured','join','JNYza','\x20(up\x20to\x20date)','\x20\x20Run:\x20ranger\x20setup\x20[token]','(not\x20found)','DEBUG','NbqAw','lAGdE','configured','plugin','none','\x1b[0m','WmFTj','ignore','\x0a---\x20Profiles\x20---','\x0aRanger\x20has\x20not\x20been\x20initialized\x20in\x20this\x20directory.','3VYDieN','22585HvdwKe','gCTWb','\x20plugin(s)\x20configured','API\x20URL:\x20','not_configured','ogBdp','837865FXHszV','CCnet'];_0x45ad=function(){return _0x392141;};return _0x45ad();}async function getInstalledSkills(){const _0x49361e=_0x4e2ecf,_0x3148f2={'rLEUe':function(_0x438686,_0x2047ad,_0x2cee83){return _0x438686(_0x2047ad,_0x2cee83);},'CvqeE':_0x49361e(0x104),'rsXSN':function(_0x4a1706){return _0x4a1706();}},[_0x5288f6,_0x5117f3]=await Promise['all']([_0x3148f2[_0x49361e(0x112)](getSkillsFromDir,getProjectSkillsDir(),_0x3148f2[_0x49361e(0xb6)]),getSkillsFromDir(_0x3148f2['rsXSN'](getUserSkillsDir),_0x49361e(0xbb))]);return{'project':_0x5288f6,'user':_0x5117f3};}async function getEnvironments(){const _0x2e4b55=_0x4e2ecf,_0x2c305d={'wubSk':'settings.json','OTjya':function(_0x38e721,_0x5980ba){return _0x38e721(_0x5980ba);},'iJaiV':function(_0x267bb6,_0x4b751d){return _0x267bb6===_0x4b751d;}},{envNames:_0xc638ea,activeEnv:_0x3420db}=await getEnvNames(),_0x14ba61=getRangerDir();if(!existsSync(_0x14ba61))return{'envs':[],'activeEnv':null};const _0x59674e=_0xc638ea[_0x2e4b55(0xcf)](_0x50b9a9=>{const _0x4a53eb=_0x2e4b55,_0x39fce3=getEnvDir(_0x50b9a9),_0x43f517=join(_0x39fce3,_0x2c305d['wubSk']),_0x22a82f=join(_0x39fce3,'auth.json'),_0x1c6507=join(_0x39fce3,'auth.json.enc');return{'name':_0x50b9a9,'settingsPath':_0x2c305d['OTjya'](existsSync,_0x43f517)?_0x43f517:_0x4a53eb(0xee),'hasPlaintextAuth':existsSync(_0x22a82f),'hasEncryptedAuth':_0x2c305d['OTjya'](existsSync,_0x1c6507),'isActive':_0x2c305d['iJaiV'](_0x50b9a9,_0x3420db)};});return{'envs':_0x59674e,'activeEnv':_0x3420db};}export async function status(){const _0x51b418=_0x4e2ecf,_0x5bf406={'OOCtg':function(_0x1cae35,_0x468ddb){return _0x1cae35(_0x468ddb);},'JnORv':function(_0x14bb7b,_0x44b485,_0x2548ed){return _0x14bb7b(_0x44b485,_0x2548ed);},'ewlwA':function(_0x545b32,_0x46c53f){return _0x545b32(_0x46c53f);},'gCTWb':function(_0x160124){return _0x160124();},'thEPF':function(_0x1cab4a){return _0x1cab4a();},'KyJyd':function(_0xefe8fd){return _0xefe8fd();},'uBvDY':'\x0a---\x20OpenCode\x20Plugin\x20---','ZAeuv':_0x51b418(0xf2),'XoFpX':function(_0x1385fc,_0x4a1c33){return _0x1385fc===_0x4a1c33;},'zoUoi':_0x51b418(0xff),'lyowf':_0x51b418(0xe9),'jpwCZ':_0x51b418(0xde),'CQBYl':function(_0x5e01f4,_0x14302d){return _0x5e01f4(_0x14302d);},'eVWEu':'unknown','himZd':'enabled','Jgwul':_0x51b418(0xc1),'ZDpyA':'\x20\x20Run:\x20ranger\x20setup\x20[token]\x20\x20(includes\x20plugin\x20installation)','ocjTj':_0x51b418(0xd7),'NqVPP':function(_0x107495,_0x2ce572){return _0x107495===_0x2ce572;},'kWELz':_0x51b418(0xc3),'lAGdE':function(_0xfaeee,_0x23866b){return _0xfaeee>_0x23866b;},'ogBdp':'\x20\x20User-level:','eaHjg':function(_0x3423f1,_0x1b2a95){return _0x3423f1(_0x1b2a95);},'mNblU':_0x51b418(0xf8),'kWvbl':function(_0xf3609c,_0x47d570){return _0xf3609c===_0x47d570;},'eFKfb':_0x51b418(0x113),'vfExH':'plaintext','NTOwd':function(_0x78b97d,_0xbbdd8c){return _0x78b97d!==_0xbbdd8c;},'WmFTj':'(not\x20found)','uJtBH':function(_0x3236fa,_0xa26c1b,_0x3c6bdf){return _0x3236fa(_0xa26c1b,_0x3c6bdf);},'nGoxV':function(_0x400d97,_0x18853a){return _0x400d97(_0x18853a);}};console['log']('\x0a📊\x20Ranger\x20Status\x0a');const _0x4de0f6=process[_0x51b418(0xba)](),_0x555174=getRangerDir();if(!_0x5bf406[_0x51b418(0xc5)](existsSync,_0x555174)){console[_0x51b418(0xca)]('Root:\x20'+_0x5bf406[_0x51b418(0xe5)](link,_0x4de0f6,_0x5bf406['ewlwA'](bold,_0x5bf406[_0x51b418(0xc0)](basename,_0x4de0f6)))),console[_0x51b418(0xca)](_0x51b418(0xf9)),console[_0x51b418(0xca)](_0x51b418(0xe1));return;}console[_0x51b418(0xca)]('Root:\x20'+link(_0x4de0f6,bold(_0x5bf406[_0x51b418(0xc5)](basename,_0x4de0f6))));const _0x53ba01=getCurrentVersion(),_0x8570b=_0x5bf406[_0x51b418(0xfc)](getLatestVersion);if(_0x8570b&&_0x8570b!==_0x53ba01)console['log'](_0x51b418(0xbf)+_0x53ba01+_0x51b418(0xb5)+_0x8570b+')'),console['log'](_0x51b418(0x110));else _0x8570b?console[_0x51b418(0xca)]('Version:\x20'+_0x53ba01+_0x51b418(0xec)):console['log'](_0x51b418(0xbf)+_0x53ba01);const _0x1f54df=await _0x5bf406['gCTWb'](getToken);if(_0x1f54df){const _0x172fce=await getCurrentUser(_0x1f54df);_0x172fce['success']?console[_0x51b418(0xca)](_0x51b418(0xc6)+bold(_0x172fce['user']['organizationName'])):(console[_0x51b418(0xca)]('API\x20Token:\x20✓\x20Found\x20but\x20invalid\x20or\x20expired'),console[_0x51b418(0xca)](_0x51b418(0xed)));}else console[_0x51b418(0xca)]('API\x20Token:\x20✗\x20Not\x20found'),console['log'](_0x51b418(0xed));process['env'][_0x51b418(0xef)]&&(console['log'](_0x51b418(0xda)+_0x5bf406[_0x51b418(0x10c)](getCurrentEnvironment)),console[_0x51b418(0xca)](_0x51b418(0xfe)+_0x5bf406['KyJyd'](getApiBaseUrl)));console[_0x51b418(0xca)](_0x5bf406['uBvDY']);const _0x45b565=await _0x5bf406['gCTWb'](getOpencodePluginStatus);if(_0x45b565[_0x51b418(0xd5)]===_0x5bf406[_0x51b418(0xb2)])console['log']('\x20\x20'+_0x5bf406[_0x51b418(0xc0)](bold,'@ranger-testing/opencode-plugin')+_0x51b418(0xcb)),_0x45b565[_0x51b418(0x10d)]&&console[_0x51b418(0xca)]('\x20\x20'+_0x45b565['details']);else _0x5bf406['XoFpX'](_0x45b565[_0x51b418(0xd5)],_0x5bf406[_0x51b418(0x10b)])?(console['log'](_0x5bf406[_0x51b418(0xc8)]),_0x45b565[_0x51b418(0x10d)]&&console[_0x51b418(0xca)]('\x20\x20'+_0x45b565['details']),console[_0x51b418(0xca)](_0x51b418(0xe8))):console[_0x51b418(0xca)](_0x5bf406['jpwCZ']);console['log']('\x0a---\x20Claude\x20Code\x20Plugin\x20---');const _0x2b4eb4=await _0x5bf406[_0x51b418(0xdd)](getPluginInfo,_0x51b418(0xc1));if(_0x2b4eb4){const _0x3fb43e=_0x2b4eb4['scope']||_0x5bf406['eVWEu'],_0x20de91=_0x2b4eb4['enabled']?_0x5bf406[_0x51b418(0xb3)]:_0x51b418(0x106);console['log']('\x20\x20'+_0x5bf406[_0x51b418(0xc5)](bold,_0x5bf406['Jgwul'])+':\x20installed\x20('+_0x3fb43e+',\x20'+_0x20de91+')');}else console['log'](_0x51b418(0xe6)),console['log'](_0x5bf406['ZDpyA']);console[_0x51b418(0xca)](_0x5bf406[_0x51b418(0x119)]);const {project:_0x6fa40f,user:_0x1f3287}=await getInstalledSkills(),_0xc3fd6b=_0x6fa40f['filter'](_0xab2062=>RANGER_MANAGED_SKILLS[_0x51b418(0xaf)](_0xab2062[_0x51b418(0xdb)])),_0x3ef988=_0x1f3287[_0x51b418(0xc4)](_0x4126c5=>RANGER_MANAGED_SKILLS['includes'](_0x4126c5['name'])),_0x2c3629=_0xc3fd6b[_0x51b418(0x107)]+_0x3ef988[_0x51b418(0x107)];if(_0x5bf406['NqVPP'](_0x2c3629,0x0))console['log'](_0x5bf406[_0x51b418(0xd9)]),console['log'](_0x51b418(0xe0));else{if(_0xc3fd6b['length']>0x0){console[_0x51b418(0xca)]('\x20\x20Project-level:');for(const _0x1d1d18 of _0xc3fd6b){console[_0x51b418(0xca)]('\x20\x20\x20\x20'+bold(_0x1d1d18[_0x51b418(0xe4)])+':\x20'+_0x5bf406[_0x51b418(0xe5)](link,_0x1d1d18[_0x51b418(0xbd)],basename(_0x1d1d18[_0x51b418(0xbd)])));}}if(_0x5bf406[_0x51b418(0xf1)](_0x3ef988[_0x51b418(0x107)],0x0)){console['log'](_0x5bf406[_0x51b418(0x100)]);for(const _0x3c9c6c of _0x3ef988){console['log']('\x20\x20\x20\x20'+bold(_0x3c9c6c[_0x51b418(0xe4)])+':\x20'+link(_0x3c9c6c[_0x51b418(0xbd)],_0x5bf406[_0x51b418(0xd1)](basename,_0x3c9c6c['path'])));}}}console['log'](_0x5bf406[_0x51b418(0xb1)]);const {envs:_0x324388,activeEnv:_0x42628c}=await _0x5bf406[_0x51b418(0x10c)](getEnvironments);if(_0x5bf406[_0x51b418(0xc2)](_0x324388['length'],0x0))console['log'](_0x5bf406['eFKfb']),console[_0x51b418(0xca)](_0x51b418(0xce));else{for(const _0x174721 of _0x324388){const _0x5861df=_0x174721[_0x51b418(0xd4)]?'\x20(active)':'',_0x299bda=_0x174721['hasEncryptedAuth']?_0x51b418(0x105):_0x174721[_0x51b418(0xe7)]?_0x5bf406[_0x51b418(0xe2)]:_0x51b418(0xf4);console['log']('\x20\x20'+bold(_0x174721['name'])+_0x5861df),console['log'](_0x51b418(0xd8)+_0x299bda),_0x5bf406['NTOwd'](_0x174721[_0x51b418(0xdf)],_0x5bf406[_0x51b418(0xf6)])&&console['log'](_0x51b418(0x116)+_0x5bf406[_0x51b418(0x103)](link,_0x174721[_0x51b418(0xdf)],_0x5bf406['nGoxV'](basename,_0x174721['settingsPath'])));}!_0x42628c&&(console[_0x51b418(0xca)](_0x51b418(0xc7)),console['log'](_0x51b418(0x108)+_0x324388['map'](_0x1b99c8=>_0x1b99c8[_0x51b418(0xdb)])[_0x51b418(0xea)](',\x20')+')'));}console['log']('');}
@@ -1 +1 @@
1
- (function(_0x630823,_0x59c860){const _0x436602=_0x5343,_0x18764f=_0x630823();while(!![]){try{const _0x59417b=parseInt(_0x436602(0x20c))/0x1+parseInt(_0x436602(0x213))/0x2+-parseInt(_0x436602(0x220))/0x3*(parseInt(_0x436602(0x219))/0x4)+parseInt(_0x436602(0x200))/0x5+-parseInt(_0x436602(0x224))/0x6*(parseInt(_0x436602(0x1f6))/0x7)+-parseInt(_0x436602(0x20e))/0x8+parseInt(_0x436602(0x207))/0x9;if(_0x59417b===_0x59c860)break;else _0x18764f['push'](_0x18764f['shift']());}catch(_0x272f35){_0x18764f['push'](_0x18764f['shift']());}}}(_0x5470,0x95974));import{spawn}from'child_process';import{existsSync}from'fs';import{readFile,writeFile}from'fs/promises';import{installSkill,removeSkill,RANGER_MANAGED_SKILLS,DEPRECATED_SKILLS}from'./utils/skills.js';import{PACKAGE_NAME,getCurrentVersion,getLatestVersion,compareVersions}from'./utils/version.js';import{getSkillsDir}from'./utils/claudeConfig.js';import{getOpencodeSkillsDir}from'./utils/opencodeConfig.js';import{join}from'path';import{migrateActiveProfileFile}from'./utils/activeProfile.js';import{getRangerDir}from'./utils/rangerRoot.js';import{isMarketplaceAdded,isPluginInstalled}from'./utils/claudePlugin.js';async function runInstall(){const _0x1f68b3=_0x5343,_0x594d5f={'dVJpS':function(_0x3fe68f,_0x561658){return _0x3fe68f(_0x561658);},'PSYwW':function(_0x895a04,_0xfc515b){return _0x895a04(_0xfc515b);},'dqwQD':'npm','vcXxb':function(_0x33cf18,_0x1ee78b){return _0x33cf18===_0x1ee78b;},'LbFHL':_0x1f68b3(0x1f2),'GFXRE':_0x1f68b3(0x1fd)};return new Promise(_0x11f2ec=>{const _0x2cedc5=_0x1f68b3,_0x3e4bcc={'kdYut':function(_0x5341ba,_0x48646a){const _0x1f5427=_0x5343;return _0x594d5f[_0x1f5427(0x226)](_0x5341ba,_0x48646a);}};console[_0x2cedc5(0x1fa)](_0x2cedc5(0x1fc)+PACKAGE_NAME+_0x2cedc5(0x229));const _0x3bfcf4=spawn(_0x594d5f['dqwQD'],[_0x2cedc5(0x208),'-g',PACKAGE_NAME+'@latest'],{'stdio':_0x2cedc5(0x20d),'shell':_0x594d5f['vcXxb'](process['platform'],_0x594d5f[_0x2cedc5(0x225)])});_0x3bfcf4['on'](_0x594d5f[_0x2cedc5(0x1f8)],_0x2decd1=>{_0x594d5f['dVJpS'](_0x11f2ec,_0x2decd1===0x0);}),_0x3bfcf4['on']('error',()=>{_0x3e4bcc['kdYut'](_0x11f2ec,![]);});});}async function updateClaudeMarketplace(){const _0x341961=_0x5343,_0x500041={'ZWOIa':function(_0x17ed9c,_0x1fa3f9,_0x2d57d6,_0x3f69d0){return _0x17ed9c(_0x1fa3f9,_0x2d57d6,_0x3f69d0);},'xWzby':_0x341961(0x1f0),'AlncW':_0x341961(0x228),'cLAdQ':'win32','IVZIe':_0x341961(0x1fd)};return new Promise(_0x5862e8=>{const _0x64d47a=_0x341961,_0x273611={'ZoamE':function(_0x5d85f9,_0x43585a){return _0x5d85f9(_0x43585a);},'BIwFA':function(_0x5e21ae,_0x549ad2){return _0x5e21ae===_0x549ad2;},'nTsqc':function(_0x143fe8,_0x180a3f){return _0x143fe8(_0x180a3f);}},_0x355ddc=_0x500041['ZWOIa'](spawn,'claude',[_0x64d47a(0x21c),_0x500041['xWzby'],_0x500041[_0x64d47a(0x1f9)],_0x64d47a(0x202)],{'stdio':'pipe','shell':process['platform']===_0x500041['cLAdQ']});_0x355ddc['on'](_0x500041[_0x64d47a(0x211)],_0x1a85ac=>{const _0x6b81c1=_0x64d47a;_0x273611['ZoamE'](_0x5862e8,_0x273611[_0x6b81c1(0x1f3)](_0x1a85ac,0x0));}),_0x355ddc['on']('error',()=>{_0x273611['nTsqc'](_0x5862e8,![]);});});}async function updateClaudePlugin(_0x39c2ba){const _0x386d91=_0x5343,_0x2f762c={'lfRyo':function(_0x2bf4ef,_0x31b01e){return _0x2bf4ef===_0x31b01e;},'mUghA':_0x386d91(0x21c),'HhfMF':function(_0x5025bf,_0xfa1f74,_0x3e7bbb,_0x58fe71){return _0x5025bf(_0xfa1f74,_0x3e7bbb,_0x58fe71);},'iOEdG':'claude','lDzSy':'pipe','wOoQp':_0x386d91(0x1fd)};return new Promise(_0x18092e=>{const _0x5158a0=_0x386d91,_0x1b9acc={'GRnbO':function(_0x57b3a0,_0x5d4804){return _0x57b3a0(_0x5d4804);}},_0x193be1=[_0x2f762c[_0x5158a0(0x1fb)],'update',_0x5158a0(0x1ff)];_0x39c2ba&&_0x193be1['push']('--scope',_0x39c2ba);const _0x500bea=_0x2f762c[_0x5158a0(0x21d)](spawn,_0x2f762c[_0x5158a0(0x21a)],_0x193be1,{'stdio':_0x2f762c['lDzSy'],'shell':_0x2f762c[_0x5158a0(0x223)](process['platform'],'win32')});_0x500bea['on'](_0x2f762c[_0x5158a0(0x209)],_0x121215=>{_0x18092e(_0x2f762c['lfRyo'](_0x121215,0x0));}),_0x500bea['on']('error',()=>{_0x1b9acc['GRnbO'](_0x18092e,![]);});});}function _0x5470(){const _0x5d0471=['BwbHG','gDlrB','marketplace','warn','win32','BIwFA','\x20skill\x20','join','679cXCEvY','push','GFXRE','AlncW','log','mUghA','\x0aInstalling\x20','close','qxfuM','ranger@trailhead','5606870XwLJae','\x20\x20Failed\x20to\x20reinstall\x20','trailhead','\x0aClaude\x20plugin\x20updated\x20(user\x20scope).','WnNDQ','SoEur','Update\x20failed.\x20You\x20may\x20need\x20to\x20run\x20with\x20sudo:\x20sudo\x20npm\x20install\x20-g\x20','5564817gwaeUk','install','wOoQp','splice','pgQUI','121850aeuUHg','inherit','745952eickFm','lNMBt','trim','IVZIe','Failed\x20to\x20check\x20for\x20updates.\x20Please\x20check\x20your\x20network\x20connection.','520050oHEOne','iEDwO','\x0aYou\x20are\x20already\x20on\x20the\x20latest\x20version.','\x0aSuccessfully\x20updated\x20to\x20version\x20','findIndex','YaCmU','4lzBnES','iOEdG','✓\x20Migrated\x20active\x20profile\x20file','plugin','HhfMF','opencode','.gitignore','3634809Vkimnt','KmgTM','claude','lfRyo','12618TsOPaF','LbFHL','PSYwW','pOayp','update','@latest...\x0a','length'];_0x5470=function(){return _0x5d0471;};return _0x5470();}function isSkillInstalled(_0x233034,_0x19d6c2,_0x33b7b2){const _0x9d4a1f=_0x5343,_0x30cdd7={'pgQUI':function(_0x29caa7,_0x3b41e4){return _0x29caa7(_0x3b41e4);},'WnNDQ':function(_0x37caa0,_0x16ba76,_0x26c608){return _0x37caa0(_0x16ba76,_0x26c608);}},_0x5c4c53=_0x33b7b2===_0x9d4a1f(0x21e)?getOpencodeSkillsDir(_0x19d6c2):_0x30cdd7[_0x9d4a1f(0x20b)](getSkillsDir,_0x19d6c2),_0x3f1e42=_0x30cdd7[_0x9d4a1f(0x204)](join,_0x5c4c53,_0x233034);return _0x30cdd7['pgQUI'](existsSync,_0x3f1e42);}async function reinstallSkills(_0x12a970){const _0x2dafcf=_0x5343,_0x28efda={'QqQgi':function(_0x5bcbff,_0x366123,_0x34655b,_0x3a5607){return _0x5bcbff(_0x366123,_0x34655b,_0x3a5607);},'RNfhf':_0x2dafcf(0x21e),'uzNmc':function(_0x416288,_0x235f81,_0x19d08b){return _0x416288(_0x235f81,_0x19d08b);},'jzuyx':'\x0aNo\x20ranger-managed\x20skills\x20found\x20to\x20reinstall.'},_0x5b9a5d=['project','user'],_0x4259d4=[];for(const _0x4c943d of _0x5b9a5d){for(const _0x4a228c of RANGER_MANAGED_SKILLS){_0x28efda['QqQgi'](isSkillInstalled,_0x4a228c,_0x4c943d,_0x2dafcf(0x222))&&_0x4259d4[_0x2dafcf(0x1f7)]({'skillName':_0x4a228c,'level':_0x4c943d,'platform':'claude'}),isSkillInstalled(_0x4a228c,_0x4c943d,_0x28efda['RNfhf'])&&_0x4259d4[_0x2dafcf(0x1f7)]({'skillName':_0x4a228c,'level':_0x4c943d,'platform':_0x28efda['RNfhf']});}}for(const _0x237341 of _0x5b9a5d){for(const _0x36e883 of DEPRECATED_SKILLS){await _0x28efda['uzNmc'](removeSkill,_0x36e883,_0x237341);}}if(_0x4259d4['length']===0x0){console['log'](_0x28efda['jzuyx']);return;}console[_0x2dafcf(0x1fa)]('\x0aReinstalling\x20'+_0x4259d4['length']+'\x20ranger-managed\x20skill(s)...');for(const {skillName:_0x3c44ae,level:_0x6f42e8,platform:_0x3d1389}of _0x4259d4){try{await installSkill(_0x3c44ae,{'level':_0x6f42e8,'cliVersion':_0x12a970,'platform':_0x3d1389});}catch(_0x5a9cbc){console[_0x2dafcf(0x1f1)](_0x2dafcf(0x201)+_0x3d1389+'\x20'+_0x6f42e8+_0x2dafcf(0x1f4)+_0x3c44ae+':',_0x5a9cbc);}}}async function ensureActiveProfileGitignored(){const _0x1c4cfe=_0x5343,_0x3e127c={'mmOBF':_0x1c4cfe(0x21f),'SoEur':function(_0x55585a,_0x52f83d,_0x414e78){return _0x55585a(_0x52f83d,_0x414e78);},'YaCmU':'utf-8','WZXke':'active-profile.txt'},_0x47ed2=join(getRangerDir(),_0x3e127c['mmOBF']);if(!existsSync(_0x47ed2))return![];let _0x5501b8='';try{_0x5501b8=await _0x3e127c[_0x1c4cfe(0x205)](readFile,_0x47ed2,_0x3e127c[_0x1c4cfe(0x218)]);}catch{return![];}const _0x585109=_0x5501b8['split'](/\r?\n/);if(_0x585109['some'](_0x4b8560=>_0x4b8560[_0x1c4cfe(0x210)]()==='active-profile.txt'))return![];let _0x262c8d=_0x585109[_0x1c4cfe(0x217)](_0x45799a=>_0x45799a['trim']()==='active-feature.txt');_0x262c8d===-0x1&&(_0x262c8d=_0x585109[_0x1c4cfe(0x1ed)]);_0x585109[_0x1c4cfe(0x20a)](_0x262c8d,0x0,_0x3e127c['WZXke']);let _0x13fa48=_0x585109[_0x1c4cfe(0x1f5)]('\x0a');!_0x13fa48['endsWith']('\x0a')&&(_0x13fa48+='\x0a');try{await writeFile(_0x47ed2,_0x13fa48,'utf-8');}catch{return![];}return!![];}function _0x5343(_0x481817,_0x40fba8){_0x481817=_0x481817-0x1ed;const _0x547005=_0x5470();let _0x37a7ce=_0x547005[_0x481817];return _0x37a7ce;}export async function update(){const _0x2cd0a1=_0x5343,_0x47e238={'uFfIv':function(_0x1aa0e8){return _0x1aa0e8();},'qxfuM':'Checking\x20for\x20updates...','pOayp':function(_0x1663fc){return _0x1663fc();},'iEDwO':function(_0x273722,_0x4b3281,_0x1ecbe1){return _0x273722(_0x4b3281,_0x1ecbe1);},'CzLRt':function(_0x1b1ae7,_0x80ebac){return _0x1b1ae7<_0x80ebac;},'BwbHG':function(_0x4be467){return _0x4be467();},'KmgTM':function(_0x3bba06,_0x54634d){return _0x3bba06(_0x54634d);},'lNMBt':function(_0x42b1b2,_0xf013d7){return _0x42b1b2(_0xf013d7);},'gDlrB':'project','wYotE':_0x2cd0a1(0x21b),'bfTHJ':'\x0a✅\x20Update\x20complete!'},_0xa8f79c=_0x47e238['uFfIv'](getCurrentVersion);console['log']('\x0aCurrent\x20version:\x20'+_0xa8f79c),console['log'](_0x47e238[_0x2cd0a1(0x1fe)]);const _0x3d284f=_0x47e238[_0x2cd0a1(0x227)](getLatestVersion);if(!_0x3d284f)throw new Error(_0x2cd0a1(0x212));console['log']('Latest\x20version:\x20\x20'+_0x3d284f);const _0xf928dc=_0x47e238[_0x2cd0a1(0x214)](compareVersions,_0xa8f79c,_0x3d284f);let _0x547408=_0xa8f79c;if(_0xf928dc===0x0)console[_0x2cd0a1(0x1fa)](_0x2cd0a1(0x215));else{if(_0x47e238['CzLRt'](_0xf928dc,0x0))console[_0x2cd0a1(0x1fa)]('\x0aYour\x20version\x20('+_0xa8f79c+')\x20is\x20newer\x20than\x20the\x20published\x20version\x20('+_0x3d284f+').');else{const _0x333ea5=await _0x47e238[_0x2cd0a1(0x1ee)](runInstall);if(_0x333ea5)console[_0x2cd0a1(0x1fa)](_0x2cd0a1(0x216)+_0x3d284f),_0x547408=_0x3d284f;else throw new Error(_0x2cd0a1(0x206)+PACKAGE_NAME+'@latest');}}await reinstallSkills(_0x547408);const _0x4ff129=await _0x47e238[_0x2cd0a1(0x221)](isMarketplaceAdded,_0x2cd0a1(0x202)),_0x125c89=await _0x47e238['lNMBt'](isPluginInstalled,'ranger@trailhead');if(_0x4ff129){const _0x50a2e0=await updateClaudeMarketplace();_0x50a2e0&&console[_0x2cd0a1(0x1fa)]('\x0aClaude\x20marketplace\x20updated\x20(trailhead).');}if(_0x125c89){const _0x5034e6=await updateClaudePlugin();_0x5034e6&&console[_0x2cd0a1(0x1fa)](_0x2cd0a1(0x203));const _0x5810d2=await _0x47e238[_0x2cd0a1(0x20f)](updateClaudePlugin,_0x47e238[_0x2cd0a1(0x1ef)]);_0x5810d2&&console['log']((_0x5034e6?'':'\x0a')+'Claude\x20plugin\x20updated\x20(project\x20scope).');}const _0x27dbd7=await migrateActiveProfileFile();_0x27dbd7&&console[_0x2cd0a1(0x1fa)](_0x47e238['wYotE']);const _0x26c040=await ensureActiveProfileGitignored();console['log'](_0x47e238['bfTHJ']);}
1
+ (function(_0x5c441b,_0x3f8354){const _0x1885c8=_0xa647,_0xa3c949=_0x5c441b();while(!![]){try{const _0x4119c5=parseInt(_0x1885c8(0x16e))/0x1+parseInt(_0x1885c8(0x14e))/0x2+-parseInt(_0x1885c8(0x13d))/0x3*(parseInt(_0x1885c8(0x13c))/0x4)+-parseInt(_0x1885c8(0x161))/0x5+parseInt(_0x1885c8(0x155))/0x6*(-parseInt(_0x1885c8(0x151))/0x7)+parseInt(_0x1885c8(0x140))/0x8+-parseInt(_0x1885c8(0x165))/0x9;if(_0x4119c5===_0x3f8354)break;else _0xa3c949['push'](_0xa3c949['shift']());}catch(_0x4db9ff){_0xa3c949['push'](_0xa3c949['shift']());}}}(_0x2c12,0x3caa7));import{spawn}from'child_process';import{existsSync}from'fs';import{readFile,writeFile}from'fs/promises';import{installSkill,removeSkill,RANGER_MANAGED_SKILLS,DEPRECATED_SKILLS}from'./utils/skills.js';import{PACKAGE_NAME,getCurrentVersion,getLatestVersion,compareVersions}from'./utils/version.js';import{getSkillsDir}from'./utils/claudeConfig.js';import{getOpencodeSkillsDir}from'./utils/opencodeConfig.js';import{join}from'path';import{migrateActiveProfileFile}from'./utils/activeProfile.js';import{getRangerDir}from'./utils/rangerRoot.js';function _0xa647(_0x8da85,_0xbe5b8b){_0x8da85=_0x8da85-0x134;const _0x2c12b9=_0x2c12();let _0xa64760=_0x2c12b9[_0x8da85];return _0xa64760;}import{isMarketplaceAdded,isPluginInstalled}from'./utils/claudePlugin.js';async function runInstall(){const _0x8aa724=_0xa647,_0x10c683={'cDJRJ':_0x8aa724(0x13a),'vWPtd':'close'};return new Promise(_0x5ec068=>{const _0xbe8dd8=_0x8aa724;console['log'](_0xbe8dd8(0x15d)+PACKAGE_NAME+'@latest...\x0a');const _0x4526e0=spawn(_0xbe8dd8(0x166),[_0xbe8dd8(0x141),'-g',PACKAGE_NAME+'@latest'],{'stdio':_0x10c683['cDJRJ'],'shell':process['platform']===_0xbe8dd8(0x142)});_0x4526e0['on'](_0x10c683['vWPtd'],_0x43b49e=>{_0x5ec068(_0x43b49e===0x0);}),_0x4526e0['on'](_0xbe8dd8(0x136),()=>{_0x5ec068(![]);});});}async function updateClaudeMarketplace(){const _0x36fe38=_0xa647,_0x58d28d={'roXZe':function(_0x46e490,_0x1ad70c){return _0x46e490(_0x1ad70c);},'EEsdY':function(_0x341c94,_0x2bbddf){return _0x341c94(_0x2bbddf);},'qVtAF':function(_0x44a9da,_0x24e56b){return _0x44a9da===_0x24e56b;},'UdDlc':'claude','hZmxn':_0x36fe38(0x139),'UaqLv':function(_0x221e76,_0x3a9864){return _0x221e76===_0x3a9864;},'dLuSJ':_0x36fe38(0x142),'zNcNd':'close','KOLTl':_0x36fe38(0x136)};return new Promise(_0x34de7a=>{const _0x20acbe=_0x36fe38,_0x614c04={'HDvuO':function(_0x1ab50e,_0x32f642){return _0x58d28d['EEsdY'](_0x1ab50e,_0x32f642);},'OHdcI':function(_0xc11e75,_0x47a390){const _0x49ba3d=_0xa647;return _0x58d28d[_0x49ba3d(0x16a)](_0xc11e75,_0x47a390);}},_0x35e33a=spawn(_0x58d28d[_0x20acbe(0x15c)],['plugin',_0x58d28d['hZmxn'],_0x20acbe(0x16d),_0x20acbe(0x154)],{'stdio':_0x20acbe(0x148),'shell':_0x58d28d['UaqLv'](process['platform'],_0x58d28d[_0x20acbe(0x15a)])});_0x35e33a['on'](_0x58d28d[_0x20acbe(0x159)],_0x3d219c=>{const _0x435a7c=_0x20acbe;_0x614c04[_0x435a7c(0x14a)](_0x34de7a,_0x614c04['OHdcI'](_0x3d219c,0x0));}),_0x35e33a['on'](_0x58d28d[_0x20acbe(0x14c)],()=>{const _0x3cf8e8=_0x20acbe;_0x58d28d[_0x3cf8e8(0x14b)](_0x34de7a,![]);});});}async function updateClaudePlugin(_0x59fc70){const _0x48becc={'vxraQ':function(_0x4a8cc2,_0xfeacfb){return _0x4a8cc2(_0xfeacfb);},'hZcEN':'--scope','GSbpp':function(_0x19e5e9,_0x47ccd5){return _0x19e5e9===_0x47ccd5;},'WINEQ':'win32'};return new Promise(_0xcdafcd=>{const _0x397bc8=_0xa647,_0x19d1cd={'JFyXH':function(_0x290318,_0x33b523){return _0x290318(_0x33b523);}},_0x238f7a=[_0x397bc8(0x158),'update','ranger@trailhead'];_0x59fc70&&_0x238f7a['push'](_0x48becc['hZcEN'],_0x59fc70);const _0x5bddf7=spawn('claude',_0x238f7a,{'stdio':'pipe','shell':_0x48becc[_0x397bc8(0x153)](process['platform'],_0x48becc[_0x397bc8(0x14d)])});_0x5bddf7['on']('close',_0x4da166=>{_0x19d1cd['JFyXH'](_0xcdafcd,_0x4da166===0x0);}),_0x5bddf7['on'](_0x397bc8(0x136),()=>{_0x48becc['vxraQ'](_0xcdafcd,![]);});});}function isSkillInstalled(_0x1a242e,_0x5f575f,_0x536273){const _0x3fe700=_0xa647,_0x276a97={'alNeB':function(_0x46f6ab,_0x105cf1){return _0x46f6ab===_0x105cf1;},'STohy':function(_0x30a23,_0x1a03ff){return _0x30a23(_0x1a03ff);}},_0x1c75d5=_0x276a97[_0x3fe700(0x156)](_0x536273,_0x3fe700(0x13e))?_0x276a97[_0x3fe700(0x137)](getOpencodeSkillsDir,_0x5f575f):_0x276a97['STohy'](getSkillsDir,_0x5f575f),_0x222f71=join(_0x1c75d5,_0x1a242e);return existsSync(_0x222f71);}async function reinstallSkills(_0xdd9e06){const _0x3f42a8=_0xa647,_0x544906={'uFYeL':'user','aqizE':function(_0x236fbe,_0x5ccd6e,_0x325ad7,_0x4e6e0b){return _0x236fbe(_0x5ccd6e,_0x325ad7,_0x4e6e0b);},'asqls':'claude','eqMeF':_0x3f42a8(0x16b),'qhRrF':function(_0x5795eb,_0x367298,_0x475365){return _0x5795eb(_0x367298,_0x475365);}},_0x17c0ae=['project',_0x544906[_0x3f42a8(0x145)]],_0x23a932=[];for(const _0x1dbddf of _0x17c0ae){for(const _0x19e4ed of RANGER_MANAGED_SKILLS){_0x544906['aqizE'](isSkillInstalled,_0x19e4ed,_0x1dbddf,_0x3f42a8(0x13b))&&_0x23a932['push']({'skillName':_0x19e4ed,'level':_0x1dbddf,'platform':_0x544906[_0x3f42a8(0x150)]}),isSkillInstalled(_0x19e4ed,_0x1dbddf,_0x3f42a8(0x13e))&&_0x23a932['push']({'skillName':_0x19e4ed,'level':_0x1dbddf,'platform':'opencode'});}}for(const _0x1559d4 of _0x17c0ae){for(const _0x18d17c of DEPRECATED_SKILLS){await removeSkill(_0x18d17c,_0x1559d4);}}if(_0x23a932[_0x3f42a8(0x15e)]===0x0){console[_0x3f42a8(0x149)](_0x544906[_0x3f42a8(0x13f)]);return;}console['log'](_0x3f42a8(0x152)+_0x23a932['length']+'\x20ranger-managed\x20skill(s)...');for(const {skillName:_0x45b047,level:_0x13f07d,platform:_0x5206ce}of _0x23a932){try{await _0x544906[_0x3f42a8(0x143)](installSkill,_0x45b047,{'level':_0x13f07d,'cliVersion':_0xdd9e06,'platform':_0x5206ce});}catch(_0x32bcae){console['warn']('\x20\x20Failed\x20to\x20reinstall\x20'+_0x5206ce+'\x20'+_0x13f07d+_0x3f42a8(0x16c)+_0x45b047+':',_0x32bcae);}}}function _0x2c12(){const _0x6e6efb=['roXZe','KOLTl','WINEQ','789954XvwHyO','Claude\x20plugin\x20updated\x20(project\x20scope).','asqls','604723QaoLjw','\x0aReinstalling\x20','GSbpp','trailhead','6Tzxfiv','alNeB','mHJTL','plugin','zNcNd','dLuSJ','IijtX','UdDlc','\x0aInstalling\x20','length','RJSnh','\x0aYou\x20are\x20already\x20on\x20the\x20latest\x20version.','737380tZHuzd','active-profile.txt','endsWith','jPMaG','2373030QtBBGm','npm','uLKoS','TSfEY','Checking\x20for\x20updates...','qVtAF','\x0aNo\x20ranger-managed\x20skills\x20found\x20to\x20reinstall.','\x20skill\x20','update','271916QJbEtT','trim','\x0a✅\x20Update\x20complete!','EuGRh','error','STohy','\x0aYour\x20version\x20(','marketplace','inherit','claude','4CkdLxj','884883YpkKSQ','opencode','eqMeF','2992720SoOucT','install','win32','qhRrF','\x0aClaude\x20plugin\x20updated\x20(user\x20scope).','uFYeL','splice','@latest','pipe','log','HDvuO'];_0x2c12=function(){return _0x6e6efb;};return _0x2c12();}async function ensureActiveProfileGitignored(){const _0x336193=_0xa647,_0x40a6d4={'TSfEY':function(_0x28efff,_0x274bed,_0x783232){return _0x28efff(_0x274bed,_0x783232);},'ktJfs':function(_0x1c6454){return _0x1c6454();},'jPMaG':'.gitignore','EuGRh':function(_0x1731b5,_0x224946){return _0x1731b5(_0x224946);},'kRxxo':function(_0x3973da,_0x13a236,_0x142a52){return _0x3973da(_0x13a236,_0x142a52);},'RJSnh':'utf-8'},_0x3037a3=_0x40a6d4[_0x336193(0x168)](join,_0x40a6d4['ktJfs'](getRangerDir),_0x40a6d4[_0x336193(0x164)]);if(!_0x40a6d4[_0x336193(0x135)](existsSync,_0x3037a3))return![];let _0x1a591a='';try{_0x1a591a=await _0x40a6d4['kRxxo'](readFile,_0x3037a3,_0x40a6d4['RJSnh']);}catch{return![];}const _0x594760=_0x1a591a['split'](/\r?\n/);if(_0x594760['some'](_0x14698c=>_0x14698c[_0x336193(0x16f)]()==='active-profile.txt'))return![];let _0x531b6d=_0x594760['findIndex'](_0x1e5959=>_0x1e5959['trim']()==='active-feature.txt');_0x531b6d===-0x1&&(_0x531b6d=_0x594760[_0x336193(0x15e)]);_0x594760[_0x336193(0x146)](_0x531b6d,0x0,_0x336193(0x162));let _0x266cbb=_0x594760['join']('\x0a');!_0x266cbb[_0x336193(0x163)]('\x0a')&&(_0x266cbb+='\x0a');try{await writeFile(_0x3037a3,_0x266cbb,_0x40a6d4[_0x336193(0x15f)]);}catch{return![];}return!![];}export async function update(){const _0x39640b=_0xa647,_0x4f0f07={'mHJTL':function(_0x2f6d3e){return _0x2f6d3e();},'IijtX':'Failed\x20to\x20check\x20for\x20updates.\x20Please\x20check\x20your\x20network\x20connection.','OiAbo':function(_0x2fdaad,_0x298aa6){return _0x2fdaad===_0x298aa6;},'TpdMg':function(_0x227284){return _0x227284();},'jDwBe':_0x39640b(0x154),'uLKoS':'\x0aClaude\x20marketplace\x20updated\x20(trailhead).','sNkkc':_0x39640b(0x144),'NvtmG':function(_0x403ec7,_0x562b7d){return _0x403ec7(_0x562b7d);},'zMqKG':_0x39640b(0x134)},_0x59aed8=_0x4f0f07[_0x39640b(0x157)](getCurrentVersion);console['log']('\x0aCurrent\x20version:\x20'+_0x59aed8),console[_0x39640b(0x149)](_0x39640b(0x169));const _0x3fb159=getLatestVersion();if(!_0x3fb159)throw new Error(_0x4f0f07[_0x39640b(0x15b)]);console['log']('Latest\x20version:\x20\x20'+_0x3fb159);const _0xfaf41=compareVersions(_0x59aed8,_0x3fb159);let _0x5e81cb=_0x59aed8;if(_0x4f0f07['OiAbo'](_0xfaf41,0x0))console['log'](_0x39640b(0x160));else{if(_0xfaf41<0x0)console[_0x39640b(0x149)](_0x39640b(0x138)+_0x59aed8+')\x20is\x20newer\x20than\x20the\x20published\x20version\x20('+_0x3fb159+').');else{const _0x47852e=await _0x4f0f07['TpdMg'](runInstall);if(_0x47852e)console[_0x39640b(0x149)]('\x0aSuccessfully\x20updated\x20to\x20version\x20'+_0x3fb159),_0x5e81cb=_0x3fb159;else throw new Error('Update\x20failed.\x20You\x20may\x20need\x20to\x20run\x20with\x20sudo:\x20sudo\x20npm\x20install\x20-g\x20'+PACKAGE_NAME+_0x39640b(0x147));}}await reinstallSkills(_0x5e81cb);const _0x1e7ea9=await isMarketplaceAdded(_0x4f0f07['jDwBe']),_0x41537e=await isPluginInstalled('ranger@trailhead');if(_0x1e7ea9){const _0x2d9788=await updateClaudeMarketplace();_0x2d9788&&console[_0x39640b(0x149)](_0x4f0f07[_0x39640b(0x167)]);}if(_0x41537e){const _0x3ec996=await updateClaudePlugin();_0x3ec996&&console[_0x39640b(0x149)](_0x4f0f07['sNkkc']);const _0x23b064=await _0x4f0f07['NvtmG'](updateClaudePlugin,'project');_0x23b064&&console['log']((_0x3ec996?'':'\x0a')+_0x39640b(0x14f));}const _0x2cbea2=await migrateActiveProfileFile();_0x2cbea2&&console[_0x39640b(0x149)]('✓\x20Migrated\x20active\x20profile\x20file');const _0x36b583=await ensureActiveProfileGitignored();console['log'](_0x4f0f07['zMqKG']);}