mirror of
https://github.com/audacity/audacity-actions.git
synced 2025-12-11 05:46:35 -06:00
16 lines
166 KiB
JavaScript
16 lines
166 KiB
JavaScript
(()=>{var e={5008:(e,t,r)=>{const n=r(2186);const i=r(1514);const o=r(5622);const s=r(1711);const a=r(5747);const c=process.env["CI"];global.workspaceDir=process.env["GITHUB_WORKSPACE"];global.conanCachePath=o.join(workspaceDir,".conan");function log(e){if(c){n.info(e)}else{console.log(e)}}function error(e){if(c){n.error(e)}else{console.error(e)}}async function execWithLog(e,arguments){if(c){return i.exec(e,arguments)}else{return i.exec(e,arguments,{listeners:{stdout:e=>{log(e.toString())},stderr:e=>{error(e.toString())}}})}}async function getExecOutput(e,arguments){if(c){return i.getExecOutput(e,arguments)}else{return i.getExecOutput(e,arguments,{listeners:{stdout:e=>{log(e.toString())},stderr:e=>{error(e.toString())}}})}}async function awaitAll(e,t){return await Promise.all(e.map((async e=>t(e))))}async function getMD5(e){const t=await a.promises.readFile(e);return s(t)}function getDateString(){const e=new Date;return[e.getFullYear(),("0"+(e.getMonth()+1)).slice(-2),("0"+e.getDate()).slice(-2)].join("")}const sleep=e=>new Promise((t=>setTimeout(t,e)));process.on("unhandledRejection",((e,t)=>{error(e);n.setFailed(e);process.exit(1)})).on("uncaughtException",(e=>{error(e);n.setFailed(e);process.exit(1)}));e.exports={log:log,error:error,execWithLog:execWithLog,getExecOutput:getExecOutput,sleep:sleep,awaitAll:awaitAll,getMD5:getMD5,getDateString:getDateString}},582:(e,t,r)=>{const n=r(2186);const i=r(2605);const o=r(7784);const s=r(5747);const a=r(5622);const c=r(5008);const l=a.join(workspaceDir,".offline");const u=a.join(l,"bin");const p=a.join(l,"conan");const d=a.join(p,"download_cache");async function downloadConan(e){const t=await o.downloadTool(`https://github.com/audacity/conan-appimage/releases/download/v${e}/conan-${e}-x86_64.AppImage`);if(!s.existsSync(u)){s.mkdirSync(u,{recursive:true})}const r=a.join(u,"conan");s.copyFileSync(t,r);console.log(`Copied ${t} to ${r}`);s.chmodSync(r,"755");return r}async function prepareEnvironment(){conan=await downloadConan("2.0.7");n.exportVariable("CONAN_HOME",p);n.addPath(u);await c.execWithLog(conan,["config","init"]);await c.execWithLog(conan,["config","set",`storage.download_cache=${d}`]);const e=(await c.getExecOutput(conan,["profile","get","settings.compiler","default"])).stdout.trim();if(e==="gcc"){await c.execWithLog(conan,["profile","update","settings.compiler.libcxx=libstdc++11","default"])}return d}async function upload(){const e=(await c.getExecOutput("git",["show","-s","--format=%h"])).stdout.trim();const t=`audacity-dependencies-${c.getDateString()}+${e}`;const r=`${t}.tar.gz`;await c.execWithLog("tar",["czf",r,"-C",workspaceDir,".offline"]);const n=i.create();await n.uploadArtifact(t,[r],workspaceDir)}e.exports={prepareEnvironment:prepareEnvironment,upload:upload}},2605:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const n=r(8802);function create(){return n.DefaultArtifactClient.create()}t.create=create},8802:function(e,t,r){"use strict";var n=this&&this.__awaiter||function(e,t,r,n){function adopt(e){return e instanceof r?e:new r((function(t){t(e)}))}return new(r||(r=Promise))((function(r,i){function fulfilled(e){try{step(n.next(e))}catch(e){i(e)}}function rejected(e){try{step(n["throw"](e))}catch(e){i(e)}}function step(e){e.done?r(e.value):adopt(e.value).then(fulfilled,rejected)}step((n=n.apply(e,t||[])).next())}))};var i=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(Object.hasOwnProperty.call(e,r))t[r]=e[r];t["default"]=e;return t};Object.defineProperty(t,"__esModule",{value:true});const o=i(r(2186));const s=r(183);const a=r(4354);const c=r(6327);const l=r(8538);const u=r(5686);const p=r(2222);const d=r(5622);class DefaultArtifactClient{static create(){return new DefaultArtifactClient}uploadArtifact(e,t,r,i){return n(this,void 0,void 0,(function*(){c.checkArtifactName(e);const n=s.getUploadSpecification(e,r,t);const l={artifactName:e,artifactItems:[],size:0,failedItems:[]};const u=new a.UploadHttpClient;if(n.length===0){o.warning(`No files found that can be uploaded`)}else{const t=yield u.createArtifactInFileContainer(e,i);if(!t.fileContainerResourceUrl){o.debug(t.toString());throw new Error("No URL provided by the Artifact Service to upload an artifact to")}o.debug(`Upload Resource URL: ${t.fileContainerResourceUrl}`);const r=yield u.uploadArtifactToFileContainer(t.fileContainerResourceUrl,n,i);yield u.patchArtifactSize(r.totalSize,e);o.info(`Finished uploading artifact ${e}. Reported size is ${r.uploadSize} bytes. There were ${r.failedItems.length} items that failed to upload`);l.artifactItems=n.map((e=>e.absoluteFilePath));l.size=r.uploadSize;l.failedItems=r.failedItems}return l}))}downloadArtifact(e,t,r){return n(this,void 0,void 0,(function*(){const n=new l.DownloadHttpClient;const i=yield n.listArtifacts();if(i.count===0){throw new Error(`Unable to find any artifacts for the associated workflow`)}const s=i.value.find((t=>t.name===e));if(!s){throw new Error(`Unable to find an artifact with the name: ${e}`)}const a=yield n.getContainerItems(s.name,s.fileContainerResourceUrl);if(!t){t=p.getWorkSpaceDirectory()}t=d.normalize(t);t=d.resolve(t);const h=u.getDownloadSpecification(e,a.value,t,(r===null||r===void 0?void 0:r.createArtifactFolder)||false);if(h.filesToDownload.length===0){o.info(`No downloadable files were found for the artifact: ${s.name}`)}else{yield c.createDirectoriesForArtifact(h.directoryStructure);o.info("Directory structure has been setup for the artifact");yield c.createEmptyFilesForArtifact(h.emptyFilesToCreate);yield n.downloadSingleArtifact(h.filesToDownload)}return{artifactName:e,downloadPath:h.rootDownloadLocation}}))}downloadAllArtifacts(e){return n(this,void 0,void 0,(function*(){const t=new l.DownloadHttpClient;const r=[];const n=yield t.listArtifacts();if(n.count===0){o.info("Unable to find any artifacts for the associated workflow");return r}if(!e){e=p.getWorkSpaceDirectory()}e=d.normalize(e);e=d.resolve(e);let i=0;while(i<n.count){const s=n.value[i];i+=1;const a=yield t.getContainerItems(s.name,s.fileContainerResourceUrl);const l=u.getDownloadSpecification(s.name,a.value,e,true);if(l.filesToDownload.length===0){o.info(`No downloadable files were found for any artifact ${s.name}`)}else{yield c.createDirectoriesForArtifact(l.directoryStructure);yield c.createEmptyFilesForArtifact(l.emptyFilesToCreate);yield t.downloadSingleArtifact(l.filesToDownload)}r.push({artifactName:s.name,downloadPath:l.rootDownloadLocation})}return r}))}}t.DefaultArtifactClient=DefaultArtifactClient},2222:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});function getUploadFileConcurrency(){return 2}t.getUploadFileConcurrency=getUploadFileConcurrency;function getUploadChunkSize(){return 8*1024*1024}t.getUploadChunkSize=getUploadChunkSize;function getRetryLimit(){return 5}t.getRetryLimit=getRetryLimit;function getRetryMultiplier(){return 1.5}t.getRetryMultiplier=getRetryMultiplier;function getInitialRetryIntervalInMilliseconds(){return 3e3}t.getInitialRetryIntervalInMilliseconds=getInitialRetryIntervalInMilliseconds;function getDownloadFileConcurrency(){return 2}t.getDownloadFileConcurrency=getDownloadFileConcurrency;function getRuntimeToken(){const e=process.env["ACTIONS_RUNTIME_TOKEN"];if(!e){throw new Error("Unable to get ACTIONS_RUNTIME_TOKEN env variable")}return e}t.getRuntimeToken=getRuntimeToken;function getRuntimeUrl(){const e=process.env["ACTIONS_RUNTIME_URL"];if(!e){throw new Error("Unable to get ACTIONS_RUNTIME_URL env variable")}return e}t.getRuntimeUrl=getRuntimeUrl;function getWorkFlowRunId(){const e=process.env["GITHUB_RUN_ID"];if(!e){throw new Error("Unable to get GITHUB_RUN_ID env variable")}return e}t.getWorkFlowRunId=getWorkFlowRunId;function getWorkSpaceDirectory(){const e=process.env["GITHUB_WORKSPACE"];if(!e){throw new Error("Unable to get GITHUB_WORKSPACE env variable")}return e}t.getWorkSpaceDirectory=getWorkSpaceDirectory;function getRetentionDays(){return process.env["GITHUB_RETENTION_DAYS"]}t.getRetentionDays=getRetentionDays},8538:function(e,t,r){"use strict";var n=this&&this.__awaiter||function(e,t,r,n){function adopt(e){return e instanceof r?e:new r((function(t){t(e)}))}return new(r||(r=Promise))((function(r,i){function fulfilled(e){try{step(n.next(e))}catch(e){i(e)}}function rejected(e){try{step(n["throw"](e))}catch(e){i(e)}}function step(e){e.done?r(e.value):adopt(e.value).then(fulfilled,rejected)}step((n=n.apply(e,t||[])).next())}))};var i=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(Object.hasOwnProperty.call(e,r))t[r]=e[r];t["default"]=e;return t};Object.defineProperty(t,"__esModule",{value:true});const o=i(r(5747));const s=i(r(2186));const a=i(r(8761));const c=r(6327);const l=r(8835);const u=r(9081);const p=r(630);const d=r(6527);const h=r(2222);const m=r(755);class DownloadHttpClient{constructor(){this.downloadHttpManager=new d.HttpManager(h.getDownloadFileConcurrency(),"@actions/artifact-download");this.statusReporter=new u.StatusReporter(1e3)}listArtifacts(){return n(this,void 0,void 0,(function*(){const e=c.getArtifactUrl();const t=this.downloadHttpManager.getClient(0);const r=c.getDownloadHeaders("application/json");const i=yield m.retryHttpClientRequest("List Artifacts",(()=>n(this,void 0,void 0,(function*(){return t.get(e,r)}))));const o=yield i.readBody();return JSON.parse(o)}))}getContainerItems(e,t){return n(this,void 0,void 0,(function*(){const r=new l.URL(t);r.searchParams.append("itemPath",e);const i=this.downloadHttpManager.getClient(0);const o=c.getDownloadHeaders("application/json");const s=yield m.retryHttpClientRequest("Get Container Items",(()=>n(this,void 0,void 0,(function*(){return i.get(r.toString(),o)}))));const a=yield s.readBody();return JSON.parse(a)}))}downloadSingleArtifact(e){return n(this,void 0,void 0,(function*(){const t=h.getDownloadFileConcurrency();s.debug(`Download file concurrency is set to ${t}`);const r=[...new Array(t).keys()];let i=0;let o=0;s.info(`Total number of files that will be downloaded: ${e.length}`);this.statusReporter.setTotalNumberOfFilesToProcess(e.length);this.statusReporter.start();yield Promise.all(r.map((t=>n(this,void 0,void 0,(function*(){while(i<e.length){const r=e[i];i+=1;const n=p.performance.now();yield this.downloadIndividualFile(t,r.sourceLocation,r.targetPath);if(s.isDebug()){s.debug(`File: ${++o}/${e.length}. ${r.targetPath} took ${(p.performance.now()-n).toFixed(3)} milliseconds to finish downloading`)}this.statusReporter.incrementProcessedCount()}}))))).catch((e=>{throw new Error(`Unable to download the artifact: ${e}`)})).finally((()=>{this.statusReporter.stop();this.downloadHttpManager.disposeAndReplaceAllClients()}))}))}downloadIndividualFile(e,t,r){return n(this,void 0,void 0,(function*(){let i=0;const a=h.getRetryLimit();let l=o.createWriteStream(r);const u=c.getDownloadHeaders("application/json",true,true);const makeDownloadRequest=()=>n(this,void 0,void 0,(function*(){const r=this.downloadHttpManager.getClient(e);return yield r.get(t,u)}));const isGzip=e=>"content-encoding"in e&&e["content-encoding"]==="gzip";const backOff=r=>n(this,void 0,void 0,(function*(){i++;if(i>a){return Promise.reject(new Error(`Retry limit has been reached. Unable to download ${t}`))}else{this.downloadHttpManager.disposeAndReplaceClient(e);if(r){s.info(`Backoff due to too many requests, retry #${i}. Waiting for ${r} milliseconds before continuing the download`);yield c.sleep(r)}else{const e=c.getExponentialRetryTimeInMilliseconds(i);s.info(`Exponential backoff for retry #${i}. Waiting for ${e} milliseconds before continuing the download`);yield c.sleep(e)}s.info(`Finished backoff for retry #${i}, continuing with download`)}}));const isAllBytesReceived=(e,t)=>{if(!e||!t||process.env["ACTIONS_ARTIFACT_SKIP_DOWNLOAD_VALIDATION"]){s.info("Skipping download validation.");return true}return parseInt(e)===t};const resetDestinationStream=e=>n(this,void 0,void 0,(function*(){l.close();yield c.rmFile(e);l=o.createWriteStream(e)}));while(i<=a){let e;try{e=yield makeDownloadRequest();if(s.isDebug()){c.displayHttpDiagnostics(e)}}catch(e){s.info("An error occurred while attempting to download a file");console.log(e);yield backOff();continue}let n=false;if(c.isSuccessStatusCode(e.message.statusCode)){try{const t=isGzip(e.message.headers);yield this.pipeResponseToFile(e,l,t);if(t||isAllBytesReceived(e.message.headers["content-length"],yield c.getFileSize(r))){return}else{n=true}}catch(e){n=true}}if(n||c.isRetryableStatusCode(e.message.statusCode)){s.info(`A ${e.message.statusCode} response code has been received while attempting to download an artifact`);resetDestinationStream(r);c.isThrottledStatusCode(e.message.statusCode)?yield backOff(c.tryGetRetryAfterValueTimeInMilliseconds(e.message.headers)):yield backOff()}else{c.displayHttpDiagnostics(e);return Promise.reject(new Error(`Unexpected http ${e.message.statusCode} during download for ${t}`))}}}))}pipeResponseToFile(e,t,r){return n(this,void 0,void 0,(function*(){yield new Promise(((n,i)=>{if(r){const r=a.createGunzip();e.message.on("error",(e=>{s.error(`An error occurred while attempting to read the response stream`);r.close();t.close();i(e)})).pipe(r).on("error",(e=>{s.error(`An error occurred while attempting to decompress the response stream`);t.close();i(e)})).pipe(t).on("close",(()=>{n()})).on("error",(e=>{s.error(`An error occurred while writing a downloaded file to ${t.path}`);i(e)}))}else{e.message.on("error",(e=>{s.error(`An error occurred while attempting to read the response stream`);t.close();i(e)})).pipe(t).on("close",(()=>{n()})).on("error",(e=>{s.error(`An error occurred while writing a downloaded file to ${t.path}`);i(e)}))}}));return}))}}t.DownloadHttpClient=DownloadHttpClient},5686:function(e,t,r){"use strict";var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(Object.hasOwnProperty.call(e,r))t[r]=e[r];t["default"]=e;return t};Object.defineProperty(t,"__esModule",{value:true});const i=n(r(5622));function getDownloadSpecification(e,t,r,n){const o=new Set;const s={rootDownloadLocation:n?i.join(r,e):r,directoryStructure:[],emptyFilesToCreate:[],filesToDownload:[]};for(const a of t){if(a.path.startsWith(`${e}/`)||a.path.startsWith(`${e}\\`)){const t=i.normalize(a.path);const c=i.join(r,n?t:t.replace(e,""));if(a.itemType==="file"){o.add(i.dirname(c));if(a.fileLength===0){s.emptyFilesToCreate.push(c)}else{s.filesToDownload.push({sourceLocation:a.contentLocation,targetPath:c})}}}}s.directoryStructure=Array.from(o);return s}t.getDownloadSpecification=getDownloadSpecification},6527:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const n=r(6327);class HttpManager{constructor(e,t){if(e<1){throw new Error("There must be at least one client")}this.userAgent=t;this.clients=new Array(e).fill(n.createHttpClient(t))}getClient(e){return this.clients[e]}disposeAndReplaceClient(e){this.clients[e].dispose();this.clients[e]=n.createHttpClient(this.userAgent)}disposeAndReplaceAllClients(){for(const[e]of this.clients.entries()){this.disposeAndReplaceClient(e)}}}t.HttpManager=HttpManager},755:function(e,t,r){"use strict";var n=this&&this.__awaiter||function(e,t,r,n){function adopt(e){return e instanceof r?e:new r((function(t){t(e)}))}return new(r||(r=Promise))((function(r,i){function fulfilled(e){try{step(n.next(e))}catch(e){i(e)}}function rejected(e){try{step(n["throw"](e))}catch(e){i(e)}}function step(e){e.done?r(e.value):adopt(e.value).then(fulfilled,rejected)}step((n=n.apply(e,t||[])).next())}))};var i=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(Object.hasOwnProperty.call(e,r))t[r]=e[r];t["default"]=e;return t};Object.defineProperty(t,"__esModule",{value:true});const o=r(6327);const s=i(r(2186));const a=r(2222);function retry(e,t,r,i){return n(this,void 0,void 0,(function*(){let n=undefined;let a=undefined;let c=false;let l="";let u=undefined;let p=1;while(p<=i){try{n=yield t();a=n.message.statusCode;if(o.isSuccessStatusCode(a)){return n}if(a){u=r.get(a)}c=o.isRetryableStatusCode(a);l=`Artifact service responded with ${a}`}catch(e){c=true;l=e.message}if(!c){s.info(`${e} - Error is not retryable`);if(n){o.displayHttpDiagnostics(n)}break}s.info(`${e} - Attempt ${p} of ${i} failed with error: ${l}`);yield o.sleep(o.getExponentialRetryTimeInMilliseconds(p));p++}if(n){o.displayHttpDiagnostics(n)}if(u){throw Error(`${e} failed: ${u}`)}throw Error(`${e} failed: ${l}`)}))}t.retry=retry;function retryHttpClientRequest(e,t,r=new Map,i=a.getRetryLimit()){return n(this,void 0,void 0,(function*(){return yield retry(e,t,r,i)}))}t.retryHttpClientRequest=retryHttpClientRequest},9081:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const n=r(2186);class StatusReporter{constructor(e){this.totalNumberOfFilesToProcess=0;this.processedCount=0;this.largeFiles=new Map;this.totalFileStatus=undefined;this.largeFileStatus=undefined;this.displayFrequencyInMilliseconds=e}setTotalNumberOfFilesToProcess(e){this.totalNumberOfFilesToProcess=e}start(){this.totalFileStatus=setInterval((()=>{const e=this.formatPercentage(this.processedCount,this.totalNumberOfFilesToProcess);n.info(`Total file count: ${this.totalNumberOfFilesToProcess} ---- Processed file #${this.processedCount} (${e.slice(0,e.indexOf(".")+2)}%)`)}),this.displayFrequencyInMilliseconds);this.largeFileStatus=setInterval((()=>{for(const e of Array.from(this.largeFiles.values())){n.info(e)}this.largeFiles.clear()}),1e3)}updateLargeFileStatus(e,t,r){const n=this.formatPercentage(t,r);const i=`Uploading ${e} (${n.slice(0,n.indexOf(".")+2)}%)`;this.largeFiles.set(e,i)}stop(){if(this.totalFileStatus){clearInterval(this.totalFileStatus)}if(this.largeFileStatus){clearInterval(this.largeFileStatus)}}incrementProcessedCount(){this.processedCount++}formatPercentage(e,t){return(e/t*100).toFixed(4).toString()}}t.StatusReporter=StatusReporter},606:function(e,t,r){"use strict";var n=this&&this.__awaiter||function(e,t,r,n){function adopt(e){return e instanceof r?e:new r((function(t){t(e)}))}return new(r||(r=Promise))((function(r,i){function fulfilled(e){try{step(n.next(e))}catch(e){i(e)}}function rejected(e){try{step(n["throw"](e))}catch(e){i(e)}}function step(e){e.done?r(e.value):adopt(e.value).then(fulfilled,rejected)}step((n=n.apply(e,t||[])).next())}))};var i=this&&this.__asyncValues||function(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t=e[Symbol.asyncIterator],r;return t?t.call(e):(e=typeof __values==="function"?__values(e):e[Symbol.iterator](),r={},verb("next"),verb("throw"),verb("return"),r[Symbol.asyncIterator]=function(){return this},r);function verb(t){r[t]=e[t]&&function(r){return new Promise((function(n,i){r=e[t](r),settle(n,i,r.done,r.value)}))}}function settle(e,t,r,n){Promise.resolve(n).then((function(t){e({value:t,done:r})}),t)}};var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(Object.hasOwnProperty.call(e,r))t[r]=e[r];t["default"]=e;return t};Object.defineProperty(t,"__esModule",{value:true});const s=o(r(5747));const a=o(r(8761));const c=r(1669);const l=c.promisify(s.stat);function createGZipFileOnDisk(e,t){return n(this,void 0,void 0,(function*(){return new Promise(((r,i)=>{const o=s.createReadStream(e);const c=a.createGzip();const u=s.createWriteStream(t);o.pipe(c).pipe(u);u.on("finish",(()=>n(this,void 0,void 0,(function*(){const e=(yield l(t)).size;r(e)}))));u.on("error",(e=>{console.log(e);i}))}))}))}t.createGZipFileOnDisk=createGZipFileOnDisk;function createGZipFileInBuffer(e){return n(this,void 0,void 0,(function*(){return new Promise((t=>n(this,void 0,void 0,(function*(){var r,n;const o=s.createReadStream(e);const c=a.createGzip();o.pipe(c);const l=[];try{for(var u=i(c),p;p=yield u.next(),!p.done;){const e=p.value;l.push(e)}}catch(e){r={error:e}}finally{try{if(p&&!p.done&&(n=u.return))yield n.call(u)}finally{if(r)throw r.error}}t(Buffer.concat(l))}))))}))}t.createGZipFileInBuffer=createGZipFileInBuffer},4354:function(e,t,r){"use strict";var n=this&&this.__awaiter||function(e,t,r,n){function adopt(e){return e instanceof r?e:new r((function(t){t(e)}))}return new(r||(r=Promise))((function(r,i){function fulfilled(e){try{step(n.next(e))}catch(e){i(e)}}function rejected(e){try{step(n["throw"](e))}catch(e){i(e)}}function step(e){e.done?r(e.value):adopt(e.value).then(fulfilled,rejected)}step((n=n.apply(e,t||[])).next())}))};var i=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(Object.hasOwnProperty.call(e,r))t[r]=e[r];t["default"]=e;return t};Object.defineProperty(t,"__esModule",{value:true});const o=i(r(5747));const s=i(r(2186));const a=i(r(8065));const c=i(r(2413));const l=r(6327);const u=r(2222);const p=r(1669);const d=r(8835);const h=r(630);const m=r(9081);const g=r(9925);const v=r(6527);const y=r(606);const E=r(755);const w=p.promisify(o.stat);class UploadHttpClient{constructor(){this.uploadHttpManager=new v.HttpManager(u.getUploadFileConcurrency(),"@actions/artifact-upload");this.statusReporter=new m.StatusReporter(1e4)}createArtifactInFileContainer(e,t){return n(this,void 0,void 0,(function*(){const r={Type:"actions_storage",Name:e};if(t&&t.retentionDays){const e=u.getRetentionDays();r.RetentionDays=l.getProperRetention(t.retentionDays,e)}const i=JSON.stringify(r,null,2);const o=l.getArtifactUrl();const s=this.uploadHttpManager.getClient(0);const a=l.getUploadHeaders("application/json",false);const c=new Map([[g.HttpCodes.Forbidden,"Artifact storage quota has been hit. Unable to upload any new artifacts"],[g.HttpCodes.BadRequest,`The artifact name ${e} is not valid. Request URL ${o}`]]);const p=yield E.retryHttpClientRequest("Create Artifact Container",(()=>n(this,void 0,void 0,(function*(){return s.post(o,i,a)}))),c);const d=yield p.readBody();return JSON.parse(d)}))}uploadArtifactToFileContainer(e,t,r){return n(this,void 0,void 0,(function*(){const i=u.getUploadFileConcurrency();const o=u.getUploadChunkSize();s.debug(`File Concurrency: ${i}, and Chunk Size: ${o}`);const a=[];let c=true;if(r){if(r.continueOnError===false){c=false}}for(const r of t){const t=new d.URL(e);t.searchParams.append("itemPath",r.uploadFilePath);a.push({file:r.absoluteFilePath,resourceUrl:t.toString(),maxChunkSize:o,continueOnError:c})}const l=[...new Array(i).keys()];const p=[];let m=0;let g=0;let v=0;let y=0;let E=false;this.statusReporter.setTotalNumberOfFilesToProcess(t.length);this.statusReporter.start();yield Promise.all(l.map((e=>n(this,void 0,void 0,(function*(){while(m<t.length){const r=a[m];m+=1;if(E){p.push(r.file);continue}const n=h.performance.now();const i=yield this.uploadFileAsync(e,r);if(s.isDebug()){s.debug(`File: ${++g}/${t.length}. ${r.file} took ${(h.performance.now()-n).toFixed(3)} milliseconds to finish upload`)}v+=i.successfulUploadSize;y+=i.totalSize;if(i.isSuccess===false){p.push(r.file);if(!c){s.error(`aborting artifact upload`);E=true}}this.statusReporter.incrementProcessedCount()}})))));this.statusReporter.stop();this.uploadHttpManager.disposeAndReplaceAllClients();s.info(`Total size of all the files uploaded is ${v} bytes`);return{uploadSize:v,totalSize:y,failedItems:p}}))}uploadFileAsync(e,t){return n(this,void 0,void 0,(function*(){const r=(yield w(t.file)).size;let n=0;let i=true;let l=0;let u=0;let p=true;if(r<65536){const n=yield y.createGZipFileInBuffer(t.file);let a;if(r<n.byteLength){a=()=>o.createReadStream(t.file);p=false;u=r}else{a=()=>{const e=new c.PassThrough;e.end(n);return e};u=n.byteLength}const d=yield this.uploadChunk(e,t.resourceUrl,a,0,u-1,u,p,r);if(!d){i=false;l+=u;s.warning(`Aborting upload for ${t.file} due to failure`)}return{isSuccess:i,successfulUploadSize:u-l,totalSize:r}}else{const c=yield a.file();u=yield y.createGZipFileOnDisk(t.file,c.path);let d=c.path;if(r<u){u=r;d=t.file;p=false}let h=false;while(n<u){const a=Math.min(u-n,t.maxChunkSize);if(u>104857600){this.statusReporter.updateLargeFileStatus(t.file,n,u)}const c=n;const m=n+a-1;n+=t.maxChunkSize;if(h){l+=a;continue}const g=yield this.uploadChunk(e,t.resourceUrl,(()=>o.createReadStream(d,{start:c,end:m,autoClose:false})),c,m,u,p,r);if(!g){i=false;l+=a;s.warning(`Aborting upload for ${t.file} due to failure`);h=true}}yield c.cleanup();return{isSuccess:i,successfulUploadSize:u-l,totalSize:r}}}))}uploadChunk(e,t,r,i,o,a,c,p){return n(this,void 0,void 0,(function*(){const d=l.getUploadHeaders("application/octet-stream",true,c,p,o-i+1,l.getContentRange(i,o,a));const uploadChunkRequest=()=>n(this,void 0,void 0,(function*(){const n=this.uploadHttpManager.getClient(e);return yield n.sendStream("PUT",t,r(),d)}));let h=0;const m=u.getRetryLimit();const incrementAndCheckRetryLimit=e=>{h++;if(h>m){if(e){l.displayHttpDiagnostics(e)}s.info(`Retry limit has been reached for chunk at offset ${i} to ${t}`);return true}return false};const backOff=t=>n(this,void 0,void 0,(function*(){this.uploadHttpManager.disposeAndReplaceClient(e);if(t){s.info(`Backoff due to too many requests, retry #${h}. Waiting for ${t} milliseconds before continuing the upload`);yield l.sleep(t)}else{const e=l.getExponentialRetryTimeInMilliseconds(h);s.info(`Exponential backoff for retry #${h}. Waiting for ${e} milliseconds before continuing the upload at offset ${i}`);yield l.sleep(e)}s.info(`Finished backoff for retry #${h}, continuing with upload`);return}));while(h<=m){let r;try{r=yield uploadChunkRequest()}catch(t){s.info(`An error has been caught http-client index ${e}, retrying the upload`);console.log(t);if(incrementAndCheckRetryLimit()){return false}yield backOff();continue}yield r.readBody();if(l.isSuccessStatusCode(r.message.statusCode)){return true}else if(l.isRetryableStatusCode(r.message.statusCode)){s.info(`A ${r.message.statusCode} status code has been received, will attempt to retry the upload`);if(incrementAndCheckRetryLimit(r)){return false}l.isThrottledStatusCode(r.message.statusCode)?yield backOff(l.tryGetRetryAfterValueTimeInMilliseconds(r.message.headers)):yield backOff()}else{s.error(`Unexpected response. Unable to upload chunk to ${t}`);l.displayHttpDiagnostics(r);return false}}return false}))}patchArtifactSize(e,t){return n(this,void 0,void 0,(function*(){const r=new d.URL(l.getArtifactUrl());r.searchParams.append("artifactName",t);const i={Size:e};const o=JSON.stringify(i,null,2);s.debug(`URL is ${r.toString()}`);const a=this.uploadHttpManager.getClient(0);const c=l.getUploadHeaders("application/json",false);const u=new Map([[g.HttpCodes.NotFound,`An Artifact with the name ${t} was not found`]]);const p=yield E.retryHttpClientRequest("Finalize artifact upload",(()=>n(this,void 0,void 0,(function*(){return a.patch(r.toString(),o,c)}))),u);yield p.readBody();s.debug(`Artifact ${t} has been successfully uploaded, total size in bytes: ${e}`)}))}}t.UploadHttpClient=UploadHttpClient},183:function(e,t,r){"use strict";var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(Object.hasOwnProperty.call(e,r))t[r]=e[r];t["default"]=e;return t};Object.defineProperty(t,"__esModule",{value:true});const i=n(r(5747));const o=r(2186);const s=r(5622);const a=r(6327);function getUploadSpecification(e,t,r){a.checkArtifactName(e);const n=[];if(!i.existsSync(t)){throw new Error(`Provided rootDirectory ${t} does not exist`)}if(!i.lstatSync(t).isDirectory()){throw new Error(`Provided rootDirectory ${t} is not a valid directory`)}t=s.normalize(t);t=s.resolve(t);for(let c of r){if(!i.existsSync(c)){throw new Error(`File ${c} does not exist`)}if(!i.lstatSync(c).isDirectory()){c=s.normalize(c);c=s.resolve(c);if(!c.startsWith(t)){throw new Error(`The rootDirectory: ${t} is not a parent directory of the file: ${c}`)}const r=c.replace(t,"");a.checkArtifactFilePath(r);n.push({absoluteFilePath:c,uploadFilePath:s.join(e,r)})}else{o.debug(`Removing ${c} from rawSearchResults because it is a directory`)}}return n}t.getUploadSpecification=getUploadSpecification},6327:function(e,t,r){"use strict";var n=this&&this.__awaiter||function(e,t,r,n){function adopt(e){return e instanceof r?e:new r((function(t){t(e)}))}return new(r||(r=Promise))((function(r,i){function fulfilled(e){try{step(n.next(e))}catch(e){i(e)}}function rejected(e){try{step(n["throw"](e))}catch(e){i(e)}}function step(e){e.done?r(e.value):adopt(e.value).then(fulfilled,rejected)}step((n=n.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});const i=r(2186);const o=r(5747);const s=r(9925);const a=r(3702);const c=r(2222);function getExponentialRetryTimeInMilliseconds(e){if(e<0){throw new Error("RetryCount should not be negative")}else if(e===0){return c.getInitialRetryIntervalInMilliseconds()}const t=c.getInitialRetryIntervalInMilliseconds()*c.getRetryMultiplier()*e;const r=t*c.getRetryMultiplier();return Math.random()*(r-t)+t}t.getExponentialRetryTimeInMilliseconds=getExponentialRetryTimeInMilliseconds;function parseEnvNumber(e){const t=Number(process.env[e]);if(Number.isNaN(t)||t<0){return undefined}return t}t.parseEnvNumber=parseEnvNumber;function getApiVersion(){return"6.0-preview"}t.getApiVersion=getApiVersion;function isSuccessStatusCode(e){if(!e){return false}return e>=200&&e<300}t.isSuccessStatusCode=isSuccessStatusCode;function isForbiddenStatusCode(e){if(!e){return false}return e===s.HttpCodes.Forbidden}t.isForbiddenStatusCode=isForbiddenStatusCode;function isRetryableStatusCode(e){if(!e){return false}const t=[s.HttpCodes.BadGateway,s.HttpCodes.GatewayTimeout,s.HttpCodes.InternalServerError,s.HttpCodes.ServiceUnavailable,s.HttpCodes.TooManyRequests,413];return t.includes(e)}t.isRetryableStatusCode=isRetryableStatusCode;function isThrottledStatusCode(e){if(!e){return false}return e===s.HttpCodes.TooManyRequests}t.isThrottledStatusCode=isThrottledStatusCode;function tryGetRetryAfterValueTimeInMilliseconds(e){if(e["retry-after"]){const t=Number(e["retry-after"]);if(!isNaN(t)){i.info(`Retry-After header is present with a value of ${t}`);return t*1e3}i.info(`Returned retry-after header value: ${t} is non-numeric and cannot be used`);return undefined}i.info(`No retry-after header was found. Dumping all headers for diagnostic purposes`);console.log(e);return undefined}t.tryGetRetryAfterValueTimeInMilliseconds=tryGetRetryAfterValueTimeInMilliseconds;function getContentRange(e,t,r){return`bytes ${e}-${t}/${r}`}t.getContentRange=getContentRange;function getDownloadHeaders(e,t,r){const n={};if(e){n["Content-Type"]=e}if(t){n["Connection"]="Keep-Alive";n["Keep-Alive"]="10"}if(r){n["Accept-Encoding"]="gzip";n["Accept"]=`application/octet-stream;api-version=${getApiVersion()}`}else{n["Accept"]=`application/json;api-version=${getApiVersion()}`}return n}t.getDownloadHeaders=getDownloadHeaders;function getUploadHeaders(e,t,r,n,i,o){const s={};s["Accept"]=`application/json;api-version=${getApiVersion()}`;if(e){s["Content-Type"]=e}if(t){s["Connection"]="Keep-Alive";s["Keep-Alive"]="10"}if(r){s["Content-Encoding"]="gzip";s["x-tfs-filelength"]=n}if(i){s["Content-Length"]=i}if(o){s["Content-Range"]=o}return s}t.getUploadHeaders=getUploadHeaders;function createHttpClient(e){return new s.HttpClient(e,[new a.BearerCredentialHandler(c.getRuntimeToken())])}t.createHttpClient=createHttpClient;function getArtifactUrl(){const e=`${c.getRuntimeUrl()}_apis/pipelines/workflows/${c.getWorkFlowRunId()}/artifacts?api-version=${getApiVersion()}`;i.debug(`Artifact Url: ${e}`);return e}t.getArtifactUrl=getArtifactUrl;function displayHttpDiagnostics(e){i.info(`##### Begin Diagnostic HTTP information #####\nStatus Code: ${e.message.statusCode}\nStatus Message: ${e.message.statusMessage}\nHeader Information: ${JSON.stringify(e.message.headers,undefined,2)}\n###### End Diagnostic HTTP information ######`)}t.displayHttpDiagnostics=displayHttpDiagnostics;const l=['"',":","<",">","|","*","?"];const u=[...l,"\\","/"];function checkArtifactName(e){if(!e){throw new Error(`Artifact name: ${e}, is incorrectly provided`)}for(const t of u){if(e.includes(t)){throw new Error(`Artifact name is not valid: ${e}. Contains character: "${t}". Invalid artifact name characters include: ${u.toString()}.`)}}}t.checkArtifactName=checkArtifactName;function checkArtifactFilePath(e){if(!e){throw new Error(`Artifact path: ${e}, is incorrectly provided`)}for(const t of l){if(e.includes(t)){throw new Error(`Artifact path is not valid: ${e}. Contains character: "${t}". Invalid characters include: ${l.toString()}.`)}}}t.checkArtifactFilePath=checkArtifactFilePath;function createDirectoriesForArtifact(e){return n(this,void 0,void 0,(function*(){for(const t of e){yield o.promises.mkdir(t,{recursive:true})}}))}t.createDirectoriesForArtifact=createDirectoriesForArtifact;function createEmptyFilesForArtifact(e){return n(this,void 0,void 0,(function*(){for(const t of e){yield(yield o.promises.open(t,"w")).close()}}))}t.createEmptyFilesForArtifact=createEmptyFilesForArtifact;function getFileSize(e){return n(this,void 0,void 0,(function*(){const t=yield o.promises.stat(e);i.debug(`${e} size:(${t.size}) blksize:(${t.blksize}) blocks:(${t.blocks})`);return t.size}))}t.getFileSize=getFileSize;function rmFile(e){return n(this,void 0,void 0,(function*(){yield o.promises.unlink(e)}))}t.rmFile=rmFile;function getProperRetention(e,t){if(e<0){throw new Error("Invalid retention, minimum value is 1.")}let r=e;if(t){const e=parseInt(t);if(!isNaN(e)&&e<r){i.warning(`Retention days is greater than the max value allowed by the repository setting, reduce retention to ${e} days`);r=e}}return r}t.getProperRetention=getProperRetention;function sleep(e){return n(this,void 0,void 0,(function*(){return new Promise((t=>setTimeout(t,e)))}))}t.sleep=sleep},7351:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){if(n===undefined)n=r;Object.defineProperty(e,n,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,n){if(n===undefined)n=r;e[n]=t[r]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))n(t,e,r);i(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.issue=t.issueCommand=void 0;const s=o(r(2087));const a=r(5278);function issueCommand(e,t,r){const n=new Command(e,t,r);process.stdout.write(n.toString()+s.EOL)}t.issueCommand=issueCommand;function issue(e,t=""){issueCommand(e,{},t)}t.issue=issue;const c="::";class Command{constructor(e,t,r){if(!e){e="missing.command"}this.command=e;this.properties=t;this.message=r}toString(){let e=c+this.command;if(this.properties&&Object.keys(this.properties).length>0){e+=" ";let t=true;for(const r in this.properties){if(this.properties.hasOwnProperty(r)){const n=this.properties[r];if(n){if(t){t=false}else{e+=","}e+=`${r}=${escapeProperty(n)}`}}}}e+=`${c}${escapeData(this.message)}`;return e}}function escapeData(e){return a.toCommandValue(e).replace(/%/g,"%25").replace(/\r/g,"%0D").replace(/\n/g,"%0A")}function escapeProperty(e){return a.toCommandValue(e).replace(/%/g,"%25").replace(/\r/g,"%0D").replace(/\n/g,"%0A").replace(/:/g,"%3A").replace(/,/g,"%2C")}},2186:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){if(n===undefined)n=r;Object.defineProperty(e,n,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,n){if(n===undefined)n=r;e[n]=t[r]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))n(t,e,r);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,r,n){function adopt(e){return e instanceof r?e:new r((function(t){t(e)}))}return new(r||(r=Promise))((function(r,i){function fulfilled(e){try{step(n.next(e))}catch(e){i(e)}}function rejected(e){try{step(n["throw"](e))}catch(e){i(e)}}function step(e){e.done?r(e.value):adopt(e.value).then(fulfilled,rejected)}step((n=n.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.getIDToken=t.getState=t.saveState=t.group=t.endGroup=t.startGroup=t.info=t.notice=t.warning=t.error=t.debug=t.isDebug=t.setFailed=t.setCommandEcho=t.setOutput=t.getBooleanInput=t.getMultilineInput=t.getInput=t.addPath=t.setSecret=t.exportVariable=t.ExitCode=void 0;const a=r(7351);const c=r(717);const l=r(5278);const u=o(r(2087));const p=o(r(5622));const d=r(8041);var h;(function(e){e[e["Success"]=0]="Success";e[e["Failure"]=1]="Failure"})(h=t.ExitCode||(t.ExitCode={}));function exportVariable(e,t){const r=l.toCommandValue(t);process.env[e]=r;const n=process.env["GITHUB_ENV"]||"";if(n){const t="_GitHubActionsFileCommandDelimeter_";const n=`${e}<<${t}${u.EOL}${r}${u.EOL}${t}`;c.issueCommand("ENV",n)}else{a.issueCommand("set-env",{name:e},r)}}t.exportVariable=exportVariable;function setSecret(e){a.issueCommand("add-mask",{},e)}t.setSecret=setSecret;function addPath(e){const t=process.env["GITHUB_PATH"]||"";if(t){c.issueCommand("PATH",e)}else{a.issueCommand("add-path",{},e)}process.env["PATH"]=`${e}${p.delimiter}${process.env["PATH"]}`}t.addPath=addPath;function getInput(e,t){const r=process.env[`INPUT_${e.replace(/ /g,"_").toUpperCase()}`]||"";if(t&&t.required&&!r){throw new Error(`Input required and not supplied: ${e}`)}if(t&&t.trimWhitespace===false){return r}return r.trim()}t.getInput=getInput;function getMultilineInput(e,t){const r=getInput(e,t).split("\n").filter((e=>e!==""));return r}t.getMultilineInput=getMultilineInput;function getBooleanInput(e,t){const r=["true","True","TRUE"];const n=["false","False","FALSE"];const i=getInput(e,t);if(r.includes(i))return true;if(n.includes(i))return false;throw new TypeError(`Input does not meet YAML 1.2 "Core Schema" specification: ${e}\n`+`Support boolean input list: \`true | True | TRUE | false | False | FALSE\``)}t.getBooleanInput=getBooleanInput;function setOutput(e,t){process.stdout.write(u.EOL);a.issueCommand("set-output",{name:e},t)}t.setOutput=setOutput;function setCommandEcho(e){a.issue("echo",e?"on":"off")}t.setCommandEcho=setCommandEcho;function setFailed(e){process.exitCode=h.Failure;error(e)}t.setFailed=setFailed;function isDebug(){return process.env["RUNNER_DEBUG"]==="1"}t.isDebug=isDebug;function debug(e){a.issueCommand("debug",{},e)}t.debug=debug;function error(e,t={}){a.issueCommand("error",l.toCommandProperties(t),e instanceof Error?e.toString():e)}t.error=error;function warning(e,t={}){a.issueCommand("warning",l.toCommandProperties(t),e instanceof Error?e.toString():e)}t.warning=warning;function notice(e,t={}){a.issueCommand("notice",l.toCommandProperties(t),e instanceof Error?e.toString():e)}t.notice=notice;function info(e){process.stdout.write(e+u.EOL)}t.info=info;function startGroup(e){a.issue("group",e)}t.startGroup=startGroup;function endGroup(){a.issue("endgroup")}t.endGroup=endGroup;function group(e,t){return s(this,void 0,void 0,(function*(){startGroup(e);let r;try{r=yield t()}finally{endGroup()}return r}))}t.group=group;function saveState(e,t){a.issueCommand("save-state",{name:e},t)}t.saveState=saveState;function getState(e){return process.env[`STATE_${e}`]||""}t.getState=getState;function getIDToken(e){return s(this,void 0,void 0,(function*(){return yield d.OidcClient.getIDToken(e)}))}t.getIDToken=getIDToken},717:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){if(n===undefined)n=r;Object.defineProperty(e,n,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,n){if(n===undefined)n=r;e[n]=t[r]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))n(t,e,r);i(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.issueCommand=void 0;const s=o(r(5747));const a=o(r(2087));const c=r(5278);function issueCommand(e,t){const r=process.env[`GITHUB_${e}`];if(!r){throw new Error(`Unable to find environment variable for file command ${e}`)}if(!s.existsSync(r)){throw new Error(`Missing file at path: ${r}`)}s.appendFileSync(r,`${c.toCommandValue(t)}${a.EOL}`,{encoding:"utf8"})}t.issueCommand=issueCommand},8041:function(e,t,r){"use strict";var n=this&&this.__awaiter||function(e,t,r,n){function adopt(e){return e instanceof r?e:new r((function(t){t(e)}))}return new(r||(r=Promise))((function(r,i){function fulfilled(e){try{step(n.next(e))}catch(e){i(e)}}function rejected(e){try{step(n["throw"](e))}catch(e){i(e)}}function step(e){e.done?r(e.value):adopt(e.value).then(fulfilled,rejected)}step((n=n.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.OidcClient=void 0;const i=r(9925);const o=r(3702);const s=r(2186);class OidcClient{static createHttpClient(e=true,t=10){const r={allowRetries:e,maxRetries:t};return new i.HttpClient("actions/oidc-client",[new o.BearerCredentialHandler(OidcClient.getRequestToken())],r)}static getRequestToken(){const e=process.env["ACTIONS_ID_TOKEN_REQUEST_TOKEN"];if(!e){throw new Error("Unable to get ACTIONS_ID_TOKEN_REQUEST_TOKEN env variable")}return e}static getIDTokenUrl(){const e=process.env["ACTIONS_ID_TOKEN_REQUEST_URL"];if(!e){throw new Error("Unable to get ACTIONS_ID_TOKEN_REQUEST_URL env variable")}return e}static getCall(e){var t;return n(this,void 0,void 0,(function*(){const r=OidcClient.createHttpClient();const n=yield r.getJson(e).catch((e=>{throw new Error(`Failed to get ID Token. \n \n Error Code : ${e.statusCode}\n \n Error Message: ${e.result.message}`)}));const i=(t=n.result)===null||t===void 0?void 0:t.value;if(!i){throw new Error("Response json body do not have ID Token field")}return i}))}static getIDToken(e){return n(this,void 0,void 0,(function*(){try{let t=OidcClient.getIDTokenUrl();if(e){const r=encodeURIComponent(e);t=`${t}&audience=${r}`}s.debug(`ID token url is ${t}`);const r=yield OidcClient.getCall(t);s.setSecret(r);return r}catch(e){throw new Error(`Error message: ${e.message}`)}}))}}t.OidcClient=OidcClient},5278:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.toCommandProperties=t.toCommandValue=void 0;function toCommandValue(e){if(e===null||e===undefined){return""}else if(typeof e==="string"||e instanceof String){return e}return JSON.stringify(e)}t.toCommandValue=toCommandValue;function toCommandProperties(e){if(!Object.keys(e).length){return{}}return{title:e.title,file:e.file,line:e.startLine,endLine:e.endLine,col:e.startColumn,endColumn:e.endColumn}}t.toCommandProperties=toCommandProperties},1514:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){if(n===undefined)n=r;Object.defineProperty(e,n,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,n){if(n===undefined)n=r;e[n]=t[r]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))n(t,e,r);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,r,n){function adopt(e){return e instanceof r?e:new r((function(t){t(e)}))}return new(r||(r=Promise))((function(r,i){function fulfilled(e){try{step(n.next(e))}catch(e){i(e)}}function rejected(e){try{step(n["throw"](e))}catch(e){i(e)}}function step(e){e.done?r(e.value):adopt(e.value).then(fulfilled,rejected)}step((n=n.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.getExecOutput=t.exec=void 0;const a=r(4304);const c=o(r(8159));function exec(e,t,r){return s(this,void 0,void 0,(function*(){const n=c.argStringToArray(e);if(n.length===0){throw new Error(`Parameter 'commandLine' cannot be null or empty.`)}const i=n[0];t=n.slice(1).concat(t||[]);const o=new c.ToolRunner(i,t,r);return o.exec()}))}t.exec=exec;function getExecOutput(e,t,r){var n,i;return s(this,void 0,void 0,(function*(){let o="";let s="";const c=new a.StringDecoder("utf8");const l=new a.StringDecoder("utf8");const u=(n=r===null||r===void 0?void 0:r.listeners)===null||n===void 0?void 0:n.stdout;const p=(i=r===null||r===void 0?void 0:r.listeners)===null||i===void 0?void 0:i.stderr;const stdErrListener=e=>{s+=l.write(e);if(p){p(e)}};const stdOutListener=e=>{o+=c.write(e);if(u){u(e)}};const d=Object.assign(Object.assign({},r===null||r===void 0?void 0:r.listeners),{stdout:stdOutListener,stderr:stdErrListener});const h=yield exec(e,t,Object.assign(Object.assign({},r),{listeners:d}));o+=c.end();s+=l.end();return{exitCode:h,stdout:o,stderr:s}}))}t.getExecOutput=getExecOutput},8159:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){if(n===undefined)n=r;Object.defineProperty(e,n,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,n){if(n===undefined)n=r;e[n]=t[r]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))n(t,e,r);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,r,n){function adopt(e){return e instanceof r?e:new r((function(t){t(e)}))}return new(r||(r=Promise))((function(r,i){function fulfilled(e){try{step(n.next(e))}catch(e){i(e)}}function rejected(e){try{step(n["throw"](e))}catch(e){i(e)}}function step(e){e.done?r(e.value):adopt(e.value).then(fulfilled,rejected)}step((n=n.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.argStringToArray=t.ToolRunner=void 0;const a=o(r(2087));const c=o(r(8614));const l=o(r(3129));const u=o(r(5622));const p=o(r(7436));const d=o(r(1962));const h=r(8213);const m=process.platform==="win32";class ToolRunner extends c.EventEmitter{constructor(e,t,r){super();if(!e){throw new Error("Parameter 'toolPath' cannot be null or empty.")}this.toolPath=e;this.args=t||[];this.options=r||{}}_debug(e){if(this.options.listeners&&this.options.listeners.debug){this.options.listeners.debug(e)}}_getCommandString(e,t){const r=this._getSpawnFileName();const n=this._getSpawnArgs(e);let i=t?"":"[command]";if(m){if(this._isCmdFile()){i+=r;for(const e of n){i+=` ${e}`}}else if(e.windowsVerbatimArguments){i+=`"${r}"`;for(const e of n){i+=` ${e}`}}else{i+=this._windowsQuoteCmdArg(r);for(const e of n){i+=` ${this._windowsQuoteCmdArg(e)}`}}}else{i+=r;for(const e of n){i+=` ${e}`}}return i}_processLineBuffer(e,t,r){try{let n=t+e.toString();let i=n.indexOf(a.EOL);while(i>-1){const e=n.substring(0,i);r(e);n=n.substring(i+a.EOL.length);i=n.indexOf(a.EOL)}return n}catch(e){this._debug(`error processing line. Failed with error ${e}`);return""}}_getSpawnFileName(){if(m){if(this._isCmdFile()){return process.env["COMSPEC"]||"cmd.exe"}}return this.toolPath}_getSpawnArgs(e){if(m){if(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)}t+='"';return[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=false;for(const n of e){if(t.some((e=>e===n))){r=true;break}}if(!r){return e}let n='"';let i=true;for(let t=e.length;t>0;t--){n+=e[t-1];if(i&&e[t-1]==="\\"){n+="\\"}else if(e[t-1]==='"'){i=true;n+='"'}else{i=false}}n+='"';return n.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='"';let r=true;for(let n=e.length;n>0;n--){t+=e[n-1];if(r&&e[n-1]==="\\"){t+="\\"}else if(e[n-1]==='"'){r=true;t+="\\"}else{r=false}}t+='"';return t.split("").reverse().join("")}_cloneExecOptions(e){e=e||{};const t={cwd:e.cwd||process.cwd(),env:e.env||process.env,silent:e.silent||false,windowsVerbatimArguments:e.windowsVerbatimArguments||false,failOnStdErr:e.failOnStdErr||false,ignoreReturnCode:e.ignoreReturnCode||false,delay:e.delay||1e4};t.outStream=e.outStream||process.stdout;t.errStream=e.errStream||process.stderr;return t}_getSpawnOptions(e,t){e=e||{};const r={};r.cwd=e.cwd;r.env=e.env;r["windowsVerbatimArguments"]=e.windowsVerbatimArguments||this._isCmdFile();if(e.windowsVerbatimArguments){r.argv0=`"${t}"`}return r}exec(){return s(this,void 0,void 0,(function*(){if(!d.isRooted(this.toolPath)&&(this.toolPath.includes("/")||m&&this.toolPath.includes("\\"))){this.toolPath=u.resolve(process.cwd(),this.options.cwd||process.cwd(),this.toolPath)}this.toolPath=yield p.which(this.toolPath,true);return new Promise(((e,t)=>s(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);if(!r.silent&&r.outStream){r.outStream.write(this._getCommandString(r)+a.EOL)}const n=new ExecState(r,this.toolPath);n.on("debug",(e=>{this._debug(e)}));if(this.options.cwd&&!(yield d.exists(this.options.cwd))){return t(new Error(`The cwd: ${this.options.cwd} does not exist!`))}const i=this._getSpawnFileName();const o=l.spawn(i,this._getSpawnArgs(r),this._getSpawnOptions(this.options,i));let s="";if(o.stdout){o.stdout.on("data",(e=>{if(this.options.listeners&&this.options.listeners.stdout){this.options.listeners.stdout(e)}if(!r.silent&&r.outStream){r.outStream.write(e)}s=this._processLineBuffer(e,s,(e=>{if(this.options.listeners&&this.options.listeners.stdline){this.options.listeners.stdline(e)}}))}))}let c="";if(o.stderr){o.stderr.on("data",(e=>{n.processStderr=true;if(this.options.listeners&&this.options.listeners.stderr){this.options.listeners.stderr(e)}if(!r.silent&&r.errStream&&r.outStream){const t=r.failOnStdErr?r.errStream:r.outStream;t.write(e)}c=this._processLineBuffer(e,c,(e=>{if(this.options.listeners&&this.options.listeners.errline){this.options.listeners.errline(e)}}))}))}o.on("error",(e=>{n.processError=e.message;n.processExited=true;n.processClosed=true;n.CheckComplete()}));o.on("exit",(e=>{n.processExitCode=e;n.processExited=true;this._debug(`Exit code ${e} received from tool '${this.toolPath}'`);n.CheckComplete()}));o.on("close",(e=>{n.processExitCode=e;n.processExited=true;n.processClosed=true;this._debug(`STDIO streams have closed for tool '${this.toolPath}'`);n.CheckComplete()}));n.on("done",((r,n)=>{if(s.length>0){this.emit("stdline",s)}if(c.length>0){this.emit("errline",c)}o.removeAllListeners();if(r){t(r)}else{e(n)}}));if(this.options.input){if(!o.stdin){throw new Error("child process missing stdin")}o.stdin.end(this.options.input)}}))))}))}}t.ToolRunner=ToolRunner;function argStringToArray(e){const t=[];let r=false;let n=false;let i="";function append(e){if(n&&e!=='"'){i+="\\"}i+=e;n=false}for(let o=0;o<e.length;o++){const s=e.charAt(o);if(s==='"'){if(!n){r=!r}else{append(s)}continue}if(s==="\\"&&n){append(s);continue}if(s==="\\"&&r){n=true;continue}if(s===" "&&!r){if(i.length>0){t.push(i);i=""}continue}append(s)}if(i.length>0){t.push(i.trim())}return t}t.argStringToArray=argStringToArray;class ExecState extends c.EventEmitter{constructor(e,t){super();this.processClosed=false;this.processError="";this.processExitCode=0;this.processExited=false;this.processStderr=false;this.delay=1e4;this.done=false;this.timeout=null;if(!t){throw new Error("toolPath must not be empty")}this.options=e;this.toolPath=t;if(e.delay){this.delay=e.delay}}CheckComplete(){if(this.done){return}if(this.processClosed){this._setResult()}else if(this.processExited){this.timeout=h.setTimeout(ExecState.HandleTimeout,this.delay,this)}}_debug(e){this.emit("debug",e)}_setResult(){let e;if(this.processExited){if(this.processError){e=new Error(`There was an error when attempting to execute the process '${this.toolPath}'. This may indicate the process failed to start. Error: ${this.processError}`)}else if(this.processExitCode!==0&&!this.options.ignoreReturnCode){e=new Error(`The process '${this.toolPath}' failed with exit code ${this.processExitCode}`)}else if(this.processStderr&&this.options.failOnStdErr){e=new Error(`The process '${this.toolPath}' failed because one or more lines were written to the STDERR stream`)}}if(this.timeout){clearTimeout(this.timeout);this.timeout=null}this.done=true;this.emit("done",e,this.processExitCode)}static HandleTimeout(e){if(e.done){return}if(!e.processClosed&&e.processExited){const t=`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._debug(t)}e._setResult()}}},3702:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});class BasicCredentialHandler{constructor(e,t){this.username=e;this.password=t}prepareRequest(e){e.headers["Authorization"]="Basic "+Buffer.from(this.username+":"+this.password).toString("base64")}canHandleAuthentication(e){return false}handleAuthentication(e,t,r){return null}}t.BasicCredentialHandler=BasicCredentialHandler;class BearerCredentialHandler{constructor(e){this.token=e}prepareRequest(e){e.headers["Authorization"]="Bearer "+this.token}canHandleAuthentication(e){return false}handleAuthentication(e,t,r){return null}}t.BearerCredentialHandler=BearerCredentialHandler;class PersonalAccessTokenCredentialHandler{constructor(e){this.token=e}prepareRequest(e){e.headers["Authorization"]="Basic "+Buffer.from("PAT:"+this.token).toString("base64")}canHandleAuthentication(e){return false}handleAuthentication(e,t,r){return null}}t.PersonalAccessTokenCredentialHandler=PersonalAccessTokenCredentialHandler},9925:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const n=r(8605);const i=r(7211);const o=r(6443);let s;var a;(function(e){e[e["OK"]=200]="OK";e[e["MultipleChoices"]=300]="MultipleChoices";e[e["MovedPermanently"]=301]="MovedPermanently";e[e["ResourceMoved"]=302]="ResourceMoved";e[e["SeeOther"]=303]="SeeOther";e[e["NotModified"]=304]="NotModified";e[e["UseProxy"]=305]="UseProxy";e[e["SwitchProxy"]=306]="SwitchProxy";e[e["TemporaryRedirect"]=307]="TemporaryRedirect";e[e["PermanentRedirect"]=308]="PermanentRedirect";e[e["BadRequest"]=400]="BadRequest";e[e["Unauthorized"]=401]="Unauthorized";e[e["PaymentRequired"]=402]="PaymentRequired";e[e["Forbidden"]=403]="Forbidden";e[e["NotFound"]=404]="NotFound";e[e["MethodNotAllowed"]=405]="MethodNotAllowed";e[e["NotAcceptable"]=406]="NotAcceptable";e[e["ProxyAuthenticationRequired"]=407]="ProxyAuthenticationRequired";e[e["RequestTimeout"]=408]="RequestTimeout";e[e["Conflict"]=409]="Conflict";e[e["Gone"]=410]="Gone";e[e["TooManyRequests"]=429]="TooManyRequests";e[e["InternalServerError"]=500]="InternalServerError";e[e["NotImplemented"]=501]="NotImplemented";e[e["BadGateway"]=502]="BadGateway";e[e["ServiceUnavailable"]=503]="ServiceUnavailable";e[e["GatewayTimeout"]=504]="GatewayTimeout"})(a=t.HttpCodes||(t.HttpCodes={}));var c;(function(e){e["Accept"]="accept";e["ContentType"]="content-type"})(c=t.Headers||(t.Headers={}));var l;(function(e){e["ApplicationJson"]="application/json"})(l=t.MediaTypes||(t.MediaTypes={}));function getProxyUrl(e){let t=o.getProxyUrl(new URL(e));return t?t.href:""}t.getProxyUrl=getProxyUrl;const u=[a.MovedPermanently,a.ResourceMoved,a.SeeOther,a.TemporaryRedirect,a.PermanentRedirect];const p=[a.BadGateway,a.ServiceUnavailable,a.GatewayTimeout];const d=["OPTIONS","GET","DELETE","HEAD"];const h=10;const m=5;class HttpClientError extends Error{constructor(e,t){super(e);this.name="HttpClientError";this.statusCode=t;Object.setPrototypeOf(this,HttpClientError.prototype)}}t.HttpClientError=HttpClientError;class HttpClientResponse{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.toString())}))}))}}t.HttpClientResponse=HttpClientResponse;function isHttps(e){let t=new URL(e);return t.protocol==="https:"}t.isHttps=isHttps;class HttpClient{constructor(e,t,r){this._ignoreSslError=false;this._allowRedirects=true;this._allowRedirectDowngrade=false;this._maxRedirects=50;this._allowRetries=false;this._maxRetries=1;this._keepAlive=false;this._disposed=false;this.userAgent=e;this.handlers=t||[];this.requestOptions=r;if(r){if(r.ignoreSslError!=null){this._ignoreSslError=r.ignoreSslError}this._socketTimeout=r.socketTimeout;if(r.allowRedirects!=null){this._allowRedirects=r.allowRedirects}if(r.allowRedirectDowngrade!=null){this._allowRedirectDowngrade=r.allowRedirectDowngrade}if(r.maxRedirects!=null){this._maxRedirects=Math.max(r.maxRedirects,0)}if(r.keepAlive!=null){this._keepAlive=r.keepAlive}if(r.allowRetries!=null){this._allowRetries=r.allowRetries}if(r.maxRetries!=null){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,n){return this.request(e,t,r,n)}async getJson(e,t={}){t[c.Accept]=this._getExistingOrDefaultHeader(t,c.Accept,l.ApplicationJson);let r=await this.get(e,t);return this._processResponse(r,this.requestOptions)}async postJson(e,t,r={}){let n=JSON.stringify(t,null,2);r[c.Accept]=this._getExistingOrDefaultHeader(r,c.Accept,l.ApplicationJson);r[c.ContentType]=this._getExistingOrDefaultHeader(r,c.ContentType,l.ApplicationJson);let i=await this.post(e,n,r);return this._processResponse(i,this.requestOptions)}async putJson(e,t,r={}){let n=JSON.stringify(t,null,2);r[c.Accept]=this._getExistingOrDefaultHeader(r,c.Accept,l.ApplicationJson);r[c.ContentType]=this._getExistingOrDefaultHeader(r,c.ContentType,l.ApplicationJson);let i=await this.put(e,n,r);return this._processResponse(i,this.requestOptions)}async patchJson(e,t,r={}){let n=JSON.stringify(t,null,2);r[c.Accept]=this._getExistingOrDefaultHeader(r,c.Accept,l.ApplicationJson);r[c.ContentType]=this._getExistingOrDefaultHeader(r,c.ContentType,l.ApplicationJson);let i=await this.patch(e,n,r);return this._processResponse(i,this.requestOptions)}async request(e,t,r,n){if(this._disposed){throw new Error("Client has already been disposed.")}let i=new URL(t);let o=this._prepareRequest(e,i,n);let s=this._allowRetries&&d.indexOf(e)!=-1?this._maxRetries+1:1;let c=0;let l;while(c<s){l=await this.requestRaw(o,r);if(l&&l.message&&l.message.statusCode===a.Unauthorized){let e;for(let t=0;t<this.handlers.length;t++){if(this.handlers[t].canHandleAuthentication(l)){e=this.handlers[t];break}}if(e){return e.handleAuthentication(this,o,r)}else{return l}}let t=this._maxRedirects;while(u.indexOf(l.message.statusCode)!=-1&&this._allowRedirects&&t>0){const s=l.message.headers["location"];if(!s){break}let a=new URL(s);if(i.protocol=="https:"&&i.protocol!=a.protocol&&!this._allowRedirectDowngrade){throw new 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.")}await l.readBody();if(a.hostname!==i.hostname){for(let e in n){if(e.toLowerCase()==="authorization"){delete n[e]}}}o=this._prepareRequest(e,a,n);l=await this.requestRaw(o,r);t--}if(p.indexOf(l.message.statusCode)==-1){return l}c+=1;if(c<s){await l.readBody();await this._performExponentialBackoff(c)}}return l}dispose(){if(this._agent){this._agent.destroy()}this._disposed=true}requestRaw(e,t){return new Promise(((r,n)=>{let callbackForResult=function(e,t){if(e){n(e)}r(t)};this.requestRawWithCallback(e,t,callbackForResult)}))}requestRawWithCallback(e,t,r){let n;if(typeof t==="string"){e.options.headers["Content-Length"]=Buffer.byteLength(t,"utf8")}let i=false;let handleResult=(e,t)=>{if(!i){i=true;r(e,t)}};let o=e.httpModule.request(e.options,(e=>{let t=new HttpClientResponse(e);handleResult(null,t)}));o.on("socket",(e=>{n=e}));o.setTimeout(this._socketTimeout||3*6e4,(()=>{if(n){n.end()}handleResult(new Error("Request timeout: "+e.options.path),null)}));o.on("error",(function(e){handleResult(e,null)}));if(t&&typeof t==="string"){o.write(t,"utf8")}if(t&&typeof t!=="string"){t.on("close",(function(){o.end()}));t.pipe(o)}else{o.end()}}getAgent(e){let t=new URL(e);return this._getAgent(t)}_prepareRequest(e,t,r){const o={};o.parsedUrl=t;const s=o.parsedUrl.protocol==="https:";o.httpModule=s?i:n;const a=s?443:80;o.options={};o.options.host=o.parsedUrl.hostname;o.options.port=o.parsedUrl.port?parseInt(o.parsedUrl.port):a;o.options.path=(o.parsedUrl.pathname||"")+(o.parsedUrl.search||"");o.options.method=e;o.options.headers=this._mergeHeaders(r);if(this.userAgent!=null){o.options.headers["user-agent"]=this.userAgent}o.options.agent=this._getAgent(o.parsedUrl);if(this.handlers){this.handlers.forEach((e=>{e.prepareRequest(o.options)}))}return o}_mergeHeaders(e){const lowercaseKeys=e=>Object.keys(e).reduce(((t,r)=>(t[r.toLowerCase()]=e[r],t)),{});if(this.requestOptions&&this.requestOptions.headers){return Object.assign({},lowercaseKeys(this.requestOptions.headers),lowercaseKeys(e))}return lowercaseKeys(e||{})}_getExistingOrDefaultHeader(e,t,r){const lowercaseKeys=e=>Object.keys(e).reduce(((t,r)=>(t[r.toLowerCase()]=e[r],t)),{});let n;if(this.requestOptions&&this.requestOptions.headers){n=lowercaseKeys(this.requestOptions.headers)[t]}return e[t]||n||r}_getAgent(e){let t;let a=o.getProxyUrl(e);let c=a&&a.hostname;if(this._keepAlive&&c){t=this._proxyAgent}if(this._keepAlive&&!c){t=this._agent}if(!!t){return t}const l=e.protocol==="https:";let u=100;if(!!this.requestOptions){u=this.requestOptions.maxSockets||n.globalAgent.maxSockets}if(c){if(!s){s=r(4294)}const e={maxSockets:u,keepAlive:this._keepAlive,proxy:{...(a.username||a.password)&&{proxyAuth:`${a.username}:${a.password}`},host:a.hostname,port:a.port}};let n;const i=a.protocol==="https:";if(l){n=i?s.httpsOverHttps:s.httpsOverHttp}else{n=i?s.httpOverHttps:s.httpOverHttp}t=n(e);this._proxyAgent=t}if(this._keepAlive&&!t){const e={keepAlive:this._keepAlive,maxSockets:u};t=l?new i.Agent(e):new n.Agent(e);this._agent=t}if(!t){t=l?i.globalAgent:n.globalAgent}if(l&&this._ignoreSslError){t.options=Object.assign(t.options||{},{rejectUnauthorized:false})}return t}_performExponentialBackoff(e){e=Math.min(h,e);const t=m*Math.pow(2,e);return new Promise((e=>setTimeout((()=>e()),t)))}static dateTimeDeserializer(e,t){if(typeof t==="string"){let e=new Date(t);if(!isNaN(e.valueOf())){return e}}return t}async _processResponse(e,t){return new Promise((async(r,n)=>{const i=e.message.statusCode;const o={statusCode:i,result:null,headers:{}};if(i==a.NotFound){r(o)}let s;let c;try{c=await e.readBody();if(c&&c.length>0){if(t&&t.deserializeDates){s=JSON.parse(c,HttpClient.dateTimeDeserializer)}else{s=JSON.parse(c)}o.result=s}o.headers=e.message.headers}catch(e){}if(i>299){let e;if(s&&s.message){e=s.message}else if(c&&c.length>0){e=c}else{e="Failed request: ("+i+")"}let t=new HttpClientError(e,i);t.result=o.result;n(t)}else{r(o)}}))}}t.HttpClient=HttpClient},6443:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});function getProxyUrl(e){let t=e.protocol==="https:";let r;if(checkBypass(e)){return r}let n;if(t){n=process.env["https_proxy"]||process.env["HTTPS_PROXY"]}else{n=process.env["http_proxy"]||process.env["HTTP_PROXY"]}if(n){r=new URL(n)}return r}t.getProxyUrl=getProxyUrl;function checkBypass(e){if(!e.hostname){return false}let t=process.env["no_proxy"]||process.env["NO_PROXY"]||"";if(!t){return false}let r;if(e.port){r=Number(e.port)}else if(e.protocol==="http:"){r=80}else if(e.protocol==="https:"){r=443}let n=[e.hostname.toUpperCase()];if(typeof r==="number"){n.push(`${n[0]}:${r}`)}for(let e of t.split(",").map((e=>e.trim().toUpperCase())).filter((e=>e))){if(n.some((t=>t===e))){return true}}return false}t.checkBypass=checkBypass},1962:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){if(n===undefined)n=r;Object.defineProperty(e,n,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,n){if(n===undefined)n=r;e[n]=t[r]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))n(t,e,r);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,r,n){function adopt(e){return e instanceof r?e:new r((function(t){t(e)}))}return new(r||(r=Promise))((function(r,i){function fulfilled(e){try{step(n.next(e))}catch(e){i(e)}}function rejected(e){try{step(n["throw"](e))}catch(e){i(e)}}function step(e){e.done?r(e.value):adopt(e.value).then(fulfilled,rejected)}step((n=n.apply(e,t||[])).next())}))};var a;Object.defineProperty(t,"__esModule",{value:true});t.getCmdPath=t.tryGetExecutablePath=t.isRooted=t.isDirectory=t.exists=t.IS_WINDOWS=t.unlink=t.symlink=t.stat=t.rmdir=t.rename=t.readlink=t.readdir=t.mkdir=t.lstat=t.copyFile=t.chmod=void 0;const c=o(r(5747));const l=o(r(5622));a=c.promises,t.chmod=a.chmod,t.copyFile=a.copyFile,t.lstat=a.lstat,t.mkdir=a.mkdir,t.readdir=a.readdir,t.readlink=a.readlink,t.rename=a.rename,t.rmdir=a.rmdir,t.stat=a.stat,t.symlink=a.symlink,t.unlink=a.unlink;t.IS_WINDOWS=process.platform==="win32";function exists(e){return s(this,void 0,void 0,(function*(){try{yield t.stat(e)}catch(e){if(e.code==="ENOENT"){return false}throw e}return true}))}t.exists=exists;function isDirectory(e,r=false){return s(this,void 0,void 0,(function*(){const n=r?yield t.stat(e):yield t.lstat(e);return n.isDirectory()}))}t.isDirectory=isDirectory;function isRooted(e){e=normalizeSeparators(e);if(!e){throw new Error('isRooted() parameter "p" cannot be empty')}if(t.IS_WINDOWS){return e.startsWith("\\")||/^[A-Z]:/i.test(e)}return e.startsWith("/")}t.isRooted=isRooted;function tryGetExecutablePath(e,r){return s(this,void 0,void 0,(function*(){let n=undefined;try{n=yield t.stat(e)}catch(t){if(t.code!=="ENOENT"){console.log(`Unexpected error attempting to determine if executable file exists '${e}': ${t}`)}}if(n&&n.isFile()){if(t.IS_WINDOWS){const t=l.extname(e).toUpperCase();if(r.some((e=>e.toUpperCase()===t))){return e}}else{if(isUnixExecutable(n)){return e}}}const i=e;for(const o of r){e=i+o;n=undefined;try{n=yield t.stat(e)}catch(t){if(t.code!=="ENOENT"){console.log(`Unexpected error attempting to determine if executable file exists '${e}': ${t}`)}}if(n&&n.isFile()){if(t.IS_WINDOWS){try{const r=l.dirname(e);const n=l.basename(e).toUpperCase();for(const i of yield t.readdir(r)){if(n===i.toUpperCase()){e=l.join(r,i);break}}}catch(t){console.log(`Unexpected error attempting to determine the actual case of the file '${e}': ${t}`)}return e}else{if(isUnixExecutable(n)){return e}}}}return""}))}t.tryGetExecutablePath=tryGetExecutablePath;function normalizeSeparators(e){e=e||"";if(t.IS_WINDOWS){e=e.replace(/\//g,"\\");return e.replace(/\\\\+/g,"\\")}return e.replace(/\/\/+/g,"/")}function isUnixExecutable(e){return(e.mode&1)>0||(e.mode&8)>0&&e.gid===process.getgid()||(e.mode&64)>0&&e.uid===process.getuid()}function getCmdPath(){var e;return(e=process.env["COMSPEC"])!==null&&e!==void 0?e:`cmd.exe`}t.getCmdPath=getCmdPath},7436:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){if(n===undefined)n=r;Object.defineProperty(e,n,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,n){if(n===undefined)n=r;e[n]=t[r]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))n(t,e,r);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,r,n){function adopt(e){return e instanceof r?e:new r((function(t){t(e)}))}return new(r||(r=Promise))((function(r,i){function fulfilled(e){try{step(n.next(e))}catch(e){i(e)}}function rejected(e){try{step(n["throw"](e))}catch(e){i(e)}}function step(e){e.done?r(e.value):adopt(e.value).then(fulfilled,rejected)}step((n=n.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.findInPath=t.which=t.mkdirP=t.rmRF=t.mv=t.cp=void 0;const a=r(2357);const c=o(r(3129));const l=o(r(5622));const u=r(1669);const p=o(r(1962));const d=u.promisify(c.exec);const h=u.promisify(c.execFile);function cp(e,t,r={}){return s(this,void 0,void 0,(function*(){const{force:n,recursive:i,copySourceDirectory:o}=readCopyOptions(r);const s=(yield p.exists(t))?yield p.stat(t):null;if(s&&s.isFile()&&!n){return}const a=s&&s.isDirectory()&&o?l.join(t,l.basename(e)):t;if(!(yield p.exists(e))){throw new Error(`no such file or directory: ${e}`)}const c=yield p.stat(e);if(c.isDirectory()){if(!i){throw new Error(`Failed to copy. ${e} is a directory, but tried to copy without recursive flag.`)}else{yield cpDirRecursive(e,a,0,n)}}else{if(l.relative(e,a)===""){throw new Error(`'${a}' and '${e}' are the same file`)}yield copyFile(e,a,n)}}))}t.cp=cp;function mv(e,t,r={}){return s(this,void 0,void 0,(function*(){if(yield p.exists(t)){let n=true;if(yield p.isDirectory(t)){t=l.join(t,l.basename(e));n=yield p.exists(t)}if(n){if(r.force==null||r.force){yield rmRF(t)}else{throw new Error("Destination already exists")}}}yield mkdirP(l.dirname(t));yield p.rename(e,t)}))}t.mv=mv;function rmRF(e){return s(this,void 0,void 0,(function*(){if(p.IS_WINDOWS){if(/[*"<>|]/.test(e)){throw new Error('File path must not contain `*`, `"`, `<`, `>` or `|` on Windows')}try{const t=p.getCmdPath();if(yield p.isDirectory(e,true)){yield d(`${t} /s /c "rd /s /q "%inputPath%""`,{env:{inputPath:e}})}else{yield d(`${t} /s /c "del /f /a "%inputPath%""`,{env:{inputPath:e}})}}catch(e){if(e.code!=="ENOENT")throw e}try{yield p.unlink(e)}catch(e){if(e.code!=="ENOENT")throw e}}else{let t=false;try{t=yield p.isDirectory(e)}catch(e){if(e.code!=="ENOENT")throw e;return}if(t){yield h(`rm`,[`-rf`,`${e}`])}else{yield p.unlink(e)}}}))}t.rmRF=rmRF;function mkdirP(e){return s(this,void 0,void 0,(function*(){a.ok(e,"a path argument must be provided");yield p.mkdir(e,{recursive:true})}))}t.mkdirP=mkdirP;function which(e,t){return s(this,void 0,void 0,(function*(){if(!e){throw new Error("parameter 'tool' is required")}if(t){const t=yield which(e,false);if(!t){if(p.IS_WINDOWS){throw new Error(`Unable to locate executable file: ${e}. 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.`)}else{throw new Error(`Unable to locate executable file: ${e}. 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 t}const r=yield findInPath(e);if(r&&r.length>0){return r[0]}return""}))}t.which=which;function findInPath(e){return s(this,void 0,void 0,(function*(){if(!e){throw new Error("parameter 'tool' is required")}const t=[];if(p.IS_WINDOWS&&process.env["PATHEXT"]){for(const e of process.env["PATHEXT"].split(l.delimiter)){if(e){t.push(e)}}}if(p.isRooted(e)){const r=yield p.tryGetExecutablePath(e,t);if(r){return[r]}return[]}if(e.includes(l.sep)){return[]}const r=[];if(process.env.PATH){for(const e of process.env.PATH.split(l.delimiter)){if(e){r.push(e)}}}const n=[];for(const i of r){const r=yield p.tryGetExecutablePath(l.join(i,e),t);if(r){n.push(r)}}return n}))}t.findInPath=findInPath;function readCopyOptions(e){const t=e.force==null?true:e.force;const r=Boolean(e.recursive);const n=e.copySourceDirectory==null?true:Boolean(e.copySourceDirectory);return{force:t,recursive:r,copySourceDirectory:n}}function cpDirRecursive(e,t,r,n){return s(this,void 0,void 0,(function*(){if(r>=255)return;r++;yield mkdirP(t);const i=yield p.readdir(e);for(const o of i){const i=`${e}/${o}`;const s=`${t}/${o}`;const a=yield p.lstat(i);if(a.isDirectory()){yield cpDirRecursive(i,s,r,n)}else{yield copyFile(i,s,n)}}yield p.chmod(t,(yield p.stat(e)).mode)}))}function copyFile(e,t,r){return s(this,void 0,void 0,(function*(){if((yield p.lstat(e)).isSymbolicLink()){try{yield p.lstat(t);yield p.unlink(t)}catch(e){if(e.code==="EPERM"){yield p.chmod(t,"0666");yield p.unlink(t)}}const r=yield p.readlink(e);yield p.symlink(r,t,p.IS_WINDOWS?"junction":null)}else if(!(yield p.exists(t))||r){yield p.copyFile(e,t)}}))}},2473:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){if(n===undefined)n=r;Object.defineProperty(e,n,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,n){if(n===undefined)n=r;e[n]=t[r]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))n(t,e,r);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,r,n){function adopt(e){return e instanceof r?e:new r((function(t){t(e)}))}return new(r||(r=Promise))((function(r,i){function fulfilled(e){try{step(n.next(e))}catch(e){i(e)}}function rejected(e){try{step(n["throw"](e))}catch(e){i(e)}}function step(e){e.done?r(e.value):adopt(e.value).then(fulfilled,rejected)}step((n=n.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t._readLinuxVersionFile=t._getOsVersion=t._findMatch=void 0;const a=o(r(5911));const c=r(2186);const l=r(2087);const u=r(3129);const p=r(5747);function _findMatch(t,r,n,i){return s(this,void 0,void 0,(function*(){const o=l.platform();let s;let u;let p;for(const s of n){const n=s.version;c.debug(`check ${n} satisfies ${t}`);if(a.satisfies(n,t)&&(!r||s.stable===r)){p=s.files.find((t=>{c.debug(`${t.arch}===${i} && ${t.platform}===${o}`);let r=t.arch===i&&t.platform===o;if(r&&t.platform_version){const n=e.exports._getOsVersion();if(n===t.platform_version){r=true}else{r=a.satisfies(n,t.platform_version)}}return r}));if(p){c.debug(`matched ${s.version}`);u=s;break}}}if(u&&p){s=Object.assign({},u);s.files=[p]}return s}))}t._findMatch=_findMatch;function _getOsVersion(){const t=l.platform();let r="";if(t==="darwin"){r=u.execSync("sw_vers -productVersion").toString()}else if(t==="linux"){const t=e.exports._readLinuxVersionFile();if(t){const e=t.split("\n");for(const t of e){const e=t.split("=");if(e.length===2&&(e[0].trim()==="VERSION_ID"||e[0].trim()==="DISTRIB_RELEASE")){r=e[1].trim().replace(/^"/,"").replace(/"$/,"");break}}}}return r}t._getOsVersion=_getOsVersion;function _readLinuxVersionFile(){const e="/etc/lsb-release";const t="/etc/os-release";let r="";if(p.existsSync(e)){r=p.readFileSync(e).toString()}else if(p.existsSync(t)){r=p.readFileSync(t).toString()}return r}t._readLinuxVersionFile=_readLinuxVersionFile},8279:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){if(n===undefined)n=r;Object.defineProperty(e,n,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,n){if(n===undefined)n=r;e[n]=t[r]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))n(t,e,r);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,r,n){function adopt(e){return e instanceof r?e:new r((function(t){t(e)}))}return new(r||(r=Promise))((function(r,i){function fulfilled(e){try{step(n.next(e))}catch(e){i(e)}}function rejected(e){try{step(n["throw"](e))}catch(e){i(e)}}function step(e){e.done?r(e.value):adopt(e.value).then(fulfilled,rejected)}step((n=n.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.RetryHelper=void 0;const a=o(r(2186));class RetryHelper{constructor(e,t,r){if(e<1){throw new Error("max attempts should be greater than or equal to 1")}this.maxAttempts=e;this.minSeconds=Math.floor(t);this.maxSeconds=Math.floor(r);if(this.minSeconds>this.maxSeconds){throw new Error("min seconds should be less than or equal to max seconds")}}execute(e,t){return s(this,void 0,void 0,(function*(){let r=1;while(r<this.maxAttempts){try{return yield e()}catch(e){if(t&&!t(e)){throw e}a.info(e.message)}const n=this.getSleepAmount();a.info(`Waiting ${n} seconds before trying again`);yield this.sleep(n);r++}return yield e()}))}getSleepAmount(){return Math.floor(Math.random()*(this.maxSeconds-this.minSeconds+1))+this.minSeconds}sleep(e){return s(this,void 0,void 0,(function*(){return new Promise((t=>setTimeout(t,e*1e3)))}))}}t.RetryHelper=RetryHelper},7784:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){if(n===undefined)n=r;Object.defineProperty(e,n,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,n){if(n===undefined)n=r;e[n]=t[r]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))n(t,e,r);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,r,n){function adopt(e){return e instanceof r?e:new r((function(t){t(e)}))}return new(r||(r=Promise))((function(r,i){function fulfilled(e){try{step(n.next(e))}catch(e){i(e)}}function rejected(e){try{step(n["throw"](e))}catch(e){i(e)}}function step(e){e.done?r(e.value):adopt(e.value).then(fulfilled,rejected)}step((n=n.apply(e,t||[])).next())}))};var a=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:true});t.evaluateVersions=t.isExplicitVersion=t.findFromManifest=t.getManifestFromRepo=t.findAllVersions=t.find=t.cacheFile=t.cacheDir=t.extractZip=t.extractXar=t.extractTar=t.extract7z=t.downloadTool=t.HTTPError=void 0;const c=o(r(2186));const l=o(r(7436));const u=o(r(5747));const p=o(r(2473));const d=o(r(2087));const h=o(r(5622));const m=o(r(9925));const g=o(r(5911));const v=o(r(2413));const y=o(r(1669));const E=a(r(824));const w=r(1514);const b=r(2357);const _=r(8279);class HTTPError extends Error{constructor(e){super(`Unexpected HTTP response: ${e}`);this.httpStatusCode=e;Object.setPrototypeOf(this,new.target.prototype)}}t.HTTPError=HTTPError;const S=process.platform==="win32";const O=process.platform==="darwin";const R="actions/tool-cache";function downloadTool(e,t,r,n){return s(this,void 0,void 0,(function*(){t=t||h.join(_getTempDirectory(),E.default());yield l.mkdirP(h.dirname(t));c.debug(`Downloading ${e}`);c.debug(`Destination ${t}`);const i=3;const o=_getGlobal("TEST_DOWNLOAD_TOOL_RETRY_MIN_SECONDS",10);const a=_getGlobal("TEST_DOWNLOAD_TOOL_RETRY_MAX_SECONDS",20);const u=new _.RetryHelper(i,o,a);return yield u.execute((()=>s(this,void 0,void 0,(function*(){return yield downloadToolAttempt(e,t||"",r,n)}))),(e=>{if(e instanceof HTTPError&&e.httpStatusCode){if(e.httpStatusCode<500&&e.httpStatusCode!==408&&e.httpStatusCode!==429){return false}}return true}))}))}t.downloadTool=downloadTool;function downloadToolAttempt(e,t,r,n){return s(this,void 0,void 0,(function*(){if(u.existsSync(t)){throw new Error(`Destination file path ${t} already exists`)}const i=new m.HttpClient(R,[],{allowRetries:false});if(r){c.debug("set auth");if(n===undefined){n={}}n.authorization=r}const o=yield i.get(e,n);if(o.message.statusCode!==200){const t=new HTTPError(o.message.statusCode);c.debug(`Failed to download from "${e}". Code(${o.message.statusCode}) Message(${o.message.statusMessage})`);throw t}const s=y.promisify(v.pipeline);const a=_getGlobal("TEST_DOWNLOAD_TOOL_RESPONSE_MESSAGE_FACTORY",(()=>o.message));const p=a();let d=false;try{yield s(p,u.createWriteStream(t));c.debug("download complete");d=true;return t}finally{if(!d){c.debug("download failed");try{yield l.rmRF(t)}catch(e){c.debug(`Failed to delete '${t}'. ${e.message}`)}}}}))}function extract7z(e,t,r){return s(this,void 0,void 0,(function*(){b.ok(S,"extract7z() not supported on current OS");b.ok(e,'parameter "file" is required');t=yield _createExtractFolder(t);const n=process.cwd();process.chdir(t);if(r){try{const t=c.isDebug()?"-bb1":"-bb0";const i=["x",t,"-bd","-sccUTF-8",e];const o={silent:true};yield w.exec(`"${r}"`,i,o)}finally{process.chdir(n)}}else{const r=h.join(__dirname,"..","scripts","Invoke-7zdec.ps1").replace(/'/g,"''").replace(/"|\n|\r/g,"");const i=e.replace(/'/g,"''").replace(/"|\n|\r/g,"");const o=t.replace(/'/g,"''").replace(/"|\n|\r/g,"");const s=`& '${r}' -Source '${i}' -Target '${o}'`;const a=["-NoLogo","-Sta","-NoProfile","-NonInteractive","-ExecutionPolicy","Unrestricted","-Command",s];const c={silent:true};try{const e=yield l.which("powershell",true);yield w.exec(`"${e}"`,a,c)}finally{process.chdir(n)}}return t}))}t.extract7z=extract7z;function extractTar(e,t,r="xz"){return s(this,void 0,void 0,(function*(){if(!e){throw new Error("parameter 'file' is required")}t=yield _createExtractFolder(t);c.debug("Checking tar --version");let n="";yield w.exec("tar --version",[],{ignoreReturnCode:true,silent:true,listeners:{stdout:e=>n+=e.toString(),stderr:e=>n+=e.toString()}});c.debug(n.trim());const i=n.toUpperCase().includes("GNU TAR");let o;if(r instanceof Array){o=r}else{o=[r]}if(c.isDebug()&&!r.includes("v")){o.push("-v")}let s=t;let a=e;if(S&&i){o.push("--force-local");s=t.replace(/\\/g,"/");a=e.replace(/\\/g,"/")}if(i){o.push("--warning=no-unknown-keyword");o.push("--overwrite")}o.push("-C",s,"-f",a);yield w.exec(`tar`,o);return t}))}t.extractTar=extractTar;function extractXar(e,t,r=[]){return s(this,void 0,void 0,(function*(){b.ok(O,"extractXar() not supported on current OS");b.ok(e,'parameter "file" is required');t=yield _createExtractFolder(t);let n;if(r instanceof Array){n=r}else{n=[r]}n.push("-x","-C",t,"-f",e);if(c.isDebug()){n.push("-v")}const i=yield l.which("xar",true);yield w.exec(`"${i}"`,_unique(n));return t}))}t.extractXar=extractXar;function extractZip(e,t){return s(this,void 0,void 0,(function*(){if(!e){throw new Error("parameter 'file' is required")}t=yield _createExtractFolder(t);if(S){yield extractZipWin(e,t)}else{yield extractZipNix(e,t)}return t}))}t.extractZip=extractZip;function extractZipWin(e,t){return s(this,void 0,void 0,(function*(){const r=e.replace(/'/g,"''").replace(/"|\n|\r/g,"");const n=t.replace(/'/g,"''").replace(/"|\n|\r/g,"");const i=yield l.which("pwsh",false);if(i){const e=[`$ErrorActionPreference = 'Stop' ;`,`try { Add-Type -AssemblyName System.IO.Compression.ZipFile } catch { } ;`,`try { [System.IO.Compression.ZipFile]::ExtractToDirectory('${r}', '${n}', $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 '${n}' -Force } else { throw $_ } } ;`].join(" ");const t=["-NoLogo","-NoProfile","-NonInteractive","-ExecutionPolicy","Unrestricted","-Command",e];c.debug(`Using pwsh at path: ${i}`);yield w.exec(`"${i}"`,t)}else{const e=[`$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 '${n}' -Force }`,`else {[System.IO.Compression.ZipFile]::ExtractToDirectory('${r}', '${n}', $true) }`].join(" ");const t=["-NoLogo","-Sta","-NoProfile","-NonInteractive","-ExecutionPolicy","Unrestricted","-Command",e];const i=yield l.which("powershell",true);c.debug(`Using powershell at path: ${i}`);yield w.exec(`"${i}"`,t)}}))}function extractZipNix(e,t){return s(this,void 0,void 0,(function*(){const r=yield l.which("unzip",true);const n=[e];if(!c.isDebug()){n.unshift("-q")}n.unshift("-o");yield w.exec(`"${r}"`,n,{cwd:t})}))}function cacheDir(e,t,r,n){return s(this,void 0,void 0,(function*(){r=g.clean(r)||r;n=n||d.arch();c.debug(`Caching tool ${t} ${r} ${n}`);c.debug(`source dir: ${e}`);if(!u.statSync(e).isDirectory()){throw new Error("sourceDir is not a directory")}const i=yield _createToolPath(t,r,n);for(const t of u.readdirSync(e)){const r=h.join(e,t);yield l.cp(r,i,{recursive:true})}_completeToolPath(t,r,n);return i}))}t.cacheDir=cacheDir;function cacheFile(e,t,r,n,i){return s(this,void 0,void 0,(function*(){n=g.clean(n)||n;i=i||d.arch();c.debug(`Caching tool ${r} ${n} ${i}`);c.debug(`source file: ${e}`);if(!u.statSync(e).isFile()){throw new Error("sourceFile is not a file")}const o=yield _createToolPath(r,n,i);const s=h.join(o,t);c.debug(`destination file ${s}`);yield l.cp(e,s);_completeToolPath(r,n,i);return o}))}t.cacheFile=cacheFile;function find(e,t,r){if(!e){throw new Error("toolName parameter is required")}if(!t){throw new Error("versionSpec parameter is required")}r=r||d.arch();if(!isExplicitVersion(t)){const n=findAllVersions(e,r);const i=evaluateVersions(n,t);t=i}let n="";if(t){t=g.clean(t)||"";const i=h.join(_getCacheDirectory(),e,t,r);c.debug(`checking cache: ${i}`);if(u.existsSync(i)&&u.existsSync(`${i}.complete`)){c.debug(`Found tool in cache ${e} ${t} ${r}`);n=i}else{c.debug("not found")}}return n}t.find=find;function findAllVersions(e,t){const r=[];t=t||d.arch();const n=h.join(_getCacheDirectory(),e);if(u.existsSync(n)){const e=u.readdirSync(n);for(const i of e){if(isExplicitVersion(i)){const e=h.join(n,i,t||"");if(u.existsSync(e)&&u.existsSync(`${e}.complete`)){r.push(i)}}}}return r}t.findAllVersions=findAllVersions;function getManifestFromRepo(e,t,r,n="master"){return s(this,void 0,void 0,(function*(){let i=[];const o=`https://api.github.com/repos/${e}/${t}/git/trees/${n}`;const s=new m.HttpClient("tool-cache");const a={};if(r){c.debug("set auth");a.authorization=r}const l=yield s.getJson(o,a);if(!l.result){return i}let u="";for(const e of l.result.tree){if(e.path==="versions-manifest.json"){u=e.url;break}}a["accept"]="application/vnd.github.VERSION.raw";let p=yield(yield s.get(u,a)).readBody();if(p){p=p.replace(/^\uFEFF/,"");try{i=JSON.parse(p)}catch(e){c.debug("Invalid json")}}return i}))}t.getManifestFromRepo=getManifestFromRepo;function findFromManifest(e,t,r,n=d.arch()){return s(this,void 0,void 0,(function*(){const i=yield p._findMatch(e,t,r,n);return i}))}t.findFromManifest=findFromManifest;function _createExtractFolder(e){return s(this,void 0,void 0,(function*(){if(!e){e=h.join(_getTempDirectory(),E.default())}yield l.mkdirP(e);return e}))}function _createToolPath(e,t,r){return s(this,void 0,void 0,(function*(){const n=h.join(_getCacheDirectory(),e,g.clean(t)||t,r||"");c.debug(`destination ${n}`);const i=`${n}.complete`;yield l.rmRF(n);yield l.rmRF(i);yield l.mkdirP(n);return n}))}function _completeToolPath(e,t,r){const n=h.join(_getCacheDirectory(),e,g.clean(t)||t,r||"");const i=`${n}.complete`;u.writeFileSync(i,"");c.debug("finished caching tool")}function isExplicitVersion(e){const t=g.clean(e)||"";c.debug(`isExplicit: ${t}`);const r=g.valid(t)!=null;c.debug(`explicit? ${r}`);return r}t.isExplicitVersion=isExplicitVersion;function evaluateVersions(e,t){let r="";c.debug(`evaluating ${e.length} versions`);e=e.sort(((e,t)=>{if(g.gt(e,t)){return 1}return-1}));for(let n=e.length-1;n>=0;n--){const i=e[n];const o=g.satisfies(i,t);if(o){r=i;break}}if(r){c.debug(`matched: ${r}`)}else{c.debug("match not found")}return r}t.evaluateVersions=evaluateVersions;function _getCacheDirectory(){const e=process.env["RUNNER_TOOL_CACHE"]||"";b.ok(e,"Expected RUNNER_TOOL_CACHE to be defined");return e}function _getTempDirectory(){const e=process.env["RUNNER_TEMP"]||"";b.ok(e,"Expected RUNNER_TEMP to be defined");return e}function _getGlobal(e,t){const r=global[e];return r!==undefined?r:t}function _unique(e){return Array.from(new Set(e))}},9417:e=>{"use strict";e.exports=balanced;function balanced(e,t,r){if(e instanceof RegExp)e=maybeMatch(e,r);if(t instanceof RegExp)t=maybeMatch(t,r);var n=range(e,t,r);return n&&{start:n[0],end:n[1],pre:r.slice(0,n[0]),body:r.slice(n[0]+e.length,n[1]),post:r.slice(n[1]+t.length)}}function maybeMatch(e,t){var r=t.match(e);return r?r[0]:null}balanced.range=range;function range(e,t,r){var n,i,o,s,a;var c=r.indexOf(e);var l=r.indexOf(t,c+1);var u=c;if(c>=0&&l>0){if(e===t){return[c,l]}n=[];o=r.length;while(u>=0&&!a){if(u==c){n.push(u);c=r.indexOf(e,u+1)}else if(n.length==1){a=[n.pop(),l]}else{i=n.pop();if(i<o){o=i;s=l}l=r.indexOf(t,u+1)}u=c<l&&c>=0?c:l}if(n.length){a=[o,s]}}return a}},3717:(e,t,r)=>{var n=r(6891);var i=r(9417);e.exports=expandTop;var o="\0SLASH"+Math.random()+"\0";var s="\0OPEN"+Math.random()+"\0";var a="\0CLOSE"+Math.random()+"\0";var c="\0COMMA"+Math.random()+"\0";var l="\0PERIOD"+Math.random()+"\0";function numeric(e){return parseInt(e,10)==e?parseInt(e,10):e.charCodeAt(0)}function escapeBraces(e){return e.split("\\\\").join(o).split("\\{").join(s).split("\\}").join(a).split("\\,").join(c).split("\\.").join(l)}function unescapeBraces(e){return e.split(o).join("\\").split(s).join("{").split(a).join("}").split(c).join(",").split(l).join(".")}function parseCommaParts(e){if(!e)return[""];var t=[];var r=i("{","}",e);if(!r)return e.split(",");var n=r.pre;var o=r.body;var s=r.post;var a=n.split(",");a[a.length-1]+="{"+o+"}";var c=parseCommaParts(s);if(s.length){a[a.length-1]+=c.shift();a.push.apply(a,c)}t.push.apply(t,a);return t}function expandTop(e){if(!e)return[];if(e.substr(0,2)==="{}"){e="\\{\\}"+e.substr(2)}return expand(escapeBraces(e),true).map(unescapeBraces)}function identity(e){return e}function embrace(e){return"{"+e+"}"}function isPadded(e){return/^-?0\d/.test(e)}function lte(e,t){return e<=t}function gte(e,t){return e>=t}function expand(e,t){var r=[];var o=i("{","}",e);if(!o||/\$$/.test(o.pre))return[e];var s=/^-?\d+\.\.-?\d+(?:\.\.-?\d+)?$/.test(o.body);var c=/^[a-zA-Z]\.\.[a-zA-Z](?:\.\.-?\d+)?$/.test(o.body);var l=s||c;var u=o.body.indexOf(",")>=0;if(!l&&!u){if(o.post.match(/,.*\}/)){e=o.pre+"{"+o.body+a+o.post;return expand(e)}return[e]}var p;if(l){p=o.body.split(/\.\./)}else{p=parseCommaParts(o.body);if(p.length===1){p=expand(p[0],false).map(embrace);if(p.length===1){var d=o.post.length?expand(o.post,false):[""];return d.map((function(e){return o.pre+p[0]+e}))}}}var h=o.pre;var d=o.post.length?expand(o.post,false):[""];var m;if(l){var g=numeric(p[0]);var v=numeric(p[1]);var y=Math.max(p[0].length,p[1].length);var E=p.length==3?Math.abs(numeric(p[2])):1;var w=lte;var b=v<g;if(b){E*=-1;w=gte}var _=p.some(isPadded);m=[];for(var S=g;w(S,v);S+=E){var O;if(c){O=String.fromCharCode(S);if(O==="\\")O=""}else{O=String(S);if(_){var R=y-O.length;if(R>0){var C=new Array(R+1).join("0");if(S<0)O="-"+C+O.slice(1);else O=C+O}}}m.push(O)}}else{m=n(p,(function(e){return expand(e,false)}))}for(var A=0;A<m.length;A++){for(var T=0;T<d.length;T++){var x=h+m[A]+d[T];if(!t||l||x)r.push(x)}}return r}},421:e=>{var t={utf8:{stringToBytes:function(e){return t.bin.stringToBytes(unescape(encodeURIComponent(e)))},bytesToString:function(e){return decodeURIComponent(escape(t.bin.bytesToString(e)))}},bin:{stringToBytes:function(e){for(var t=[],r=0;r<e.length;r++)t.push(e.charCodeAt(r)&255);return t},bytesToString:function(e){for(var t=[],r=0;r<e.length;r++)t.push(String.fromCharCode(e[r]));return t.join("")}}};e.exports=t},6891:e=>{e.exports=function(e,r){var n=[];for(var i=0;i<e.length;i++){var o=r(e[i],i);if(t(o))n.push.apply(n,o);else n.push(o)}return n};var t=Array.isArray||function(e){return Object.prototype.toString.call(e)==="[object Array]"}},7935:e=>{(function(){var t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",r={rotl:function(e,t){return e<<t|e>>>32-t},rotr:function(e,t){return e<<32-t|e>>>t},endian:function(e){if(e.constructor==Number){return r.rotl(e,8)&16711935|r.rotl(e,24)&4278255360}for(var t=0;t<e.length;t++)e[t]=r.endian(e[t]);return e},randomBytes:function(e){for(var t=[];e>0;e--)t.push(Math.floor(Math.random()*256));return t},bytesToWords:function(e){for(var t=[],r=0,n=0;r<e.length;r++,n+=8)t[n>>>5]|=e[r]<<24-n%32;return t},wordsToBytes:function(e){for(var t=[],r=0;r<e.length*32;r+=8)t.push(e[r>>>5]>>>24-r%32&255);return t},bytesToHex:function(e){for(var t=[],r=0;r<e.length;r++){t.push((e[r]>>>4).toString(16));t.push((e[r]&15).toString(16))}return t.join("")},hexToBytes:function(e){for(var t=[],r=0;r<e.length;r+=2)t.push(parseInt(e.substr(r,2),16));return t},bytesToBase64:function(e){for(var r=[],n=0;n<e.length;n+=3){var i=e[n]<<16|e[n+1]<<8|e[n+2];for(var o=0;o<4;o++)if(n*8+o*6<=e.length*8)r.push(t.charAt(i>>>6*(3-o)&63));else r.push("=")}return r.join("")},base64ToBytes:function(e){e=e.replace(/[^A-Z0-9+\/]/gi,"");for(var r=[],n=0,i=0;n<e.length;i=++n%4){if(i==0)continue;r.push((t.indexOf(e.charAt(n-1))&Math.pow(2,-2*i+8)-1)<<i*2|t.indexOf(e.charAt(n))>>>6-i*2)}return r}};e.exports=r})()},6863:(e,t,r)=>{e.exports=realpath;realpath.realpath=realpath;realpath.sync=realpathSync;realpath.realpathSync=realpathSync;realpath.monkeypatch=monkeypatch;realpath.unmonkeypatch=unmonkeypatch;var n=r(5747);var i=n.realpath;var o=n.realpathSync;var s=process.version;var a=/^v[0-5]\./.test(s);var c=r(1734);function newError(e){return e&&e.syscall==="realpath"&&(e.code==="ELOOP"||e.code==="ENOMEM"||e.code==="ENAMETOOLONG")}function realpath(e,t,r){if(a){return i(e,t,r)}if(typeof t==="function"){r=t;t=null}i(e,t,(function(n,i){if(newError(n)){c.realpath(e,t,r)}else{r(n,i)}}))}function realpathSync(e,t){if(a){return o(e,t)}try{return o(e,t)}catch(r){if(newError(r)){return c.realpathSync(e,t)}else{throw r}}}function monkeypatch(){n.realpath=realpath;n.realpathSync=realpathSync}function unmonkeypatch(){n.realpath=i;n.realpathSync=o}},1734:(e,t,r)=>{var n=r(5622);var i=process.platform==="win32";var o=r(5747);var s=process.env.NODE_DEBUG&&/fs/.test(process.env.NODE_DEBUG);function rethrow(){var e;if(s){var t=new Error;e=debugCallback}else e=missingCallback;return e;function debugCallback(e){if(e){t.message=e.message;e=t;missingCallback(e)}}function missingCallback(e){if(e){if(process.throwDeprecation)throw e;else if(!process.noDeprecation){var t="fs: missing callback "+(e.stack||e.message);if(process.traceDeprecation)console.trace(t);else console.error(t)}}}}function maybeCallback(e){return typeof e==="function"?e:rethrow()}var a=n.normalize;if(i){var c=/(.*?)(?:[\/\\]+|$)/g}else{var c=/(.*?)(?:[\/]+|$)/g}if(i){var l=/^(?:[a-zA-Z]:|[\\\/]{2}[^\\\/]+[\\\/][^\\\/]+)?[\\\/]*/}else{var l=/^[\/]*/}t.realpathSync=function realpathSync(e,t){e=n.resolve(e);if(t&&Object.prototype.hasOwnProperty.call(t,e)){return t[e]}var r=e,s={},a={};var u;var p;var d;var h;start();function start(){var t=l.exec(e);u=t[0].length;p=t[0];d=t[0];h="";if(i&&!a[d]){o.lstatSync(d);a[d]=true}}while(u<e.length){c.lastIndex=u;var m=c.exec(e);h=p;p+=m[0];d=h+m[1];u=c.lastIndex;if(a[d]||t&&t[d]===d){continue}var g;if(t&&Object.prototype.hasOwnProperty.call(t,d)){g=t[d]}else{var v=o.lstatSync(d);if(!v.isSymbolicLink()){a[d]=true;if(t)t[d]=d;continue}var y=null;if(!i){var E=v.dev.toString(32)+":"+v.ino.toString(32);if(s.hasOwnProperty(E)){y=s[E]}}if(y===null){o.statSync(d);y=o.readlinkSync(d)}g=n.resolve(h,y);if(t)t[d]=g;if(!i)s[E]=y}e=n.resolve(g,e.slice(u));start()}if(t)t[r]=e;return e};t.realpath=function realpath(e,t,r){if(typeof r!=="function"){r=maybeCallback(t);t=null}e=n.resolve(e);if(t&&Object.prototype.hasOwnProperty.call(t,e)){return process.nextTick(r.bind(null,null,t[e]))}var s=e,a={},u={};var p;var d;var h;var m;start();function start(){var t=l.exec(e);p=t[0].length;d=t[0];h=t[0];m="";if(i&&!u[h]){o.lstat(h,(function(e){if(e)return r(e);u[h]=true;LOOP()}))}else{process.nextTick(LOOP)}}function LOOP(){if(p>=e.length){if(t)t[s]=e;return r(null,e)}c.lastIndex=p;var n=c.exec(e);m=d;d+=n[0];h=m+n[1];p=c.lastIndex;if(u[h]||t&&t[h]===h){return process.nextTick(LOOP)}if(t&&Object.prototype.hasOwnProperty.call(t,h)){return gotResolvedLink(t[h])}return o.lstat(h,gotStat)}function gotStat(e,n){if(e)return r(e);if(!n.isSymbolicLink()){u[h]=true;if(t)t[h]=h;return process.nextTick(LOOP)}if(!i){var s=n.dev.toString(32)+":"+n.ino.toString(32);if(a.hasOwnProperty(s)){return gotTarget(null,a[s],h)}}o.stat(h,(function(e){if(e)return r(e);o.readlink(h,(function(e,t){if(!i)a[s]=t;gotTarget(e,t)}))}))}function gotTarget(e,i,o){if(e)return r(e);var s=n.resolve(m,i);if(t)t[o]=s;gotResolvedLink(s)}function gotResolvedLink(t){e=n.resolve(t,e.slice(p));start()}}},7625:(e,t,r)=>{t.setopts=setopts;t.ownProp=ownProp;t.makeAbs=makeAbs;t.finish=finish;t.mark=mark;t.isIgnored=isIgnored;t.childrenIgnored=childrenIgnored;function ownProp(e,t){return Object.prototype.hasOwnProperty.call(e,t)}var n=r(5747);var i=r(5622);var o=r(3973);var s=r(8714);var a=o.Minimatch;function alphasort(e,t){return e.localeCompare(t,"en")}function setupIgnores(e,t){e.ignore=t.ignore||[];if(!Array.isArray(e.ignore))e.ignore=[e.ignore];if(e.ignore.length){e.ignore=e.ignore.map(ignoreMap)}}function ignoreMap(e){var t=null;if(e.slice(-3)==="/**"){var r=e.replace(/(\/\*\*)+$/,"");t=new a(r,{dot:true})}return{matcher:new a(e,{dot:true}),gmatcher:t}}function setopts(e,t,r){if(!r)r={};if(r.matchBase&&-1===t.indexOf("/")){if(r.noglobstar){throw new Error("base matching requires globstar")}t="**/"+t}e.silent=!!r.silent;e.pattern=t;e.strict=r.strict!==false;e.realpath=!!r.realpath;e.realpathCache=r.realpathCache||Object.create(null);e.follow=!!r.follow;e.dot=!!r.dot;e.mark=!!r.mark;e.nodir=!!r.nodir;if(e.nodir)e.mark=true;e.sync=!!r.sync;e.nounique=!!r.nounique;e.nonull=!!r.nonull;e.nosort=!!r.nosort;e.nocase=!!r.nocase;e.stat=!!r.stat;e.noprocess=!!r.noprocess;e.absolute=!!r.absolute;e.fs=r.fs||n;e.maxLength=r.maxLength||Infinity;e.cache=r.cache||Object.create(null);e.statCache=r.statCache||Object.create(null);e.symlinks=r.symlinks||Object.create(null);setupIgnores(e,r);e.changedCwd=false;var o=process.cwd();if(!ownProp(r,"cwd"))e.cwd=o;else{e.cwd=i.resolve(r.cwd);e.changedCwd=e.cwd!==o}e.root=r.root||i.resolve(e.cwd,"/");e.root=i.resolve(e.root);if(process.platform==="win32")e.root=e.root.replace(/\\/g,"/");e.cwdAbs=s(e.cwd)?e.cwd:makeAbs(e,e.cwd);if(process.platform==="win32")e.cwdAbs=e.cwdAbs.replace(/\\/g,"/");e.nomount=!!r.nomount;r.nonegate=true;r.nocomment=true;e.minimatch=new a(t,r);e.options=e.minimatch.options}function finish(e){var t=e.nounique;var r=t?[]:Object.create(null);for(var n=0,i=e.matches.length;n<i;n++){var o=e.matches[n];if(!o||Object.keys(o).length===0){if(e.nonull){var s=e.minimatch.globSet[n];if(t)r.push(s);else r[s]=true}}else{var a=Object.keys(o);if(t)r.push.apply(r,a);else a.forEach((function(e){r[e]=true}))}}if(!t)r=Object.keys(r);if(!e.nosort)r=r.sort(alphasort);if(e.mark){for(var n=0;n<r.length;n++){r[n]=e._mark(r[n])}if(e.nodir){r=r.filter((function(t){var r=!/\/$/.test(t);var n=e.cache[t]||e.cache[makeAbs(e,t)];if(r&&n)r=n!=="DIR"&&!Array.isArray(n);return r}))}}if(e.ignore.length)r=r.filter((function(t){return!isIgnored(e,t)}));e.found=r}function mark(e,t){var r=makeAbs(e,t);var n=e.cache[r];var i=t;if(n){var o=n==="DIR"||Array.isArray(n);var s=t.slice(-1)==="/";if(o&&!s)i+="/";else if(!o&&s)i=i.slice(0,-1);if(i!==t){var a=makeAbs(e,i);e.statCache[a]=e.statCache[r];e.cache[a]=e.cache[r]}}return i}function makeAbs(e,t){var r=t;if(t.charAt(0)==="/"){r=i.join(e.root,t)}else if(s(t)||t===""){r=t}else if(e.changedCwd){r=i.resolve(e.cwd,t)}else{r=i.resolve(t)}if(process.platform==="win32")r=r.replace(/\\/g,"/");return r}function isIgnored(e,t){if(!e.ignore.length)return false;return e.ignore.some((function(e){return e.matcher.match(t)||!!(e.gmatcher&&e.gmatcher.match(t))}))}function childrenIgnored(e,t){if(!e.ignore.length)return false;return e.ignore.some((function(e){return!!(e.gmatcher&&e.gmatcher.match(t))}))}},1957:(e,t,r)=>{e.exports=glob;var n=r(6863);var i=r(3973);var o=i.Minimatch;var s=r(4124);var a=r(8614).EventEmitter;var c=r(5622);var l=r(2357);var u=r(8714);var p=r(9010);var d=r(7625);var h=d.setopts;var m=d.ownProp;var g=r(2492);var v=r(1669);var y=d.childrenIgnored;var E=d.isIgnored;var w=r(1223);function glob(e,t,r){if(typeof t==="function")r=t,t={};if(!t)t={};if(t.sync){if(r)throw new TypeError("callback provided to sync glob");return p(e,t)}return new Glob(e,t,r)}glob.sync=p;var b=glob.GlobSync=p.GlobSync;glob.glob=glob;function extend(e,t){if(t===null||typeof t!=="object"){return e}var r=Object.keys(t);var n=r.length;while(n--){e[r[n]]=t[r[n]]}return e}glob.hasMagic=function(e,t){var r=extend({},t);r.noprocess=true;var n=new Glob(e,r);var i=n.minimatch.set;if(!e)return false;if(i.length>1)return true;for(var o=0;o<i[0].length;o++){if(typeof i[0][o]!=="string")return true}return false};glob.Glob=Glob;s(Glob,a);function Glob(e,t,r){if(typeof t==="function"){r=t;t=null}if(t&&t.sync){if(r)throw new TypeError("callback provided to sync glob");return new b(e,t)}if(!(this instanceof Glob))return new Glob(e,t,r);h(this,e,t);this._didRealPath=false;var n=this.minimatch.set.length;this.matches=new Array(n);if(typeof r==="function"){r=w(r);this.on("error",r);this.on("end",(function(e){r(null,e)}))}var i=this;this._processing=0;this._emitQueue=[];this._processQueue=[];this.paused=false;if(this.noprocess)return this;if(n===0)return done();var o=true;for(var s=0;s<n;s++){this._process(this.minimatch.set[s],s,false,done)}o=false;function done(){--i._processing;if(i._processing<=0){if(o){process.nextTick((function(){i._finish()}))}else{i._finish()}}}}Glob.prototype._finish=function(){l(this instanceof Glob);if(this.aborted)return;if(this.realpath&&!this._didRealpath)return this._realpath();d.finish(this);this.emit("end",this.found)};Glob.prototype._realpath=function(){if(this._didRealpath)return;this._didRealpath=true;var e=this.matches.length;if(e===0)return this._finish();var t=this;for(var r=0;r<this.matches.length;r++)this._realpathSet(r,next);function next(){if(--e===0)t._finish()}};Glob.prototype._realpathSet=function(e,t){var r=this.matches[e];if(!r)return t();var i=Object.keys(r);var o=this;var s=i.length;if(s===0)return t();var a=this.matches[e]=Object.create(null);i.forEach((function(r,i){r=o._makeAbs(r);n.realpath(r,o.realpathCache,(function(n,i){if(!n)a[i]=true;else if(n.syscall==="stat")a[r]=true;else o.emit("error",n);if(--s===0){o.matches[e]=a;t()}}))}))};Glob.prototype._mark=function(e){return d.mark(this,e)};Glob.prototype._makeAbs=function(e){return d.makeAbs(this,e)};Glob.prototype.abort=function(){this.aborted=true;this.emit("abort")};Glob.prototype.pause=function(){if(!this.paused){this.paused=true;this.emit("pause")}};Glob.prototype.resume=function(){if(this.paused){this.emit("resume");this.paused=false;if(this._emitQueue.length){var e=this._emitQueue.slice(0);this._emitQueue.length=0;for(var t=0;t<e.length;t++){var r=e[t];this._emitMatch(r[0],r[1])}}if(this._processQueue.length){var n=this._processQueue.slice(0);this._processQueue.length=0;for(var t=0;t<n.length;t++){var i=n[t];this._processing--;this._process(i[0],i[1],i[2],i[3])}}}};Glob.prototype._process=function(e,t,r,n){l(this instanceof Glob);l(typeof n==="function");if(this.aborted)return;this._processing++;if(this.paused){this._processQueue.push([e,t,r,n]);return}var o=0;while(typeof e[o]==="string"){o++}var s;switch(o){case e.length:this._processSimple(e.join("/"),t,n);return;case 0:s=null;break;default:s=e.slice(0,o).join("/");break}var a=e.slice(o);var c;if(s===null)c=".";else if(u(s)||u(e.join("/"))){if(!s||!u(s))s="/"+s;c=s}else c=s;var p=this._makeAbs(c);if(y(this,c))return n();var d=a[0]===i.GLOBSTAR;if(d)this._processGlobStar(s,c,p,a,t,r,n);else this._processReaddir(s,c,p,a,t,r,n)};Glob.prototype._processReaddir=function(e,t,r,n,i,o,s){var a=this;this._readdir(r,o,(function(c,l){return a._processReaddir2(e,t,r,n,i,o,l,s)}))};Glob.prototype._processReaddir2=function(e,t,r,n,i,o,s,a){if(!s)return a();var l=n[0];var u=!!this.minimatch.negate;var p=l._glob;var d=this.dot||p.charAt(0)===".";var h=[];for(var m=0;m<s.length;m++){var g=s[m];if(g.charAt(0)!=="."||d){var v;if(u&&!e){v=!g.match(l)}else{v=g.match(l)}if(v)h.push(g)}}var y=h.length;if(y===0)return a();if(n.length===1&&!this.mark&&!this.stat){if(!this.matches[i])this.matches[i]=Object.create(null);for(var m=0;m<y;m++){var g=h[m];if(e){if(e!=="/")g=e+"/"+g;else g=e+g}if(g.charAt(0)==="/"&&!this.nomount){g=c.join(this.root,g)}this._emitMatch(i,g)}return a()}n.shift();for(var m=0;m<y;m++){var g=h[m];var E;if(e){if(e!=="/")g=e+"/"+g;else g=e+g}this._process([g].concat(n),i,o,a)}a()};Glob.prototype._emitMatch=function(e,t){if(this.aborted)return;if(E(this,t))return;if(this.paused){this._emitQueue.push([e,t]);return}var r=u(t)?t:this._makeAbs(t);if(this.mark)t=this._mark(t);if(this.absolute)t=r;if(this.matches[e][t])return;if(this.nodir){var n=this.cache[r];if(n==="DIR"||Array.isArray(n))return}this.matches[e][t]=true;var i=this.statCache[r];if(i)this.emit("stat",t,i);this.emit("match",t)};Glob.prototype._readdirInGlobStar=function(e,t){if(this.aborted)return;if(this.follow)return this._readdir(e,false,t);var r="lstat\0"+e;var n=this;var i=g(r,lstatcb_);if(i)n.fs.lstat(e,i);function lstatcb_(r,i){if(r&&r.code==="ENOENT")return t();var o=i&&i.isSymbolicLink();n.symlinks[e]=o;if(!o&&i&&!i.isDirectory()){n.cache[e]="FILE";t()}else n._readdir(e,false,t)}};Glob.prototype._readdir=function(e,t,r){if(this.aborted)return;r=g("readdir\0"+e+"\0"+t,r);if(!r)return;if(t&&!m(this.symlinks,e))return this._readdirInGlobStar(e,r);if(m(this.cache,e)){var n=this.cache[e];if(!n||n==="FILE")return r();if(Array.isArray(n))return r(null,n)}var i=this;i.fs.readdir(e,readdirCb(this,e,r))};function readdirCb(e,t,r){return function(n,i){if(n)e._readdirError(t,n,r);else e._readdirEntries(t,i,r)}}Glob.prototype._readdirEntries=function(e,t,r){if(this.aborted)return;if(!this.mark&&!this.stat){for(var n=0;n<t.length;n++){var i=t[n];if(e==="/")i=e+i;else i=e+"/"+i;this.cache[i]=true}}this.cache[e]=t;return r(null,t)};Glob.prototype._readdirError=function(e,t,r){if(this.aborted)return;switch(t.code){case"ENOTSUP":case"ENOTDIR":var n=this._makeAbs(e);this.cache[n]="FILE";if(n===this.cwdAbs){var i=new Error(t.code+" invalid cwd "+this.cwd);i.path=this.cwd;i.code=t.code;this.emit("error",i);this.abort()}break;case"ENOENT":case"ELOOP":case"ENAMETOOLONG":case"UNKNOWN":this.cache[this._makeAbs(e)]=false;break;default:this.cache[this._makeAbs(e)]=false;if(this.strict){this.emit("error",t);this.abort()}if(!this.silent)console.error("glob error",t);break}return r()};Glob.prototype._processGlobStar=function(e,t,r,n,i,o,s){var a=this;this._readdir(r,o,(function(c,l){a._processGlobStar2(e,t,r,n,i,o,l,s)}))};Glob.prototype._processGlobStar2=function(e,t,r,n,i,o,s,a){if(!s)return a();var c=n.slice(1);var l=e?[e]:[];var u=l.concat(c);this._process(u,i,false,a);var p=this.symlinks[r];var d=s.length;if(p&&o)return a();for(var h=0;h<d;h++){var m=s[h];if(m.charAt(0)==="."&&!this.dot)continue;var g=l.concat(s[h],c);this._process(g,i,true,a);var v=l.concat(s[h],n);this._process(v,i,true,a)}a()};Glob.prototype._processSimple=function(e,t,r){var n=this;this._stat(e,(function(i,o){n._processSimple2(e,t,i,o,r)}))};Glob.prototype._processSimple2=function(e,t,r,n,i){if(!this.matches[t])this.matches[t]=Object.create(null);if(!n)return i();if(e&&u(e)&&!this.nomount){var o=/[\/\\]$/.test(e);if(e.charAt(0)==="/"){e=c.join(this.root,e)}else{e=c.resolve(this.root,e);if(o)e+="/"}}if(process.platform==="win32")e=e.replace(/\\/g,"/");this._emitMatch(t,e);i()};Glob.prototype._stat=function(e,t){var r=this._makeAbs(e);var n=e.slice(-1)==="/";if(e.length>this.maxLength)return t();if(!this.stat&&m(this.cache,r)){var i=this.cache[r];if(Array.isArray(i))i="DIR";if(!n||i==="DIR")return t(null,i);if(n&&i==="FILE")return t()}var o;var s=this.statCache[r];if(s!==undefined){if(s===false)return t(null,s);else{var a=s.isDirectory()?"DIR":"FILE";if(n&&a==="FILE")return t();else return t(null,a,s)}}var c=this;var l=g("stat\0"+r,lstatcb_);if(l)c.fs.lstat(r,l);function lstatcb_(n,i){if(i&&i.isSymbolicLink()){return c.fs.stat(r,(function(n,o){if(n)c._stat2(e,r,null,i,t);else c._stat2(e,r,n,o,t)}))}else{c._stat2(e,r,n,i,t)}}};Glob.prototype._stat2=function(e,t,r,n,i){if(r&&(r.code==="ENOENT"||r.code==="ENOTDIR")){this.statCache[t]=false;return i()}var o=e.slice(-1)==="/";this.statCache[t]=n;if(t.slice(-1)==="/"&&n&&!n.isDirectory())return i(null,false,n);var s=true;if(n)s=n.isDirectory()?"DIR":"FILE";this.cache[t]=this.cache[t]||s;if(o&&s==="FILE")return i();return i(null,s,n)}},9010:(e,t,r)=>{e.exports=globSync;globSync.GlobSync=GlobSync;var n=r(6863);var i=r(3973);var o=i.Minimatch;var s=r(1957).Glob;var a=r(1669);var c=r(5622);var l=r(2357);var u=r(8714);var p=r(7625);var d=p.setopts;var h=p.ownProp;var m=p.childrenIgnored;var g=p.isIgnored;function globSync(e,t){if(typeof t==="function"||arguments.length===3)throw new TypeError("callback provided to sync glob\n"+"See: https://github.com/isaacs/node-glob/issues/167");return new GlobSync(e,t).found}function GlobSync(e,t){if(!e)throw new Error("must provide pattern");if(typeof t==="function"||arguments.length===3)throw new TypeError("callback provided to sync glob\n"+"See: https://github.com/isaacs/node-glob/issues/167");if(!(this instanceof GlobSync))return new GlobSync(e,t);d(this,e,t);if(this.noprocess)return this;var r=this.minimatch.set.length;this.matches=new Array(r);for(var n=0;n<r;n++){this._process(this.minimatch.set[n],n,false)}this._finish()}GlobSync.prototype._finish=function(){l(this instanceof GlobSync);if(this.realpath){var e=this;this.matches.forEach((function(t,r){var i=e.matches[r]=Object.create(null);for(var o in t){try{o=e._makeAbs(o);var s=n.realpathSync(o,e.realpathCache);i[s]=true}catch(t){if(t.syscall==="stat")i[e._makeAbs(o)]=true;else throw t}}}))}p.finish(this)};GlobSync.prototype._process=function(e,t,r){l(this instanceof GlobSync);var n=0;while(typeof e[n]==="string"){n++}var o;switch(n){case e.length:this._processSimple(e.join("/"),t);return;case 0:o=null;break;default:o=e.slice(0,n).join("/");break}var s=e.slice(n);var a;if(o===null)a=".";else if(u(o)||u(e.join("/"))){if(!o||!u(o))o="/"+o;a=o}else a=o;var c=this._makeAbs(a);if(m(this,a))return;var p=s[0]===i.GLOBSTAR;if(p)this._processGlobStar(o,a,c,s,t,r);else this._processReaddir(o,a,c,s,t,r)};GlobSync.prototype._processReaddir=function(e,t,r,n,i,o){var s=this._readdir(r,o);if(!s)return;var a=n[0];var l=!!this.minimatch.negate;var u=a._glob;var p=this.dot||u.charAt(0)===".";var d=[];for(var h=0;h<s.length;h++){var m=s[h];if(m.charAt(0)!=="."||p){var g;if(l&&!e){g=!m.match(a)}else{g=m.match(a)}if(g)d.push(m)}}var v=d.length;if(v===0)return;if(n.length===1&&!this.mark&&!this.stat){if(!this.matches[i])this.matches[i]=Object.create(null);for(var h=0;h<v;h++){var m=d[h];if(e){if(e.slice(-1)!=="/")m=e+"/"+m;else m=e+m}if(m.charAt(0)==="/"&&!this.nomount){m=c.join(this.root,m)}this._emitMatch(i,m)}return}n.shift();for(var h=0;h<v;h++){var m=d[h];var y;if(e)y=[e,m];else y=[m];this._process(y.concat(n),i,o)}};GlobSync.prototype._emitMatch=function(e,t){if(g(this,t))return;var r=this._makeAbs(t);if(this.mark)t=this._mark(t);if(this.absolute){t=r}if(this.matches[e][t])return;if(this.nodir){var n=this.cache[r];if(n==="DIR"||Array.isArray(n))return}this.matches[e][t]=true;if(this.stat)this._stat(t)};GlobSync.prototype._readdirInGlobStar=function(e){if(this.follow)return this._readdir(e,false);var t;var r;var n;try{r=this.fs.lstatSync(e)}catch(e){if(e.code==="ENOENT"){return null}}var i=r&&r.isSymbolicLink();this.symlinks[e]=i;if(!i&&r&&!r.isDirectory())this.cache[e]="FILE";else t=this._readdir(e,false);return t};GlobSync.prototype._readdir=function(e,t){var r;if(t&&!h(this.symlinks,e))return this._readdirInGlobStar(e);if(h(this.cache,e)){var n=this.cache[e];if(!n||n==="FILE")return null;if(Array.isArray(n))return n}try{return this._readdirEntries(e,this.fs.readdirSync(e))}catch(t){this._readdirError(e,t);return null}};GlobSync.prototype._readdirEntries=function(e,t){if(!this.mark&&!this.stat){for(var r=0;r<t.length;r++){var n=t[r];if(e==="/")n=e+n;else n=e+"/"+n;this.cache[n]=true}}this.cache[e]=t;return t};GlobSync.prototype._readdirError=function(e,t){switch(t.code){case"ENOTSUP":case"ENOTDIR":var r=this._makeAbs(e);this.cache[r]="FILE";if(r===this.cwdAbs){var n=new Error(t.code+" invalid cwd "+this.cwd);n.path=this.cwd;n.code=t.code;throw n}break;case"ENOENT":case"ELOOP":case"ENAMETOOLONG":case"UNKNOWN":this.cache[this._makeAbs(e)]=false;break;default:this.cache[this._makeAbs(e)]=false;if(this.strict)throw t;if(!this.silent)console.error("glob error",t);break}};GlobSync.prototype._processGlobStar=function(e,t,r,n,i,o){var s=this._readdir(r,o);if(!s)return;var a=n.slice(1);var c=e?[e]:[];var l=c.concat(a);this._process(l,i,false);var u=s.length;var p=this.symlinks[r];if(p&&o)return;for(var d=0;d<u;d++){var h=s[d];if(h.charAt(0)==="."&&!this.dot)continue;var m=c.concat(s[d],a);this._process(m,i,true);var g=c.concat(s[d],n);this._process(g,i,true)}};GlobSync.prototype._processSimple=function(e,t){var r=this._stat(e);if(!this.matches[t])this.matches[t]=Object.create(null);if(!r)return;if(e&&u(e)&&!this.nomount){var n=/[\/\\]$/.test(e);if(e.charAt(0)==="/"){e=c.join(this.root,e)}else{e=c.resolve(this.root,e);if(n)e+="/"}}if(process.platform==="win32")e=e.replace(/\\/g,"/");this._emitMatch(t,e)};GlobSync.prototype._stat=function(e){var t=this._makeAbs(e);var r=e.slice(-1)==="/";if(e.length>this.maxLength)return false;if(!this.stat&&h(this.cache,t)){var n=this.cache[t];if(Array.isArray(n))n="DIR";if(!r||n==="DIR")return n;if(r&&n==="FILE")return false}var i;var o=this.statCache[t];if(!o){var s;try{s=this.fs.lstatSync(t)}catch(e){if(e&&(e.code==="ENOENT"||e.code==="ENOTDIR")){this.statCache[t]=false;return false}}if(s&&s.isSymbolicLink()){try{o=this.fs.statSync(t)}catch(e){o=s}}else{o=s}}this.statCache[t]=o;var n=true;if(o)n=o.isDirectory()?"DIR":"FILE";this.cache[t]=this.cache[t]||n;if(r&&n==="FILE")return false;return n};GlobSync.prototype._mark=function(e){return p.mark(this,e)};GlobSync.prototype._makeAbs=function(e){return p.makeAbs(this,e)}},2492:(e,t,r)=>{var n=r(2940);var i=Object.create(null);var o=r(1223);e.exports=n(inflight);function inflight(e,t){if(i[e]){i[e].push(t);return null}else{i[e]=[t];return makeres(e)}}function makeres(e){return o((function RES(){var t=i[e];var r=t.length;var n=slice(arguments);try{for(var o=0;o<r;o++){t[o].apply(null,n)}}finally{if(t.length>r){t.splice(0,r);process.nextTick((function(){RES.apply(null,n)}))}else{delete i[e]}}}))}function slice(e){var t=e.length;var r=[];for(var n=0;n<t;n++)r[n]=e[n];return r}},4124:(e,t,r)=>{try{var n=r(1669);if(typeof n.inherits!=="function")throw"";e.exports=n.inherits}catch(t){e.exports=r(8544)}},8544:e=>{if(typeof Object.create==="function"){e.exports=function inherits(e,t){if(t){e.super_=t;e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:false,writable:true,configurable:true}})}}}else{e.exports=function inherits(e,t){if(t){e.super_=t;var TempCtor=function(){};TempCtor.prototype=t.prototype;e.prototype=new TempCtor;e.prototype.constructor=e}}}},5625:e=>{
|
|
/*!
|
|
* Determine if an object is a Buffer
|
|
*
|
|
* @author Feross Aboukhadijeh <https://feross.org>
|
|
* @license MIT
|
|
*/
|
|
e.exports=function(e){return e!=null&&(isBuffer(e)||isSlowBuffer(e)||!!e._isBuffer)};function isBuffer(e){return!!e.constructor&&typeof e.constructor.isBuffer==="function"&&e.constructor.isBuffer(e)}function isSlowBuffer(e){return typeof e.readFloatLE==="function"&&typeof e.slice==="function"&&isBuffer(e.slice(0,0))}},1711:(e,t,r)=>{(function(){var t=r(7935),n=r(421).utf8,i=r(5625),o=r(421).bin,md5=function(e,r){if(e.constructor==String)if(r&&r.encoding==="binary")e=o.stringToBytes(e);else e=n.stringToBytes(e);else if(i(e))e=Array.prototype.slice.call(e,0);else if(!Array.isArray(e)&&e.constructor!==Uint8Array)e=e.toString();var s=t.bytesToWords(e),a=e.length*8,c=1732584193,l=-271733879,u=-1732584194,p=271733878;for(var d=0;d<s.length;d++){s[d]=(s[d]<<8|s[d]>>>24)&16711935|(s[d]<<24|s[d]>>>8)&4278255360}s[a>>>5]|=128<<a%32;s[(a+64>>>9<<4)+14]=a;var h=md5._ff,m=md5._gg,g=md5._hh,v=md5._ii;for(var d=0;d<s.length;d+=16){var y=c,E=l,w=u,b=p;c=h(c,l,u,p,s[d+0],7,-680876936);p=h(p,c,l,u,s[d+1],12,-389564586);u=h(u,p,c,l,s[d+2],17,606105819);l=h(l,u,p,c,s[d+3],22,-1044525330);c=h(c,l,u,p,s[d+4],7,-176418897);p=h(p,c,l,u,s[d+5],12,1200080426);u=h(u,p,c,l,s[d+6],17,-1473231341);l=h(l,u,p,c,s[d+7],22,-45705983);c=h(c,l,u,p,s[d+8],7,1770035416);p=h(p,c,l,u,s[d+9],12,-1958414417);u=h(u,p,c,l,s[d+10],17,-42063);l=h(l,u,p,c,s[d+11],22,-1990404162);c=h(c,l,u,p,s[d+12],7,1804603682);p=h(p,c,l,u,s[d+13],12,-40341101);u=h(u,p,c,l,s[d+14],17,-1502002290);l=h(l,u,p,c,s[d+15],22,1236535329);c=m(c,l,u,p,s[d+1],5,-165796510);p=m(p,c,l,u,s[d+6],9,-1069501632);u=m(u,p,c,l,s[d+11],14,643717713);l=m(l,u,p,c,s[d+0],20,-373897302);c=m(c,l,u,p,s[d+5],5,-701558691);p=m(p,c,l,u,s[d+10],9,38016083);u=m(u,p,c,l,s[d+15],14,-660478335);l=m(l,u,p,c,s[d+4],20,-405537848);c=m(c,l,u,p,s[d+9],5,568446438);p=m(p,c,l,u,s[d+14],9,-1019803690);u=m(u,p,c,l,s[d+3],14,-187363961);l=m(l,u,p,c,s[d+8],20,1163531501);c=m(c,l,u,p,s[d+13],5,-1444681467);p=m(p,c,l,u,s[d+2],9,-51403784);u=m(u,p,c,l,s[d+7],14,1735328473);l=m(l,u,p,c,s[d+12],20,-1926607734);c=g(c,l,u,p,s[d+5],4,-378558);p=g(p,c,l,u,s[d+8],11,-2022574463);u=g(u,p,c,l,s[d+11],16,1839030562);l=g(l,u,p,c,s[d+14],23,-35309556);c=g(c,l,u,p,s[d+1],4,-1530992060);p=g(p,c,l,u,s[d+4],11,1272893353);u=g(u,p,c,l,s[d+7],16,-155497632);l=g(l,u,p,c,s[d+10],23,-1094730640);c=g(c,l,u,p,s[d+13],4,681279174);p=g(p,c,l,u,s[d+0],11,-358537222);u=g(u,p,c,l,s[d+3],16,-722521979);l=g(l,u,p,c,s[d+6],23,76029189);c=g(c,l,u,p,s[d+9],4,-640364487);p=g(p,c,l,u,s[d+12],11,-421815835);u=g(u,p,c,l,s[d+15],16,530742520);l=g(l,u,p,c,s[d+2],23,-995338651);c=v(c,l,u,p,s[d+0],6,-198630844);p=v(p,c,l,u,s[d+7],10,1126891415);u=v(u,p,c,l,s[d+14],15,-1416354905);l=v(l,u,p,c,s[d+5],21,-57434055);c=v(c,l,u,p,s[d+12],6,1700485571);p=v(p,c,l,u,s[d+3],10,-1894986606);u=v(u,p,c,l,s[d+10],15,-1051523);l=v(l,u,p,c,s[d+1],21,-2054922799);c=v(c,l,u,p,s[d+8],6,1873313359);p=v(p,c,l,u,s[d+15],10,-30611744);u=v(u,p,c,l,s[d+6],15,-1560198380);l=v(l,u,p,c,s[d+13],21,1309151649);c=v(c,l,u,p,s[d+4],6,-145523070);p=v(p,c,l,u,s[d+11],10,-1120210379);u=v(u,p,c,l,s[d+2],15,718787259);l=v(l,u,p,c,s[d+9],21,-343485551);c=c+y>>>0;l=l+E>>>0;u=u+w>>>0;p=p+b>>>0}return t.endian([c,l,u,p])};md5._ff=function(e,t,r,n,i,o,s){var a=e+(t&r|~t&n)+(i>>>0)+s;return(a<<o|a>>>32-o)+t};md5._gg=function(e,t,r,n,i,o,s){var a=e+(t&n|r&~n)+(i>>>0)+s;return(a<<o|a>>>32-o)+t};md5._hh=function(e,t,r,n,i,o,s){var a=e+(t^r^n)+(i>>>0)+s;return(a<<o|a>>>32-o)+t};md5._ii=function(e,t,r,n,i,o,s){var a=e+(r^(t|~n))+(i>>>0)+s;return(a<<o|a>>>32-o)+t};md5._blocksize=16;md5._digestsize=16;e.exports=function(e,r){if(e===undefined||e===null)throw new Error("Illegal argument "+e);var n=t.wordsToBytes(md5(e,r));return r&&r.asBytes?n:r&&r.asString?o.bytesToString(n):t.bytesToHex(n)}})()},3973:(e,t,r)=>{e.exports=minimatch;minimatch.Minimatch=Minimatch;var n={sep:"/"};try{n=r(5622)}catch(e){}var i=minimatch.GLOBSTAR=Minimatch.GLOBSTAR={};var o=r(3717);var s={"!":{open:"(?:(?!(?:",close:"))[^/]*?)"},"?":{open:"(?:",close:")?"},"+":{open:"(?:",close:")+"},"*":{open:"(?:",close:")*"},"@":{open:"(?:",close:")"}};var a="[^/]";var c=a+"*?";var l="(?:(?!(?:\\/|^)(?:\\.{1,2})($|\\/)).)*?";var u="(?:(?!(?:\\/|^)\\.).)*?";var p=charSet("().*{}+?[]^$\\!");function charSet(e){return e.split("").reduce((function(e,t){e[t]=true;return e}),{})}var d=/\/+/;minimatch.filter=filter;function filter(e,t){t=t||{};return function(r,n,i){return minimatch(r,e,t)}}function ext(e,t){e=e||{};t=t||{};var r={};Object.keys(t).forEach((function(e){r[e]=t[e]}));Object.keys(e).forEach((function(t){r[t]=e[t]}));return r}minimatch.defaults=function(e){if(!e||!Object.keys(e).length)return minimatch;var t=minimatch;var r=function minimatch(r,n,i){return t.minimatch(r,n,ext(e,i))};r.Minimatch=function Minimatch(r,n){return new t.Minimatch(r,ext(e,n))};return r};Minimatch.defaults=function(e){if(!e||!Object.keys(e).length)return Minimatch;return minimatch.defaults(e).Minimatch};function minimatch(e,t,r){if(typeof t!=="string"){throw new TypeError("glob pattern string required")}if(!r)r={};if(!r.nocomment&&t.charAt(0)==="#"){return false}if(t.trim()==="")return e==="";return new Minimatch(t,r).match(e)}function Minimatch(e,t){if(!(this instanceof Minimatch)){return new Minimatch(e,t)}if(typeof e!=="string"){throw new TypeError("glob pattern string required")}if(!t)t={};e=e.trim();if(n.sep!=="/"){e=e.split(n.sep).join("/")}this.options=t;this.set=[];this.pattern=e;this.regexp=null;this.negate=false;this.comment=false;this.empty=false;this.make()}Minimatch.prototype.debug=function(){};Minimatch.prototype.make=make;function make(){if(this._made)return;var e=this.pattern;var t=this.options;if(!t.nocomment&&e.charAt(0)==="#"){this.comment=true;return}if(!e){this.empty=true;return}this.parseNegate();var r=this.globSet=this.braceExpand();if(t.debug)this.debug=console.error;this.debug(this.pattern,r);r=this.globParts=r.map((function(e){return e.split(d)}));this.debug(this.pattern,r);r=r.map((function(e,t,r){return e.map(this.parse,this)}),this);this.debug(this.pattern,r);r=r.filter((function(e){return e.indexOf(false)===-1}));this.debug(this.pattern,r);this.set=r}Minimatch.prototype.parseNegate=parseNegate;function parseNegate(){var e=this.pattern;var t=false;var r=this.options;var n=0;if(r.nonegate)return;for(var i=0,o=e.length;i<o&&e.charAt(i)==="!";i++){t=!t;n++}if(n)this.pattern=e.substr(n);this.negate=t}minimatch.braceExpand=function(e,t){return braceExpand(e,t)};Minimatch.prototype.braceExpand=braceExpand;function braceExpand(e,t){if(!t){if(this instanceof Minimatch){t=this.options}else{t={}}}e=typeof e==="undefined"?this.pattern:e;if(typeof e==="undefined"){throw new TypeError("undefined pattern")}if(t.nobrace||!e.match(/\{.*\}/)){return[e]}return o(e)}Minimatch.prototype.parse=parse;var h={};function parse(e,t){if(e.length>1024*64){throw new TypeError("pattern is too long")}var r=this.options;if(!r.noglobstar&&e==="**")return i;if(e==="")return"";var n="";var o=!!r.nocase;var l=false;var u=[];var d=[];var m;var g=false;var v=-1;var y=-1;var E=e.charAt(0)==="."?"":r.dot?"(?!(?:^|\\/)\\.{1,2}(?:$|\\/))":"(?!\\.)";var w=this;function clearStateChar(){if(m){switch(m){case"*":n+=c;o=true;break;case"?":n+=a;o=true;break;default:n+="\\"+m;break}w.debug("clearStateChar %j %j",m,n);m=false}}for(var b=0,_=e.length,S;b<_&&(S=e.charAt(b));b++){this.debug("%s\t%s %s %j",e,b,n,S);if(l&&p[S]){n+="\\"+S;l=false;continue}switch(S){case"/":return false;case"\\":clearStateChar();l=true;continue;case"?":case"*":case"+":case"@":case"!":this.debug("%s\t%s %s %j <-- stateChar",e,b,n,S);if(g){this.debug(" in class");if(S==="!"&&b===y+1)S="^";n+=S;continue}w.debug("call clearStateChar %j",m);clearStateChar();m=S;if(r.noext)clearStateChar();continue;case"(":if(g){n+="(";continue}if(!m){n+="\\(";continue}u.push({type:m,start:b-1,reStart:n.length,open:s[m].open,close:s[m].close});n+=m==="!"?"(?:(?!(?:":"(?:";this.debug("plType %j %j",m,n);m=false;continue;case")":if(g||!u.length){n+="\\)";continue}clearStateChar();o=true;var O=u.pop();n+=O.close;if(O.type==="!"){d.push(O)}O.reEnd=n.length;continue;case"|":if(g||!u.length||l){n+="\\|";l=false;continue}clearStateChar();n+="|";continue;case"[":clearStateChar();if(g){n+="\\"+S;continue}g=true;y=b;v=n.length;n+=S;continue;case"]":if(b===y+1||!g){n+="\\"+S;l=false;continue}if(g){var R=e.substring(y+1,b);try{RegExp("["+R+"]")}catch(e){var C=this.parse(R,h);n=n.substr(0,v)+"\\["+C[0]+"\\]";o=o||C[1];g=false;continue}}o=true;g=false;n+=S;continue;default:clearStateChar();if(l){l=false}else if(p[S]&&!(S==="^"&&g)){n+="\\"}n+=S}}if(g){R=e.substr(y+1);C=this.parse(R,h);n=n.substr(0,v)+"\\["+C[0];o=o||C[1]}for(O=u.pop();O;O=u.pop()){var A=n.slice(O.reStart+O.open.length);this.debug("setting tail",n,O);A=A.replace(/((?:\\{2}){0,64})(\\?)\|/g,(function(e,t,r){if(!r){r="\\"}return t+t+r+"|"}));this.debug("tail=%j\n %s",A,A,O,n);var T=O.type==="*"?c:O.type==="?"?a:"\\"+O.type;o=true;n=n.slice(0,O.reStart)+T+"\\("+A}clearStateChar();if(l){n+="\\\\"}var x=false;switch(n.charAt(0)){case".":case"[":case"(":x=true}for(var I=d.length-1;I>-1;I--){var k=d[I];var N=n.slice(0,k.reStart);var P=n.slice(k.reStart,k.reEnd-8);var D=n.slice(k.reEnd-8,k.reEnd);var L=n.slice(k.reEnd);D+=L;var M=N.split("(").length-1;var $=L;for(b=0;b<M;b++){$=$.replace(/\)[+*?]?/,"")}L=$;var F="";if(L===""&&t!==h){F="$"}var j=N+P+L+F+D;n=j}if(n!==""&&o){n="(?=.)"+n}if(x){n=E+n}if(t===h){return[n,o]}if(!o){return globUnescape(e)}var U=r.nocase?"i":"";try{var G=new RegExp("^"+n+"$",U)}catch(e){return new RegExp("$.")}G._glob=e;G._src=n;return G}minimatch.makeRe=function(e,t){return new Minimatch(e,t||{}).makeRe()};Minimatch.prototype.makeRe=makeRe;function makeRe(){if(this.regexp||this.regexp===false)return this.regexp;var e=this.set;if(!e.length){this.regexp=false;return this.regexp}var t=this.options;var r=t.noglobstar?c:t.dot?l:u;var n=t.nocase?"i":"";var o=e.map((function(e){return e.map((function(e){return e===i?r:typeof e==="string"?regExpEscape(e):e._src})).join("\\/")})).join("|");o="^(?:"+o+")$";if(this.negate)o="^(?!"+o+").*$";try{this.regexp=new RegExp(o,n)}catch(e){this.regexp=false}return this.regexp}minimatch.match=function(e,t,r){r=r||{};var n=new Minimatch(t,r);e=e.filter((function(e){return n.match(e)}));if(n.options.nonull&&!e.length){e.push(t)}return e};Minimatch.prototype.match=match;function match(e,t){this.debug("match",e,this.pattern);if(this.comment)return false;if(this.empty)return e==="";if(e==="/"&&t)return true;var r=this.options;if(n.sep!=="/"){e=e.split(n.sep).join("/")}e=e.split(d);this.debug(this.pattern,"split",e);var i=this.set;this.debug(this.pattern,"set",i);var o;var s;for(s=e.length-1;s>=0;s--){o=e[s];if(o)break}for(s=0;s<i.length;s++){var a=i[s];var c=e;if(r.matchBase&&a.length===1){c=[o]}var l=this.matchOne(c,a,t);if(l){if(r.flipNegate)return true;return!this.negate}}if(r.flipNegate)return false;return this.negate}Minimatch.prototype.matchOne=function(e,t,r){var n=this.options;this.debug("matchOne",{this:this,file:e,pattern:t});this.debug("matchOne",e.length,t.length);for(var o=0,s=0,a=e.length,c=t.length;o<a&&s<c;o++,s++){this.debug("matchOne loop");var l=t[s];var u=e[o];this.debug(t,l,u);if(l===false)return false;if(l===i){this.debug("GLOBSTAR",[t,l,u]);var p=o;var d=s+1;if(d===c){this.debug("** at the end");for(;o<a;o++){if(e[o]==="."||e[o]===".."||!n.dot&&e[o].charAt(0)===".")return false}return true}while(p<a){var h=e[p];this.debug("\nglobstar while",e,p,t,d,h);if(this.matchOne(e.slice(p),t.slice(d),r)){this.debug("globstar found match!",p,a,h);return true}else{if(h==="."||h===".."||!n.dot&&h.charAt(0)==="."){this.debug("dot detected!",e,p,t,d);break}this.debug("globstar swallow a segment, and continue");p++}}if(r){this.debug("\n>>> no match, partial?",e,p,t,d);if(p===a)return true}return false}var m;if(typeof l==="string"){if(n.nocase){m=u.toLowerCase()===l.toLowerCase()}else{m=u===l}this.debug("string match",l,u,m)}else{m=u.match(l);this.debug("pattern match",l,u,m)}if(!m)return false}if(o===a&&s===c){return true}else if(o===a){return r}else if(s===c){var g=o===a-1&&e[o]==="";return g}throw new Error("wtf?")};function globUnescape(e){return e.replace(/\\(.)/g,"$1")}function regExpEscape(e){return e.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&")}},1223:(e,t,r)=>{var n=r(2940);e.exports=n(once);e.exports.strict=n(onceStrict);once.proto=once((function(){Object.defineProperty(Function.prototype,"once",{value:function(){return once(this)},configurable:true});Object.defineProperty(Function.prototype,"onceStrict",{value:function(){return onceStrict(this)},configurable:true})}));function once(e){var f=function(){if(f.called)return f.value;f.called=true;return f.value=e.apply(this,arguments)};f.called=false;return f}function onceStrict(e){var f=function(){if(f.called)throw new Error(f.onceError);f.called=true;return f.value=e.apply(this,arguments)};var t=e.name||"Function wrapped with `once`";f.onceError=t+" shouldn't be called more than once";f.called=false;return f}},8714:e=>{"use strict";function posix(e){return e.charAt(0)==="/"}function win32(e){var t=/^([a-zA-Z]:|[\\\/]{2}[^\\\/]+[\\\/]+[^\\\/]+)?([\\\/])?([\s\S]*?)$/;var r=t.exec(e);var n=r[1]||"";var i=Boolean(n&&n.charAt(1)!==":");return Boolean(r[2]||i)}e.exports=process.platform==="win32"?win32:posix;e.exports.posix=posix;e.exports.win32=win32},5911:(e,t)=>{t=e.exports=SemVer;var r;if(typeof process==="object"&&process.env&&process.env.NODE_DEBUG&&/\bsemver\b/i.test(process.env.NODE_DEBUG)){r=function(){var e=Array.prototype.slice.call(arguments,0);e.unshift("SEMVER");console.log.apply(console,e)}}else{r=function(){}}t.SEMVER_SPEC_VERSION="2.0.0";var n=256;var i=Number.MAX_SAFE_INTEGER||9007199254740991;var o=16;var s=t.re=[];var a=t.src=[];var c=t.tokens={};var l=0;function tok(e){c[e]=l++}tok("NUMERICIDENTIFIER");a[c.NUMERICIDENTIFIER]="0|[1-9]\\d*";tok("NUMERICIDENTIFIERLOOSE");a[c.NUMERICIDENTIFIERLOOSE]="[0-9]+";tok("NONNUMERICIDENTIFIER");a[c.NONNUMERICIDENTIFIER]="\\d*[a-zA-Z-][a-zA-Z0-9-]*";tok("MAINVERSION");a[c.MAINVERSION]="("+a[c.NUMERICIDENTIFIER]+")\\."+"("+a[c.NUMERICIDENTIFIER]+")\\."+"("+a[c.NUMERICIDENTIFIER]+")";tok("MAINVERSIONLOOSE");a[c.MAINVERSIONLOOSE]="("+a[c.NUMERICIDENTIFIERLOOSE]+")\\."+"("+a[c.NUMERICIDENTIFIERLOOSE]+")\\."+"("+a[c.NUMERICIDENTIFIERLOOSE]+")";tok("PRERELEASEIDENTIFIER");a[c.PRERELEASEIDENTIFIER]="(?:"+a[c.NUMERICIDENTIFIER]+"|"+a[c.NONNUMERICIDENTIFIER]+")";tok("PRERELEASEIDENTIFIERLOOSE");a[c.PRERELEASEIDENTIFIERLOOSE]="(?:"+a[c.NUMERICIDENTIFIERLOOSE]+"|"+a[c.NONNUMERICIDENTIFIER]+")";tok("PRERELEASE");a[c.PRERELEASE]="(?:-("+a[c.PRERELEASEIDENTIFIER]+"(?:\\."+a[c.PRERELEASEIDENTIFIER]+")*))";tok("PRERELEASELOOSE");a[c.PRERELEASELOOSE]="(?:-?("+a[c.PRERELEASEIDENTIFIERLOOSE]+"(?:\\."+a[c.PRERELEASEIDENTIFIERLOOSE]+")*))";tok("BUILDIDENTIFIER");a[c.BUILDIDENTIFIER]="[0-9A-Za-z-]+";tok("BUILD");a[c.BUILD]="(?:\\+("+a[c.BUILDIDENTIFIER]+"(?:\\."+a[c.BUILDIDENTIFIER]+")*))";tok("FULL");tok("FULLPLAIN");a[c.FULLPLAIN]="v?"+a[c.MAINVERSION]+a[c.PRERELEASE]+"?"+a[c.BUILD]+"?";a[c.FULL]="^"+a[c.FULLPLAIN]+"$";tok("LOOSEPLAIN");a[c.LOOSEPLAIN]="[v=\\s]*"+a[c.MAINVERSIONLOOSE]+a[c.PRERELEASELOOSE]+"?"+a[c.BUILD]+"?";tok("LOOSE");a[c.LOOSE]="^"+a[c.LOOSEPLAIN]+"$";tok("GTLT");a[c.GTLT]="((?:<|>)?=?)";tok("XRANGEIDENTIFIERLOOSE");a[c.XRANGEIDENTIFIERLOOSE]=a[c.NUMERICIDENTIFIERLOOSE]+"|x|X|\\*";tok("XRANGEIDENTIFIER");a[c.XRANGEIDENTIFIER]=a[c.NUMERICIDENTIFIER]+"|x|X|\\*";tok("XRANGEPLAIN");a[c.XRANGEPLAIN]="[v=\\s]*("+a[c.XRANGEIDENTIFIER]+")"+"(?:\\.("+a[c.XRANGEIDENTIFIER]+")"+"(?:\\.("+a[c.XRANGEIDENTIFIER]+")"+"(?:"+a[c.PRERELEASE]+")?"+a[c.BUILD]+"?"+")?)?";tok("XRANGEPLAINLOOSE");a[c.XRANGEPLAINLOOSE]="[v=\\s]*("+a[c.XRANGEIDENTIFIERLOOSE]+")"+"(?:\\.("+a[c.XRANGEIDENTIFIERLOOSE]+")"+"(?:\\.("+a[c.XRANGEIDENTIFIERLOOSE]+")"+"(?:"+a[c.PRERELEASELOOSE]+")?"+a[c.BUILD]+"?"+")?)?";tok("XRANGE");a[c.XRANGE]="^"+a[c.GTLT]+"\\s*"+a[c.XRANGEPLAIN]+"$";tok("XRANGELOOSE");a[c.XRANGELOOSE]="^"+a[c.GTLT]+"\\s*"+a[c.XRANGEPLAINLOOSE]+"$";tok("COERCE");a[c.COERCE]="(^|[^\\d])"+"(\\d{1,"+o+"})"+"(?:\\.(\\d{1,"+o+"}))?"+"(?:\\.(\\d{1,"+o+"}))?"+"(?:$|[^\\d])";tok("COERCERTL");s[c.COERCERTL]=new RegExp(a[c.COERCE],"g");tok("LONETILDE");a[c.LONETILDE]="(?:~>?)";tok("TILDETRIM");a[c.TILDETRIM]="(\\s*)"+a[c.LONETILDE]+"\\s+";s[c.TILDETRIM]=new RegExp(a[c.TILDETRIM],"g");var u="$1~";tok("TILDE");a[c.TILDE]="^"+a[c.LONETILDE]+a[c.XRANGEPLAIN]+"$";tok("TILDELOOSE");a[c.TILDELOOSE]="^"+a[c.LONETILDE]+a[c.XRANGEPLAINLOOSE]+"$";tok("LONECARET");a[c.LONECARET]="(?:\\^)";tok("CARETTRIM");a[c.CARETTRIM]="(\\s*)"+a[c.LONECARET]+"\\s+";s[c.CARETTRIM]=new RegExp(a[c.CARETTRIM],"g");var p="$1^";tok("CARET");a[c.CARET]="^"+a[c.LONECARET]+a[c.XRANGEPLAIN]+"$";tok("CARETLOOSE");a[c.CARETLOOSE]="^"+a[c.LONECARET]+a[c.XRANGEPLAINLOOSE]+"$";tok("COMPARATORLOOSE");a[c.COMPARATORLOOSE]="^"+a[c.GTLT]+"\\s*("+a[c.LOOSEPLAIN]+")$|^$";tok("COMPARATOR");a[c.COMPARATOR]="^"+a[c.GTLT]+"\\s*("+a[c.FULLPLAIN]+")$|^$";tok("COMPARATORTRIM");a[c.COMPARATORTRIM]="(\\s*)"+a[c.GTLT]+"\\s*("+a[c.LOOSEPLAIN]+"|"+a[c.XRANGEPLAIN]+")";s[c.COMPARATORTRIM]=new RegExp(a[c.COMPARATORTRIM],"g");var d="$1$2$3";tok("HYPHENRANGE");a[c.HYPHENRANGE]="^\\s*("+a[c.XRANGEPLAIN]+")"+"\\s+-\\s+"+"("+a[c.XRANGEPLAIN]+")"+"\\s*$";tok("HYPHENRANGELOOSE");a[c.HYPHENRANGELOOSE]="^\\s*("+a[c.XRANGEPLAINLOOSE]+")"+"\\s+-\\s+"+"("+a[c.XRANGEPLAINLOOSE]+")"+"\\s*$";tok("STAR");a[c.STAR]="(<|>)?=?\\s*\\*";for(var h=0;h<l;h++){r(h,a[h]);if(!s[h]){s[h]=new RegExp(a[h])}}t.parse=parse;function parse(e,t){if(!t||typeof t!=="object"){t={loose:!!t,includePrerelease:false}}if(e instanceof SemVer){return e}if(typeof e!=="string"){return null}if(e.length>n){return null}var r=t.loose?s[c.LOOSE]:s[c.FULL];if(!r.test(e)){return null}try{return new SemVer(e,t)}catch(e){return null}}t.valid=valid;function valid(e,t){var r=parse(e,t);return r?r.version:null}t.clean=clean;function clean(e,t){var r=parse(e.trim().replace(/^[=v]+/,""),t);return r?r.version:null}t.SemVer=SemVer;function SemVer(e,t){if(!t||typeof t!=="object"){t={loose:!!t,includePrerelease:false}}if(e instanceof SemVer){if(e.loose===t.loose){return e}else{e=e.version}}else if(typeof e!=="string"){throw new TypeError("Invalid Version: "+e)}if(e.length>n){throw new TypeError("version is longer than "+n+" characters")}if(!(this instanceof SemVer)){return new SemVer(e,t)}r("SemVer",e,t);this.options=t;this.loose=!!t.loose;var o=e.trim().match(t.loose?s[c.LOOSE]:s[c.FULL]);if(!o){throw new TypeError("Invalid Version: "+e)}this.raw=e;this.major=+o[1];this.minor=+o[2];this.patch=+o[3];if(this.major>i||this.major<0){throw new TypeError("Invalid major version")}if(this.minor>i||this.minor<0){throw new TypeError("Invalid minor version")}if(this.patch>i||this.patch<0){throw new TypeError("Invalid patch version")}if(!o[4]){this.prerelease=[]}else{this.prerelease=o[4].split(".").map((function(e){if(/^[0-9]+$/.test(e)){var t=+e;if(t>=0&&t<i){return t}}return e}))}this.build=o[5]?o[5].split("."):[];this.format()}SemVer.prototype.format=function(){this.version=this.major+"."+this.minor+"."+this.patch;if(this.prerelease.length){this.version+="-"+this.prerelease.join(".")}return this.version};SemVer.prototype.toString=function(){return this.version};SemVer.prototype.compare=function(e){r("SemVer.compare",this.version,this.options,e);if(!(e instanceof SemVer)){e=new SemVer(e,this.options)}return this.compareMain(e)||this.comparePre(e)};SemVer.prototype.compareMain=function(e){if(!(e instanceof SemVer)){e=new SemVer(e,this.options)}return compareIdentifiers(this.major,e.major)||compareIdentifiers(this.minor,e.minor)||compareIdentifiers(this.patch,e.patch)};SemVer.prototype.comparePre=function(e){if(!(e instanceof SemVer)){e=new SemVer(e,this.options)}if(this.prerelease.length&&!e.prerelease.length){return-1}else if(!this.prerelease.length&&e.prerelease.length){return 1}else if(!this.prerelease.length&&!e.prerelease.length){return 0}var t=0;do{var n=this.prerelease[t];var i=e.prerelease[t];r("prerelease compare",t,n,i);if(n===undefined&&i===undefined){return 0}else if(i===undefined){return 1}else if(n===undefined){return-1}else if(n===i){continue}else{return compareIdentifiers(n,i)}}while(++t)};SemVer.prototype.compareBuild=function(e){if(!(e instanceof SemVer)){e=new SemVer(e,this.options)}var t=0;do{var n=this.build[t];var i=e.build[t];r("prerelease compare",t,n,i);if(n===undefined&&i===undefined){return 0}else if(i===undefined){return 1}else if(n===undefined){return-1}else if(n===i){continue}else{return compareIdentifiers(n,i)}}while(++t)};SemVer.prototype.inc=function(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":if(this.prerelease.length===0){this.inc("patch",t)}this.inc("pre",t);break;case"major":if(this.minor!==0||this.patch!==0||this.prerelease.length===0){this.major++}this.minor=0;this.patch=0;this.prerelease=[];break;case"minor":if(this.patch!==0||this.prerelease.length===0){this.minor++}this.patch=0;this.prerelease=[];break;case"patch":if(this.prerelease.length===0){this.patch++}this.prerelease=[];break;case"pre":if(this.prerelease.length===0){this.prerelease=[0]}else{var r=this.prerelease.length;while(--r>=0){if(typeof this.prerelease[r]==="number"){this.prerelease[r]++;r=-2}}if(r===-1){this.prerelease.push(0)}}if(t){if(this.prerelease[0]===t){if(isNaN(this.prerelease[1])){this.prerelease=[t,0]}}else{this.prerelease=[t,0]}}break;default:throw new Error("invalid increment argument: "+e)}this.format();this.raw=this.version;return this};t.inc=inc;function inc(e,t,r,n){if(typeof r==="string"){n=r;r=undefined}try{return new SemVer(e,r).inc(t,n).version}catch(e){return null}}t.diff=diff;function diff(e,t){if(eq(e,t)){return null}else{var r=parse(e);var n=parse(t);var i="";if(r.prerelease.length||n.prerelease.length){i="pre";var o="prerelease"}for(var s in r){if(s==="major"||s==="minor"||s==="patch"){if(r[s]!==n[s]){return i+s}}}return o}}t.compareIdentifiers=compareIdentifiers;var m=/^[0-9]+$/;function compareIdentifiers(e,t){var r=m.test(e);var n=m.test(t);if(r&&n){e=+e;t=+t}return e===t?0:r&&!n?-1:n&&!r?1:e<t?-1:1}t.rcompareIdentifiers=rcompareIdentifiers;function rcompareIdentifiers(e,t){return compareIdentifiers(t,e)}t.major=major;function major(e,t){return new SemVer(e,t).major}t.minor=minor;function minor(e,t){return new SemVer(e,t).minor}t.patch=patch;function patch(e,t){return new SemVer(e,t).patch}t.compare=compare;function compare(e,t,r){return new SemVer(e,r).compare(new SemVer(t,r))}t.compareLoose=compareLoose;function compareLoose(e,t){return compare(e,t,true)}t.compareBuild=compareBuild;function compareBuild(e,t,r){var n=new SemVer(e,r);var i=new SemVer(t,r);return n.compare(i)||n.compareBuild(i)}t.rcompare=rcompare;function rcompare(e,t,r){return compare(t,e,r)}t.sort=sort;function sort(e,r){return e.sort((function(e,n){return t.compareBuild(e,n,r)}))}t.rsort=rsort;function rsort(e,r){return e.sort((function(e,n){return t.compareBuild(n,e,r)}))}t.gt=gt;function gt(e,t,r){return compare(e,t,r)>0}t.lt=lt;function lt(e,t,r){return compare(e,t,r)<0}t.eq=eq;function eq(e,t,r){return compare(e,t,r)===0}t.neq=neq;function neq(e,t,r){return compare(e,t,r)!==0}t.gte=gte;function gte(e,t,r){return compare(e,t,r)>=0}t.lte=lte;function lte(e,t,r){return compare(e,t,r)<=0}t.cmp=cmp;function cmp(e,t,r,n){switch(t){case"===":if(typeof e==="object")e=e.version;if(typeof r==="object")r=r.version;return e===r;case"!==":if(typeof e==="object")e=e.version;if(typeof r==="object")r=r.version;return e!==r;case"":case"=":case"==":return eq(e,r,n);case"!=":return neq(e,r,n);case">":return gt(e,r,n);case">=":return gte(e,r,n);case"<":return lt(e,r,n);case"<=":return lte(e,r,n);default:throw new TypeError("Invalid operator: "+t)}}t.Comparator=Comparator;function Comparator(e,t){if(!t||typeof t!=="object"){t={loose:!!t,includePrerelease:false}}if(e instanceof Comparator){if(e.loose===!!t.loose){return e}else{e=e.value}}if(!(this instanceof Comparator)){return new Comparator(e,t)}r("comparator",e,t);this.options=t;this.loose=!!t.loose;this.parse(e);if(this.semver===g){this.value=""}else{this.value=this.operator+this.semver.version}r("comp",this)}var g={};Comparator.prototype.parse=function(e){var t=this.options.loose?s[c.COMPARATORLOOSE]:s[c.COMPARATOR];var r=e.match(t);if(!r){throw new TypeError("Invalid comparator: "+e)}this.operator=r[1]!==undefined?r[1]:"";if(this.operator==="="){this.operator=""}if(!r[2]){this.semver=g}else{this.semver=new SemVer(r[2],this.options.loose)}};Comparator.prototype.toString=function(){return this.value};Comparator.prototype.test=function(e){r("Comparator.test",e,this.options.loose);if(this.semver===g||e===g){return true}if(typeof e==="string"){try{e=new SemVer(e,this.options)}catch(e){return false}}return cmp(e,this.operator,this.semver,this.options)};Comparator.prototype.intersects=function(e,t){if(!(e instanceof Comparator)){throw new TypeError("a Comparator is required")}if(!t||typeof t!=="object"){t={loose:!!t,includePrerelease:false}}var r;if(this.operator===""){if(this.value===""){return true}r=new Range(e.value,t);return satisfies(this.value,r,t)}else if(e.operator===""){if(e.value===""){return true}r=new Range(this.value,t);return satisfies(e.semver,r,t)}var n=(this.operator===">="||this.operator===">")&&(e.operator===">="||e.operator===">");var i=(this.operator==="<="||this.operator==="<")&&(e.operator==="<="||e.operator==="<");var o=this.semver.version===e.semver.version;var s=(this.operator===">="||this.operator==="<=")&&(e.operator===">="||e.operator==="<=");var a=cmp(this.semver,"<",e.semver,t)&&((this.operator===">="||this.operator===">")&&(e.operator==="<="||e.operator==="<"));var c=cmp(this.semver,">",e.semver,t)&&((this.operator==="<="||this.operator==="<")&&(e.operator===">="||e.operator===">"));return n||i||o&&s||a||c};t.Range=Range;function Range(e,t){if(!t||typeof t!=="object"){t={loose:!!t,includePrerelease:false}}if(e instanceof Range){if(e.loose===!!t.loose&&e.includePrerelease===!!t.includePrerelease){return e}else{return new Range(e.raw,t)}}if(e instanceof Comparator){return new Range(e.value,t)}if(!(this instanceof Range)){return new Range(e,t)}this.options=t;this.loose=!!t.loose;this.includePrerelease=!!t.includePrerelease;this.raw=e;this.set=e.split(/\s*\|\|\s*/).map((function(e){return this.parseRange(e.trim())}),this).filter((function(e){return e.length}));if(!this.set.length){throw new TypeError("Invalid SemVer Range: "+e)}this.format()}Range.prototype.format=function(){this.range=this.set.map((function(e){return e.join(" ").trim()})).join("||").trim();return this.range};Range.prototype.toString=function(){return this.range};Range.prototype.parseRange=function(e){var t=this.options.loose;e=e.trim();var n=t?s[c.HYPHENRANGELOOSE]:s[c.HYPHENRANGE];e=e.replace(n,hyphenReplace);r("hyphen replace",e);e=e.replace(s[c.COMPARATORTRIM],d);r("comparator trim",e,s[c.COMPARATORTRIM]);e=e.replace(s[c.TILDETRIM],u);e=e.replace(s[c.CARETTRIM],p);e=e.split(/\s+/).join(" ");var i=t?s[c.COMPARATORLOOSE]:s[c.COMPARATOR];var o=e.split(" ").map((function(e){return parseComparator(e,this.options)}),this).join(" ").split(/\s+/);if(this.options.loose){o=o.filter((function(e){return!!e.match(i)}))}o=o.map((function(e){return new Comparator(e,this.options)}),this);return o};Range.prototype.intersects=function(e,t){if(!(e instanceof Range)){throw new TypeError("a Range is required")}return this.set.some((function(r){return isSatisfiable(r,t)&&e.set.some((function(e){return isSatisfiable(e,t)&&r.every((function(r){return e.every((function(e){return r.intersects(e,t)}))}))}))}))};function isSatisfiable(e,t){var r=true;var n=e.slice();var i=n.pop();while(r&&n.length){r=n.every((function(e){return i.intersects(e,t)}));i=n.pop()}return r}t.toComparators=toComparators;function toComparators(e,t){return new Range(e,t).set.map((function(e){return e.map((function(e){return e.value})).join(" ").trim().split(" ")}))}function parseComparator(e,t){r("comp",e,t);e=replaceCarets(e,t);r("caret",e);e=replaceTildes(e,t);r("tildes",e);e=replaceXRanges(e,t);r("xrange",e);e=replaceStars(e,t);r("stars",e);return e}function isX(e){return!e||e.toLowerCase()==="x"||e==="*"}function replaceTildes(e,t){return e.trim().split(/\s+/).map((function(e){return replaceTilde(e,t)})).join(" ")}function replaceTilde(e,t){var n=t.loose?s[c.TILDELOOSE]:s[c.TILDE];return e.replace(n,(function(t,n,i,o,s){r("tilde",e,t,n,i,o,s);var a;if(isX(n)){a=""}else if(isX(i)){a=">="+n+".0.0 <"+(+n+1)+".0.0"}else if(isX(o)){a=">="+n+"."+i+".0 <"+n+"."+(+i+1)+".0"}else if(s){r("replaceTilde pr",s);a=">="+n+"."+i+"."+o+"-"+s+" <"+n+"."+(+i+1)+".0"}else{a=">="+n+"."+i+"."+o+" <"+n+"."+(+i+1)+".0"}r("tilde return",a);return a}))}function replaceCarets(e,t){return e.trim().split(/\s+/).map((function(e){return replaceCaret(e,t)})).join(" ")}function replaceCaret(e,t){r("caret",e,t);var n=t.loose?s[c.CARETLOOSE]:s[c.CARET];return e.replace(n,(function(t,n,i,o,s){r("caret",e,t,n,i,o,s);var a;if(isX(n)){a=""}else if(isX(i)){a=">="+n+".0.0 <"+(+n+1)+".0.0"}else if(isX(o)){if(n==="0"){a=">="+n+"."+i+".0 <"+n+"."+(+i+1)+".0"}else{a=">="+n+"."+i+".0 <"+(+n+1)+".0.0"}}else if(s){r("replaceCaret pr",s);if(n==="0"){if(i==="0"){a=">="+n+"."+i+"."+o+"-"+s+" <"+n+"."+i+"."+(+o+1)}else{a=">="+n+"."+i+"."+o+"-"+s+" <"+n+"."+(+i+1)+".0"}}else{a=">="+n+"."+i+"."+o+"-"+s+" <"+(+n+1)+".0.0"}}else{r("no pr");if(n==="0"){if(i==="0"){a=">="+n+"."+i+"."+o+" <"+n+"."+i+"."+(+o+1)}else{a=">="+n+"."+i+"."+o+" <"+n+"."+(+i+1)+".0"}}else{a=">="+n+"."+i+"."+o+" <"+(+n+1)+".0.0"}}r("caret return",a);return a}))}function replaceXRanges(e,t){r("replaceXRanges",e,t);return e.split(/\s+/).map((function(e){return replaceXRange(e,t)})).join(" ")}function replaceXRange(e,t){e=e.trim();var n=t.loose?s[c.XRANGELOOSE]:s[c.XRANGE];return e.replace(n,(function(n,i,o,s,a,c){r("xRange",e,n,i,o,s,a,c);var l=isX(o);var u=l||isX(s);var p=u||isX(a);var d=p;if(i==="="&&d){i=""}c=t.includePrerelease?"-0":"";if(l){if(i===">"||i==="<"){n="<0.0.0-0"}else{n="*"}}else if(i&&d){if(u){s=0}a=0;if(i===">"){i=">=";if(u){o=+o+1;s=0;a=0}else{s=+s+1;a=0}}else if(i==="<="){i="<";if(u){o=+o+1}else{s=+s+1}}n=i+o+"."+s+"."+a+c}else if(u){n=">="+o+".0.0"+c+" <"+(+o+1)+".0.0"+c}else if(p){n=">="+o+"."+s+".0"+c+" <"+o+"."+(+s+1)+".0"+c}r("xRange return",n);return n}))}function replaceStars(e,t){r("replaceStars",e,t);return e.trim().replace(s[c.STAR],"")}function hyphenReplace(e,t,r,n,i,o,s,a,c,l,u,p,d){if(isX(r)){t=""}else if(isX(n)){t=">="+r+".0.0"}else if(isX(i)){t=">="+r+"."+n+".0"}else{t=">="+t}if(isX(c)){a=""}else if(isX(l)){a="<"+(+c+1)+".0.0"}else if(isX(u)){a="<"+c+"."+(+l+1)+".0"}else if(p){a="<="+c+"."+l+"."+u+"-"+p}else{a="<="+a}return(t+" "+a).trim()}Range.prototype.test=function(e){if(!e){return false}if(typeof e==="string"){try{e=new SemVer(e,this.options)}catch(e){return false}}for(var t=0;t<this.set.length;t++){if(testSet(this.set[t],e,this.options)){return true}}return false};function testSet(e,t,n){for(var i=0;i<e.length;i++){if(!e[i].test(t)){return false}}if(t.prerelease.length&&!n.includePrerelease){for(i=0;i<e.length;i++){r(e[i].semver);if(e[i].semver===g){continue}if(e[i].semver.prerelease.length>0){var o=e[i].semver;if(o.major===t.major&&o.minor===t.minor&&o.patch===t.patch){return true}}}return false}return true}t.satisfies=satisfies;function satisfies(e,t,r){try{t=new Range(t,r)}catch(e){return false}return t.test(e)}t.maxSatisfying=maxSatisfying;function maxSatisfying(e,t,r){var n=null;var i=null;try{var o=new Range(t,r)}catch(e){return null}e.forEach((function(e){if(o.test(e)){if(!n||i.compare(e)===-1){n=e;i=new SemVer(n,r)}}}));return n}t.minSatisfying=minSatisfying;function minSatisfying(e,t,r){var n=null;var i=null;try{var o=new Range(t,r)}catch(e){return null}e.forEach((function(e){if(o.test(e)){if(!n||i.compare(e)===1){n=e;i=new SemVer(n,r)}}}));return n}t.minVersion=minVersion;function minVersion(e,t){e=new Range(e,t);var r=new SemVer("0.0.0");if(e.test(r)){return r}r=new SemVer("0.0.0-0");if(e.test(r)){return r}r=null;for(var n=0;n<e.set.length;++n){var i=e.set[n];i.forEach((function(e){var t=new SemVer(e.semver.version);switch(e.operator){case">":if(t.prerelease.length===0){t.patch++}else{t.prerelease.push(0)}t.raw=t.format();case"":case">=":if(!r||gt(r,t)){r=t}break;case"<":case"<=":break;default:throw new Error("Unexpected operation: "+e.operator)}}))}if(r&&e.test(r)){return r}return null}t.validRange=validRange;function validRange(e,t){try{return new Range(e,t).range||"*"}catch(e){return null}}t.ltr=ltr;function ltr(e,t,r){return outside(e,t,"<",r)}t.gtr=gtr;function gtr(e,t,r){return outside(e,t,">",r)}t.outside=outside;function outside(e,t,r,n){e=new SemVer(e,n);t=new Range(t,n);var i,o,s,a,c;switch(r){case">":i=gt;o=lte;s=lt;a=">";c=">=";break;case"<":i=lt;o=gte;s=gt;a="<";c="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(satisfies(e,t,n)){return false}for(var l=0;l<t.set.length;++l){var u=t.set[l];var p=null;var d=null;u.forEach((function(e){if(e.semver===g){e=new Comparator(">=0.0.0")}p=p||e;d=d||e;if(i(e.semver,p.semver,n)){p=e}else if(s(e.semver,d.semver,n)){d=e}}));if(p.operator===a||p.operator===c){return false}if((!d.operator||d.operator===a)&&o(e,d.semver)){return false}else if(d.operator===c&&s(e,d.semver)){return false}}return true}t.prerelease=prerelease;function prerelease(e,t){var r=parse(e,t);return r&&r.prerelease.length?r.prerelease:null}t.intersects=intersects;function intersects(e,t,r){e=new Range(e,r);t=new Range(t,r);return e.intersects(t)}t.coerce=coerce;function coerce(e,t){if(e instanceof SemVer){return e}if(typeof e==="number"){e=String(e)}if(typeof e!=="string"){return null}t=t||{};var r=null;if(!t.rtl){r=e.match(s[c.COERCE])}else{var n;while((n=s[c.COERCERTL].exec(e))&&(!r||r.index+r[0].length!==e.length)){if(!r||n.index+n[0].length!==r.index+r[0].length){r=n}s[c.COERCERTL].lastIndex=n.index+n[1].length+n[2].length}s[c.COERCERTL].lastIndex=-1}if(r===null){return null}return parse(r[2]+"."+(r[3]||"0")+"."+(r[4]||"0"),t)}},8065:(e,t,r)=>{const{promisify:n}=r(1669);const i=r(8517);e.exports.fileSync=i.fileSync;const o=n(((e,t)=>i.file(e,((e,r,i,o)=>e?t(e):t(undefined,{path:r,fd:i,cleanup:n(o)})))));e.exports.file=async e=>o(e);e.exports.withFile=async function withFile(t,r){const{path:n,fd:i,cleanup:o}=await e.exports.file(r);try{return await t({path:n,fd:i})}finally{await o()}};e.exports.dirSync=i.dirSync;const s=n(((e,t)=>i.dir(e,((e,r,i)=>e?t(e):t(undefined,{path:r,cleanup:n(i)})))));e.exports.dir=async e=>s(e);e.exports.withDir=async function withDir(t,r){const{path:n,cleanup:i}=await e.exports.dir(r);try{return await t({path:n})}finally{await i()}};e.exports.tmpNameSync=i.tmpNameSync;e.exports.tmpName=n(i.tmpName);e.exports.tmpdir=i.tmpdir;e.exports.setGracefulCleanup=i.setGracefulCleanup},8517:(e,t,r)=>{
|
|
/*!
|
|
* Tmp
|
|
*
|
|
* Copyright (c) 2011-2017 KARASZI Istvan <github@spam.raszi.hu>
|
|
*
|
|
* MIT Licensed
|
|
*/
|
|
const n=r(5747);const i=r(2087);const o=r(5622);const s=r(6417);const a=n.constants&&i.constants?{fs:n.constants,os:i.constants}:process.binding("constants");const c=r(2371);const l="0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz",u=/XXXXXX/,p=3,d=(a.O_CREAT||a.fs.O_CREAT)|(a.O_EXCL||a.fs.O_EXCL)|(a.O_RDWR||a.fs.O_RDWR),h=a.EBADF||a.os.errno.EBADF,m=a.ENOENT||a.os.errno.ENOENT,g=448,v=384,y="exit",E="SIGINT",w=[];var b=false;function _randomChars(e){var t=[],r=null;try{r=s.randomBytes(e)}catch(t){r=s.pseudoRandomBytes(e)}for(var n=0;n<e;n++){t.push(l[r[n]%l.length])}return t.join("")}function _isUndefined(e){return typeof e==="undefined"}function _parseArguments(e,t){if(typeof e==="function"){return[{},e]}if(_isUndefined(e)){return[{},t]}return[e,t]}function _generateTmpName(e){const t=_getTmpDir();if(isBlank(e.dir)&&isBlank(t)){throw new Error("No tmp dir specified")}if(!isBlank(e.name)){return o.join(e.dir||t,e.name)}if(e.template){var r=e.template;if(o.basename(r)===r)r=o.join(e.dir||t,r);return r.replace(u,_randomChars(6))}const n=[isBlank(e.prefix)?"tmp-":e.prefix,process.pid,_randomChars(12),e.postfix?e.postfix:""].join("");return o.join(e.dir||t,n)}function tmpName(e,t){var r=_parseArguments(e,t),i=r[0],o=r[1],s=!isBlank(i.name)?1:i.tries||p;if(isNaN(s)||s<0)return o(new Error("Invalid tries"));if(i.template&&!i.template.match(u))return o(new Error("Invalid template provided"));(function _getUniqueName(){try{const e=_generateTmpName(i);n.stat(e,(function(t){if(!t){if(s-- >0)return _getUniqueName();return o(new Error("Could not get a unique tmp filename, max tries reached "+e))}o(null,e)}))}catch(e){o(e)}})()}function tmpNameSync(e){var t=_parseArguments(e),r=t[0],i=!isBlank(r.name)?1:r.tries||p;if(isNaN(i)||i<0)throw new Error("Invalid tries");if(r.template&&!r.template.match(u))throw new Error("Invalid template provided");do{const e=_generateTmpName(r);try{n.statSync(e)}catch(t){return e}}while(i-- >0);throw new Error("Could not get a unique tmp filename, max tries reached")}function file(e,t){var r=_parseArguments(e,t),i=r[0],o=r[1];tmpName(i,(function _tmpNameCreated(e,t){if(e)return o(e);n.open(t,d,i.mode||v,(function _fileCreated(e,r){if(e)return o(e);if(i.discardDescriptor){return n.close(r,(function _discardCallback(e){if(e){try{n.unlinkSync(t)}catch(t){if(!isENOENT(t)){e=t}}return o(e)}o(null,t,undefined,_prepareTmpFileRemoveCallback(t,-1,i))}))}if(i.detachDescriptor){return o(null,t,r,_prepareTmpFileRemoveCallback(t,-1,i))}o(null,t,r,_prepareTmpFileRemoveCallback(t,r,i))}))}))}function fileSync(e){var t=_parseArguments(e),r=t[0];const i=r.discardDescriptor||r.detachDescriptor;const o=tmpNameSync(r);var s=n.openSync(o,d,r.mode||v);if(r.discardDescriptor){n.closeSync(s);s=undefined}return{name:o,fd:s,removeCallback:_prepareTmpFileRemoveCallback(o,i?-1:s,r)}}function dir(e,t){var r=_parseArguments(e,t),i=r[0],o=r[1];tmpName(i,(function _tmpNameCreated(e,t){if(e)return o(e);n.mkdir(t,i.mode||g,(function _dirCreated(e){if(e)return o(e);o(null,t,_prepareTmpDirRemoveCallback(t,i))}))}))}function dirSync(e){var t=_parseArguments(e),r=t[0];const i=tmpNameSync(r);n.mkdirSync(i,r.mode||g);return{name:i,removeCallback:_prepareTmpDirRemoveCallback(i,r)}}function _removeFileAsync(e,t){const _handler=function(e){if(e&&!isENOENT(e)){return t(e)}t()};if(0<=e[0])n.close(e[0],(function(t){n.unlink(e[1],_handler)}));else n.unlink(e[1],_handler)}function _removeFileSync(e){try{if(0<=e[0])n.closeSync(e[0])}catch(e){if(!isEBADF(e)&&!isENOENT(e))throw e}finally{try{n.unlinkSync(e[1])}catch(e){if(!isENOENT(e))throw e}}}function _prepareTmpFileRemoveCallback(e,t,r){const n=_prepareRemoveCallback(_removeFileSync,[t,e]);const i=_prepareRemoveCallback(_removeFileAsync,[t,e],n);if(!r.keep)w.unshift(n);return i}function _rimrafRemoveDirWrapper(e,t){c(e,t)}function _rimrafRemoveDirSyncWrapper(e,t){try{return t(null,c.sync(e))}catch(e){return t(e)}}function _prepareTmpDirRemoveCallback(e,t){const r=t.unsafeCleanup?_rimrafRemoveDirWrapper:n.rmdir.bind(n);const i=t.unsafeCleanup?_rimrafRemoveDirSyncWrapper:n.rmdirSync.bind(n);const o=_prepareRemoveCallback(i,e);const s=_prepareRemoveCallback(r,e,o);if(!t.keep)w.unshift(o);return s}function _prepareRemoveCallback(e,t,r){var n=false;return function _cleanupCallback(i){i=i||function(){};if(!n){const o=r||_cleanupCallback;const s=w.indexOf(o);if(s>=0)w.splice(s,1);n=true;if(e.length===1){try{e(t);return i(null)}catch(e){return i(e)}}else return e(t,i)}else return i(new Error("cleanup callback has already been called"))}}function _garbageCollector(){if(!b)return;while(w.length){try{w[0]()}catch(e){}}}function isEBADF(e){return isExpectedError(e,-h,"EBADF")}function isENOENT(e){return isExpectedError(e,-m,"ENOENT")}function isExpectedError(e,t,r){return e.code===t||e.code===r}function isBlank(e){return e===null||e===undefined||!e.trim()}function setGracefulCleanup(){b=true}function _getTmpDir(){return i.tmpdir()}function _is_legacy_listener(e){return(e.name==="_exit"||e.name==="_uncaughtExceptionThrown")&&e.toString().indexOf("_garbageCollector();")>-1}function _safely_install_sigint_listener(){const e=process.listeners(E);const t=[];for(let r=0,n=e.length;r<n;r++){const n=e[r];if(n.name==="_tmp$sigint_listener"){t.push(n);process.removeListener(E,n)}}process.on(E,(function _tmp$sigint_listener(e){for(let e=0,r=t.length;e<r;e++){try{t[e](false)}catch(e){}}try{_garbageCollector()}finally{if(!!e){process.exit(0)}}}))}function _safely_install_exit_listener(){const e=process.listeners(y);const t=[];for(let r=0,n=e.length;r<n;r++){const n=e[r];if(n.name==="_tmp$safe_listener"||_is_legacy_listener(n)){if(n.name!=="_uncaughtExceptionThrown"){t.push(n)}process.removeListener(y,n)}}process.addListener(y,(function _tmp$safe_listener(e){for(let r=0,n=t.length;r<n;r++){try{t[r](e)}catch(e){}}_garbageCollector()}))}_safely_install_exit_listener();_safely_install_sigint_listener();Object.defineProperty(e.exports,"tmpdir",{enumerable:true,configurable:false,get:function(){return _getTmpDir()}});e.exports.dir=dir;e.exports.dirSync=dirSync;e.exports.file=file;e.exports.fileSync=fileSync;e.exports.tmpName=tmpName;e.exports.tmpNameSync=tmpNameSync;e.exports.setGracefulCleanup=setGracefulCleanup},2371:(e,t,r)=>{e.exports=rimraf;rimraf.sync=rimrafSync;var n=r(2357);var i=r(5622);var o=r(5747);var s=undefined;try{s=r(1957)}catch(e){}var a=parseInt("666",8);var c={nosort:true,silent:true};var l=0;var u=process.platform==="win32";function defaults(e){var t=["unlink","chmod","stat","lstat","rmdir","readdir"];t.forEach((function(t){e[t]=e[t]||o[t];t=t+"Sync";e[t]=e[t]||o[t]}));e.maxBusyTries=e.maxBusyTries||3;e.emfileWait=e.emfileWait||1e3;if(e.glob===false){e.disableGlob=true}if(e.disableGlob!==true&&s===undefined){throw Error("glob dependency not found, set `options.disableGlob = true` if intentional")}e.disableGlob=e.disableGlob||false;e.glob=e.glob||c}function rimraf(e,t,r){if(typeof t==="function"){r=t;t={}}n(e,"rimraf: missing path");n.equal(typeof e,"string","rimraf: path should be a string");n.equal(typeof r,"function","rimraf: callback function required");n(t,"rimraf: invalid options argument provided");n.equal(typeof t,"object","rimraf: options should be object");defaults(t);var i=0;var o=null;var a=0;if(t.disableGlob||!s.hasMagic(e))return afterGlob(null,[e]);t.lstat(e,(function(r,n){if(!r)return afterGlob(null,[e]);s(e,t.glob,afterGlob)}));function next(e){o=o||e;if(--a===0)r(o)}function afterGlob(e,n){if(e)return r(e);a=n.length;if(a===0)return r();n.forEach((function(e){rimraf_(e,t,(function CB(r){if(r){if((r.code==="EBUSY"||r.code==="ENOTEMPTY"||r.code==="EPERM")&&i<t.maxBusyTries){i++;var n=i*100;return setTimeout((function(){rimraf_(e,t,CB)}),n)}if(r.code==="EMFILE"&&l<t.emfileWait){return setTimeout((function(){rimraf_(e,t,CB)}),l++)}if(r.code==="ENOENT")r=null}l=0;next(r)}))}))}}function rimraf_(e,t,r){n(e);n(t);n(typeof r==="function");t.lstat(e,(function(n,i){if(n&&n.code==="ENOENT")return r(null);if(n&&n.code==="EPERM"&&u)fixWinEPERM(e,t,n,r);if(i&&i.isDirectory())return rmdir(e,t,n,r);t.unlink(e,(function(n){if(n){if(n.code==="ENOENT")return r(null);if(n.code==="EPERM")return u?fixWinEPERM(e,t,n,r):rmdir(e,t,n,r);if(n.code==="EISDIR")return rmdir(e,t,n,r)}return r(n)}))}))}function fixWinEPERM(e,t,r,i){n(e);n(t);n(typeof i==="function");if(r)n(r instanceof Error);t.chmod(e,a,(function(n){if(n)i(n.code==="ENOENT"?null:r);else t.stat(e,(function(n,o){if(n)i(n.code==="ENOENT"?null:r);else if(o.isDirectory())rmdir(e,t,r,i);else t.unlink(e,i)}))}))}function fixWinEPERMSync(e,t,r){n(e);n(t);if(r)n(r instanceof Error);try{t.chmodSync(e,a)}catch(e){if(e.code==="ENOENT")return;else throw r}try{var i=t.statSync(e)}catch(e){if(e.code==="ENOENT")return;else throw r}if(i.isDirectory())rmdirSync(e,t,r);else t.unlinkSync(e)}function rmdir(e,t,r,i){n(e);n(t);if(r)n(r instanceof Error);n(typeof i==="function");t.rmdir(e,(function(n){if(n&&(n.code==="ENOTEMPTY"||n.code==="EEXIST"||n.code==="EPERM"))rmkids(e,t,i);else if(n&&n.code==="ENOTDIR")i(r);else i(n)}))}function rmkids(e,t,r){n(e);n(t);n(typeof r==="function");t.readdir(e,(function(n,o){if(n)return r(n);var s=o.length;if(s===0)return t.rmdir(e,r);var a;o.forEach((function(n){rimraf(i.join(e,n),t,(function(n){if(a)return;if(n)return r(a=n);if(--s===0)t.rmdir(e,r)}))}))}))}function rimrafSync(e,t){t=t||{};defaults(t);n(e,"rimraf: missing path");n.equal(typeof e,"string","rimraf: path should be a string");n(t,"rimraf: missing options");n.equal(typeof t,"object","rimraf: options should be object");var r;if(t.disableGlob||!s.hasMagic(e)){r=[e]}else{try{t.lstatSync(e);r=[e]}catch(n){r=s.sync(e,t.glob)}}if(!r.length)return;for(var i=0;i<r.length;i++){var e=r[i];try{var o=t.lstatSync(e)}catch(r){if(r.code==="ENOENT")return;if(r.code==="EPERM"&&u)fixWinEPERMSync(e,t,r)}try{if(o&&o.isDirectory())rmdirSync(e,t,null);else t.unlinkSync(e)}catch(r){if(r.code==="ENOENT")return;if(r.code==="EPERM")return u?fixWinEPERMSync(e,t,r):rmdirSync(e,t,r);if(r.code!=="EISDIR")throw r;rmdirSync(e,t,r)}}}function rmdirSync(e,t,r){n(e);n(t);if(r)n(r instanceof Error);try{t.rmdirSync(e)}catch(n){if(n.code==="ENOENT")return;if(n.code==="ENOTDIR")throw r;if(n.code==="ENOTEMPTY"||n.code==="EEXIST"||n.code==="EPERM")rmkidsSync(e,t)}}function rmkidsSync(e,t){n(e);n(t);t.readdirSync(e).forEach((function(r){rimrafSync(i.join(e,r),t)}));var r=u?100:1;var o=0;do{var s=true;try{var a=t.rmdirSync(e,t);s=false;return a}finally{if(++o<r&&s)continue}}while(true)}},4294:(e,t,r)=>{e.exports=r(4219)},4219:(e,t,r)=>{"use strict";var n=r(1631);var i=r(4016);var o=r(8605);var s=r(7211);var a=r(8614);var c=r(2357);var l=r(1669);t.httpOverHttp=httpOverHttp;t.httpsOverHttp=httpsOverHttp;t.httpOverHttps=httpOverHttps;t.httpsOverHttps=httpsOverHttps;function httpOverHttp(e){var t=new TunnelingAgent(e);t.request=o.request;return t}function httpsOverHttp(e){var t=new TunnelingAgent(e);t.request=o.request;t.createSocket=createSecureSocket;t.defaultPort=443;return t}function httpOverHttps(e){var t=new TunnelingAgent(e);t.request=s.request;return t}function httpsOverHttps(e){var t=new TunnelingAgent(e);t.request=s.request;t.createSocket=createSecureSocket;t.defaultPort=443;return t}function TunnelingAgent(e){var t=this;t.options=e||{};t.proxyOptions=t.options.proxy||{};t.maxSockets=t.options.maxSockets||o.Agent.defaultMaxSockets;t.requests=[];t.sockets=[];t.on("free",(function onFree(e,r,n,i){var o=toOptions(r,n,i);for(var s=0,a=t.requests.length;s<a;++s){var c=t.requests[s];if(c.host===o.host&&c.port===o.port){t.requests.splice(s,1);c.request.onSocket(e);return}}e.destroy();t.removeSocket(e)}))}l.inherits(TunnelingAgent,a.EventEmitter);TunnelingAgent.prototype.addRequest=function addRequest(e,t,r,n){var i=this;var o=mergeOptions({request:e},i.options,toOptions(t,r,n));if(i.sockets.length>=this.maxSockets){i.requests.push(o);return}i.createSocket(o,(function(t){t.on("free",onFree);t.on("close",onCloseOrRemove);t.on("agentRemove",onCloseOrRemove);e.onSocket(t);function onFree(){i.emit("free",t,o)}function onCloseOrRemove(e){i.removeSocket(t);t.removeListener("free",onFree);t.removeListener("close",onCloseOrRemove);t.removeListener("agentRemove",onCloseOrRemove)}}))};TunnelingAgent.prototype.createSocket=function createSocket(e,t){var r=this;var n={};r.sockets.push(n);var i=mergeOptions({},r.proxyOptions,{method:"CONNECT",path:e.host+":"+e.port,agent:false,headers:{host:e.host+":"+e.port}});if(e.localAddress){i.localAddress=e.localAddress}if(i.proxyAuth){i.headers=i.headers||{};i.headers["Proxy-Authorization"]="Basic "+new Buffer(i.proxyAuth).toString("base64")}u("making CONNECT request");var o=r.request(i);o.useChunkedEncodingByDefault=false;o.once("response",onResponse);o.once("upgrade",onUpgrade);o.once("connect",onConnect);o.once("error",onError);o.end();function onResponse(e){e.upgrade=true}function onUpgrade(e,t,r){process.nextTick((function(){onConnect(e,t,r)}))}function onConnect(i,s,a){o.removeAllListeners();s.removeAllListeners();if(i.statusCode!==200){u("tunneling socket could not be established, statusCode=%d",i.statusCode);s.destroy();var c=new Error("tunneling socket could not be established, "+"statusCode="+i.statusCode);c.code="ECONNRESET";e.request.emit("error",c);r.removeSocket(n);return}if(a.length>0){u("got illegal response body from proxy");s.destroy();var c=new Error("got illegal response body from proxy");c.code="ECONNRESET";e.request.emit("error",c);r.removeSocket(n);return}u("tunneling connection has established");r.sockets[r.sockets.indexOf(n)]=s;return t(s)}function onError(t){o.removeAllListeners();u("tunneling socket could not be established, cause=%s\n",t.message,t.stack);var i=new Error("tunneling socket could not be established, "+"cause="+t.message);i.code="ECONNRESET";e.request.emit("error",i);r.removeSocket(n)}};TunnelingAgent.prototype.removeSocket=function removeSocket(e){var t=this.sockets.indexOf(e);if(t===-1){return}this.sockets.splice(t,1);var r=this.requests.shift();if(r){this.createSocket(r,(function(e){r.request.onSocket(e)}))}};function createSecureSocket(e,t){var r=this;TunnelingAgent.prototype.createSocket.call(r,e,(function(n){var o=e.request.getHeader("host");var s=mergeOptions({},r.options,{socket:n,servername:o?o.replace(/:.*$/,""):e.host});var a=i.connect(0,s);r.sockets[r.sockets.indexOf(n)]=a;t(a)}))}function toOptions(e,t,r){if(typeof e==="string"){return{host:e,port:t,localAddress:r}}return e}function mergeOptions(e){for(var t=1,r=arguments.length;t<r;++t){var n=arguments[t];if(typeof n==="object"){var i=Object.keys(n);for(var o=0,s=i.length;o<s;++o){var a=i[o];if(n[a]!==undefined){e[a]=n[a]}}}}return e}var u;if(process.env.NODE_DEBUG&&/\btunnel\b/.test(process.env.NODE_DEBUG)){u=function(){var e=Array.prototype.slice.call(arguments);if(typeof e[0]==="string"){e[0]="TUNNEL: "+e[0]}else{e.unshift("TUNNEL:")}console.error.apply(console,e)}}else{u=function(){}}t.debug=u},2707:e=>{var t=[];for(var r=0;r<256;++r){t[r]=(r+256).toString(16).substr(1)}function bytesToUuid(e,r){var n=r||0;var i=t;return[i[e[n++]],i[e[n++]],i[e[n++]],i[e[n++]],"-",i[e[n++]],i[e[n++]],"-",i[e[n++]],i[e[n++]],"-",i[e[n++]],i[e[n++]],"-",i[e[n++]],i[e[n++]],i[e[n++]],i[e[n++]],i[e[n++]],i[e[n++]]].join("")}e.exports=bytesToUuid},5859:(e,t,r)=>{var n=r(6417);e.exports=function nodeRNG(){return n.randomBytes(16)}},824:(e,t,r)=>{var n=r(5859);var i=r(2707);function v4(e,t,r){var o=t&&r||0;if(typeof e=="string"){t=e==="binary"?new Array(16):null;e=null}e=e||{};var s=e.random||(e.rng||n)();s[6]=s[6]&15|64;s[8]=s[8]&63|128;if(t){for(var a=0;a<16;++a){t[o+a]=s[a]}}return t||i(s)}e.exports=v4},2940:e=>{e.exports=wrappy;function wrappy(e,t){if(e&&t)return wrappy(e)(t);if(typeof e!=="function")throw new TypeError("need wrapper function");Object.keys(e).forEach((function(t){wrapper[t]=e[t]}));return wrapper;function wrapper(){var t=new Array(arguments.length);for(var r=0;r<t.length;r++){t[r]=arguments[r]}var n=e.apply(this,t);var i=t[t.length-1];if(typeof n==="function"&&n!==i){Object.keys(i).forEach((function(e){n[e]=i[e]}))}return n}}},2357:e=>{"use strict";e.exports=require("assert")},3129:e=>{"use strict";e.exports=require("child_process")},6417:e=>{"use strict";e.exports=require("crypto")},8614:e=>{"use strict";e.exports=require("events")},5747:e=>{"use strict";e.exports=require("fs")},8605:e=>{"use strict";e.exports=require("http")},7211:e=>{"use strict";e.exports=require("https")},1631:e=>{"use strict";e.exports=require("net")},2087:e=>{"use strict";e.exports=require("os")},5622:e=>{"use strict";e.exports=require("path")},630:e=>{"use strict";e.exports=require("perf_hooks")},2413:e=>{"use strict";e.exports=require("stream")},4304:e=>{"use strict";e.exports=require("string_decoder")},8213:e=>{"use strict";e.exports=require("timers")},4016:e=>{"use strict";e.exports=require("tls")},8835:e=>{"use strict";e.exports=require("url")},1669:e=>{"use strict";e.exports=require("util")},8761:e=>{"use strict";e.exports=require("zlib")}};var t={};function __nccwpck_require__(r){var n=t[r];if(n!==undefined){return n.exports}var i=t[r]={exports:{}};var o=true;try{e[r].call(i.exports,i,i.exports,__nccwpck_require__);o=false}finally{if(o)delete t[r]}return i.exports}if(typeof __nccwpck_require__!=="undefined")__nccwpck_require__.ab=__dirname+"/";var r={};(()=>{const e=__nccwpck_require__(2186);const t=__nccwpck_require__(5747);const r=__nccwpck_require__(5622);const n=__nccwpck_require__(5008);const i=__nccwpck_require__(582);const o=e.getInput("generator")||"Unix Makefiles";const s=e.getInput("build_type")||"Release";async function run(){cachePath=await i.prepareEnvironment();const a=r.join(workspaceDir,".offline","temp");try{await n.execWithLog("cmake",["-S",workspaceDir,"-B",a,"-G",o,"-D","audacity_conan_allow_prebuilt_binaries=no","-D","audacity_conan_force_build_dependencies=yes","-D",`audacity_conan_download_cache=${cachePath}`,"-D",`CMAKE_BUILD_TYPE=${s}`,"-D",`CMAKE_CONFIGURATION_TYPES=${s}`,...e.getMultilineInput("cmake_options")]);await t.promises.rm(a,{recursive:true});await n.execWithLog("conan",["remove","*","--src","--builds","--packages","--force"]);await i.upload()}catch(t){n.error(t.message);e.setFailed(t.message)}}run()})();module.exports=r})(); |