setup-cpp/dist/setup_cpp.js

3 lines
121 KiB
JavaScript
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

function e(e){return e&&e.__esModule?e.default:e}function t(e,t,r,o){Object.defineProperty(e,t,{get:r,set:o,enumerable:!0,configurable:!0})}function r(e,t,o){if("function"==typeof t&&(o=t,t={}),!o){if("function"!=typeof Promise)throw new TypeError("callback not provided");return new Promise(((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)}))}function o(t,r,o){if(!["darwin","linux"].includes(process.platform))return;if("string"==typeof Re)return{binDir:Re};const s=e(we).sync("brew",{nothrow:!0});return null!==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})}function s(e,t,r){return Ne(this,void 0,void 0,(function*(){const o=Le.argStringToArray(e);if(0===o.length)throw Error("Parameter 'commandLine' cannot be null or empty.");const s=o[0];return t=o.slice(1).concat(t||[]),new Le.ToolRunner(s,t,r).exec()}))}function n(e){return void 0!==De||(De=!!process.env.CI||0===(null===(t=process.getuid)||void 0===t?void 0:t.call(process))),De?"sudo "+e:e;var t}async function i(e,t,r=!0){const o=n("apt-get");let s=0;if("string"==typeof r&&(s=await Ae.exec(n("add-apt-repository"),["--update","-y",r])),je&&!0!==r||(s=await Ae.exec(o,["update","-y"]),je=!0),void 0!==t&&""!==t)try{s=await Ae.exec(o,["install","-y",`${e}=${t}`])}catch{s=await Ae.exec(o,["install","-y",`${e}-${t}`])}else s=await Ae.exec(o,["install","-y",e]);if(0!==s)throw Error(`Failed to install ${e} ${t}`);return{binDir:"/usr/bin/"}}function a(e,t){const r=e.options.env||process.env,o=process.cwd(),s=null!=e.options.cwd,n=s&&void 0!==process.chdir&&!process.chdir.disabled;if(n)try{process.chdir(e.options.cwd)}catch(e){}let i;try{i=we.sync(e.command,{path:r[Ue({env:r})],pathExt:t?te.delimiter:void 0})}catch(e){}finally{n&&process.chdir(o)}return i&&(i=te.resolve(s?e.options.cwd:"",i)),i}function l(e,t){return Object.assign(Error(`${t} ${e.command} ENOENT`),{code:"ENOENT",errno:"ENOENT",syscall:`${t} ${e.command}`,path:e.command,spawnargs:e.args})}function c(e,t){return Ze&&1===e&&!t.file?l(t.original,"spawn"):null}function u(e,t,r){const o=Fe(e,t,r),s=oe.spawn(o.command,o.args,o.options);return We.hookChildProcess(s,o),s}function p(t,r){return Je&&null!==e(we).sync("brew",{nothrow:!0})||(o(0,0,process),Je=!0),e(Me).sync("brew",["install",void 0!==r&&""!==r?`${t}@${r}`:t],{stdio:"inherit"}),{binDir:"/usr/local/bin/"}}async function d(e){try{xe.addPath(e)}catch(t){switch(xe.error(t),process.platform){case"win32":await Ae.exec(`setx PATH=${e};%PATH%`);break;case"linux":case"darwin":await Ae.exec(`echo "export PATH=${e}:$PATH" >> ~/.profile`),await Ae.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}`}}}function h(t,r,o){if("win32"!==process.platform)return;if("string"==typeof Ke)return{binDir:Ke};const s=e(we).sync("choco",{nothrow:!0});if(null!==s)return Ke=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)throw Error("Failed to install chocolatey");const n=e(we).sync("choco",{nothrow:!0});return Ke=null!==n?te.dirname(n):"C:/ProgramData/Chocolatey/bin/",re.existsSync(Ke)?{binDir:Ke}:void 0}async function f(t,r,o=[]){let s;if(Qe&&null!==e(we).sync("choco",{nothrow:!0})||(await h(0,0,process),Qe=!0),s=void 0!==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)throw Error(`Failed to install ${t} ${r}`);const n="C:/ProgramData/Chocolatey/bin/";return await d(n),{binDir:n}}function m(e,t){const r=[];t=t||ut.arch();const o=pt.join(E(),e);if(lt.existsSync(o)){const e=lt.readdirSync(o);for(const s of e)if(x(s)){const e=pt.join(o,s,t||"");lt.existsSync(e)&&lt.existsSync(e+".complete")&&r.push(s)}}return r}function v(e){return st(this,void 0,void 0,(function*(){return e||(e=pt.join(b(),vt.default())),yield at.mkdirP(e),e}))}function y(e,t,r){return st(this,void 0,void 0,(function*(){const o=pt.join(E(),e,ht.clean(t)||t,r||"");it.debug("destination "+o);const s=o+".complete";return yield at.rmRF(o),yield at.rmRF(s),yield at.mkdirP(o),o}))}function g(e,t,r){const o=pt.join(E(),e,ht.clean(t)||t,r||"");lt.writeFileSync(o+".complete",""),it.debug("finished caching tool")}function x(e){const t=ht.clean(e)||"";it.debug("isExplicit: "+t);const r=null!=ht.valid(t);return it.debug("explicit? "+r),r}function w(e,t){let r="";it.debug(`evaluating ${e.length} versions`);for(let o=(e=e.sort(((e,t)=>ht.gt(e,t)?1:-1))).length-1;o>=0;o--){const s=e[o];if(ht.satisfies(s,t)){r=s;break}}return it.debug(r?"matched: "+r:"match not found"),r}function E(){const e=process.env.RUNNER_TOOL_CACHE||"";return ae.ok(e,"Expected RUNNER_TOOL_CACHE to be defined"),e}function b(){const e=process.env.RUNNER_TEMP||"";return ae.ok(e,"Expected RUNNER_TEMP to be defined"),e}function P(e,t){const r=me[e];return void 0!==r?r:t}async function O(e,t,r,o){var s,n;process.env.RUNNER_TEMP=null!==(s=process.env.RUNNER_TEMP)&&void 0!==s?s:ee.tmpdir(),process.env.RUNNER_TOOL_CACHE=null!==(n=process.env.RUNNER_TOOL_CACH)&&void 0!==n?n:te.join(ee.tmpdir(),"setup_cpp","ToolCache");const{url:i,binRelativeDir:a,extractedFolderName:l,extractFunction:c}=await r(t,process.platform);try{const r=et.find(e,t);if(r){xe.info(`${e} ${t} was found in the cache.`);const o=te.join(r,l),s=te.join(o,a);return await d(s),{installDir:o,binDir:s}}}catch{}const u=await Rt.async(i,{algorithm:"md5"}),p=te.join(o,u);if(!re.existsSync(p)){xe.info(`Download and extract ${e} ${t}`);const r=await et.downloadTool(i);await(null==c?void 0:c(r,p))}const h=te.join(p,l),f=te.join(h,a);return xe.info(`Add ${f} to PATH`),await d(f),"string"==typeof process.env.RUNNER_TOOL_CACHE&&await et.cacheDir(p,e,t),{installDir:h,binDir:f}}function $(t,r){var o;const s=null!==(o=e(_t)(t))&&void 0!==o?o:t,n=null!=r?r:process.platform,i=xe.getInput("architecture")||process.arch;switch(n){case"win32":{const r=e(St)(s,"v3.19.6");let o;o=["ia32","x86","i386","x32"].includes(i)?r?"win32-x86":"windows-i386":r?"win64-x64":"windows-x86_64";const n=`cmake-${t}-${o}`;return{binRelativeDir:"bin/",extractedFolderName:n,extractFunction:et.extractZip,url:`https://github.com/Kitware/CMake/releases/download/v${t}/${n}.zip`}}case"darwin":{const r=`cmake-${t}-${e(St)(s,"v3.19.1")?"Darwin-x86_64":"macos-universal"}`;return{binRelativeDir:"CMake.app/Contents/bin/",extractedFolderName:r,extractFunction:et.extractTar,url:`https://github.com/Kitware/CMake/releases/download/v${t}/${r}.tar.gz`}}case"linux":{const r=e(St)(s,"v3.19.8");let o;o=["aarch64"].includes(i)?r?"Linux-aarch64":"linux-aarch64":r?"Linux-x86_64":"linux-x86_64";const n=`cmake-${t}-${o}`;return{binRelativeDir:"bin/",extractedFolderName:n,extractFunction:et.extractTar,url:`https://github.com/Kitware/CMake/releases/download/v${t}/${n}.tar.gz`}}default:throw Error(`Unsupported platform '${n}'`)}}function S(t,r,o,s=!1){const n=te.join(t,r),i=te.join(t,o);e(re).existsSync(i)||(e(re).symlinkSync(n,i),!Mt&&s&&e(re).chmodSync(i,"755"))}function _(e){return R(e)||!!kt.validRange(e)}function R(e){return"nightly"===e}function A(e,t){const r=et.find.bind(void 0,"PyPy",e);let o=r(t);if(!o&&Mt&&(o=r("x86")),!o)throw Error(`PyPy ${e} not found`);const s=te.join(o,"bin");xe.exportVariable("pythonLocation",Mt?o:s),xe.addPath(o),xe.addPath(s),Mt&&xe.addPath(te.join(o,"Scripts"));const n="pypy"+e;return xe.setOutput("python-version",n),{impl:n,version:C(o)}}function C(e){const t=e.split(te.sep),r=t.findIndex((e=>"PyPy"===e||"Python"===e));return t[r+1]||""}function T(e){const t=te.join(e,"bin");return Mt?e:t}function I(e){return e.replace(/(\d+\.\d+\.\d+)((?:a|b|rc))(\d*)/g,"$1-$2.$3")}function N(e){return e.files.find((e=>Ut.includes(e.arch)&&Vt.includes(e.platform)))}function L(e,t,r){return e.files.find((e=>e.arch===t&&e.platform===r))}async function D(t,r,o){try{if(t.startsWith("pypy-")){const r=await async function(t,r){let o,s="",n="";const i=(e=>{const t=e.split("-").filter((e=>!!e));if(2>t.length||"pypy"!=t[0])throw Error("Invalid 'version' property for PyPy. PyPy version should be specified as 'pypy-<python-version>'. See README for examples and documentation.");const r=t[1];let o;if(o=t.length>2?I(t[2]):"x",!_(r)||!_(o))throw Error("Invalid 'version' property for PyPy. Both Python version and PyPy versions should satisfy SemVer notation. See README for examples and documentation.");if(!/^\d+\.\d+$/.test(r))throw Error("Invalid format of Python version for PyPy. Python version should be specified in format 'x.y'. See README for examples and documentation.");return{pypyVersion:o,pythonVersion:r}})(t);({installDir:o,resolvedPythonVersion:n,resolvedPyPyVersion:s}=((t,r,o)=>{let s="",n="",i=Mt?(e=>{let t="";return Ut.forEach((r=>t=t||et.find("PyPy",e,r))),t})(t):et.find("PyPy",t,o);return i&&(n=(e=>te.basename(te.dirname(e)))(i),s=(t=>{let r="",o=te.join(t,"PYPY_VERSION");return e(re).existsSync(o)&&(r=""+e(re).readFileSync(o)),r})(i),kt.satisfies(s,r)||(i=null,s="",n="")),i||xe.info(`PyPy version ${t} (${r}) was not found in the local cache`),{installDir:i,resolvedPythonVersion:n,resolvedPyPyVersion:s}})(i.pythonVersion,i.pypyVersion,r)),o||({installDir:o,resolvedPythonVersion:n,resolvedPyPyVersion:s}=await(async(t,r,o)=>{let s;const n=await(async()=>{const e="https://downloads.python.org/pypy/versions.json",t=new Bt.HttpClient("tool-cache"),r=await t.getJson(e);if(!r.result)throw Error(`Unable to retrieve the list of available PyPy versions from '${e}'`);return r.result})();if(!n||0===n.length)throw Error("No release was found in PyPy version.json");const i=((e,t,r,o)=>{const s=e.filter((e=>{const s=kt.satisfies(kt.coerce(e.python_version),t),n=R(r)&&R(e.pypy_version)||kt.satisfies(I(e.pypy_version),r),i=e.files&&(Mt?(e=>e.files.some((e=>Ut.includes(e.arch)&&Vt.includes(e.platform))))(e):((e,t,r)=>e.files.some((e=>e.arch===t&&e.platform===r)))(e,o,process.platform));return s&&n&&i}));if(0===s.length)return null;const n=s.sort(((e,t)=>kt.compare(kt.coerce(I(t.pypy_version)),kt.coerce(I(e.pypy_version)))||kt.compare(kt.coerce(t.python_version),kt.coerce(e.python_version))))[0];return{foundAsset:Mt?N(n):L(n,o,process.platform),resolvedPythonVersion:n.python_version,resolvedPyPyVersion:n.pypy_version}})(n,r,t,o);if(!i||!i.foundAsset)throw Error(`PyPy version ${r} (${t}) with arch ${o} not found`);const{foundAsset:a,resolvedPythonVersion:l,resolvedPyPyVersion:c}=i;let u=""+a.download_url;xe.info(`Downloading PyPy from "${u}" ...`);const p=await et.downloadTool(u);xe.info("Extracting downloaded archive..."),s=Mt?await et.extractZip(p):await et.extractTar(p,void 0,"x");const d=e(re).readdirSync(s)[0],h=te.join(s,d);let f=h;R(c)||(f=await et.cacheDir(h,"PyPy",l,o)),((t,r)=>{const o=te.join(t,"PYPY_VERSION");e(re).writeFileSync(o,r)})(f,c);const m=T(f);return await(async(e,t)=>{const r=kt.coerce(t),o=kt.major(r),s=2===o?"":"3";let n=Mt?".exe":"";xe.info("Creating symlinks..."),S(e,`pypy${s}${n}`,`python${o}${n}`,!0),S(e,`pypy${s}${n}`,"python"+n,!0)})(m,l),await(async e=>{xe.info("Installing and updating pip");const t=te.join(e,"python");await Ae.exec(t+" -m ensurepip"),await Ae.exec(e+"/python -m pip install --ignore-installed pip")})(m),{installDir:f,resolvedPythonVersion:l,resolvedPyPyVersion:c}})(i.pypyVersion,i.pythonVersion,r));const a=te.join(o,Mt?"Scripts":"bin"),l=T(o);return xe.exportVariable("pythonLocation",l),xe.addPath(l),xe.addPath(a),{resolvedPyPyVersion:s,resolvedPythonVersion:n}}(t,o);xe.info(`Successfully setup PyPy ${r.resolvedPyPyVersion} with Python (${r.resolvedPythonVersion})`)}else{const e=await(async(e,t)=>{switch(e.toUpperCase()){case"PYPY2":return A("2",t);case"PYPY3":return A("3.6",t);default:return await async function(e,t){const r=((o=e).endsWith("-dev")?`>= ${o.slice(0,-4)}.0-a0`:o).replace(/(\d+\.\d+\.\d+)((?:a|b|rc)\d*)/g,"$1-$2");var o;xe.debug(`Semantic version spec of ${e} is ${r}`);let s=et.find("Python",r,t);if(!s){xe.info(`Version ${r} was not found in the local cache`);const e=await(async(e,t)=>{const r=await et.getManifestFromRepo("actions","python-versions",Gt,"main");return await et.findFromManifest(e,!1,r,t)})(r,t);e&&e.files&&e.files.length>0&&(xe.info(`Version ${r} is available for downloading`),await(async e=>{const t=e.files[0].download_url;xe.info(`Download from "${t}"`);const r=await et.downloadTool(t,void 0,Gt);let o;xe.info("Extract downloaded archive"),o=Mt?await et.extractZip(r):await et.extractTar(r),xe.info("Execute installation script"),await(async e=>{const t={cwd:e,env:{...process.env,...Ft&&{LD_LIBRARY_PATH:te.join(e,"lib")}},silent:!0,listeners:{stdout(e){xe.info((""+e).trim())},stderr(e){xe.error((""+e).trim())}}};Mt?await Ae.exec("powershell",["./setup.ps1"],t):await Ae.exec("bash",["./setup.sh"],t)})(o)})(e),s=et.find("Python",r,t))}if(!s)throw Error([`Version ${e} with arch ${t} not found`,"The list of all available versions can be found here: "+Ht].join(ee.EOL));if(xe.exportVariable("pythonLocation",s),Ft){const e=process.env.LD_LIBRARY_PATH?":"+process.env.LD_LIBRARY_PATH:"",t=te.join(s,"lib");e.split(":").includes(t)||xe.exportVariable("LD_LIBRARY_PATH",t+e)}if(xe.addPath(s),xe.addPath((e=>te.join(e,Mt?"Scripts":"bin"))(s)),Mt){const e=te.basename(te.dirname(s)),t=kt.major(e),r=kt.minor(e),o=te.join(process.env.APPDATA||"","Python",`Python${t}${r}`,"Scripts");xe.addPath(o)}const n=C(s);return xe.setOutput("python-version",n),{impl:"CPython",version:n}}(e,t)}})(t,o);xe.info(`Successfully setup ${e.impl} (${e.version})`)}const r=te.join(__dirname,"..",".github");xe.info("##[add-matcher]"+te.join(r,"python.json"))}catch(e){xe.setFailed(e.message)}}function j(e){return new Promise((t=>{pe.get(e,(e=>{t(void 0!==e.statusCode&&e.statusCode>=200&&399>=e.statusCode)}))}))}async function k(t,r){if(void 0===Yt&&(null!==e(we).sync("pip3",{nothrow:!0})?Yt="pip3":null!==e(we).sync("pip",{nothrow:!0})&&await(async(t,r,o=/v?(\d\S*)/)=>{const s=await(async(e,t=/v?(\d\S*)/)=>{try{var r,o;const{stderr:n,stdout:i}=await Ae.getExecOutput(e,["--version"]);var s;return null!==(s=null===(r=i.match(t))||void 0===r?void 0:r[1])&&void 0!==s?s:null===(o=n.match(t))||void 0===o?void 0:o[1]}catch(e){return void console.error(e)}})(t,o);return"string"==typeof s&&"string"==typeof r&&""!==s&&""!==r&&-1!==e(Xt)(s,r)})("python","3.0.0")?Yt="pip":(await D("3.x",0,process.arch),Yt="pip3")),0!==e(Me).sync(Yt,["install",void 0!==r&&""!==r?`${t}==${r}`:t],{stdio:"inherit"}).status)throw Error(`Failed to install ${t} ${r}`);if(void 0===zt){if("linux"===process.platform)zt="/home/runner/.local/bin/";else if("darwin"===process.platform)zt="/usr/local/bin/";else try{zt=te.join((await Ae.getExecOutput('python3 -c "import sys;print(sys.base_exec_prefix);"')).stdout.trim(),"Scripts")}catch{zt=te.join((await Ae.getExecOutput('python -c "import sys;print(sys.base_exec_prefix);"')).stdout.trim(),"Scripts")}xe.info(zt+" to PATH"),await d(zt)}return{binDir:zt}}async function M(e,t){if(0!==await Ae.exec("7z",["x",e,"-o"+t]))throw Error(`Failed to extract ${e} to ${t} with 7z`);return t}async function F(e,t,r=["--strip-components=1"]){try{await Zt.mkdirP(t)}catch{}if(0!==await Ae.exec("tar",["xf",e,"-C",t,...r]))throw Error(`Failed to extract ${e} to ${t} with tar`);return t}function U(e,t,r){return`https://github.com/llvm/llvm-project/releases/download/llvmorg-${e}/${t}${e}${r}`}function V(e,t,r){return`https://releases.llvm.org/${e}/${t}${e}${r}`}function q(t,r){switch(t){case"darwin":return(t=>{if(Kt.has(t))return null;const r="clang+llvm-",o=`-x86_64${"9.0.0"===t?"-darwin-apple":"-apple-darwin"}.tar.xz`;return e(St)(t,"9.0.1")?V(t,r,o):U(t,r,o)})(r);case"linux":return(t=>{let r=t;const o=Qt.get(r);let s;void 0!==o&&(r=o),s=r.includes("ubuntu")?r:""!==r&&r in er?er[r]:er["12.0.1-rc4"];const n="clang+llvm-",i="5.0.0"===r?`-linux-x86_64${s}.tar.xz`:`-x86_64-linux-gnu${s}.tar.xz`;return e(St)(r,"9.0.1")?V(r,n,i):U(r,n,i)})(r);case"win32":return(async t=>{if(tr.has(t))return null;const r="LLVM-",o=e(St)(t,"3.7.0")?"-win32.exe":"-win64.exe",s=e(St)(t,"9.0.1");let n,i=!1;return s&&(n=V(t,r,o),await j(n)||(i=!0)),!i&&s||(n=U(t,r,o)),n})(r);default:return null}}async function G(e,t){const[r,o]=await(async(e,t,r,o)=>{if(!e.has(r))throw Error(`Unsupported target! (platform='${t}', version='${r}')`);for(const s of((e,t)=>Array.from(e).filter((e=>/^\d+\.\d+\.\d+$/.test(e)&&e.startsWith(t))).sort().reverse())(e,r)){const e=await o(t,s);if(null!==e&&await j(e))return[s,e]}throw Error(`Unsupported target! (platform='${t}', version='${r}')`)})(Jt,t,e,q);return xe.setOutput("version",r),{url:o,extractedFolderName:"",binRelativeDir:"bin",extractFunction:"win32"===t?M:F}}async function H(t,r,o){let s=r;""!==s&&void 0!==s||(s="win32"===process.platform?"C:/Program Files/LLVM":"./llvm"),s=te.resolve(s);const n=await O("llvm",t,G,s),i=te.join(s,"lib");var a;const l=null!==(a=process.env.LD_LIBRARY_PATH)&&void 0!==a?a:"";var c;const u=null!==(c=process.env.DYLD_LIBRARY_PATH)&&void 0!==c?c:"";xe.exportVariable("LLVM_PATH",s);const p=e(Wt)(t);if(xe.exportVariable("LD_LIBRARY_PATH",`${i}${te.delimiter}${l}`),xe.exportVariable("DYLD_LIBRARY_PATH",`${i}${te.delimiter}${u}`),xe.exportVariable("CPATH",`${s}/lib/clang/${p}/include`),xe.exportVariable("LDFLAGS",`-L${s}/lib`),xe.exportVariable("CPPFLAGS",`-I${s}/include`),xe.exportVariable("CC",s+"/bin/clang"),xe.exportVariable("CXX",s+"/bin/clang++"),xe.exportVariable("LIBRARY_PATH",s+"/lib"),"darwin"===process.platform)try{const e=await Ae.getExecOutput("xcrun --sdk macosx --show-sdk-path"),t=e.stdout||e.stderr;re.existsSync(t)&&xe.exportVariable("SDKROOT",t)}catch(e){xe.error(e)}return n}async function B(e,t,r,o,s,n){if("win32"!==process.platform)return;let i,a;try{"2015"===e?(i="14.0.25420.1",await f("visualcpp-build-tools",i,["--ignore-dependencies","--params","'/IncludeRequired'"]),a="C:/Program Files (x86)/MSBuild/Microsoft.Cpp/v4.0/v140",re.existsSync(a)&&xe.exportVariable("VCTargetsPath",a)):"2017"===e?(i="14.16",await f("visualstudio2017buildtools","15.9.38.0",["--package-parameters","'--add Microsoft.VisualStudio.Workload.NativeDesktop --includeRecommended --passive'"]),a="C:/Program Files (x86)/Microsoft Visual Studio/2017/BuildTools/VC/Tools/MSVC/14.16"):"2019"===e&&(i="14.29.30133",await f("visualstudio2019buildtools","16.11.2.0",["--package-parameters","'--add Microsoft.VisualStudio.Workload.NativeDesktop --includeRecommended --passive'"]),a="C:/Program Files (x86)/Microsoft Visual Studio/2019/BuildTools/VC/Tools/MSVC/14.29.30133")}catch(e){xe.error(e)}void 0!==a&&re.existsSync(a)&&xe.exportVariable("VCTargetsPath",a);const{setupMSVCDevCmd:l}=ge("jJT7R");l((e=>{switch(e){case"x32":case"32":case"ia32":return"x86";case"64":return"x64";default:return e}})(r),o,i,s,n)}function X(e,t){const r=(e=>{switch(e){case"win32":return"win";case"darwin":return"mac";case"linux":return"linux";default:throw Error(`Unsupported platform '${e}'`)}})(t);return{binRelativeDir:"",extractedFolderName:"",extractFunction:et.extractZip,url:`https://github.com/ninja-build/ninja/releases/download/v${e}/ninja-${r}.zip`}}function Y(e){return null==e?[]:Array.isArray(e)?e:[e]}function z(e,t,r,o){var s,n=e[t],i=~o.string.indexOf(t)?null==r||!0===r?"":r+"":"boolean"==typeof r?r:~o.boolean.indexOf(t)?"false"!==r&&("true"===r||(e._.push(0*(s=+r)==0?s:r),!!r)):0*(s=+r)==0?s:r;e[t]=null==n?i:Array.isArray(n)?n.concat(i):[n,i]}function W(e,t){return"true"===t||void 0===t&&e in nr?nr[e]:null!=t?t:""}async function Z(t,r,o){let s;switch(process.platform){case"win32":"arm"!==o&&"arm64"!==o||await f("gcc-arm-embedded",t),await f("mingw",t),"x64"===o&&re.existsSync("C:/tools/mingw64/bin")?(s="C:/tools/mingw64/bin",await d(s)):"ia32"===o&&re.existsSync("C:/tools/mingw32/bin")?(s="C:/tools/mingw32/bin",await d(s)):re.existsSync("C:/ProgramData/Chocolatey/bin/g++.exe")&&(s="C:/ProgramData/Chocolatey/bin/");break;case"darwin":s=p("gcc",t).binDir;break;case"linux":"x64"===o?s=(await i("g++",t,"ppa:ubuntu-toolchain-r/test")).binDir:(xe.info(`Install g++-multilib because gcc for ${o} was requested`),s=(await i("g++-multilib",t,"ppa:ubuntu-toolchain-r/test")).binDir);break;default:throw Error("Unsupported platform for "+o)}if(void 0!==s){var n;const r=e(Wt)(null!==(n=e(_t)(t))&&void 0!==n?n:t);return"win32"===process.platform?(xe.exportVariable("CC",s+"/gcc"),xe.exportVariable("CXX",s+"/g++")):(xe.exportVariable("CC",`${s}/gcc-${r}`),xe.exportVariable("CXX",`${s}/g++-${r}`)),{binDir:s}}}async function J(t){const r=!!process.env.CI;r||(process.env.ACTIONS_ALLOW_UNSECURE_COMMANDS="true");const o=((e,t)=>{var r,o,s,n,i,a={_:[]},l=0,c=0,u=0,p=(e=e||[]).length;const d=void 0!==(t=t||{}).alias,h=void 0!==t.unknown,f=void 0!==t.default;if(t.alias=t.alias||{},t.string=Y(t.string),t.boolean=Y(t.boolean),d)for(r in t.alias)for(o=t.alias[r]=Y(t.alias[r]),l=0;o.length>l;l++)(t.alias[o[l]]=o.concat(r)).splice(l,1);for(l=t.boolean.length;l-- >0;)for(c=(o=t.alias[t.boolean[l]]||[]).length;c-- >0;)t.boolean.push(o[c]);for(l=t.string.length;l-- >0;)for(c=(o=t.alias[t.string[l]]||[]).length;c-- >0;)t.string.push(o[c]);if(f)for(r in t.default)if(n=typeof t.default[r],o=t.alias[r]=t.alias[r]||[],void 0!==t[n])for(t[n].push(r),l=0;o.length>l;l++)t[n].push(o[l]);const m=h?Object.keys(t.alias):[];for(l=0;p>l;l++){if("--"===(s=e[l])){a._=a._.concat(e.slice(++l));break}for(c=0;s.length>c&&45===s.charCodeAt(c);c++);if(0===c)a._.push(s);else if("no-"===s.substring(c,c+3)){if(n=s.substring(c+3),h&&!~m.indexOf(n))return t.unknown(s);a[n]=!1}else{for(u=c+1;s.length>u&&61!==s.charCodeAt(u);u++);for(n=s.substring(c,u),i=s.substring(++u)||l+1===p||45===(""+e[l+1]).charCodeAt(0)||e[++l],o=2===c?[n]:n,u=0;o.length>u;u++){if(n=o[u],h&&!~m.indexOf(n))return t.unknown("-".repeat(c)+n);z(a,n,o.length>u+1||i,t)}}}if(f)for(r in t.default)void 0===a[r]&&(a[r]=t.default[r]);if(d)for(r in a)for(o=t.alias[r]||[];o.length>0;)a[o.shift()]=a[r];return a})(t,{string:lr,default:Object.fromEntries(lr.map((e=>[e,K(e)]))),alias:{h:"help"},boolean:"help"});var s;o.help&&xe.info('\nsetup_cpp [options]\nsetup_cpp --compiler llvm --cmake true --ninja true --ccache true --conan "1.40.1"\n\nInstall all the tools required for building and testing C++/C projects.\n\n--architecture\t the cpu architecture to install the tools for. By default it uses the current CPU architecture.\n--compiler\t the <compiler> to install.\n \t You can specify the version instead of specifying just the name e.g: --compiler \'llvm-11\'\n\n--tool_name\t pass "true" or pass the <version> you would like to install for this tool.\n\nAll the available tools:\n--llvm\n--gcc\n--cmake\n--ninja\n--meson\n--conan\n--ccache\n--cppcheck\n--doxygen\n--gcovr\n--opencppcoverage\n--python\n--choco\n--brew\n ');const n=null!==(s=o.architecture)&&void 0!==s?s:process.arch;var i;const a=null!==(i=process.env.SETUP_CPP_DIR)&&void 0!==i?i:e(rr)("~/setup_cpp"),l=[],c=[],u=o.compiler;try{if(void 0!==u){const t=u.split("-"),r=t[0];let o;if(1 in t){const r=t[1];null!==e(sr)(r)?o=r:xe.error(`Invalid version ${r} used for the compiler. Using the default version...`)}switch(r){case"llvm":case"clang":case"clang++":await H(W("llvm",o),a);break;case"gcc":case"mingw":case"cygwin":case"msys":await Z(W("gcc",o),0,n);break;case"cl":case"msvc":case"msbuild":case"vs":case"visualstudio":case"visualcpp":case"visualc++":await B(W("msvc",o),0,n);break;default:c.push("Unsupported compiler "+r)}}}catch(e){c.push("Failed to install the "+u)}for(const e of ar){const t=o[e];if(void 0!==t){const r=ir[e];try{const o=await r(W(e,t),a,n);l.push(void 0!==o?Q(e,o):e+" was successfully installed")}catch(t){c.push(e+" failed to install")}}}return l.forEach((e=>r?xe.info(e):console.log(`${e}`))),c.forEach((e=>r?xe.error(e):console.log(`${e}`))),xe.info("setup_cpp finished"),0===c.length?0:1}function K(e){const t=xe.getInput(e.toLowerCase());if("false"!==t&&""!==t)return t}function Q(e,t){let r=e+" was successfully installed";return"installDir"in t&&(r+="\nThe installation direcotry is "+t.installDir),""!==t.binDir&&(r+="\nThe binary direcotry is "+t.binDir),r}var ee=require("os"),te=require("path"),re=require("fs"),oe=require("child_process"),se=require("string_decoder"),ne=require("events"),ie=require("timers"),ae=require("assert"),le=require("util"),ce=require("stream"),ue=require("http"),pe=require("https");require("net");var de=require("tls"),he=require("crypto"),fe=require("process"),me="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:"undefined"!=typeof global?global:{},ve={},ye={},ge=me.parcelRequire810d;null==ge&&((ge=e=>{if(e in ve)return ve[e].exports;if(e in ye){var t=ye[e];delete ye[e];var r={id:e,exports:{}};return ve[e]=r,t.call(r.exports,r,r.exports),r.exports}var o=Error("Cannot find module '"+e+"'");throw o.code="MODULE_NOT_FOUND",o}).register=(e,t)=>{ye[e]=t},me.parcelRequire810d=ge),t(module.exports,"main",(()=>J)),ge.register("6FGZZ",(function(e,t){"use strict";function r(e,t){const r=process.env["INPUT_"+e.replace(/ /g,"_").toUpperCase()]||"";if(t&&t.required&&!r)throw Error("Input required and not supplied: "+e);return t&&!1===t.trimWhitespace?r:r.trim()}function o(e,t={}){u.issueCommand("error",d.toCommandProperties(t),e instanceof Error?""+e:e)}function s(e){u.issue("group",e)}function n(){u.issue("endgroup")}var i=e.exports&&e.exports.__createBinding||(Object.create?(e,t,r,o)=>{void 0===o&&(o=r),Object.defineProperty(e,o,{enumerable:!0,get(){return t[r]}})}:(e,t,r,o)=>{void 0===o&&(o=r),e[o]=t[r]}),a=e.exports&&e.exports.__setModuleDefault||(Object.create?(e,t)=>{Object.defineProperty(e,"default",{enumerable:!0,value:t})}:(e,t)=>{e.default=t}),l=e.exports&&e.exports.__importStar||(e=>{if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)"default"!==r&&Object.hasOwnProperty.call(e,r)&&i(t,e,r);return a(t,e),t}),c=e.exports&&e.exports.__awaiter||((e,t,r,o)=>new(r||(r=Promise))(((s,n)=>{function i(e){try{l(o.next(e))}catch(e){n(e)}}function a(e){try{l(o.throw(e))}catch(e){n(e)}}function l(e){var t;e.done?s(e.value):(t=e.value,t instanceof r?t:new r((e=>{e(t)}))).then(i,a)}l((o=o.apply(e,t||[])).next())})));Object.defineProperty(e.exports,"__esModule",{value:!0}),e.exports.getState=e.exports.saveState=e.exports.group=e.exports.endGroup=e.exports.startGroup=e.exports.info=e.exports.notice=e.exports.warning=e.exports.error=e.exports.debug=e.exports.isDebug=e.exports.setFailed=e.exports.setCommandEcho=e.exports.setOutput=e.exports.getBooleanInput=e.exports.getMultilineInput=e.exports.getInput=e.exports.addPath=e.exports.setSecret=e.exports.exportVariable=e.exports.ExitCode=void 0;var u=ge("eOxkI"),p=ge("85a1M"),d=ge("lK3O3");const h=l(ee),f=l(te);var m,v;(v=m=e.exports.ExitCode||(e.exports.ExitCode={}))[v.Success=0]="Success",v[v.Failure=1]="Failure",e.exports.exportVariable=(e,t)=>{const r=d.toCommandValue(t);if(process.env[e]=r,process.env.GITHUB_ENV){const t="_GitHubActionsFileCommandDelimeter_";p.issueCommand("ENV",`${e}<<${t}${h.EOL}${r}${h.EOL}${t}`)}else u.issueCommand("set-env",{name:e},r)},e.exports.setSecret=e=>{u.issueCommand("add-mask",{},e)},e.exports.addPath=e=>{process.env.GITHUB_PATH?p.issueCommand("PATH",e):u.issueCommand("add-path",{},e),process.env.PATH=`${e}${f.delimiter}${process.env.PATH}`},e.exports.getInput=r,e.exports.getMultilineInput=(e,t)=>r(e,t).split("\n").filter((e=>""!==e)),e.exports.getBooleanInput=(e,t)=>{const o=r(e,t);if(["true","True","TRUE"].includes(o))return!0;if(["false","False","FALSE"].includes(o))return!1;throw new TypeError(`Input does not meet YAML 1.2 "Core Schema" specification: ${e}\nSupport boolean input list: \`true | True | TRUE | false | False | FALSE\``)},e.exports.setOutput=(e,t)=>{process.stdout.write(h.EOL),u.issueCommand("set-output",{name:e},t)},e.exports.setCommandEcho=e=>{u.issue("echo",e?"on":"off")},e.exports.setFailed=e=>{process.exitCode=m.Failure,o(e)},e.exports.isDebug=()=>"1"===process.env.RUNNER_DEBUG,e.exports.debug=e=>{u.issueCommand("debug",{},e)},e.exports.error=o,e.exports.warning=(e,t={})=>{u.issueCommand("warning",d.toCommandProperties(t),e instanceof Error?""+e:e)},e.exports.notice=(e,t={})=>{u.issueCommand("notice",d.toCommandProperties(t),e instanceof Error?""+e:e)},e.exports.info=e=>{process.stdout.write(e+h.EOL)},e.exports.startGroup=s,e.exports.endGroup=n,e.exports.group=function(e,t){return c(this,void 0,void 0,(function*(){let r;s(e);try{r=yield t()}finally{n()}return r}))},e.exports.saveState=(e,t)=>{u.issueCommand("save-state",{name:e},t)},e.exports.getState=e=>process.env["STATE_"+e]||""})),ge.register("eOxkI",(function(e,t){"use strict";function r(e,t,r){const o=new l(e,t,r);process.stdout.write(""+o+i.EOL)}var o=e.exports&&e.exports.__createBinding||(Object.create?(e,t,r,o)=>{void 0===o&&(o=r),Object.defineProperty(e,o,{enumerable:!0,get(){return t[r]}})}:(e,t,r,o)=>{void 0===o&&(o=r),e[o]=t[r]}),s=e.exports&&e.exports.__setModuleDefault||(Object.create?(e,t)=>{Object.defineProperty(e,"default",{enumerable:!0,value:t})}:(e,t)=>{e.default=t}),n=e.exports&&e.exports.__importStar||(e=>{if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)"default"!==r&&Object.hasOwnProperty.call(e,r)&&o(t,e,r);return s(t,e),t});Object.defineProperty(e.exports,"__esModule",{value:!0}),e.exports.issue=e.exports.issueCommand=void 0;const i=n(ee);var a=ge("lK3O3");e.exports.issueCommand=r,e.exports.issue=(e,t="")=>{r(e,{},t)};class l{constructor(e,t,r){e||(e="missing.command"),this.command=e,this.properties=t,this.message=r}toString(){let e="::"+this.command;if(this.properties&&Object.keys(this.properties).length>0){e+=" ";let r=!0;for(const o in this.properties)if(this.properties.hasOwnProperty(o)){const s=this.properties[o];s&&(r?r=!1:e+=",",e+=`${o}=${t=s,a.toCommandValue(t).replace(/%/g,"%25").replace(/\r/g,"%0D").replace(/\n/g,"%0A").replace(/:/g,"%3A").replace(/,/g,"%2C")}`)}}var t;return e+="::"+(e=>a.toCommandValue(this.message).replace(/%/g,"%25").replace(/\r/g,"%0D").replace(/\n/g,"%0A"))(),e}}})),ge.register("lK3O3",((e,t)=>{"use strict";Object.defineProperty(e.exports,"__esModule",{value:!0}),e.exports.toCommandProperties=e.exports.toCommandValue=void 0,e.exports.toCommandValue=e=>null==e?"":"string"==typeof e||e instanceof String?e:JSON.stringify(e),e.exports.toCommandProperties=e=>Object.keys(e).length?{title:e.title,line:e.startLine,endLine:e.endLine,col:e.startColumn,endColumn:e.endColumn}:{}})),ge.register("85a1M",((e,t)=>{"use strict";var r=e.exports&&e.exports.__createBinding||(Object.create?(e,t,r,o)=>{void 0===o&&(o=r),Object.defineProperty(e,o,{enumerable:!0,get(){return t[r]}})}:(e,t,r,o)=>{void 0===o&&(o=r),e[o]=t[r]}),o=e.exports&&e.exports.__setModuleDefault||(Object.create?(e,t)=>{Object.defineProperty(e,"default",{enumerable:!0,value:t})}:(e,t)=>{e.default=t}),s=e.exports&&e.exports.__importStar||(e=>{if(e&&e.__esModule)return e;var t={};if(null!=e)for(var s in e)"default"!==s&&Object.hasOwnProperty.call(e,s)&&r(t,e,s);return o(t,e),t});Object.defineProperty(e.exports,"__esModule",{value:!0}),e.exports.issueCommand=void 0;const n=s(re),i=s(ee);var a=ge("lK3O3");e.exports.issueCommand=(e,t)=>{const r=process.env["GITHUB_"+e];if(!r)throw Error("Unable to find environment variable for file command "+e);if(!n.existsSync(r))throw Error("Missing file at path: "+r);n.appendFileSync(r,`${a.toCommandValue(t)}${i.EOL}`,{encoding:"utf8"})}}));var xe=ge("6FGZZ"),we={};const Ee="win32"===process.platform||"cygwin"===process.env.OSTYPE||"msys"===process.env.OSTYPE,be=Ee?";":":";var Pe,Oe={};ge.register("5vEMD",((e,t)=>{function r(e,t,r){return!(!e.isSymbolicLink()&&!e.isFile())&&((e,t)=>{var r=void 0!==t.pathExt?t.pathExt:process.env.PATHEXT;if(!r)return!0;if(-1!==(r=r.split(";")).indexOf(""))return!0;for(var o=0;r.length>o;o++){var s=r[o].toLowerCase();if(s&&e.substr(-s.length).toLowerCase()===s)return!0}return!1})(t,r)}function o(e,t,o){re.stat(e,((s,n)=>{o(s,!s&&r(n,e,t))}))}e.exports=o,o.sync=(e,t)=>r(re.statSync(e),e,t)})),ge.register("kam8f",((e,t)=>{function r(e,t,r){re.stat(e,((e,s)=>{r(e,!e&&o(s,t))}))}function o(e,t){return e.isFile()&&((e,t)=>{var r=e.mode,o=e.uid,s=e.gid,n=void 0!==t.uid?t.uid:process.getuid&&process.getuid(),i=void 0!==t.gid?t.gid:process.getgid&&process.getgid(),a=parseInt("100",8),l=parseInt("010",8),c=a|l;return r&parseInt("001",8)||r&l&&s===i||r&a&&o===n||r&c&&0===n})(e,t)}e.exports=r,r.sync=(e,t)=>o(re.statSync(e),t)})),Pe="win32"===process.platform||me.TESTING_WINDOWS?ge("5vEMD"):ge("kam8f"),Oe=r,r.sync=(e,t)=>{try{return Pe.sync(e,t||{})}catch(e){if(t&&t.ignoreErrors||"EACCES"===e.code)return!1;throw e}};const $e=e=>Object.assign(Error("not found: "+e),{code:"ENOENT"}),Se=(e,t)=>{const r=t.colon||be,o=e.match(/\//)||Ee&&e.match(/\\/)?[""]:[...Ee?[process.cwd()]:[],...(t.path||process.env.PATH||"").split(r)],s=Ee?t.pathExt||process.env.PATHEXT||".EXE;.CMD;.BAT;.COM":"",n=Ee?s.split(r):[""];return Ee&&-1!==e.indexOf(".")&&""!==n[0]&&n.unshift(""),{pathEnv:o,pathExt:n,pathExtExe:s}},_e=(e,t,r)=>{"function"==typeof t&&(r=t,t={}),t||(t={});const{pathEnv:o,pathExt:s,pathExtExe:n}=Se(e,t),i=[],a=r=>new Promise(((s,n)=>{if(r===o.length)return t.all&&i.length?s(i):n($e(e));const a=o[r],c=/^".*"$/.test(a)?a.slice(1,-1):a,u=te.join(c,e),p=!c&&/^\.[\\\/]/.test(e)?e.slice(0,2)+u:u;s(l(p,r,0))})),l=(e,r,o)=>new Promise(((c,u)=>{if(o===s.length)return c(a(r+1));const p=s[o];Oe(e+p,{pathExt:n},((s,n)=>{if(!s&&n){if(!t.all)return c(e+p);i.push(e+p)}return c(l(e,r,o+1))}))}));return r?a(0).then((e=>r(null,e)),r):a(0)};let Re;we=_e,_e.sync=(e,t)=>{t=t||{};const{pathEnv:r,pathExt:o,pathExtExe:s}=Se(e,t),n=[];for(let i=0;r.length>i;i++){const a=r[i],l=/^".*"$/.test(a)?a.slice(1,-1):a,c=te.join(l,e),u=!l&&/^\.[\\\/]/.test(e)?e.slice(0,2)+c:c;for(let e=0;o.length>e;e++){const r=u+o[e];try{if(Oe.sync(r,{pathExt:s})){if(!t.all)return r;n.push(r)}}catch(e){}}}if(t.all&&n.length)return n;if(t.nothrow)return null;throw $e(e)};var Ae={},Ce=Ae&&Ae.__createBinding||(Object.create?(e,t,r,o)=>{void 0===o&&(o=r),Object.defineProperty(e,o,{enumerable:!0,get(){return t[r]}})}:(e,t,r,o)=>{void 0===o&&(o=r),e[o]=t[r]}),Te=Ae&&Ae.__setModuleDefault||(Object.create?(e,t)=>{Object.defineProperty(e,"default",{enumerable:!0,value:t})}:(e,t)=>{e.default=t}),Ie=Ae&&Ae.__importStar||(e=>{if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)"default"!==r&&Object.hasOwnProperty.call(e,r)&&Ce(t,e,r);return Te(t,e),t}),Ne=Ae&&Ae.__awaiter||((e,t,r,o)=>new(r||(r=Promise))(((s,n)=>{function i(e){try{l(o.next(e))}catch(e){n(e)}}function a(e){try{l(o.throw(e))}catch(e){n(e)}}function l(e){var t;e.done?s(e.value):(t=e.value,t instanceof r?t:new r((e=>{e(t)}))).then(i,a)}l((o=o.apply(e,t||[])).next())})));Object.defineProperty(Ae,"__esModule",{value:!0}),Ae.getExecOutput=Ae.exec=void 0,ge.register("fk1Ma",(function(e,t){"use strict";var r=e.exports&&e.exports.__createBinding||(Object.create?(e,t,r,o)=>{void 0===o&&(o=r),Object.defineProperty(e,o,{enumerable:!0,get(){return t[r]}})}:(e,t,r,o)=>{void 0===o&&(o=r),e[o]=t[r]}),o=e.exports&&e.exports.__setModuleDefault||(Object.create?(e,t)=>{Object.defineProperty(e,"default",{enumerable:!0,value:t})}:(e,t)=>{e.default=t}),s=e.exports&&e.exports.__importStar||(e=>{if(e&&e.__esModule)return e;var t={};if(null!=e)for(var s in e)"default"!==s&&Object.hasOwnProperty.call(e,s)&&r(t,e,s);return o(t,e),t}),n=e.exports&&e.exports.__awaiter||((e,t,r,o)=>new(r||(r=Promise))(((s,n)=>{function i(e){try{l(o.next(e))}catch(e){n(e)}}function a(e){try{l(o.throw(e))}catch(e){n(e)}}function l(e){var t;e.done?s(e.value):(t=e.value,t instanceof r?t:new r((e=>{e(t)}))).then(i,a)}l((o=o.apply(e,t||[])).next())})));Object.defineProperty(e.exports,"__esModule",{value:!0}),e.exports.argStringToArray=e.exports.ToolRunner=void 0;const i=s(ee),a=s(ne),l=s(oe),c=s(te),u=s(ge("q05Mr")),p=s(ge("fyhIP")),d="win32"===process.platform;e.exports.ToolRunner=class extends a.EventEmitter{constructor(e,t,r){if(super(),!e)throw Error("Parameter 'toolPath' cannot be null or empty.");this.toolPath=e,this.args=t||[],this.options=r||{}}_debug(e){this.options.listeners&&this.options.listeners.debug&&this.options.listeners.debug(e)}_getCommandString(e,t){const r=this._getSpawnFileName(),o=this._getSpawnArgs(e);let s=t?"":"[command]";if(d)if(this._isCmdFile()){s+=r;for(const e of o)s+=" "+e}else if(e.windowsVerbatimArguments){s+=`"${r}"`;for(const e of o)s+=" "+e}else{s+=this._windowsQuoteCmdArg(r);for(const e of o)s+=" "+this._windowsQuoteCmdArg(e)}else{s+=r;for(const e of o)s+=" "+e}return s}_processLineBuffer(e,t,r){try{let o=t+""+e,s=o.indexOf(i.EOL);for(;s>-1;)r(o.substring(0,s)),o=o.substring(s+i.EOL.length),s=o.indexOf(i.EOL);return o}catch(e){return this._debug("error processing line. Failed with error "+e),""}}_getSpawnFileName(){return d&&this._isCmdFile()?process.env.COMSPEC||"cmd.exe":this.toolPath}_getSpawnArgs(e){if(d&&this._isCmdFile()){let t='/D /S /C "'+this._windowsQuoteCmdArg(this.toolPath);for(const r of this.args)t+=" ",t+=e.windowsVerbatimArguments?r:this._windowsQuoteCmdArg(r);return t+='"',[t]}return this.args}_endsWith(e,t){return e.endsWith(t)}_isCmdFile(){const e=this.toolPath.toUpperCase();return this._endsWith(e,".CMD")||this._endsWith(e,".BAT")}_windowsQuoteCmdArg(e){if(!this._isCmdFile())return this._uvQuoteCmdArg(e);if(!e)return'""';const t=[" ","\t","&","(",")","[","]","{","}","^","=",";","!","'","+",",","`","~","|","<",">",'"'];let r=!1;for(const o of e)if(t.some((e=>e===o))){r=!0;break}if(!r)return e;let o='"',s=!0;for(let t=e.length;t>0;t--)o+=e[t-1],s&&"\\"===e[t-1]?o+="\\":'"'===e[t-1]?(s=!0,o+='"'):s=!1;return o+='"',o.split("").reverse().join("")}_uvQuoteCmdArg(e){if(!e)return'""';if(!e.includes(" ")&&!e.includes("\t")&&!e.includes('"'))return e;if(!e.includes('"')&&!e.includes("\\"))return`"${e}"`;let t='"',r=!0;for(let o=e.length;o>0;o--)t+=e[o-1],r&&"\\"===e[o-1]?t+="\\":'"'===e[o-1]?(r=!0,t+="\\"):r=!1;return t+='"',t.split("").reverse().join("")}_cloneExecOptions(e){const t={cwd:(e=e||{}).cwd||process.cwd(),env:e.env||process.env,silent:e.silent||!1,windowsVerbatimArguments:e.windowsVerbatimArguments||!1,failOnStdErr:e.failOnStdErr||!1,ignoreReturnCode:e.ignoreReturnCode||!1,delay:e.delay||1e4};return t.outStream=e.outStream||process.stdout,t.errStream=e.errStream||process.stderr,t}_getSpawnOptions(e,t){const r={};return r.cwd=(e=e||{}).cwd,r.env=e.env,r.windowsVerbatimArguments=e.windowsVerbatimArguments||this._isCmdFile(),e.windowsVerbatimArguments&&(r.argv0=`"${t}"`),r}exec(){return n(this,void 0,void 0,(function*(){return!p.isRooted(this.toolPath)&&(this.toolPath.includes("/")||d&&this.toolPath.includes("\\"))&&(this.toolPath=c.resolve(process.cwd(),this.options.cwd||process.cwd(),this.toolPath)),this.toolPath=yield u.which(this.toolPath,!0),new Promise(((e,t)=>n(this,void 0,void 0,(function*(){this._debug("exec tool: "+this.toolPath),this._debug("arguments:");for(const e of this.args)this._debug(" "+e);const r=this._cloneExecOptions(this.options);!r.silent&&r.outStream&&r.outStream.write(this._getCommandString(r)+i.EOL);const o=new h(r,this.toolPath);if(o.on("debug",(e=>{this._debug(e)})),this.options.cwd&&!(yield p.exists(this.options.cwd)))return t(Error(`The cwd: ${this.options.cwd} does not exist!`));const s=this._getSpawnFileName(),n=l.spawn(s,this._getSpawnArgs(r),this._getSpawnOptions(this.options,s));let a="";n.stdout&&n.stdout.on("data",(e=>{this.options.listeners&&this.options.listeners.stdout&&this.options.listeners.stdout(e),!r.silent&&r.outStream&&r.outStream.write(e),a=this._processLineBuffer(e,a,(e=>{this.options.listeners&&this.options.listeners.stdline&&this.options.listeners.stdline(e)}))}));let c="";if(n.stderr&&n.stderr.on("data",(e=>{o.processStderr=!0,this.options.listeners&&this.options.listeners.stderr&&this.options.listeners.stderr(e),!r.silent&&r.errStream&&r.outStream&&(r.failOnStdErr?r.errStream:r.outStream).write(e),c=this._processLineBuffer(e,c,(e=>{this.options.listeners&&this.options.listeners.errline&&this.options.listeners.errline(e)}))})),n.on("error",(e=>{o.processError=e.message,o.processExited=!0,o.processClosed=!0,o.CheckComplete()})),n.on("exit",(e=>{o.processExitCode=e,o.processExited=!0,this._debug(`Exit code ${e} received from tool '${this.toolPath}'`),o.CheckComplete()})),n.on("close",(e=>{o.processExitCode=e,o.processExited=!0,o.processClosed=!0,this._debug(`STDIO streams have closed for tool '${this.toolPath}'`),o.CheckComplete()})),o.on("done",((r,o)=>{a.length>0&&this.emit("stdline",a),c.length>0&&this.emit("errline",c),n.removeAllListeners(),r?t(r):e(o)})),this.options.input){if(!n.stdin)throw Error("child process missing stdin");n.stdin.end(this.options.input)}}))))}))}},e.exports.argStringToArray=e=>{function t(e){s&&'"'!==e&&(n+="\\"),n+=e,s=!1}const r=[];let o=!1,s=!1,n="";for(let i=0;e.length>i;i++){const a=e.charAt(i);'"'!==a?"\\"===a&&s?t(a):"\\"===a&&o?s=!0:" "!==a||o?t(a):n.length>0&&(r.push(n),n=""):s?t(a):o=!o}return n.length>0&&r.push(n.trim()),r};class h extends a.EventEmitter{constructor(e,t){if(super(),this.processClosed=!1,this.processError="",this.processExitCode=0,this.processExited=!1,this.processStderr=!1,this.delay=1e4,this.done=!1,this.timeout=null,!t)throw Error("toolPath must not be empty");this.options=e,this.toolPath=t,e.delay&&(this.delay=e.delay)}CheckComplete(){this.done||(this.processClosed?this._setResult():this.processExited&&(this.timeout=ie.setTimeout(h.HandleTimeout,this.delay,this)))}_debug(e){this.emit("debug",e)}_setResult(){let e;this.processExited&&(this.processError?e=Error(`There was an error when attempting to execute the process '${this.toolPath}'. This may indicate the process failed to start. Error: ${this.processError}`):0===this.processExitCode||this.options.ignoreReturnCode?this.processStderr&&this.options.failOnStdErr&&(e=Error(`The process '${this.toolPath}' failed because one or more lines were written to the STDERR stream`)):e=Error(`The process '${this.toolPath}' failed with exit code ${this.processExitCode}`)),this.timeout&&(clearTimeout(this.timeout),this.timeout=null),this.done=!0,this.emit("done",e,this.processExitCode)}static HandleTimeout(e){e.done||(!e.processClosed&&e.processExited&&e._debug(`The STDIO streams did not close within ${e.delay/1e3} seconds of the exit event from process '${e.toolPath}'. This may indicate a child process inherited the STDIO streams and has not yet exited.`),e._setResult())}}})),ge.register("q05Mr",(function(e,t){"use strict";function r(e){return u(this,void 0,void 0,(function*(){if(h.IS_WINDOWS){if(/[*"<>|]/.test(e))throw Error('File path must not contain `*`, `"`, `<`, `>` or `|` on Windows');try{const t=h.getCmdPath();(yield h.isDirectory(e,!0))?yield f(t+' /s /c "rd /s /q "%inputPath%""',{env:{inputPath:e}}):yield f(t+' /s /c "del /f /a "%inputPath%""',{env:{inputPath:e}})}catch(e){if("ENOENT"!==e.code)throw e}try{yield h.unlink(e)}catch(e){if("ENOENT"!==e.code)throw e}}else{let t=!1;try{t=yield h.isDirectory(e)}catch(e){if("ENOENT"!==e.code)throw e;return}t?yield m("rm",["-rf",""+e]):yield h.unlink(e)}}))}function o(e){return u(this,void 0,void 0,(function*(){ae.ok(e,"a path argument must be provided"),yield h.mkdir(e,{recursive:!0})}))}function s(e){return u(this,void 0,void 0,(function*(){if(!e)throw Error("parameter 'tool' is required");const t=[];if(h.IS_WINDOWS&&process.env.PATHEXT)for(const e of process.env.PATHEXT.split(d.delimiter))e&&t.push(e);if(h.isRooted(e)){const r=yield h.tryGetExecutablePath(e,t);return r?[r]:[]}if(e.includes(d.sep))return[];const r=[];if(process.env.PATH)for(const e of process.env.PATH.split(d.delimiter))e&&r.push(e);const o=[];for(const s of r){const r=yield h.tryGetExecutablePath(d.join(s,e),t);r&&o.push(r)}return o}))}function n(e,t,r,s){return u(this,void 0,void 0,(function*(){if(r>=255)return;r++,yield o(t);const a=yield h.readdir(e);for(const o of a){const a=`${e}/${o}`,l=`${t}/${o}`;(yield h.lstat(a)).isDirectory()?yield n(a,l,r,s):yield i(a,l,s)}yield h.chmod(t,(yield h.stat(e)).mode)}))}function i(e,t,r){return u(this,void 0,void 0,(function*(){if((yield h.lstat(e)).isSymbolicLink()){try{yield h.lstat(t),yield h.unlink(t)}catch(e){"EPERM"===e.code&&(yield h.chmod(t,"0666"),yield h.unlink(t))}const r=yield h.readlink(e);yield h.symlink(r,t,h.IS_WINDOWS?"junction":null)}else(yield h.exists(t))&&!r||(yield h.copyFile(e,t))}))}var a=e.exports&&e.exports.__createBinding||(Object.create?(e,t,r,o)=>{void 0===o&&(o=r),Object.defineProperty(e,o,{enumerable:!0,get(){return t[r]}})}:(e,t,r,o)=>{void 0===o&&(o=r),e[o]=t[r]}),l=e.exports&&e.exports.__setModuleDefault||(Object.create?(e,t)=>{Object.defineProperty(e,"default",{enumerable:!0,value:t})}:(e,t)=>{e.default=t}),c=e.exports&&e.exports.__importStar||(e=>{if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)"default"!==r&&Object.hasOwnProperty.call(e,r)&&a(t,e,r);return l(t,e),t}),u=e.exports&&e.exports.__awaiter||((e,t,r,o)=>new(r||(r=Promise))(((s,n)=>{function i(e){try{l(o.next(e))}catch(e){n(e)}}function a(e){try{l(o.throw(e))}catch(e){n(e)}}function l(e){var t;e.done?s(e.value):(t=e.value,t instanceof r?t:new r((e=>{e(t)}))).then(i,a)}l((o=o.apply(e,t||[])).next())})));Object.defineProperty(e.exports,"__esModule",{value:!0}),e.exports.findInPath=e.exports.which=e.exports.mkdirP=e.exports.rmRF=e.exports.mv=e.exports.cp=void 0;const p=c(oe),d=c(te),h=c(ge("fyhIP")),f=le.promisify(p.exec),m=le.promisify(p.execFile);e.exports.cp=function(e,t,r={}){return u(this,void 0,void 0,(function*(){const{force:o,recursive:s,copySourceDirectory:a}=(e=>({force:null==e.force||e.force,recursive:!!e.recursive,copySourceDirectory:null==e.copySourceDirectory||!!e.copySourceDirectory}))(r),l=(yield h.exists(t))?yield h.stat(t):null;if(l&&l.isFile()&&!o)return;const c=l&&l.isDirectory()&&a?d.join(t,d.basename(e)):t;if(!(yield h.exists(e)))throw Error("no such file or directory: "+e);if((yield h.stat(e)).isDirectory()){if(!s)throw Error(`Failed to copy. ${e} is a directory, but tried to copy without recursive flag.`);yield n(e,c,0,o)}else{if(""===d.relative(e,c))throw Error(`'${c}' and '${e}' are the same file`);yield i(e,c,o)}}))},e.exports.mv=function(e,t,s={}){return u(this,void 0,void 0,(function*(){if(yield h.exists(t)){let o=!0;if((yield h.isDirectory(t))&&(t=d.join(t,d.basename(e)),o=yield h.exists(t)),o){if(null!=s.force&&!s.force)throw Error("Destination already exists");yield r(t)}}yield o(d.dirname(t)),yield h.rename(e,t)}))},e.exports.rmRF=r,e.exports.mkdirP=o,e.exports.which=function e(t,r){return u(this,void 0,void 0,(function*(){if(!t)throw Error("parameter 'tool' is required");if(r){const r=yield e(t,!1);if(!r)throw Error(h.IS_WINDOWS?`Unable to locate executable file: ${t}. Please verify either the file path exists or the file can be found within a directory specified by the PATH environment variable. Also verify the file has a valid extension for an executable file.`:`Unable to locate executable file: ${t}. Please verify either the file path exists or the file can be found within a directory specified by the PATH environment variable. Also check the file mode to verify the file is executable.`);return r}const o=yield s(t);return o&&o.length>0?o[0]:""}))},e.exports.findInPath=s})),ge.register("fyhIP",(function(e,t){"use strict";function r(e){return(1&e.mode)>0||(8&e.mode)>0&&e.gid===process.getgid()||(64&e.mode)>0&&e.uid===process.getuid()}var o,s=e.exports&&e.exports.__createBinding||(Object.create?(e,t,r,o)=>{void 0===o&&(o=r),Object.defineProperty(e,o,{enumerable:!0,get(){return t[r]}})}:(e,t,r,o)=>{void 0===o&&(o=r),e[o]=t[r]}),n=e.exports&&e.exports.__setModuleDefault||(Object.create?(e,t)=>{Object.defineProperty(e,"default",{enumerable:!0,value:t})}:(e,t)=>{e.default=t}),i=e.exports&&e.exports.__importStar||(e=>{if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)"default"!==r&&Object.hasOwnProperty.call(e,r)&&s(t,e,r);return n(t,e),t}),a=e.exports&&e.exports.__awaiter||((e,t,r,o)=>new(r||(r=Promise))(((s,n)=>{function i(e){try{l(o.next(e))}catch(e){n(e)}}function a(e){try{l(o.throw(e))}catch(e){n(e)}}function l(e){var t;e.done?s(e.value):(t=e.value,t instanceof r?t:new r((e=>{e(t)}))).then(i,a)}l((o=o.apply(e,t||[])).next())})));Object.defineProperty(e.exports,"__esModule",{value:!0}),e.exports.getCmdPath=e.exports.tryGetExecutablePath=e.exports.isRooted=e.exports.isDirectory=e.exports.exists=e.exports.IS_WINDOWS=e.exports.unlink=e.exports.symlink=e.exports.stat=e.exports.rmdir=e.exports.rename=e.exports.readlink=e.exports.readdir=e.exports.mkdir=e.exports.lstat=e.exports.copyFile=e.exports.chmod=void 0;const l=i(re),c=i(te);e.exports.chmod=(o=l.promises).chmod,e.exports.copyFile=o.copyFile,e.exports.lstat=o.lstat,e.exports.mkdir=o.mkdir,e.exports.readdir=o.readdir,e.exports.readlink=o.readlink,e.exports.rename=o.rename,e.exports.rmdir=o.rmdir,e.exports.stat=o.stat,e.exports.symlink=o.symlink,e.exports.unlink=o.unlink,e.exports.IS_WINDOWS="win32"===process.platform,e.exports.exists=function(t){return a(this,void 0,void 0,(function*(){try{yield e.exports.stat(t)}catch(e){if("ENOENT"===e.code)return!1;throw e}return!0}))},e.exports.isDirectory=function(t,r=!1){return a(this,void 0,void 0,(function*(){return(r?yield e.exports.stat(t):yield e.exports.lstat(t)).isDirectory()}))},e.exports.isRooted=t=>{if(!(t=(t=>(t=t||"",e.exports.IS_WINDOWS?(t=t.replace(/\//g,"\\")).replace(/\\\\+/g,"\\"):t.replace(/\/\/+/g,"/")))(t)))throw Error('isRooted() parameter "p" cannot be empty');return e.exports.IS_WINDOWS?t.startsWith("\\")||/^[A-Z]:/i.test(t):t.startsWith("/")},e.exports.tryGetExecutablePath=function(t,o){return a(this,void 0,void 0,(function*(){let s;try{s=yield e.exports.stat(t)}catch(e){"ENOENT"!==e.code&&console.log(`Unexpected error attempting to determine if executable file exists '${t}': ${e}`)}if(s&&s.isFile())if(e.exports.IS_WINDOWS){const e=c.extname(t).toUpperCase();if(o.some((t=>t.toUpperCase()===e)))return t}else if(r(s))return t;const n=t;for(const i of o){t=n+i,s=void 0;try{s=yield e.exports.stat(t)}catch(e){"ENOENT"!==e.code&&console.log(`Unexpected error attempting to determine if executable file exists '${t}': ${e}`)}if(s&&s.isFile()){if(e.exports.IS_WINDOWS){try{const r=c.dirname(t),o=c.basename(t).toUpperCase();for(const s of yield e.exports.readdir(r))if(o===s.toUpperCase()){t=c.join(r,s);break}}catch(e){console.log(`Unexpected error attempting to determine the actual case of the file '${t}': ${e}`)}return t}if(r(s))return t}}return""}))},e.exports.getCmdPath=()=>{var e;return null!==(e=process.env.COMSPEC)&&void 0!==e?e:"cmd.exe"}}));const Le=Ie(ge("fk1Ma"));let De;Ae.exec=s,Ae.getExecOutput=function(e,t,r){var o,n;return Ne(this,void 0,void 0,(function*(){let i="",a="";const l=new se.StringDecoder("utf8"),c=new se.StringDecoder("utf8"),u=null===(o=null==r?void 0:r.listeners)||void 0===o?void 0:o.stdout,p=null===(n=null==r?void 0:r.listeners)||void 0===n?void 0:n.stderr,d=Object.assign(Object.assign({},null==r?void 0:r.listeners),{stdout(e){i+=l.write(e),u&&u(e)},stderr(e){a+=c.write(e),p&&p(e)}}),h=yield s(e,t,Object.assign(Object.assign({},r),{listeners:d}));return i+=l.end(),a+=c.end(),{exitCode:h,stdout:i,stderr:a}}))};let je=!1;var ke,Me={},Fe={},Ue={};const Ve=(e={})=>{const t=e.env||process.env;return"win32"!==(e.platform||process.platform)?"PATH":Object.keys(t).reverse().find((e=>"PATH"===e.toUpperCase()))||"Path"};var qe,Ge;(Ue=Ve).default=Ve,ke=e=>a(e)||a(e,!0),Ge=e=>e.replace(/([()\][%!^"`<>&|;, *?])/g,"^$1"),qe=(e,t)=>(e=(e=`"${e=(e=(e=""+e).replace(/(\\*)"/g,'$1$1\\"')).replace(/(\\*)$/,"$1$1")}"`).replace(/([()\][%!^"`<>&|;, *?])/g,"^$1"),t&&(e=e.replace(/([()\][%!^"`<>&|;, *?])/g,"^$1")),e);var He,Be;He=(e="")=>{const t=e.match(/^#!(.*)/);if(!t)return null;const[r,o]=t[0].replace(/#! ?/,"").split(" "),s=r.split("/").pop();return"env"===s?o:o?`${s} ${o}`:s},Be=e=>{const t=Buffer.alloc(150);let r;try{r=re.openSync(e,"r"),re.readSync(r,t,0,150,0),re.closeSync(r)}catch(e){}return He(""+t)};const Xe="win32"===process.platform,Ye=/\.(?:com|exe)$/i,ze=/node_modules[\\/].bin[\\/][^\\/]+\.cmd$/i;Fe=(e,t,r)=>{t&&!Array.isArray(t)&&(r=t,t=null);const o={command:e,args:t=t?t.slice(0):[],options:r=Object.assign({},r),file:void 0,original:{command:e,args:t}};return r.shell?o:(e=>{if(!Xe)return e;const t=(e=>{e.file=ke(e);const t=e.file&&Be(e.file);return t?(e.args.unshift(e.file),e.command=t,ke(e)):e.file})(e),r=!Ye.test(t);if(e.options.forceShell||r){const r=ze.test(t);e.command=te.normalize(e.command),e.command=Ge(e.command),e.args=e.args.map((e=>qe(e,r)));const o=[e.command].concat(e.args).join(" ");e.args=["/d","/s","/c",`"${o}"`],e.command=process.env.comspec||"cmd.exe",e.options.windowsVerbatimArguments=!0}return e})(o)};var We={};const Ze="win32"===process.platform;We={hookChildProcess(e,t){if(!Ze)return;const r=e.emit;e.emit=function(o,s){if("exit"===o){const o=c(s,t);if(o)return r.call(e,"error",o)}return r.apply(e,arguments)}},verifyENOENT:c,verifyENOENTSync(e,t){return Ze&&1===e&&!t.file?l(t.original,"spawnSync"):null},notFoundError:l},(Me=u).spawn=u,Me.sync=(e,t,r)=>{const o=Fe(e,t,r),s=oe.spawnSync(o.command,o.args,o.options);return s.error=s.error||We.verifyENOENTSync(s.status,o),s},Me._parse=Fe,Me._enoent=We;let Je=!1;xe=ge("6FGZZ"),xe=ge("6FGZZ");let Ke,Qe=!1;var et={},tt=et&&et.__createBinding||(Object.create?(e,t,r,o)=>{void 0===o&&(o=r),Object.defineProperty(e,o,{enumerable:!0,get(){return t[r]}})}:(e,t,r,o)=>{void 0===o&&(o=r),e[o]=t[r]}),rt=et&&et.__setModuleDefault||(Object.create?(e,t)=>{Object.defineProperty(e,"default",{enumerable:!0,value:t})}:(e,t)=>{e.default=t}),ot=et&&et.__importStar||(e=>{if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)"default"!==r&&Object.hasOwnProperty.call(e,r)&&tt(t,e,r);return rt(t,e),t}),st=et&&et.__awaiter||((e,t,r,o)=>new(r||(r=Promise))(((s,n)=>{function i(e){try{l(o.next(e))}catch(e){n(e)}}function a(e){try{l(o.throw(e))}catch(e){n(e)}}function l(e){var t;e.done?s(e.value):(t=e.value,t instanceof r?t:new r((e=>{e(t)}))).then(i,a)}l((o=o.apply(e,t||[])).next())}))),nt=et&&et.__importDefault||(e=>e&&e.__esModule?e:{default:e});Object.defineProperty(et,"__esModule",{value:!0}),et.evaluateVersions=et.isExplicitVersion=et.findFromManifest=et.getManifestFromRepo=et.findAllVersions=et.find=et.cacheFile=et.cacheDir=et.extractZip=et.extractXar=et.extractTar=et.extract7z=et.downloadTool=et.HTTPError=void 0;const it=ot(ge("6FGZZ")),at=ot(ge("q05Mr")),lt=ot(re);ge.register("1Hds5",(function(e,t){"use strict";var r=e.exports&&e.exports.__createBinding||(Object.create?(e,t,r,o)=>{void 0===o&&(o=r),Object.defineProperty(e,o,{enumerable:!0,get(){return t[r]}})}:(e,t,r,o)=>{void 0===o&&(o=r),e[o]=t[r]}),o=e.exports&&e.exports.__setModuleDefault||(Object.create?(e,t)=>{Object.defineProperty(e,"default",{enumerable:!0,value:t})}:(e,t)=>{e.default=t}),s=e.exports&&e.exports.__importStar||(e=>{if(e&&e.__esModule)return e;var t={};if(null!=e)for(var s in e)"default"!==s&&Object.hasOwnProperty.call(e,s)&&r(t,e,s);return o(t,e),t}),n=e.exports&&e.exports.__awaiter||((e,t,r,o)=>new(r||(r=Promise))(((s,n)=>{function i(e){try{l(o.next(e))}catch(e){n(e)}}function a(e){try{l(o.throw(e))}catch(e){n(e)}}function l(e){var t;e.done?s(e.value):(t=e.value,t instanceof r?t:new r((e=>{e(t)}))).then(i,a)}l((o=o.apply(e,t||[])).next())})));Object.defineProperty(e.exports,"__esModule",{value:!0}),e.exports._readLinuxVersionFile=e.exports._getOsVersion=e.exports._findMatch=void 0;const i=s(ge("hBwzM"));var a=ge("6FGZZ");e.exports._findMatch=function(t,r,o,s){return n(this,void 0,void 0,(function*(){const n=ee.platform();let l,c,u;for(const l of o){const o=l.version;if(a.debug(`check ${o} satisfies ${t}`),i.satisfies(o,t)&&(!r||l.stable===r)&&(u=l.files.find((t=>{a.debug(`${t.arch}===${s} && ${t.platform}===${n}`);let r=t.arch===s&&t.platform===n;if(r&&t.platform_version){const o=e.exports._getOsVersion();r=o===t.platform_version||i.satisfies(o,t.platform_version)}return r})),u)){a.debug("matched "+l.version),c=l;break}}return c&&u&&(l=Object.assign({},c),l.files=[u]),l}))},e.exports._getOsVersion=()=>{const t=ee.platform();let r="";if("darwin"===t)r=""+oe.execSync("sw_vers -productVersion");else if("linux"===t){const t=e.exports._readLinuxVersionFile();if(t){const e=t.split("\n");for(const t of e){const e=t.split("=");if(2===e.length&&("VERSION_ID"===e[0].trim()||"DISTRIB_RELEASE"===e[0].trim())){r=e[1].trim().replace(/^"/,"").replace(/"$/,"");break}}}}return r},e.exports._readLinuxVersionFile=()=>{const e="/etc/lsb-release",t="/etc/os-release";let r="";return re.existsSync(e)?r=""+re.readFileSync(e):re.existsSync(t)&&(r=""+re.readFileSync(t)),r}})),ge.register("hBwzM",((e,t)=>{var r=ge("j1nFx");e.exports={re:r.re,src:r.src,tokens:r.t,SEMVER_SPEC_VERSION:ge("9PnyI").SEMVER_SPEC_VERSION,SemVer:ge("j4Bpm"),compareIdentifiers:ge("9vPNp").compareIdentifiers,rcompareIdentifiers:ge("9vPNp").rcompareIdentifiers,parse:ge("bd0kF"),valid:ge("1JJDJ"),clean:ge("6mLCu"),inc:ge("1Orzu"),diff:ge("kGDR5"),major:ge("k3zcS"),minor:ge("e8NKK"),patch:ge("3Fhst"),prerelease:ge("6elLy"),compare:ge("1wyqe"),rcompare:ge("las47"),compareLoose:ge("dQlWE"),compareBuild:ge("7REgF"),sort:ge("3U0ar"),rsort:ge("98o3F"),gt:ge("6bYo1"),lt:ge("98Pyg"),eq:ge("4eeum"),neq:ge("a0PPD"),gte:ge("kRrXd"),lte:ge("ju11K"),cmp:ge("cITzi"),coerce:ge("5M2Mq"),Comparator:ge("hDCF3"),Range:ge("8YuUE"),satisfies:ge("6rO9c"),toComparators:ge("fx4Sd"),maxSatisfying:ge("bMVW7"),minSatisfying:ge("g5aoW"),minVersion:ge("hO4RL"),validRange:ge("hXGf0"),outside:ge("2MRaB"),gtr:ge("bqGrY"),ltr:ge("3AeSM"),intersects:ge("2Lyoi"),simplifyRange:ge("5pzc6"),subset:ge("2XGoS")}})),ge.register("j1nFx",((e,t)=>{var r=ge("9PnyI").MAX_SAFE_COMPONENT_LENGTH,o=ge("8eni4");const s=(t=e.exports={}).re=[],n=t.src=[],i=t.t={};let a=0;const l=(e,t,r)=>{const l=a++;o(l,t),i[e]=l,n[l]=t,s[l]=RegExp(t,r?"g":void 0)};l("NUMERICIDENTIFIER","0|[1-9]\\d*"),l("NUMERICIDENTIFIERLOOSE","[0-9]+"),l("NONNUMERICIDENTIFIER","\\d*[a-zA-Z-][a-zA-Z0-9-]*"),l("MAINVERSION",`(${n[i.NUMERICIDENTIFIER]})\\.(${n[i.NUMERICIDENTIFIER]})\\.(${n[i.NUMERICIDENTIFIER]})`),l("MAINVERSIONLOOSE",`(${n[i.NUMERICIDENTIFIERLOOSE]})\\.(${n[i.NUMERICIDENTIFIERLOOSE]})\\.(${n[i.NUMERICIDENTIFIERLOOSE]})`),l("PRERELEASEIDENTIFIER",`(?:${n[i.NUMERICIDENTIFIER]}|${n[i.NONNUMERICIDENTIFIER]})`),l("PRERELEASEIDENTIFIERLOOSE",`(?:${n[i.NUMERICIDENTIFIERLOOSE]}|${n[i.NONNUMERICIDENTIFIER]})`),l("PRERELEASE",`(?:-(${n[i.PRERELEASEIDENTIFIER]}(?:\\.${n[i.PRERELEASEIDENTIFIER]})*))`),l("PRERELEASELOOSE",`(?:-?(${n[i.PRERELEASEIDENTIFIERLOOSE]}(?:\\.${n[i.PRERELEASEIDENTIFIERLOOSE]})*))`),l("BUILDIDENTIFIER","[0-9A-Za-z-]+"),l("BUILD",`(?:\\+(${n[i.BUILDIDENTIFIER]}(?:\\.${n[i.BUILDIDENTIFIER]})*))`),l("FULLPLAIN",`v?${n[i.MAINVERSION]}${n[i.PRERELEASE]}?${n[i.BUILD]}?`),l("FULL",`^${n[i.FULLPLAIN]}$`),l("LOOSEPLAIN",`[v=\\s]*${n[i.MAINVERSIONLOOSE]}${n[i.PRERELEASELOOSE]}?${n[i.BUILD]}?`),l("LOOSE",`^${n[i.LOOSEPLAIN]}$`),l("GTLT","((?:<|>)?=?)"),l("XRANGEIDENTIFIERLOOSE",n[i.NUMERICIDENTIFIERLOOSE]+"|x|X|\\*"),l("XRANGEIDENTIFIER",n[i.NUMERICIDENTIFIER]+"|x|X|\\*"),l("XRANGEPLAIN",`[v=\\s]*(${n[i.XRANGEIDENTIFIER]})(?:\\.(${n[i.XRANGEIDENTIFIER]})(?:\\.(${n[i.XRANGEIDENTIFIER]})(?:${n[i.PRERELEASE]})?${n[i.BUILD]}?)?)?`),l("XRANGEPLAINLOOSE",`[v=\\s]*(${n[i.XRANGEIDENTIFIERLOOSE]})(?:\\.(${n[i.XRANGEIDENTIFIERLOOSE]})(?:\\.(${n[i.XRANGEIDENTIFIERLOOSE]})(?:${n[i.PRERELEASELOOSE]})?${n[i.BUILD]}?)?)?`),l("XRANGE",`^${n[i.GTLT]}\\s*${n[i.XRANGEPLAIN]}$`),l("XRANGELOOSE",`^${n[i.GTLT]}\\s*${n[i.XRANGEPLAINLOOSE]}$`),l("COERCE",`(^|[^\\d])(\\d{1,${r}})(?:\\.(\\d{1,${r}}))?(?:\\.(\\d{1,${r}}))?(?:$|[^\\d])`),l("COERCERTL",n[i.COERCE],!0),l("LONETILDE","(?:~>?)"),l("TILDETRIM",`(\\s*)${n[i.LONETILDE]}\\s+`,!0),t.tildeTrimReplace="$1~",l("TILDE",`^${n[i.LONETILDE]}${n[i.XRANGEPLAIN]}$`),l("TILDELOOSE",`^${n[i.LONETILDE]}${n[i.XRANGEPLAINLOOSE]}$`),l("LONECARET","(?:\\^)"),l("CARETTRIM",`(\\s*)${n[i.LONECARET]}\\s+`,!0),t.caretTrimReplace="$1^",l("CARET",`^${n[i.LONECARET]}${n[i.XRANGEPLAIN]}$`),l("CARETLOOSE",`^${n[i.LONECARET]}${n[i.XRANGEPLAINLOOSE]}$`),l("COMPARATORLOOSE",`^${n[i.GTLT]}\\s*(${n[i.LOOSEPLAIN]})$|^$`),l("COMPARATOR",`^${n[i.GTLT]}\\s*(${n[i.FULLPLAIN]})$|^$`),l("COMPARATORTRIM",`(\\s*)${n[i.GTLT]}\\s*(${n[i.LOOSEPLAIN]}|${n[i.XRANGEPLAIN]})`,!0),t.comparatorTrimReplace="$1$2$3",l("HYPHENRANGE",`^\\s*(${n[i.XRANGEPLAIN]})\\s+-\\s+(${n[i.XRANGEPLAIN]})\\s*$`),l("HYPHENRANGELOOSE",`^\\s*(${n[i.XRANGEPLAINLOOSE]})\\s+-\\s+(${n[i.XRANGEPLAINLOOSE]})\\s*$`),l("STAR","(<|>)?=?\\s*\\*"),l("GTE0","^\\s*>=\\s*0.0.0\\s*$"),l("GTE0PRE","^\\s*>=\\s*0.0.0-0\\s*$")})),ge.register("9PnyI",((e,t)=>{e.exports={SEMVER_SPEC_VERSION:"2.0.0",MAX_LENGTH:256,MAX_SAFE_INTEGER:Number.MAX_SAFE_INTEGER||9007199254740991,MAX_SAFE_COMPONENT_LENGTH:16}})),ge.register("8eni4",((e,t)=>{const r=("object"==typeof process&&process,()=>{});e.exports=r})),ge.register("j4Bpm",(function(e,t){var r=ge("8eni4"),o=ge("9PnyI"),s=o.MAX_SAFE_INTEGER,n=o.MAX_LENGTH,i=ge("j1nFx"),a=i.t,l=i.re,c=ge("26eGk"),u=ge("9vPNp").compareIdentifiers;class p{constructor(e,t){if(t=c(t),e instanceof p){if(e.loose===!!t.loose&&e.includePrerelease===!!t.includePrerelease)return e;e=e.version}else if("string"!=typeof e)throw new TypeError("Invalid Version: "+e);if(e.length>n)throw new TypeError(`version is longer than ${n} characters`);r("SemVer",e,t),this.options=t,this.loose=!!t.loose,this.includePrerelease=!!t.includePrerelease;const o=e.trim().match(t.loose?l[a.LOOSE]:l[a.FULL]);if(!o)throw new TypeError("Invalid Version: "+e);if(this.raw=e,this.major=+o[1],this.minor=+o[2],this.patch=+o[3],this.major>s||0>this.major)throw new TypeError("Invalid major version");if(this.minor>s||0>this.minor)throw new TypeError("Invalid minor version");if(this.patch>s||0>this.patch)throw new TypeError("Invalid patch version");this.prerelease=o[4]?o[4].split(".").map((e=>{if(/^[0-9]+$/.test(e)){const t=+e;if(t>=0&&s>t)return t}return e})):[],this.build=o[5]?o[5].split("."):[],this.format()}format(){return this.version=`${this.major}.${this.minor}.${this.patch}`,this.prerelease.length&&(this.version+="-"+this.prerelease.join(".")),this.version}toString(){return this.version}compare(e){if(r("SemVer.compare",this.version,this.options,e),!(e instanceof p)){if("string"==typeof e&&e===this.version)return 0;e=new p(e,this.options)}return e.version===this.version?0:this.compareMain(e)||this.comparePre(e)}compareMain(e){return e instanceof p||(e=new p(e,this.options)),u(this.major,e.major)||u(this.minor,e.minor)||u(this.patch,e.patch)}comparePre(e){if(e instanceof p||(e=new p(e,this.options)),this.prerelease.length&&!e.prerelease.length)return-1;if(!this.prerelease.length&&e.prerelease.length)return 1;if(!this.prerelease.length&&!e.prerelease.length)return 0;let t=0;do{const o=this.prerelease[t],s=e.prerelease[t];if(r("prerelease compare",t,o,s),void 0===o&&void 0===s)return 0;if(void 0===s)return 1;if(void 0===o)return-1;if(o!==s)return u(o,s)}while(++t)}compareBuild(e){e instanceof p||(e=new p(e,this.options));let t=0;do{const o=this.build[t],s=e.build[t];if(r("prerelease compare",t,o,s),void 0===o&&void 0===s)return 0;if(void 0===s)return 1;if(void 0===o)return-1;if(o!==s)return u(o,s)}while(++t)}inc(e,t){switch(e){case"premajor":this.prerelease.length=0,this.patch=0,this.minor=0,this.major++,this.inc("pre",t);break;case"preminor":this.prerelease.length=0,this.patch=0,this.minor++,this.inc("pre",t);break;case"prepatch":this.prerelease.length=0,this.inc("patch",t),this.inc("pre",t);break;case"prerelease":0===this.prerelease.length&&this.inc("patch",t),this.inc("pre",t);break;case"major":0===this.minor&&0===this.patch&&0!==this.prerelease.length||this.major++,this.minor=0,this.patch=0,this.prerelease=[];break;case"minor":0===this.patch&&0!==this.prerelease.length||this.minor++,this.patch=0,this.prerelease=[];break;case"patch":0===this.prerelease.length&&this.patch++,this.prerelease=[];break;case"pre":if(0===this.prerelease.length)this.prerelease=[0];else{let e=this.prerelease.length;for(;--e>=0;)"number"==typeof this.prerelease[e]&&(this.prerelease[e]++,e=-2);-1===e&&this.prerelease.push(0)}t&&(this.prerelease[0]===t?isNaN(this.prerelease[1])&&(this.prerelease=[t,0]):this.prerelease=[t,0]);break;default:throw Error("invalid increment argument: "+e)}return this.format(),this.raw=this.version,this}}e.exports=p})),ge.register("26eGk",((e,t)=>{const r=["includePrerelease","loose","rtl"];e.exports=e=>e?"object"!=typeof e?{loose:!0}:r.filter((t=>e[t])).reduce(((e,t)=>(e[t]=!0,e)),{}):{}})),ge.register("9vPNp",((e,t)=>{const r=/^[0-9]+$/,o=(e,t)=>{const o=r.test(e),s=r.test(t);return o&&s&&(e=+e,t=+t),e===t?0:o&&!s?-1:s&&!o?1:t>e?-1:1};e.exports={compareIdentifiers:o,rcompareIdentifiers(e,t){return o(t,e)}}})),ge.register("bd0kF",((e,t)=>{var r=ge("9PnyI").MAX_LENGTH,o=ge("j1nFx"),s=o.t,n=o.re,i=ge("j4Bpm"),a=ge("26eGk");e.exports=(e,t)=>{if(t=a(t),e instanceof i)return e;if("string"!=typeof e)return null;if(e.length>r)return null;if(!(t.loose?n[s.LOOSE]:n[s.FULL]).test(e))return null;try{return new i(e,t)}catch(e){return null}}})),ge.register("1JJDJ",((e,t)=>{var r=ge("bd0kF");e.exports=(e,t)=>{const o=r(e,t);return o?o.version:null}})),ge.register("6mLCu",((e,t)=>{var r=ge("bd0kF");e.exports=(e,t)=>{const o=r(e.trim().replace(/^[=v]+/,""),t);return o?o.version:null}})),ge.register("1Orzu",((e,t)=>{var r=ge("j4Bpm");e.exports=(e,t,o,s)=>{"string"==typeof o&&(s=o,o=void 0);try{return new r(e,o).inc(t,s).version}catch(e){return null}}})),ge.register("kGDR5",((e,t)=>{var r=ge("bd0kF"),o=ge("4eeum");e.exports=(e,t)=>{if(o(e,t))return null;{const o=r(e),s=r(t),n=o.prerelease.length||s.prerelease.length,i=n?"pre":"",a=n?"prerelease":"";for(const e in o)if(("major"===e||"minor"===e||"patch"===e)&&o[e]!==s[e])return i+e;return a}}})),ge.register("4eeum",((e,t)=>{var r=ge("1wyqe");e.exports=(e,t,o)=>0===r(e,t,o)})),ge.register("1wyqe",((e,t)=>{var r=ge("j4Bpm");e.exports=(e,t,o)=>new r(e,o).compare(new r(t,o))})),ge.register("k3zcS",((e,t)=>{var r=ge("j4Bpm");e.exports=(e,t)=>new r(e,t).major})),ge.register("e8NKK",((e,t)=>{var r=ge("j4Bpm");e.exports=(e,t)=>new r(e,t).minor})),ge.register("3Fhst",((e,t)=>{var r=ge("j4Bpm");e.exports=(e,t)=>new r(e,t).patch})),ge.register("6elLy",((e,t)=>{var r=ge("bd0kF");e.exports=(e,t)=>{const o=r(e,t);return o&&o.prerelease.length?o.prerelease:null}})),ge.register("las47",((e,t)=>{var r=ge("1wyqe");e.exports=(e,t,o)=>r(t,e,o)})),ge.register("dQlWE",((e,t)=>{var r=ge("1wyqe");e.exports=(e,t)=>r(e,t,!0)})),ge.register("7REgF",((e,t)=>{var r=ge("j4Bpm");e.exports=(e,t,o)=>{const s=new r(e,o),n=new r(t,o);return s.compare(n)||s.compareBuild(n)}})),ge.register("3U0ar",((e,t)=>{var r=ge("7REgF");e.exports=(e,t)=>e.sort(((e,o)=>r(e,o,t)))})),ge.register("98o3F",((e,t)=>{var r=ge("7REgF");e.exports=(e,t)=>e.sort(((e,o)=>r(o,e,t)))})),ge.register("6bYo1",((e,t)=>{var r=ge("1wyqe");e.exports=(e,t,o)=>r(e,t,o)>0})),ge.register("98Pyg",((e,t)=>{var r=ge("1wyqe");e.exports=(e,t,o)=>0>r(e,t,o)})),ge.register("a0PPD",((e,t)=>{var r=ge("1wyqe");e.exports=(e,t,o)=>0!==r(e,t,o)})),ge.register("kRrXd",((e,t)=>{var r=ge("1wyqe");e.exports=(e,t,o)=>r(e,t,o)>=0})),ge.register("ju11K",((e,t)=>{var r=ge("1wyqe");e.exports=(e,t,o)=>0>=r(e,t,o)})),ge.register("cITzi",((e,t)=>{var r=ge("4eeum"),o=ge("a0PPD"),s=ge("6bYo1"),n=ge("kRrXd"),i=ge("98Pyg"),a=ge("ju11K");e.exports=(e,t,l,c)=>{switch(t){case"===":return"object"==typeof e&&(e=e.version),"object"==typeof l&&(l=l.version),e===l;case"!==":return"object"==typeof e&&(e=e.version),"object"==typeof l&&(l=l.version),e!==l;case"":case"=":case"==":return r(e,l,c);case"!=":return o(e,l,c);case">":return s(e,l,c);case">=":return n(e,l,c);case"<":return i(e,l,c);case"<=":return a(e,l,c);default:throw new TypeError("Invalid operator: "+t)}}})),ge.register("5M2Mq",((e,t)=>{var r=ge("j4Bpm"),o=ge("bd0kF"),s=ge("j1nFx"),n=s.t,i=s.re;e.exports=(e,t)=>{if(e instanceof r)return e;if("number"==typeof e&&(e+=""),"string"!=typeof e)return null;let s=null;if((t=t||{}).rtl){let t;for(;(t=i[n.COERCERTL].exec(e))&&(!s||s.index+s[0].length!==e.length);)s&&t.index+t[0].length===s.index+s[0].length||(s=t),i[n.COERCERTL].lastIndex=t.index+t[1].length+t[2].length;i[n.COERCERTL].lastIndex=-1}else s=e.match(i[n.COERCE]);return null===s?null:o(`${s[2]}.${s[3]||"0"}.${s[4]||"0"}`,t)}})),ge.register("hDCF3",(function(e,t){const r=Symbol();class o{static get ANY(){return r}constructor(e,t){if(t=s(t),e instanceof o){if(e.loose===!!t.loose)return e;e=e.value}c("comparator",e,t),this.options=t,this.loose=!!t.loose,this.parse(e),this.value=this.semver===r?"":this.operator+this.semver.version,c("comp",this)}parse(e){const t=e.match(this.options.loose?a[i.COMPARATORLOOSE]:a[i.COMPARATOR]);if(!t)throw new TypeError("Invalid comparator: "+e);this.operator=void 0!==t[1]?t[1]:"","="===this.operator&&(this.operator=""),this.semver=t[2]?new u(t[2],this.options.loose):r}toString(){return this.value}test(e){if(c("Comparator.test",e,this.options.loose),this.semver===r||e===r)return!0;if("string"==typeof e)try{e=new u(e,this.options)}catch(e){return!1}return l(e,this.operator,this.semver,this.options)}intersects(e,t){if(!(e instanceof o))throw new TypeError("a Comparator is required");if(t&&"object"==typeof t||(t={loose:!!t,includePrerelease:!1}),""===this.operator)return""===this.value||new p(e.value,t).test(this.value);if(""===e.operator)return""===e.value||new p(this.value,t).test(e.semver);const r=!(">="!==this.operator&&">"!==this.operator||">="!==e.operator&&">"!==e.operator),s=!("<="!==this.operator&&"<"!==this.operator||"<="!==e.operator&&"<"!==e.operator),n=this.semver.version===e.semver.version,i=!(">="!==this.operator&&"<="!==this.operator||">="!==e.operator&&"<="!==e.operator),a=l(this.semver,"<",e.semver,t)&&(">="===this.operator||">"===this.operator)&&("<="===e.operator||"<"===e.operator),c=l(this.semver,">",e.semver,t)&&("<="===this.operator||"<"===this.operator)&&(">="===e.operator||">"===e.operator);return r||s||n&&i||a||c}}e.exports=o;var s=ge("26eGk"),n=ge("j1nFx"),i=n.t,a=n.re,l=ge("cITzi"),c=ge("8eni4"),u=ge("j4Bpm"),p=ge("8YuUE")})),ge.register("8YuUE",(function(e,t){class r{constructor(e,t){if(t=s(t),e instanceof r)return e.loose===!!t.loose&&e.includePrerelease===!!t.includePrerelease?e:new r(e.raw,t);if(e instanceof n)return this.raw=e.value,this.set=[[e]],this.format(),this;if(this.options=t,this.loose=!!t.loose,this.includePrerelease=!!t.includePrerelease,this.raw=e,this.set=e.split(/\s*\|\|\s*/).map((e=>this.parseRange(e.trim()))).filter((e=>e.length)),!this.set.length)throw new TypeError("Invalid SemVer Range: "+e);if(this.set.length>1){const e=this.set[0];if(this.set=this.set.filter((e=>!f(e[0]))),0===this.set.length)this.set=[e];else if(this.set.length>1)for(const e of this.set)if(1===e.length&&m(e[0])){this.set=[e];break}}this.format()}format(){return this.range=this.set.map((e=>e.join(" ").trim())).join("||").trim(),this.range}toString(){return this.range}parseRange(e){e=e.trim();const t=`parseRange:${Object.keys(this.options).join(",")}:${e}`,r=o.get(t);if(r)return r;const s=this.options.loose;e=e.replace(s?d[u.HYPHENRANGELOOSE]:d[u.HYPHENRANGE],_(this.options.includePrerelease)),i("hyphen replace",e),e=e.replace(d[u.COMPARATORTRIM],p),i("comparator trim",e,d[u.COMPARATORTRIM]),e=(e=(e=e.replace(d[u.TILDETRIM],h)).replace(d[u.CARETTRIM],c)).split(/\s+/).join(" ");const a=s?d[u.COMPARATORLOOSE]:d[u.COMPARATOR],l=e.split(" ").map((e=>y(e,this.options))).join(" ").split(/\s+/).map((e=>S(e,this.options))).filter(this.options.loose?e=>!!e.match(a):()=>!0).map((e=>new n(e,this.options))),m=new Map;for(const e of l){if(f(e))return[e];m.set(e.value,e)}m.size>1&&m.has("")&&m.delete("");const v=[...m.values()];return o.set(t,v),v}intersects(e,t){if(!(e instanceof r))throw new TypeError("a Range is required");return this.set.some((r=>v(r,t)&&e.set.some((e=>v(e,t)&&r.every((r=>e.every((e=>r.intersects(e,t)))))))))}test(e){if(!e)return!1;if("string"==typeof e)try{e=new a(e,this.options)}catch(e){return!1}for(let t=0;this.set.length>t;t++)if(R(this.set[t],e,this.options))return!0;return!1}}e.exports=r;const o=new(ge("hqS6J"))({max:1e3});var s=ge("26eGk"),n=ge("hDCF3"),i=ge("8eni4"),a=ge("j4Bpm"),l=ge("j1nFx"),c=l.caretTrimReplace,u=l.t,p=l.comparatorTrimReplace,d=l.re,h=l.tildeTrimReplace;const f=e=>"<0.0.0-0"===e.value,m=e=>""===e.value,v=(e,t)=>{let r=!0;const o=e.slice();let s=o.pop();for(;r&&o.length;)r=o.every((e=>s.intersects(e,t))),s=o.pop();return r},y=(e,t)=>(i("comp",e,t),e=E(e,t),i("caret",e),e=x(e,t),i("tildes",e),e=P(e,t),i("xrange",e),e=$(e,t),i("stars",e),e),g=e=>!e||"x"===e.toLowerCase()||"*"===e,x=(e,t)=>e.trim().split(/\s+/).map((e=>w(e,t))).join(" "),w=(e,t)=>e.replace(t.loose?d[u.TILDELOOSE]:d[u.TILDE],((t,r,o,s,n)=>{let a;return i("tilde",e,t,r,o,s,n),g(r)?a="":g(o)?a=`>=${r}.0.0 <${+r+1}.0.0-0`:g(s)?a=`>=${r}.${o}.0 <${r}.${+o+1}.0-0`:n?(i("replaceTilde pr",n),a=`>=${r}.${o}.${s}-${n} <${r}.${+o+1}.0-0`):a=`>=${r}.${o}.${s} <${r}.${+o+1}.0-0`,i("tilde return",a),a})),E=(e,t)=>e.trim().split(/\s+/).map((e=>b(e,t))).join(" "),b=(e,t)=>{i("caret",e,t);const r=t.includePrerelease?"-0":"";return e.replace(t.loose?d[u.CARETLOOSE]:d[u.CARET],((t,o,s,n,a)=>{let l;return i("caret",e,t,o,s,n,a),g(o)?l="":g(s)?l=`>=${o}.0.0${r} <${+o+1}.0.0-0`:g(n)?l="0"===o?`>=${o}.${s}.0${r} <${o}.${+s+1}.0-0`:`>=${o}.${s}.0${r} <${+o+1}.0.0-0`:a?(i("replaceCaret pr",a),l="0"===o?"0"===s?`>=${o}.${s}.${n}-${a} <${o}.${s}.${+n+1}-0`:`>=${o}.${s}.${n}-${a} <${o}.${+s+1}.0-0`:`>=${o}.${s}.${n}-${a} <${+o+1}.0.0-0`):(i("no pr"),l="0"===o?"0"===s?`>=${o}.${s}.${n}${r} <${o}.${s}.${+n+1}-0`:`>=${o}.${s}.${n}${r} <${o}.${+s+1}.0-0`:`>=${o}.${s}.${n} <${+o+1}.0.0-0`),i("caret return",l),l}))},P=(e,t)=>(i("replaceXRanges",e,t),e.split(/\s+/).map((e=>O(e,t))).join(" ")),O=(e,t)=>(e=e.trim()).replace(t.loose?d[u.XRANGELOOSE]:d[u.XRANGE],((r,o,s,n,a,l)=>{i("xRange",e,r,o,s,n,a,l);const c=g(s),u=c||g(n),p=u||g(a);return"="===o&&p&&(o=""),l=t.includePrerelease?"-0":"",c?r=">"===o||"<"===o?"<0.0.0-0":"*":o&&p?(u&&(n=0),a=0,">"===o?(o=">=",u?(s=+s+1,n=0,a=0):(n=+n+1,a=0)):"<="===o&&(o="<",u?s=+s+1:n=+n+1),"<"===o&&(l="-0"),r=`${o+s}.${n}.${a}${l}`):u?r=`>=${s}.0.0${l} <${+s+1}.0.0-0`:p&&(r=`>=${s}.${n}.0${l} <${s}.${+n+1}.0-0`),i("xRange return",r),r})),$=(e,t)=>(i("replaceStars",e,t),e.trim().replace(d[u.STAR],"")),S=(e,t)=>(i("replaceGTE0",e,t),e.trim().replace(d[t.includePrerelease?u.GTE0PRE:u.GTE0],"")),_=e=>(t,r,o,s,n,i,a,l,c,u,p,d,h)=>`${r=g(o)?"":g(s)?`>=${o}.0.0${e?"-0":""}`:g(n)?`>=${o}.${s}.0${e?"-0":""}`:i?">="+r:`>=${r}${e?"-0":""}`} ${l=g(c)?"":g(u)?`<${+c+1}.0.0-0`:g(p)?`<${c}.${+u+1}.0-0`:d?`<=${c}.${u}.${p}-${d}`:e?`<${c}.${u}.${+p+1}-0`:"<="+l}`.trim(),R=(e,t,r)=>{for(let r=0;e.length>r;r++)if(!e[r].test(t))return!1;if(t.prerelease.length&&!r.includePrerelease){for(let r=0;e.length>r;r++)if(i(e[r].semver),e[r].semver!==n.ANY&&e[r].semver.prerelease.length>0){const o=e[r].semver;if(o.major===t.major&&o.minor===t.minor&&o.patch===t.patch)return!0}return!1}return!0}})),ge.register("hqS6J",(function(e,t){"use strict";var r=ge("9ShIP");const o=Symbol(),s=Symbol(),n=Symbol(),i=Symbol(),a=Symbol(),l=Symbol(),c=Symbol(),u=Symbol(),p=Symbol(),d=Symbol(),h=()=>1,f=(e,t,r)=>{const o=e[p].get(t);if(o){const t=o.value;if(m(e,t)){if(y(e,o),!e[i])return}else r&&(e[d]&&(o.value.now=Date.now()),e[u].unshiftNode(o));return t.value}},m=(e,t)=>{if(!t||!t.maxAge&&!e[a])return!1;const r=Date.now()-t.now;return t.maxAge?r>t.maxAge:e[a]&&r>e[a]},v=e=>{if(e[s]>e[o])for(let t=e[u].tail;e[s]>e[o]&&null!==t;){const r=t.prev;y(e,t),t=r}},y=(e,t)=>{if(t){const r=t.value;e[l]&&e[l](r.key,r.value),e[s]-=r.length,e[p].delete(r.key),e[u].removeNode(t)}};class g{constructor(e,t,r,o,s){this.key=e,this.value=t,this.length=r,this.now=o,this.maxAge=s||0}}const x=(e,t,r,o)=>{let s=r.value;m(e,s)&&(y(e,r),e[i]||(s=void 0)),s&&t.call(o,s.value,s.key,e)};e.exports=class{constructor(e){if("number"==typeof e&&(e={max:e}),e||(e={}),e.max&&("number"!=typeof e.max||0>e.max))throw new TypeError("max must be a non-negative number");this[o]=e.max||1/0;const t=e.length||h;if(this[n]="function"!=typeof t?h:t,this[i]=e.stale||!1,e.maxAge&&"number"!=typeof e.maxAge)throw new TypeError("maxAge must be a number");this[a]=e.maxAge||0,this[l]=e.dispose,this[c]=e.noDisposeOnSet||!1,this[d]=e.updateAgeOnGet||!1,this.reset()}set max(e){if("number"!=typeof e||0>e)throw new TypeError("max must be a non-negative number");this[o]=e||1/0,v(this)}get max(){return this[o]}set allowStale(e){this[i]=!!e}get allowStale(){return this[i]}set maxAge(e){if("number"!=typeof e)throw new TypeError("maxAge must be a non-negative number");this[a]=e,v(this)}get maxAge(){return this[a]}set lengthCalculator(e){"function"!=typeof e&&(e=h),e!==this[n]&&(this[n]=e,this[s]=0,this[u].forEach((e=>{e.length=this[n](e.value,e.key),this[s]+=e.length}))),v(this)}get lengthCalculator(){return this[n]}get length(){return this[s]}get itemCount(){return this[u].length}rforEach(e,t){t=t||this;for(let r=this[u].tail;null!==r;){const o=r.prev;x(this,e,r,t),r=o}}forEach(e,t){t=t||this;for(let r=this[u].head;null!==r;){const o=r.next;x(this,e,r,t),r=o}}keys(){return this[u].toArray().map((e=>e.key))}values(){return this[u].toArray().map((e=>e.value))}reset(){this[l]&&this[u]&&this[u].length&&this[u].forEach((e=>this[l](e.key,e.value))),this[p]=new Map,this[u]=new r,this[s]=0}dump(){return this[u].map((e=>!m(this,e)&&{k:e.key,v:e.value,e:e.now+(e.maxAge||0)})).toArray().filter((e=>e))}dumpLru(){return this[u]}set(e,t,r){if((r=r||this[a])&&"number"!=typeof r)throw new TypeError("maxAge must be a number");const i=r?Date.now():0,d=this[n](t,e);if(this[p].has(e)){if(d>this[o])return y(this,this[p].get(e)),!1;const n=this[p].get(e).value;return this[l]&&(this[c]||this[l](e,n.value)),n.now=i,n.maxAge=r,n.value=t,this[s]+=d-n.length,n.length=d,this.get(e),v(this),!0}const h=new g(e,t,d,i,r);return h.length>this[o]?(this[l]&&this[l](e,t),!1):(this[s]+=h.length,this[u].unshift(h),this[p].set(e,this[u].head),v(this),!0)}has(e){if(!this[p].has(e))return!1;const t=this[p].get(e).value;return!m(this,t)}get(e){return f(this,e,!0)}peek(e){return f(this,e,!1)}pop(){const e=this[u].tail;return e?(y(this,e),e.value):null}del(e){y(this,this[p].get(e))}load(e){this.reset();const t=Date.now();for(let r=e.length-1;r>=0;r--){const o=e[r],s=o.e||0;if(0===s)this.set(o.k,o.v);else{const e=s-t;e>0&&this.set(o.k,o.v,e)}}}prune(){this[p].forEach(((e,t)=>f(this,t,!1)))}}})),ge.register("9ShIP",(function(e,t){"use strict";function r(e){var t=this;if(t instanceof r||(t=new r),t.tail=null,t.head=null,t.length=0,e&&"function"==typeof e.forEach)e.forEach((e=>{t.push(e)}));else if(arguments.length>0)for(var o=0,s=arguments.length;s>o;o++)t.push(arguments[o]);return t}function o(e,t,r){var o=t===e.head?new i(r,null,t,e):new i(r,t,t.next,e);return null===o.next&&(e.tail=o),null===o.prev&&(e.head=o),e.length++,o}function s(e,t){e.tail=new i(t,e.tail,null,e),e.head||(e.head=e.tail),e.length++}function n(e,t){e.head=new i(t,null,e.head,e),e.tail||(e.tail=e.head),e.length++}function i(e,t,r,o){if(!(this instanceof i))return new i(e,t,r,o);this.list=o,this.value=e,t?(t.next=this,this.prev=t):this.prev=null,r?(r.prev=this,this.next=r):this.next=null}e.exports=r,r.Node=i,r.create=r,r.prototype.removeNode=function(e){if(e.list!==this)throw Error("removing node which does not belong to this list");var t=e.next,r=e.prev;return t&&(t.prev=r),r&&(r.next=t),e===this.head&&(this.head=t),e===this.tail&&(this.tail=r),e.list.length--,e.next=null,e.prev=null,e.list=null,t},r.prototype.unshiftNode=function(e){if(e!==this.head){e.list&&e.list.removeNode(e);var t=this.head;e.list=this,e.next=t,t&&(t.prev=e),this.head=e,this.tail||(this.tail=e),this.length++}},r.prototype.pushNode=function(e){if(e!==this.tail){e.list&&e.list.removeNode(e);var t=this.tail;e.list=this,e.prev=t,t&&(t.next=e),this.tail=e,this.head||(this.head=e),this.length++}},r.prototype.push=function(){for(var e=0,t=arguments.length;t>e;e++)s(this,arguments[e]);return this.length},r.prototype.unshift=function(){for(var e=0,t=arguments.length;t>e;e++)n(this,arguments[e]);return this.length},r.prototype.pop=function(){if(this.tail){var e=this.tail.value;return this.tail=this.tail.prev,this.tail?this.tail.next=null:this.head=null,this.length--,e}},r.prototype.shift=function(){if(this.head){var e=this.head.value;return this.head=this.head.next,this.head?this.head.prev=null:this.tail=null,this.length--,e}},r.prototype.forEach=function(e,t){t=t||this;for(var r=this.head,o=0;null!==r;o++)e.call(t,r.value,o,this),r=r.next},r.prototype.forEachReverse=function(e,t){t=t||this;for(var r=this.tail,o=this.length-1;null!==r;o--)e.call(t,r.value,o,this),r=r.prev},r.prototype.get=function(e){for(var t=0,r=this.head;null!==r&&e>t;t++)r=r.next;if(t===e&&null!==r)return r.value},r.prototype.getReverse=function(e){for(var t=0,r=this.tail;null!==r&&e>t;t++)r=r.prev;if(t===e&&null!==r)return r.value},r.prototype.map=function(e,t){t=t||this;for(var o=new r,s=this.head;null!==s;)o.push(e.call(t,s.value,this)),s=s.next;return o},r.prototype.mapReverse=function(e,t){t=t||this;for(var o=new r,s=this.tail;null!==s;)o.push(e.call(t,s.value,this)),s=s.prev;return o},r.prototype.reduce=function(e,t){var r,o=this.head;if(arguments.length>1)r=t;else{if(!this.head)throw new TypeError("Reduce of empty list with no initial value");o=this.head.next,r=this.head.value}for(var s=0;null!==o;s++)r=e(r,o.value,s),o=o.next;return r},r.prototype.reduceReverse=function(e,t){var r,o=this.tail;if(arguments.length>1)r=t;else{if(!this.tail)throw new TypeError("Reduce of empty list with no initial value");o=this.tail.prev,r=this.tail.value}for(var s=this.length-1;null!==o;s--)r=e(r,o.value,s),o=o.prev;return r},r.prototype.toArray=function(){for(var e=Array(this.length),t=0,r=this.head;null!==r;t++)e[t]=r.value,r=r.next;return e},r.prototype.toArrayReverse=function(){for(var e=Array(this.length),t=0,r=this.tail;null!==r;t++)e[t]=r.value,r=r.prev;return e},r.prototype.slice=function(e,t){0>(t=t||this.length)&&(t+=this.length),0>(e=e||0)&&(e+=this.length);var o=new r;if(e>t||0>t)return o;0>e&&(e=0),t>this.length&&(t=this.length);for(var s=0,n=this.head;null!==n&&e>s;s++)n=n.next;for(;null!==n&&t>s;s++,n=n.next)o.push(n.value);return o},r.prototype.sliceReverse=function(e,t){0>(t=t||this.length)&&(t+=this.length),0>(e=e||0)&&(e+=this.length);var o=new r;if(e>t||0>t)return o;0>e&&(e=0),t>this.length&&(t=this.length);for(var s=this.length,n=this.tail;null!==n&&s>t;s--)n=n.prev;for(;null!==n&&s>e;s--,n=n.prev)o.push(n.value);return o},r.prototype.splice=function(e,t,...r){e>this.length&&(e=this.length-1),0>e&&(e=this.length+e);for(var s=0,n=this.head;null!==n&&e>s;s++)n=n.next;var i=[];for(s=0;n&&t>s;s++)i.push(n.value),n=this.removeNode(n);for(null===n&&(n=this.tail),n!==this.head&&n!==this.tail&&(n=n.prev),s=0;r.length>s;s++)n=o(this,n,r[s]);return i},r.prototype.reverse=function(){for(var e=this.head,t=this.tail,r=e;null!==r;r=r.prev){var o=r.prev;r.prev=r.next,r.next=o}return this.head=t,this.tail=e,this};try{ge("bdwRA")(r)}catch(e){}})),ge.register("bdwRA",(function(e,t){"use strict";e.exports=function(e){e.prototype[Symbol.iterator]=function*(){for(let e=this.head;e;e=e.next)yield e.value}}})),ge.register("6rO9c",((e,t)=>{var r=ge("8YuUE");e.exports=(e,t,o)=>{try{t=new r(t,o)}catch(e){return!1}return t.test(e)}})),ge.register("fx4Sd",((e,t)=>{var r=ge("8YuUE");e.exports=(e,t)=>new r(e,t).set.map((e=>e.map((e=>e.value)).join(" ").trim().split(" ")))})),ge.register("bMVW7",((e,t)=>{var r=ge("j4Bpm"),o=ge("8YuUE");e.exports=(e,t,s)=>{let n=null,i=null,a=null;try{a=new o(t,s)}catch(e){return null}return e.forEach((e=>{a.test(e)&&(n&&-1!==i.compare(e)||(n=e,i=new r(n,s)))})),n}})),ge.register("g5aoW",((e,t)=>{var r=ge("j4Bpm"),o=ge("8YuUE");e.exports=(e,t,s)=>{let n=null,i=null,a=null;try{a=new o(t,s)}catch(e){return null}return e.forEach((e=>{a.test(e)&&(n&&1!==i.compare(e)||(n=e,i=new r(n,s)))})),n}})),ge.register("hO4RL",((e,t)=>{var r=ge("j4Bpm"),o=ge("8YuUE"),s=ge("6bYo1");e.exports=(e,t)=>{e=new o(e,t);let n=new r("0.0.0");if(e.test(n))return n;if(n=new r("0.0.0-0"),e.test(n))return n;n=null;for(let t=0;e.set.length>t;++t){let o=null;e.set[t].forEach((e=>{const t=new r(e.semver.version);switch(e.operator){case">":0===t.prerelease.length?t.patch++:t.prerelease.push(0),t.raw=t.format();case"":case">=":o&&!s(t,o)||(o=t);break;case"<":case"<=":break;default:throw Error("Unexpected operation: "+e.operator)}})),!o||n&&!s(n,o)||(n=o)}return n&&e.test(n)?n:null}})),ge.register("hXGf0",((e,t)=>{var r=ge("8YuUE");e.exports=(e,t)=>{try{return new r(e,t).range||"*"}catch(e){return null}}})),ge.register("2MRaB",((e,t)=>{var r=ge("j4Bpm"),o=ge("hDCF3");const{ANY:s}=o;var n=ge("8YuUE"),i=ge("6rO9c"),a=ge("6bYo1"),l=ge("98Pyg"),c=ge("ju11K"),u=ge("kRrXd");e.exports=(e,t,p,d)=>{let h,f,m,v,y;switch(e=new r(e,d),t=new n(t,d),p){case">":h=a,f=c,m=l,v=">",y=">=";break;case"<":h=l,f=u,m=a,v="<",y="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(i(e,t,d))return!1;for(let r=0;t.set.length>r;++r){let n=null,i=null;if(t.set[r].forEach((e=>{e.semver===s&&(e=new o(">=0.0.0")),n=n||e,i=i||e,h(e.semver,n.semver,d)?n=e:m(e.semver,i.semver,d)&&(i=e)})),n.operator===v||n.operator===y)return!1;if((!i.operator||i.operator===v)&&f(e,i.semver))return!1;if(i.operator===y&&m(e,i.semver))return!1}return!0}})),ge.register("bqGrY",((e,t)=>{var r=ge("2MRaB");e.exports=(e,t,o)=>r(e,t,">",o)})),ge.register("3AeSM",((e,t)=>{var r=ge("2MRaB");e.exports=(e,t,o)=>r(e,t,"<",o)})),ge.register("2Lyoi",((e,t)=>{var r=ge("8YuUE");e.exports=(e,t,o)=>(e=new r(e,o),t=new r(t,o),e.intersects(t))})),ge.register("5pzc6",((e,t)=>{var r=ge("6rO9c"),o=ge("1wyqe");e.exports=(e,t,s)=>{const n=[];let i=null,a=null;const l=e.sort(((e,t)=>o(e,t,s)));for(const e of l)r(e,t,s)?(a=e,i||(i=e)):(a&&n.push([i,a]),a=null,i=null);i&&n.push([i,null]);const c=[];for(const[e,t]of n)c.push(e===t?e:t||e!==l[0]?t?e===l[0]?"<="+t:`${e} - ${t}`:">="+e:"*");const u=c.join(" || ");return("string"==typeof t.raw?t.raw:t+"").length>u.length?u:t}})),ge.register("2XGoS",((e,t)=>{var r=ge("8YuUE"),o=ge("hDCF3");const{ANY:s}=o;var n=ge("6rO9c"),i=ge("1wyqe");const a=(e,t,r)=>{if(e===t)return!0;if(1===e.length&&e[0].semver===s){if(1===t.length&&t[0].semver===s)return!0;e=r.includePrerelease?[new o(">=0.0.0-0")]:[new o(">=0.0.0")]}if(1===t.length&&t[0].semver===s){if(r.includePrerelease)return!0;t=[new o(">=0.0.0")]}const a=new Set;let u,p,d,h,f,m,v;for(const t of e)">"===t.operator||">="===t.operator?u=l(u,t,r):"<"===t.operator||"<="===t.operator?p=c(p,t,r):a.add(t.semver);if(a.size>1)return null;if(u&&p){if(d=i(u.semver,p.semver,r),d>0)return null;if(0===d&&(">="!==u.operator||"<="!==p.operator))return null}for(const e of a){if(u&&!n(e,u+"",r))return null;if(p&&!n(e,p+"",r))return null;for(const o of t)if(!n(e,o+"",r))return!1;return!0}let y=!(!p||r.includePrerelease||!p.semver.prerelease.length)&&p.semver,g=!(!u||r.includePrerelease||!u.semver.prerelease.length)&&u.semver;y&&1===y.prerelease.length&&"<"===p.operator&&0===y.prerelease[0]&&(y=!1);for(const e of t){if(v=v||">"===e.operator||">="===e.operator,m=m||"<"===e.operator||"<="===e.operator,u)if(g&&e.semver.prerelease&&e.semver.prerelease.length&&e.semver.major===g.major&&e.semver.minor===g.minor&&e.semver.patch===g.patch&&(g=!1),">"===e.operator||">="===e.operator){if(h=l(u,e,r),h===e&&h!==u)return!1}else if(">="===u.operator&&!n(u.semver,e+"",r))return!1;if(p)if(y&&e.semver.prerelease&&e.semver.prerelease.length&&e.semver.major===y.major&&e.semver.minor===y.minor&&e.semver.patch===y.patch&&(y=!1),"<"===e.operator||"<="===e.operator){if(f=c(p,e,r),f===e&&f!==p)return!1}else if("<="===p.operator&&!n(p.semver,e+"",r))return!1;if(!e.operator&&(p||u)&&0!==d)return!1}return!(u&&m&&!p&&0!==d||p&&v&&!u&&0!==d||g||y)},l=(e,t,r)=>{if(!e)return t;const o=i(e.semver,t.semver,r);return o>0?e:0>o||">"===t.operator&&">="===e.operator?t:e},c=(e,t,r)=>{if(!e)return t;const o=i(e.semver,t.semver,r);return 0>o?e:o>0||"<"===t.operator&&"<="===e.operator?t:e};e.exports=(e,t,o={})=>{if(e===t)return!0;e=new r(e,o),t=new r(t,o);let s=!1;e:for(const r of e.set){for(const e of t.set){const t=a(r,e,o);if(s=s||null!==t,t)continue e}if(s)return!1}return!0}}));const ct=ot(ge("1Hds5")),ut=ot(ee),pt=ot(te);ge.register("9AGbw",(function(e,t){"use strict";Object.defineProperty(e.exports,"__esModule",{value:!0});var r=ge("cEfL5");let o;var s,n,i,a,l;(n=s=e.exports.HttpCodes||(e.exports.HttpCodes={}))[n.OK=200]="OK",n[n.MultipleChoices=300]="MultipleChoices",n[n.MovedPermanently=301]="MovedPermanently",n[n.ResourceMoved=302]="ResourceMoved",n[n.SeeOther=303]="SeeOther",n[n.NotModified=304]="NotModified",n[n.UseProxy=305]="UseProxy",n[n.SwitchProxy=306]="SwitchProxy",n[n.TemporaryRedirect=307]="TemporaryRedirect",n[n.PermanentRedirect=308]="PermanentRedirect",n[n.BadRequest=400]="BadRequest",n[n.Unauthorized=401]="Unauthorized",n[n.PaymentRequired=402]="PaymentRequired",n[n.Forbidden=403]="Forbidden",n[n.NotFound=404]="NotFound",n[n.MethodNotAllowed=405]="MethodNotAllowed",n[n.NotAcceptable=406]="NotAcceptable",n[n.ProxyAuthenticationRequired=407]="ProxyAuthenticationRequired",n[n.RequestTimeout=408]="RequestTimeout",n[n.Conflict=409]="Conflict",n[n.Gone=410]="Gone",n[n.TooManyRequests=429]="TooManyRequests",n[n.InternalServerError=500]="InternalServerError",n[n.NotImplemented=501]="NotImplemented",n[n.BadGateway=502]="BadGateway",n[n.ServiceUnavailable=503]="ServiceUnavailable",n[n.GatewayTimeout=504]="GatewayTimeout",(a=i=e.exports.Headers||(e.exports.Headers={})).Accept="accept",a.ContentType="content-type",(l=e.exports.MediaTypes||(e.exports.MediaTypes={})).ApplicationJson="application/json",e.exports.getProxyUrl=e=>{let t=r.getProxyUrl(new URL(e));return t?t.href:""};const c=[s.MovedPermanently,s.ResourceMoved,s.SeeOther,s.TemporaryRedirect,s.PermanentRedirect],u=[s.BadGateway,s.ServiceUnavailable,s.GatewayTimeout],p=["OPTIONS","GET","DELETE","HEAD"];class d extends Error{constructor(e,t){super(e),this.name="HttpClientError",this.statusCode=t,Object.setPrototypeOf(this,d.prototype)}}e.exports.HttpClientError=d;class h{constructor(e){this.message=e}readBody(){return new Promise((async(e,t)=>{let r=Buffer.alloc(0);this.message.on("data",(e=>{r=Buffer.concat([r,e])})),this.message.on("end",(()=>{e(""+r)}))}))}}e.exports.HttpClientResponse=h,e.exports.isHttps=e=>"https:"===new URL(e).protocol;class f{constructor(e,t,r){this._ignoreSslError=!1,this._allowRedirects=!0,this._allowRedirectDowngrade=!1,this._maxRedirects=50,this._allowRetries=!1,this._maxRetries=1,this._keepAlive=!1,this._disposed=!1,this.userAgent=e,this.handlers=t||[],this.requestOptions=r,r&&(null!=r.ignoreSslError&&(this._ignoreSslError=r.ignoreSslError),this._socketTimeout=r.socketTimeout,null!=r.allowRedirects&&(this._allowRedirects=r.allowRedirects),null!=r.allowRedirectDowngrade&&(this._allowRedirectDowngrade=r.allowRedirectDowngrade),null!=r.maxRedirects&&(this._maxRedirects=Math.max(r.maxRedirects,0)),null!=r.keepAlive&&(this._keepAlive=r.keepAlive),null!=r.allowRetries&&(this._allowRetries=r.allowRetries),null!=r.maxRetries&&(this._maxRetries=r.maxRetries))}options(e,t){return this.request("OPTIONS",e,null,t||{})}get(e,t){return this.request("GET",e,null,t||{})}del(e,t){return this.request("DELETE",e,null,t||{})}post(e,t,r){return this.request("POST",e,t,r||{})}patch(e,t,r){return this.request("PATCH",e,t,r||{})}put(e,t,r){return this.request("PUT",e,t,r||{})}head(e,t){return this.request("HEAD",e,null,t||{})}sendStream(e,t,r,o){return this.request(e,t,r,o)}async getJson(e,t={}){t[i.Accept]=this._getExistingOrDefaultHeader(t,i.Accept,l.ApplicationJson);let r=await this.get(e,t);return this._processResponse(r,this.requestOptions)}async postJson(e,t,r={}){let o=JSON.stringify(t,null,2);r[i.Accept]=this._getExistingOrDefaultHeader(r,i.Accept,l.ApplicationJson),r[i.ContentType]=this._getExistingOrDefaultHeader(r,i.ContentType,l.ApplicationJson);let s=await this.post(e,o,r);return this._processResponse(s,this.requestOptions)}async putJson(e,t,r={}){let o=JSON.stringify(t,null,2);r[i.Accept]=this._getExistingOrDefaultHeader(r,i.Accept,l.ApplicationJson),r[i.ContentType]=this._getExistingOrDefaultHeader(r,i.ContentType,l.ApplicationJson);let s=await this.put(e,o,r);return this._processResponse(s,this.requestOptions)}async patchJson(e,t,r={}){let o=JSON.stringify(t,null,2);r[i.Accept]=this._getExistingOrDefaultHeader(r,i.Accept,l.ApplicationJson),r[i.ContentType]=this._getExistingOrDefaultHeader(r,i.ContentType,l.ApplicationJson);let s=await this.patch(e,o,r);return this._processResponse(s,this.requestOptions)}async request(e,t,r,o){if(this._disposed)throw Error("Client has already been disposed.");let n,i=new URL(t),a=this._prepareRequest(e,i,o),l=this._allowRetries&&-1!=p.indexOf(e)?this._maxRetries+1:1,d=0;for(;l>d;){if(n=await this.requestRaw(a,r),n&&n.message&&n.message.statusCode===s.Unauthorized){let e;for(let t=0;this.handlers.length>t;t++)if(this.handlers[t].canHandleAuthentication(n)){e=this.handlers[t];break}return e?e.handleAuthentication(this,a,r):n}let t=this._maxRedirects;for(;-1!=c.indexOf(n.message.statusCode)&&this._allowRedirects&&t>0;){const s=n.message.headers.location;if(!s)break;let l=new URL(s);if("https:"==i.protocol&&i.protocol!=l.protocol&&!this._allowRedirectDowngrade)throw Error("Redirect from HTTPS to HTTP protocol. This downgrade is not allowed for security reasons. If you want to allow this behavior, set the allowRedirectDowngrade option to true.");if(await n.readBody(),l.hostname!==i.hostname)for(let e in o)"authorization"===e.toLowerCase()&&delete o[e];a=this._prepareRequest(e,l,o),n=await this.requestRaw(a,r),t--}if(-1==u.indexOf(n.message.statusCode))return n;d+=1,l>d&&(await n.readBody(),await this._performExponentialBackoff(d))}return n}dispose(){this._agent&&this._agent.destroy(),this._disposed=!0}requestRaw(e,t){return new Promise(((r,o)=>{this.requestRawWithCallback(e,t,((e,t)=>{e&&o(e),r(t)}))}))}requestRawWithCallback(e,t,r){let o;"string"==typeof t&&(e.options.headers["Content-Length"]=Buffer.byteLength(t,"utf8"));let s=!1,n=(e,t)=>{s||(s=!0,r(e,t))},i=e.httpModule.request(e.options,(e=>{let t=new h(e);n(null,t)}));i.on("socket",(e=>{o=e})),i.setTimeout(this._socketTimeout||18e4,(()=>{o&&o.end(),n(Error("Request timeout: "+e.options.path),null)})),i.on("error",(e=>{n(e,null)})),t&&"string"==typeof t&&i.write(t,"utf8"),t&&"string"!=typeof t?(t.on("close",(()=>{i.end()})),t.pipe(i)):i.end()}getAgent(e){let t=new URL(e);return this._getAgent(t)}_prepareRequest(e,t,r){const o={};o.parsedUrl=t;const s="https:"===o.parsedUrl.protocol;o.httpModule=s?pe:ue;const n=s?443:80;return o.options={},o.options.host=o.parsedUrl.hostname,o.options.port=o.parsedUrl.port?parseInt(o.parsedUrl.port):n,o.options.path=(o.parsedUrl.pathname||"")+(o.parsedUrl.search||""),o.options.method=e,o.options.headers=this._mergeHeaders(r),null!=this.userAgent&&(o.options.headers["user-agent"]=this.userAgent),o.options.agent=this._getAgent(o.parsedUrl),this.handlers&&this.handlers.forEach((e=>{e.prepareRequest(o.options)})),o}_mergeHeaders(e){const t=e=>Object.keys(e).reduce(((t,r)=>(t[r.toLowerCase()]=e[r],t)),{});return this.requestOptions&&this.requestOptions.headers?Object.assign({},t(this.requestOptions.headers),t(e)):t(e||{})}_getExistingOrDefaultHeader(e,t,r){let o;var s;return this.requestOptions&&this.requestOptions.headers&&(o=(s=this.requestOptions.headers,Object.keys(s).reduce(((e,t)=>(e[t.toLowerCase()]=s[t],e)),{}))[t]),e[t]||o||r}_getAgent(e){let t,s=r.getProxyUrl(e),n=s&&s.hostname;if(this._keepAlive&&n&&(t=this._proxyAgent),this._keepAlive&&!n&&(t=this._agent),t)return t;const i="https:"===e.protocol;let a=100;if(this.requestOptions&&(a=this.requestOptions.maxSockets||ue.globalAgent.maxSockets),n){o||(o=ge("hEhmi"));const e={maxSockets:a,keepAlive:this._keepAlive,proxy:{...(s.username||s.password)&&{proxyAuth:`${s.username}:${s.password}`},host:s.hostname,port:s.port}};let r;const n="https:"===s.protocol;r=i?n?o.httpsOverHttps:o.httpsOverHttp:n?o.httpOverHttps:o.httpOverHttp,t=r(e),this._proxyAgent=t}if(this._keepAlive&&!t){const e={keepAlive:this._keepAlive,maxSockets:a};t=i?new pe.Agent(e):new ue.Agent(e),this._agent=t}return t||(t=i?pe.globalAgent:ue.globalAgent),i&&this._ignoreSslError&&(t.options=Object.assign(t.options||{},{rejectUnauthorized:!1})),t}_performExponentialBackoff(e){const t=5*Math.pow(2,e=Math.min(10,e));return new Promise((e=>setTimeout((()=>e()),t)))}static dateTimeDeserializer(e,t){if("string"==typeof t){let e=new Date(t);if(!isNaN(e.valueOf()))return e}return t}async _processResponse(e,t){return new Promise((async(r,o)=>{const n=e.message.statusCode,i={statusCode:n,result:null,headers:{}};let a,l;n==s.NotFound&&r(i);try{l=await e.readBody(),l&&l.length>0&&(a=t&&t.deserializeDates?JSON.parse(l,f.dateTimeDeserializer):JSON.parse(l),i.result=a),i.headers=e.message.headers}catch(e){}if(n>299){let e;e=a&&a.message?a.message:l&&l.length>0?l:"Failed request: ("+n+")";let t=new d(e,n);t.result=i.result,o(t)}else r(i)}))}}e.exports.HttpClient=f})),ge.register("cEfL5",((e,t)=>{"use strict";function r(e){if(!e.hostname)return!1;let t,r=process.env.no_proxy||process.env.NO_PROXY||"";if(!r)return!1;e.port?t=+e.port:"http:"===e.protocol?t=80:"https:"===e.protocol&&(t=443);let o=[e.hostname.toUpperCase()];"number"==typeof t&&o.push(`${o[0]}:${t}`);for(let e of r.split(",").map((e=>e.trim().toUpperCase())).filter((e=>e)))if(o.some((t=>t===e)))return!0;return!1}Object.defineProperty(e.exports,"__esModule",{value:!0}),e.exports.getProxyUrl=e=>{let t,o,s="https:"===e.protocol;return r(e)||(o=s?process.env.https_proxy||process.env.HTTPS_PROXY:process.env.http_proxy||process.env.HTTP_PROXY,o&&(t=new URL(o))),t},e.exports.checkBypass=r})),ge.register("hEhmi",((e,t)=>{e.exports=ge("88ZfI")})),ge.register("88ZfI",(function(e,r){function o(e){var t=this;t.options=e||{},t.proxyOptions=t.options.proxy||{},t.maxSockets=t.options.maxSockets||ue.Agent.defaultMaxSockets,t.requests=[],t.sockets=[],t.on("free",((e,r,o,s)=>{for(var i=n(r,o,s),a=0,l=t.requests.length;l>a;++a){var c=t.requests[a];if(c.host===i.host&&c.port===i.port)return t.requests.splice(a,1),void c.request.onSocket(e)}e.destroy(),t.removeSocket(e)}))}function s(e,t){var r=this;o.prototype.createSocket.call(r,e,(o=>{var s=e.request.getHeader("host"),n=i({},r.options,{socket:o,servername:s?s.replace(/:.*$/,""):e.host}),a=de.connect(0,n);r.sockets[r.sockets.indexOf(o)]=a,t(a)}))}function n(e,t,r){return"string"==typeof e?{host:e,port:t,localAddress:r}:e}function i(e){for(var t=1,r=arguments.length;r>t;++t){var o=arguments[t];if("object"==typeof o)for(var s=Object.keys(o),n=0,i=s.length;i>n;++n){var a=s[n];void 0!==o[a]&&(e[a]=o[a])}}return e}var a,l,c,u,p,d;t(e.exports,"httpOverHttps",(()=>a),(e=>a=e)),t(e.exports,"httpsOverHttp",(()=>l),(e=>l=e)),t(e.exports,"httpOverHttp",(()=>c),(e=>c=e)),t(e.exports,"httpsOverHttps",(()=>u),(e=>u=e)),t(e.exports,"debug",(()=>p),(e=>p=e)),c=e=>{var t=new o(e);return t.request=ue.request,t},l=e=>{var t=new o(e);return t.request=ue.request,t.createSocket=s,t.defaultPort=443,t},a=e=>{var t=new o(e);return t.request=pe.request,t},u=e=>{var t=new o(e);return t.request=pe.request,t.createSocket=s,t.defaultPort=443,t},le.inherits(o,ne.EventEmitter),o.prototype.addRequest=function(e,t,r,o){var s=this,a=i({request:e},s.options,n(t,r,o));this.maxSockets>s.sockets.length?s.createSocket(a,(t=>{function r(){s.emit("free",t,a)}function o(e){s.removeSocket(t),t.removeListener("free",r),t.removeListener("close",o),t.removeListener("agentRemove",o)}t.on("free",r),t.on("close",o),t.on("agentRemove",o),e.onSocket(t)})):s.requests.push(a)},o.prototype.createSocket=function(e,t){function r(r,n,i){var l;return a.removeAllListeners(),n.removeAllListeners(),200!==r.statusCode?(d("tunneling socket could not be established, statusCode=%d",r.statusCode),n.destroy(),(l=Error("tunneling socket could not be established, statusCode="+r.statusCode)).code="ECONNRESET",e.request.emit("error",l),void o.removeSocket(s)):i.length>0?(d("got illegal response body from proxy"),n.destroy(),(l=Error("got illegal response body from proxy")).code="ECONNRESET",e.request.emit("error",l),void o.removeSocket(s)):(d("tunneling connection has established"),o.sockets[o.sockets.indexOf(s)]=n,t(n))}var o=this,s={};o.sockets.push(s);var n=i({},o.proxyOptions,{method:"CONNECT",path:e.host+":"+e.port,agent:!1,headers:{host:e.host+":"+e.port}});e.localAddress&&(n.localAddress=e.localAddress),n.proxyAuth&&(n.headers=n.headers||{},n.headers["Proxy-Authorization"]="Basic "+new Buffer(n.proxyAuth).toString("base64")),d("making CONNECT request");var a=o.request(n);a.useChunkedEncodingByDefault=!1,a.once("response",(e=>{e.upgrade=!0})),a.once("upgrade",((e,t,o)=>{process.nextTick((()=>{r(e,t,o)}))})),a.once("connect",r),a.once("error",(t=>{a.removeAllListeners(),d("tunneling socket could not be established, cause=%s\n",t.message,t.stack);var r=Error("tunneling socket could not be established, cause="+t.message);r.code="ECONNRESET",e.request.emit("error",r),o.removeSocket(s)})),a.end()},o.prototype.removeSocket=function(e){var t=this.sockets.indexOf(e);if(-1!==t){this.sockets.splice(t,1);var r=this.requests.shift();r&&this.createSocket(r,(e=>{r.request.onSocket(e)}))}},p=d=()=>{}}));const dt=ot(ge("9AGbw")),ht=ot(ge("hBwzM")),ft=ot(ce),mt=ot(le);ge.register("kceBH",((e,t)=>{var r=ge("diWfV"),o=ge("8n3PT");e.exports=(e,t,s)=>{var n=t&&s||0;"string"==typeof e&&(t="binary"===e?Array(16):null,e=null);var i=(e=e||{}).random||(e.rng||r)();if(i[6]=15&i[6]|64,i[8]=63&i[8]|128,t)for(var a=0;16>a;++a)t[n+a]=i[a];return t||o(i)}})),ge.register("diWfV",((e,t)=>{e.exports=()=>he.randomBytes(16)})),ge.register("8n3PT",((e,t)=>{for(var r=[],o=0;256>o;++o)r[o]=(o+256).toString(16).substr(1);e.exports=(e,t)=>{var o=t||0;return""+r[e[o++]]+r[e[o++]]+r[e[o++]]+r[e[o++]]+"-"+r[e[o++]]+r[e[o++]]+"-"+r[e[o++]]+r[e[o++]]+"-"+r[e[o++]]+r[e[o++]]+"-"+r[e[o++]]+r[e[o++]]+r[e[o++]]+r[e[o++]]+r[e[o++]]+r[e[o++]]}}));const vt=nt(ge("kceBH"));var yt={},gt=yt&&yt.__createBinding||(Object.create?(e,t,r,o)=>{void 0===o&&(o=r),Object.defineProperty(e,o,{enumerable:!0,get(){return t[r]}})}:(e,t,r,o)=>{void 0===o&&(o=r),e[o]=t[r]}),xt=yt&&yt.__setModuleDefault||(Object.create?(e,t)=>{Object.defineProperty(e,"default",{enumerable:!0,value:t})}:(e,t)=>{e.default=t}),wt=yt&&yt.__importStar||(e=>{if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)"default"!==r&&Object.hasOwnProperty.call(e,r)&&gt(t,e,r);return xt(t,e),t}),Et=yt&&yt.__awaiter||((e,t,r,o)=>new(r||(r=Promise))(((s,n)=>{function i(e){try{l(o.next(e))}catch(e){n(e)}}function a(e){try{l(o.throw(e))}catch(e){n(e)}}function l(e){var t;e.done?s(e.value):(t=e.value,t instanceof r?t:new r((e=>{e(t)}))).then(i,a)}l((o=o.apply(e,t||[])).next())})));Object.defineProperty(yt,"__esModule",{value:!0}),yt.RetryHelper=void 0;const bt=wt(ge("6FGZZ"));yt.RetryHelper=class{constructor(e,t,r){if(1>e)throw Error("max attempts should be greater than or equal to 1");if(this.maxAttempts=e,this.minSeconds=Math.floor(t),this.maxSeconds=Math.floor(r),this.minSeconds>this.maxSeconds)throw Error("min seconds should be less than or equal to max seconds")}execute(e,t){return Et(this,void 0,void 0,(function*(){let r=1;for(;this.maxAttempts>r;){try{return yield e()}catch(e){if(t&&!t(e))throw e;bt.info(e.message)}const o=this.getSleepAmount();bt.info(`Waiting ${o} seconds before trying again`),yield this.sleep(o),r++}return yield e()}))}getSleepAmount(){return Math.floor(Math.random()*(this.maxSeconds-this.minSeconds+1))+this.minSeconds}sleep(e){return Et(this,void 0,void 0,(function*(){return new Promise((t=>setTimeout(t,1e3*e)))}))}};class Pt extends Error{constructor(e){super("Unexpected HTTP response: "+e),this.httpStatusCode=e,Object.setPrototypeOf(this,new.target.prototype)}}et.HTTPError=Pt;const Ot="win32"===process.platform,$t="darwin"===process.platform;et.downloadTool=function(e,t,r,o){return st(this,void 0,void 0,(function*(){t=t||pt.join(b(),vt.default()),yield at.mkdirP(pt.dirname(t)),it.debug("Downloading "+e),it.debug("Destination "+t);const s=P("TEST_DOWNLOAD_TOOL_RETRY_MIN_SECONDS",10),n=P("TEST_DOWNLOAD_TOOL_RETRY_MAX_SECONDS",20),i=new yt.RetryHelper(3,s,n);return yield i.execute((()=>st(this,void 0,void 0,(function*(){return yield function(e,t,r,o){return st(this,void 0,void 0,(function*(){if(lt.existsSync(t))throw Error(`Destination file path ${t} already exists`);const s=new dt.HttpClient("actions/tool-cache",[],{allowRetries:!1});r&&(it.debug("set auth"),void 0===o&&(o={}),o.authorization=r);const n=yield s.get(e,o);if(200!==n.message.statusCode){const t=new Pt(n.message.statusCode);throw it.debug(`Failed to download from "${e}". Code(${n.message.statusCode}) Message(${n.message.statusMessage})`),t}const i=mt.promisify(ft.pipeline),a=P("TEST_DOWNLOAD_TOOL_RESPONSE_MESSAGE_FACTORY",(()=>n.message))();let l=!1;try{return yield i(a,lt.createWriteStream(t)),it.debug("download complete"),l=!0,t}finally{if(!l){it.debug("download failed");try{yield at.rmRF(t)}catch(e){it.debug(`Failed to delete '${t}'. ${e.message}`)}}}}))}(e,t||"",r,o)}))),(e=>!(e instanceof Pt&&e.httpStatusCode&&500>e.httpStatusCode&&408!==e.httpStatusCode&&429!==e.httpStatusCode)))}))},et.extract7z=function(e,t,r){return st(this,void 0,void 0,(function*(){ae.ok(Ot,"extract7z() not supported on current OS"),ae.ok(e,'parameter "file" is required'),t=yield v(t);const o=process.cwd();if(process.chdir(t),r)try{const t=["x",it.isDebug()?"-bb1":"-bb0","-bd","-sccUTF-8",e],s={silent:!0};yield Ae.exec(`"${r}"`,t,s)}finally{process.chdir(o)}else{const r=["-NoLogo","-Sta","-NoProfile","-NonInteractive","-ExecutionPolicy","Unrestricted","-Command",`& '${pt.join(__dirname,"..","scripts","Invoke-7zdec.ps1").replace(/'/g,"''").replace(/"|\n|\r/g,"")}' -Source '${e.replace(/'/g,"''").replace(/"|\n|\r/g,"")}' -Target '${t.replace(/'/g,"''").replace(/"|\n|\r/g,"")}'`],s={silent:!0};try{const e=yield at.which("powershell",!0);yield Ae.exec(`"${e}"`,r,s)}finally{process.chdir(o)}}return t}))},et.extractTar=function(e,t,r="xz"){return st(this,void 0,void 0,(function*(){if(!e)throw Error("parameter 'file' is required");t=yield v(t),it.debug("Checking tar --version");let o="";yield Ae.exec("tar --version",[],{ignoreReturnCode:!0,silent:!0,listeners:{stdout(e){return o+=""+e},stderr(e){return o+=""+e}}}),it.debug(o.trim());const s=o.toUpperCase().includes("GNU TAR");let n;n=r instanceof Array?r:[r],it.isDebug()&&!r.includes("v")&&n.push("-v");let i=t,a=e;return Ot&&s&&(n.push("--force-local"),i=t.replace(/\\/g,"/"),a=e.replace(/\\/g,"/")),s&&(n.push("--warning=no-unknown-keyword"),n.push("--overwrite")),n.push("-C",i,"-f",a),yield Ae.exec("tar",n),t}))},et.extractXar=function(e,t,r=[]){return st(this,void 0,void 0,(function*(){let o;ae.ok($t,"extractXar() not supported on current OS"),ae.ok(e,'parameter "file" is required'),t=yield v(t),o=r instanceof Array?r:[r],o.push("-x","-C",t,"-f",e),it.isDebug()&&o.push("-v");const s=yield at.which("xar",!0);var n;return yield Ae.exec(`"${s}"`,(n=o,Array.from(new Set(n)))),t}))},et.extractZip=function(e,t){return st(this,void 0,void 0,(function*(){if(!e)throw Error("parameter 'file' is required");return t=yield v(t),Ot?yield function(e,t){return st(this,void 0,void 0,(function*(){const r=e.replace(/'/g,"''").replace(/"|\n|\r/g,""),o=t.replace(/'/g,"''").replace(/"|\n|\r/g,""),s=yield at.which("pwsh",!1);if(s){const e=["-NoLogo","-NoProfile","-NonInteractive","-ExecutionPolicy","Unrestricted","-Command",["$ErrorActionPreference = 'Stop' ; try { Add-Type -AssemblyName System.IO.Compression.ZipFile } catch { } ;",`try { [System.IO.Compression.ZipFile]::ExtractToDirectory('${r}', '${o}', $true) }`,`catch { if (($_.Exception.GetType().FullName -eq 'System.Management.Automation.MethodException') -or ($_.Exception.GetType().FullName -eq 'System.Management.Automation.RuntimeException') ){ Expand-Archive -LiteralPath '${r}' -DestinationPath '${o}' -Force } else { throw $_ } } ;`].join(" ")];it.debug("Using pwsh at path: "+s),yield Ae.exec(`"${s}"`,e)}else{const e=["-NoLogo","-Sta","-NoProfile","-NonInteractive","-ExecutionPolicy","Unrestricted","-Command",["$ErrorActionPreference = 'Stop' ; try { Add-Type -AssemblyName System.IO.Compression.FileSystem } catch { } ;",`if ((Get-Command -Name Expand-Archive -Module Microsoft.PowerShell.Archive -ErrorAction Ignore)) { Expand-Archive -LiteralPath '${r}' -DestinationPath '${o}' -Force }`,`else {[System.IO.Compression.ZipFile]::ExtractToDirectory('${r}', '${o}', $true) }`].join(" ")],t=yield at.which("powershell",!0);it.debug("Using powershell at path: "+t),yield Ae.exec(`"${t}"`,e)}}))}(e,t):yield function(e,t){return st(this,void 0,void 0,(function*(){const r=yield at.which("unzip",!0),o=[e];it.isDebug()||o.unshift("-q"),o.unshift("-o"),yield Ae.exec(`"${r}"`,o,{cwd:t})}))}(e,t),t}))},et.cacheDir=function(e,t,r,o){return st(this,void 0,void 0,(function*(){if(r=ht.clean(r)||r,o=o||ut.arch(),it.debug(`Caching tool ${t} ${r} ${o}`),it.debug("source dir: "+e),!lt.statSync(e).isDirectory())throw Error("sourceDir is not a directory");const s=yield y(t,r,o);for(const t of lt.readdirSync(e)){const r=pt.join(e,t);yield at.cp(r,s,{recursive:!0})}return g(t,r,o),s}))},et.cacheFile=function(e,t,r,o,s){return st(this,void 0,void 0,(function*(){if(o=ht.clean(o)||o,s=s||ut.arch(),it.debug(`Caching tool ${r} ${o} ${s}`),it.debug("source file: "+e),!lt.statSync(e).isFile())throw Error("sourceFile is not a file");const n=yield y(r,o,s),i=pt.join(n,t);return it.debug("destination file "+i),yield at.cp(e,i),g(r,o,s),n}))},et.find=(e,t,r)=>{if(!e)throw Error("toolName parameter is required");if(!t)throw Error("versionSpec parameter is required");r=r||ut.arch(),x(t)||(t=w(m(e,r),t));let o="";if(t){t=ht.clean(t)||"";const s=pt.join(E(),e,t,r);it.debug("checking cache: "+s),lt.existsSync(s)&&lt.existsSync(s+".complete")?(it.debug(`Found tool in cache ${e} ${t} ${r}`),o=s):it.debug("not found")}return o},et.findAllVersions=m,et.getManifestFromRepo=function(e,t,r,o="master"){return st(this,void 0,void 0,(function*(){let s=[];const n=`https://api.github.com/repos/${e}/${t}/git/trees/${o}`,i=new dt.HttpClient("tool-cache"),a={};r&&(it.debug("set auth"),a.authorization=r);const l=yield i.getJson(n,a);if(!l.result)return s;let c="";for(const e of l.result.tree)if("versions-manifest.json"===e.path){c=e.url;break}a.accept="application/vnd.github.VERSION.raw";let u=yield(yield i.get(c,a)).readBody();if(u){u=u.replace(/^\uFEFF/,"");try{s=JSON.parse(u)}catch(e){it.debug("Invalid json")}}return s}))},et.findFromManifest=function(e,t,r,o=ut.arch()){return st(this,void 0,void 0,(function*(){return yield ct._findMatch(e,t,r,o)}))},et.isExplicitVersion=x,et.evaluateVersions=w,xe=ge("6FGZZ");var St=ge("ju11K"),_t=ge("5M2Mq"),Rt=(xe=ge("6FGZZ"),{}),At={};const Ct=e=>null!==e&&"object"==typeof e&&"function"==typeof e.pipe;Ct.writable=e=>Ct(e)&&!1!==e.writable&&"function"==typeof e._write&&"object"==typeof e._writableState,Ct.readable=e=>Ct(e)&&!1!==e.readable&&"function"==typeof e._read&&"object"==typeof e._readableState,Ct.duplex=e=>Ct.writable(e)&&Ct.readable(e),Ct.transform=e=>Ct.duplex(e)&&"function"==typeof e._transform,At=Ct;const{Worker:Tt}=(()=>{try{return $e68279e3338bc371$import$ad18b0afc1a10da7}catch(e){return{}}})();let It,Nt=0;const Lt=new Map,Dt=(e,t,r)=>new Promise(((o,s)=>{const n=Nt++;Lt.set(n,{resolve:o,reject:s}),void 0===It&&(It=new Tt(te.join(__dirname,"thread.js")),It.on("message",(e=>{const t=Lt.get(e.id);Lt.delete(e.id),0===Lt.size&&It.unref(),void 0===e.error?t.resolve(e.value):t.reject((e=>{const t=Error(e.message);for(const[r,o]of Object.entries(e))"message"!==r&&(t[r]=o);return t})(e.error))})),It.on("error",(e=>{throw e}))),It.ref(),It.postMessage({id:n,method:e,args:t},r)})),jt=(e,t={})=>{let r=t.encoding||"hex";"buffer"===r&&(r=void 0);const o=he.createHash(t.algorithm||"sha512"),s=e=>{o.update(e,"string"==typeof e?"utf8":void 0)};return Array.isArray(e)?e.forEach(s):s(e),o.digest(r)};jt.stream=(e={})=>{let t=e.encoding||"hex";"buffer"===t&&(t=void 0);const r=he.createHash(e.algorithm||"sha512");return r.setEncoding(t),r},jt.fromStream=async(e,t={})=>{if(!At(e))throw new TypeError("Expected a stream");return new Promise(((r,o)=>{e.on("error",o).pipe(jt.stream(t)).on("error",o).on("finish",(function(){r(this.read())}))}))},void 0===Tt?(jt.fromFile=async(e,t)=>jt.fromStream(re.createReadStream(e),t),jt.async=async(e,t)=>jt(e,t)):(jt.fromFile=async(e,{algorithm:t="sha512",encoding:r="hex"}={})=>{const o=await Dt("hashFile",[t,e]);return"buffer"===r?Buffer.from(o):Buffer.from(o).toString(r)},jt.async=async(e,{algorithm:t="sha512",encoding:r="hex"}={})=>{"buffer"===r&&(r=void 0);const o=await Dt("hash",[t,e]);return void 0===r?Buffer.from(o):Buffer.from(o).toString(r)}),jt.fromFileSync=(e,t)=>jt(re.readFileSync(e),t),Rt=jt,xe=ge("6FGZZ"),xe=ge("6FGZZ");var kt=ge("hBwzM");const Mt="win32"===process.platform,Ft="linux"===process.platform,Ut=["x86","x64"],Vt=["win32","win64"];kt=ge("hBwzM");const qt=(xe=ge("6FGZZ")).getInput("token"),Gt=qt&&"GITHUB.COM"===new URL(process.env.GITHUB_SERVER_URL||"https://github.com").hostname.toUpperCase()?"token "+qt:void 0,Ht="https://raw.githubusercontent.com/actions/python-versions/main/versions-manifest.json";xe=ge("6FGZZ"),xe=ge("6FGZZ"),kt=ge("hBwzM");var Bt=ge("9AGbw"),Xt=(kt=ge("hBwzM"),xe=ge("6FGZZ"),ge("1wyqe"));let Yt,zt;xe=ge("6FGZZ"),St=ge("ju11K");var Wt=ge("k3zcS"),Zt=ge("q05Mr");const Jt=(e=>{const t=new Set(e);for(const r of e)t.add(/^\d+/.exec(r)[0]),t.add(/^\d+\.\d+/.exec(r)[0]);return t})(["3.5.0","3.5.1","3.5.2","3.6.0","3.6.1","3.6.2","3.7.0","3.7.1","3.8.0","3.8.1","3.9.0","3.9.1","4.0.0","4.0.1","5.0.0","5.0.1","5.0.2","6.0.0","6.0.1","7.0.0","7.0.1","7.1.0","8.0.0","8.0.1","9.0.0","9.0.1","10.0.0","10.0.1","11.0.0","11.0.1","11.1.0","12.0.0","12.0.1"]),Kt=new Set(["3.5.1","3.6.1","3.6.2","3.7.1","3.8.1","3.9.1","6.0.1","7.0.1","7.1.0","8.0.1","11.0.1","11.1.0","12.0.1"]),Qt=new Map([["12.0.1","12.0.1-rc4"]]),er={"3.5.0":"-ubuntu-14.04","3.5.1":"","3.5.2":"-ubuntu-14.04","3.6.0":"-ubuntu-14.04","3.6.1":"-ubuntu-14.04","3.6.2":"-ubuntu-14.04","3.7.0":"-ubuntu-14.04","3.7.1":"-ubuntu-14.04","3.8.0":"-ubuntu-16.04","3.8.1":"-ubuntu-16.04","3.9.0":"-ubuntu-16.04","3.9.1":"-ubuntu-16.04","4.0.0":"-ubuntu-16.04","5.0.0":"-ubuntu16.04","5.0.1":"-ubuntu-16.04","5.0.2":"-ubuntu-16.04","6.0.0":"-ubuntu-16.04","6.0.1":"-ubuntu-16.04","7.0.0":"-ubuntu-16.04","7.0.1":"-ubuntu-18.04","7.1.0":"-ubuntu-14.04","8.0.0":"-ubuntu-18.04","9.0.0":"-ubuntu-18.04","9.0.1":"-ubuntu-16.04","10.0.0":"-ubuntu-18.04","10.0.1":"-ubuntu-16.04","11.0.0":"-ubuntu-20.04","11.0.1":"-ubuntu-16.04","11.1.0":"-ubuntu-16.04","12.0.0":"-ubuntu-20.04","12.0.1-rc4":"-ubuntu-21.04"},tr=new Set(["10.0.1"]);var rr;xe=ge("6FGZZ"),ge.register("jJT7R",((e,r)=>{function o(e){return-1!=["PATH","INCLUDE","LIB","LIBPATH"].indexOf(e.toUpperCase())}function s(e,t,r,s,n){if("win32"!=fe.platform)return void i.info("This is not a Windows virtual environment, bye!");fe.env.PATH+=te.delimiter+u;let p={win32:"x86",win64:"x64",x86_64:"x64","x86-64":"x64"};e.toLowerCase()in p&&(e=p[e.toLowerCase()]);var d=[e];"true"==s&&d.push("uwp"),t&&d.push(t),r&&d.push("-vcvars_ver="+r),"true"==n&&d.push("-vcvars_spectre_libs=spectre");const h=`"${(()=>{let e=(e=>{try{return(""+oe.execSync("vswhere -products * -latest -prerelease -property installationPath")).trim()+"\\VC\\Auxiliary\\Build\\vcvarsall.bat"}catch(e){i.warning("vswhere failed: "+e)}return null})();if(e&&re.existsSync(e))return i.info("Found with vswhere: "+e),e;i.info("Not found with vswhere");for(const t of c)for(const r of l)if(e=`${a}\\Microsoft Visual Studio\\${t}\\${r}\\VC\\Auxiliary\\Build\\vcvarsall.bat`,i.info("Trying standard location: "+e),re.existsSync(e))return i.info("Found standard location: "+e),e;if(i.info("Not found in standard locations"),e=a+"\\Microsoft Visual C++ Build Tools\\vcbuildtools.bat",re.existsSync(e))return i.info("Found VS 2015: "+e),e;throw i.info("Not found in VS 2015 location: "+e),Error("Microsoft Visual Studio not found")})()}" ${d.join(" ")}`;i.debug("vcvars command-line: "+h);const f=(""+oe.execSync(`set && cls && ${h} && cls && set`,{shell:"cmd"})).split("\f"),m=f[0].split("\r\n"),v=f[1].split("\r\n"),y=f[2].split("\r\n"),g=v.filter((e=>!(!e.match(/^\[ERROR.*\]/)||e.match(/Error in script usage. The correct usage is:$/))));if(g.length>0)throw Error("invalid parameters\r\n"+g.join("\r\n"));let x={};for(let e of m){const[t,r]=e.split("=");x[t]=r}i.startGroup("Environment variables");for(let e of y){if(!e.includes("="))continue;let[t,r]=e.split("=");r!==x[t]&&(i.info("Setting "+t),o(t)&&(r=r.split(";").filter(((e,t,r)=>r.indexOf(e)===t)).join(";")),i.exportVariable(t,r))}i.endGroup(),i.info("Configured Developer Command Prompt")}var n;t(e.exports,"setupMSVCDevCmd",(()=>n),(e=>n=e));var i=ge("k2PtG");const a=fe.env["ProgramFiles(x86)"],l=["Enterprise","Professional","Community"],c=["2019","2017"],u=a+"\\Microsoft Visual Studio\\Installer";n=s;try{s(i.getInput("arch"),i.getInput("sdk"),i.getInput("toolset"),i.getInput("uwp"),i.getInput("spectre"))}catch(e){i.setFailed("Could not setup Developer Command Prompt: "+e.message)}})),ge.register("k2PtG",(function(e,t){"use strict";function r(e){a.issue("error",e instanceof Error?""+e:e)}function o(e){a.issue("group",e)}function s(){a.issue("endgroup")}var n=e.exports&&e.exports.__awaiter||((e,t,r,o)=>new(r||(r=Promise))(((s,n)=>{function i(e){try{l(o.next(e))}catch(e){n(e)}}function a(e){try{l(o.throw(e))}catch(e){n(e)}}function l(e){var t;e.done?s(e.value):(t=e.value,t instanceof r?t:new r((e=>{e(t)}))).then(i,a)}l((o=o.apply(e,t||[])).next())}))),i=e.exports&&e.exports.__importStar||(e=>{if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)Object.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t.default=e,t});Object.defineProperty(e.exports,"__esModule",{value:!0});var a=ge("lTVmt"),l=ge("48DC3"),c=ge("3tRAC");const u=i(ee),p=i(te);var d,h;(h=d=e.exports.ExitCode||(e.exports.ExitCode={}))[h.Success=0]="Success",h[h.Failure=1]="Failure",e.exports.exportVariable=(e,t)=>{const r=c.toCommandValue(t);if(process.env[e]=r,process.env.GITHUB_ENV){const t="_GitHubActionsFileCommandDelimeter_";l.issueCommand("ENV",`${e}<<${t}${u.EOL}${r}${u.EOL}${t}`)}else a.issueCommand("set-env",{name:e},r)},e.exports.setSecret=e=>{a.issueCommand("add-mask",{},e)},e.exports.addPath=e=>{process.env.GITHUB_PATH?l.issueCommand("PATH",e):a.issueCommand("add-path",{},e),process.env.PATH=`${e}${p.delimiter}${process.env.PATH}`},e.exports.getInput=(e,t)=>{const r=process.env["INPUT_"+e.replace(/ /g,"_").toUpperCase()]||"";if(t&&t.required&&!r)throw Error("Input required and not supplied: "+e);return r.trim()},e.exports.setOutput=(e,t)=>{a.issueCommand("set-output",{name:e},t)},e.exports.setCommandEcho=e=>{a.issue("echo",e?"on":"off")},e.exports.setFailed=e=>{process.exitCode=d.Failure,r(e)},e.exports.isDebug=()=>"1"===process.env.RUNNER_DEBUG,e.exports.debug=e=>{a.issueCommand("debug",{},e)},e.exports.error=r,e.exports.warning=e=>{a.issue("warning",e instanceof Error?""+e:e)},e.exports.info=e=>{process.stdout.write(e+u.EOL)},e.exports.startGroup=o,e.exports.endGroup=s,e.exports.group=function(e,t){return n(this,void 0,void 0,(function*(){let r;o(e);try{r=yield t()}finally{s()}return r}))},e.exports.saveState=(e,t)=>{a.issueCommand("save-state",{name:e},t)},e.exports.getState=e=>process.env["STATE_"+e]||""})),ge.register("lTVmt",(function(e,t){"use strict";function r(e,t,r){const o=new i(e,t,r);process.stdout.write(""+o+s.EOL)}var o=e.exports&&e.exports.__importStar||(e=>{if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)Object.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t.default=e,t});Object.defineProperty(e.exports,"__esModule",{value:!0});const s=o(ee);var n=ge("3tRAC");e.exports.issueCommand=r,e.exports.issue=(e,t="")=>{r(e,{},t)};class i{constructor(e,t,r){e||(e="missing.command"),this.command=e,this.properties=t,this.message=r}toString(){let e="::"+this.command;if(this.properties&&Object.keys(this.properties).length>0){e+=" ";let r=!0;for(const o in this.properties)if(this.properties.hasOwnProperty(o)){const s=this.properties[o];s&&(r?r=!1:e+=",",e+=`${o}=${t=s,n.toCommandValue(t).replace(/%/g,"%25").replace(/\r/g,"%0D").replace(/\n/g,"%0A").replace(/:/g,"%3A").replace(/,/g,"%2C")}`)}}var t;return e+="::"+(e=>n.toCommandValue(this.message).replace(/%/g,"%25").replace(/\r/g,"%0D").replace(/\n/g,"%0A"))(),e}}})),ge.register("3tRAC",((e,t)=>{"use strict";Object.defineProperty(e.exports,"__esModule",{value:!0}),e.exports.toCommandValue=e=>null==e?"":"string"==typeof e||e instanceof String?e:JSON.stringify(e)})),ge.register("48DC3",((e,t)=>{"use strict";var r=e.exports&&e.exports.__importStar||(e=>{if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)Object.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t.default=e,t});Object.defineProperty(e.exports,"__esModule",{value:!0});const o=r(re),s=r(ee);var n=ge("3tRAC");e.exports.issueCommand=(e,t)=>{const r=process.env["GITHUB_"+e];if(!r)throw Error("Unable to find environment variable for file command "+e);if(!o.existsSync(r))throw Error("Missing file at path: "+r);o.appendFileSync(r,`${n.toCommandValue(t)}${s.EOL}`,{encoding:"utf8"})}}));const or=ee.homedir();rr=e=>{if("string"!=typeof e)throw new TypeError("Expected a string, got "+typeof e);return or?e.replace(/^~(?=$|\/|\\)/,or):e};var sr=ge("1JJDJ");const nr={msvc:"2019",llvm:"11",ninja:"1.10.2",cmake:"3.20.2",gcovr:"5.0",conan:"1.40.1",meson:"0.59.1",python:"3.x",gcc:"win32"===process.platform?"10.2.0":"11"};xe=ge("6FGZZ"),Wt=ge("k3zcS"),_t=ge("5M2Mq");const ir={cmake(e,t,r){return O("cmake",e,$,t)},ninja(e,t,r){return O("ninja",e,X,t)},python:D,conan(e,t,r){return k("conan",e)},meson(e,t,r){return k("meson",e)},gcovr(e,t,r){return k("gcovr",e)},async opencppcoverage(e,t,r){if("win32"!==process.platform)return;await f("opencppcoverage",e);const o="C:/Program Files/OpenCppCoverage";return await d(o),{binDir:o}},llvm:H,gcc:Z,choco:h,brew:o,ccache(e,t,r){switch(process.platform){case"win32":return f("ccache",e);case"darwin":return p("ccache",e);case"linux":return i("ccache",e);default:throw Error("Unsupported platform")}},async doxygen(e,t,r){switch(process.platform){case"win32":{await f("doxygen.install",e),await f("graphviz",e),await d("C:/Program Files/Graphviz/bin");const t="C:/Program Files/doxygen/bin";return await d(t),{binDir:t}}case"darwin":return p("doxygen",e),p("graphviz",e);case"linux":return await i("doxygen",e),i("graphviz",e);default:throw Error("Unsupported platform")}},async cppcheck(e,t,r){switch(process.platform){case"win32":{await f("cppcheck",e);const t="C:/Program Files/Cppcheck";return await d(t),{binDir:t}}case"darwin":return p("cppcheck",e);case"linux":return i("cppcheck",e);default:throw Error("Unsupported platform")}},msvc:B},ar=["cmake","ninja","python","conan","meson","gcovr","opencppcoverage","llvm","gcc","choco","brew","ccache","doxygen","cppcheck","msvc"],lr=["compiler","architecture",...ar];J(process.argv).then((e=>{process.exitCode=e})).catch((e=>{xe.error("main() panicked!"),xe.error(e),process.exitCode=1}));
//# sourceMappingURL=setup_cpp.js.map