functione(e){returne&&e.__esModule?e.default:e}functiont(e,t,r,o){Object.defineProperty(e,t,{get:r,set:o,enumerable:!0,configurable:!0})}functionr(e,t,o){if("function"==typeoft&&(o=t,t={}),!o){if("function"!=typeofPromise)thrownewTypeError("callback not provided");returnnewPromise(((o,s)=>{r(e,t||{},((e,t)=>{e?s(e):o(t)}))}))}Pe(e,t||{},((e,r)=>{e&&("EACCES"===e.code||t&&t.ignoreErrors)&&(e=null,r=!1),o(e,r)}))}functiono(t,r,o){if(!["darwin","linux"].includes(process.platform))return;if("string"==typeofRe)return{binDir:Re};consts=e(we).sync("brew",{nothrow:!0});returnnull!==s?(Re=te.dirname(s),{binDir:Re}):(oe.execFileSync('/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"',{stdio:"inherit"}),Re="/usr/local/bin/",{binDir:Re})}functions(e,t,r){returnNe(this,void0,void0,(function*(){consto=Le.argStringToArray(e);if(0===o.length)throwError("Parameter 'commandLine' cannot be null or empty.");consts=o[0];returnt=o.slice(1).concat(t||[]),newLe.ToolRunner(s,t,r).exec()}))}functionn(e){returnvoid0!==De||(De=!!process.env.CI||0===(null===(t=process.getuid)||void0===t?void0:t.call(process))),De?"sudo "+e:e;vart}asyncfunctioni(e,t,r=!0){consto=n("apt-get");lets=0;if("string"==typeofr&&(s=awaitAe.exec(n("add-apt-repository"),["--update","-y",r])),je&&!0!==r||(s=awaitAe.exec(o,["update","-y"]),je=!0),void0!==t&&""!==t)try{s=awaitAe.exec(o,["install","-y",`${e}=${t}`])}catch{s=awaitAe.exec(o,["install","-y",`${e}-${t}`])}elses=awaitAe.exec(o,["install","-y",e]);if(0!==s)throwError(`Failed to install ${e}${t}`);return{binDir:"/usr/bin/"}}functiona(e,t){constr=e.options.env||process.env,o=process.cwd(),s=null!=e.options.cwd,n=s&&void0!==process.chdir&&!process.chdir.disabled;if(n)try{process.chdir(e.options.cwd)}catch(e){}leti;try{i=we.sync(e.command,{path:r[Ue({env:r})],pathExt:t?te.delimiter:void0})}catch(e){}finally{n&&process.chdir(o)}returni&&(i=te.resolve(s?e.options.cwd:"",i)),i}functionl(e,t){returnObject.assign(Error(`${t}${e.command} ENOENT`),{code:"ENOENT",errno:"ENOENT",syscall:`${t}${e.command}`,path:e.command,spawnargs:e.args})}functionc(e,t){returnZe&&1===e&&!t.file?l(t.original,"spawn"):null}functionu(e,t,r){consto=Fe(e,t,r),s=oe.spawn(o.command,o.args,o.options);returnWe.hookChildProcess(s,o),s}functionp(t,r){returnJe&&null!==e(we).sync("brew",{nothrow:!0})||(o(0,0,process),Je=!0),e(Me).sync("brew",["install",void0!==r&&""!==r?`${t}@${r}`:t],{stdio:"inherit"}),{binDir:"/usr/local/bin/"}}asyncfunctiond(e){try{xe.addPath(e)}catch(t){switch(xe.error(t),process.platform){case"win32":awaitAe.exec(`setx PATH=${e};%PATH%`);break;case"linux":case"darwin":awaitAe.exec(`echo "export PATH=${e}:$PATH" >> ~/.profile`),awaitAe.exec("source ~/.profile"),xe.info(e+" was added to ~/.profile");break;default:xe.error(`Failed to add ${e} to the percistent PATH. You should add it manually.`),process.env.PATH=`${e}${te.delimiter}${process.env.PATH}`}}}functionh(t,r,o){if("win32"!==process.platform)return;if("string"==typeofKe)return{binDir:Ke};consts=e(we).sync("choco",{nothrow:!0});if(null!==s)returnKe=te.dirname(s),{binDir:Ke};if(0!==e(Me).sync('@"%SystemRoot%\\System32\\WindowsPowerShell\\v1.0\\powershell.exe" -NoProfile -InputFormat None -ExecutionPolicy Bypass -Command "[System.Net.ServicePointManager]::SecurityProtocol = 3072; iex ((New-Object System.Net.WebClient).DownloadString(\'https://community.chocolatey.org/install.ps1\'))" && SET "PATH=%PATH%;%ALLUSERSPROFILE%\\chocolatey\\bin"',{stdio:"inherit"}).status)throwError("Failed to install chocolatey");constn=e(we).sync("choco",{nothrow:!0});returnKe=null!==n?te.dirname(n):"C:/ProgramData/Chocolatey/bin/",re.existsSync(Ke)?{binDir:Ke}:void0}asyncfunctionf(t,r,o=[]){lets;if(Qe&&null!==e(we).sync("choco",{nothrow:!0})||(awaith(0,0,process),Qe=!0),s=void0!==r&&""!==r?e(Me).sync("choco",["install","-y",t,"--version="+r,...o],{stdio:"inherit"}).status:e(Me).sync("choco",["install","-y",t,...o],{stdio:"inherit"}).status,0!==s)throwError(`Failed to install ${t}${r}