From 2101eb250ce5f56f96155666cc9fbef757b3c4e8 Mon Sep 17 00:00:00 2001 From: JP Bois Date: Wed, 22 Feb 2023 19:09:35 +0100 Subject: [PATCH] chore: fixing monorepo use case (#50) * chore: fixing monorepo use case * chore: fixing types --- dist/index.js | 2 +- src/logic/jest/doBadgesExist.test.ts | 6 ++++-- src/logic/jest/doBadgesExist.ts | 4 +--- src/logic/jest/hasCoverageEvolved.test.ts | 8 +++++--- src/logic/jest/hasCoverageEvolved.ts | 3 ++- src/workflow/actionWorkflow.test.ts | 9 ++++++--- src/workflow/actionWorkflow.ts | 15 ++++++--------- 7 files changed, 25 insertions(+), 22 deletions(-) diff --git a/dist/index.js b/dist/index.js index 20747fb..447de02 100644 --- a/dist/index.js +++ b/dist/index.js @@ -1,4 +1,4 @@ -(()=>{var __webpack_modules__={1065:function(e,a,t){"use strict";var i=this&&this.__awaiter||function(e,a,t,i){function adopt(e){return e instanceof t?e:new t((function(a){a(e)}))}return new(t||(t=Promise))((function(t,s){function fulfilled(e){try{step(i.next(e))}catch(e){s(e)}}function rejected(e){try{step(i["throw"](e))}catch(e){s(e)}}function step(e){e.done?t(e.value):adopt(e.value).then(fulfilled,rejected)}step((i=i.apply(e,a||[])).next())}))};Object.defineProperty(a,"__esModule",{value:true});a.pushBadges=void 0;const s=t(8686);const o=t(7697);const pushBadges=()=>i(void 0,void 0,void 0,(function*(){yield(0,o.exec)("git add",["./badges"]);yield(0,o.exec)("git commit",["-m",(0,s.getInput)("commit-message")]);yield(0,o.exec)("git push")}));a.pushBadges=pushBadges},3333:function(e,a,t){"use strict";var i=this&&this.__awaiter||function(e,a,t,i){function adopt(e){return e instanceof t?e:new t((function(a){a(e)}))}return new(t||(t=Promise))((function(t,s){function fulfilled(e){try{step(i.next(e))}catch(e){s(e)}}function rejected(e){try{step(i["throw"](e))}catch(e){s(e)}}function step(e){e.done?t(e.value):adopt(e.value).then(fulfilled,rejected)}step((i=i.apply(e,a||[])).next())}))};Object.defineProperty(a,"__esModule",{value:true});a.setGitConfig=void 0;const s=t(8686);const o=t(7697);const r=t(7481);const setGitConfig=()=>i(void 0,void 0,void 0,(function*(){const e=(0,s.getInput)("commit-user-email");const a=(0,s.getInput)("commit-user");yield(0,o.exec)("git config",["--global","user.name",a.length===0?r.context.actor:a]);yield(0,o.exec)("git config",["--global","user.email",e.length===0?`${r.context.actor}@users.noreply.github.com`:e])}));a.setGitConfig=setGitConfig},1864:(e,a,t)=>{"use strict";Object.defineProperty(a,"__esModule",{value:true});a.getCurrentBranch=void 0;const i=t(3848);const getCurrentBranch=()=>{var e;let a;try{a=JSON.parse((0,i.readFileSync)(process.env.GITHUB_EVENT_PATH,{encoding:"utf8"}))}catch(e){return undefined}const t=(e=a.ref)===null||e===void 0?void 0:e.split("/").slice(2).join("/");return t};a.getCurrentBranch=getCurrentBranch},1706:(e,a,t)=>{"use strict";Object.defineProperty(a,"__esModule",{value:true});a.isBranchValidForBadgesGeneration=void 0;const i=t(8686);const s=t(1864);const isBranchValidForBadgesGeneration=()=>{const e=(0,s.getCurrentBranch)();if(!e){(0,i.error)(`🔶 Unable to get current branch from github event.`);return false}let a=(0,i.getInput)("branches").split(",");if(a.length===1&&a[0].length===0){(0,i.info)(`🔶 No branches specified, defaulting to master and main`);a=["master","main"]}return a.includes(e)};a.isBranchValidForBadgesGeneration=isBranchValidForBadgesGeneration},2321:function(e,a,t){"use strict";var i=this&&this.__awaiter||function(e,a,t,i){function adopt(e){return e instanceof t?e:new t((function(a){a(e)}))}return new(t||(t=Promise))((function(t,s){function fulfilled(e){try{step(i.next(e))}catch(e){s(e)}}function rejected(e){try{step(i["throw"](e))}catch(e){s(e)}}function step(e){e.done?t(e.value):adopt(e.value).then(fulfilled,rejected)}step((i=i.apply(e,a||[])).next())}))};Object.defineProperty(a,"__esModule",{value:true});a.doBadgesExist=void 0;const s=t(3848);const doBadgesExist=()=>i(void 0,void 0,void 0,(function*(){const e=["coverage-branches.svg","coverage-functions.svg","coverage-jest coverage.svg","coverage-lines.svg","coverage-statements.svg"];const a=yield Promise.all(e.map((e=>(0,s.pathExists)(`./badges/${e}`))));return a.every((e=>e===true))}));a.doBadgesExist=doBadgesExist},3516:function(e,a,t){"use strict";var i=this&&this.__awaiter||function(e,a,t,i){function adopt(e){return e instanceof t?e:new t((function(a){a(e)}))}return new(t||(t=Promise))((function(t,s){function fulfilled(e){try{step(i.next(e))}catch(e){s(e)}}function rejected(e){try{step(i["throw"](e))}catch(e){s(e)}}function step(e){e.done?t(e.value):adopt(e.value).then(fulfilled,rejected)}step((i=i.apply(e,a||[])).next())}))};Object.defineProperty(a,"__esModule",{value:true});a.hasCoverageEvolved=void 0;const s=t(7697);const hasCoverageEvolved=e=>i(void 0,void 0,void 0,(function*(){if(!e){return true}const a=yield(0,s.exec)("git diff",["--quiet","./badges/*"],{ignoreReturnCode:true});const t=a===1;return t}));a.hasCoverageEvolved=hasCoverageEvolved},2972:function(e,a,t){"use strict";var i=this&&this.__awaiter||function(e,a,t,i){function adopt(e){return e instanceof t?e:new t((function(a){a(e)}))}return new(t||(t=Promise))((function(t,s){function fulfilled(e){try{step(i.next(e))}catch(e){s(e)}}function rejected(e){try{step(i["throw"](e))}catch(e){s(e)}}function step(e){e.done?t(e.value):adopt(e.value).then(fulfilled,rejected)}step((i=i.apply(e,a||[])).next())}))};Object.defineProperty(a,"__esModule",{value:true});a.isJestCoverageReportAvailable=void 0;const s=t(8686);const o=t(3848);const isUndefined=e=>(e===null||e===void 0?void 0:e.pct)===undefined;const isJestCoverageReportAvailable=()=>i(void 0,void 0,void 0,(function*(){const e=(0,s.getInput)("coverage-summary-path");const a=yield(0,o.pathExists)(e);if(!a){return false}const t=yield(0,o.readJson)(e);if(!t||!t.total){return false}if(isUndefined(t.total.branches)||isUndefined(t.total.functions)||isUndefined(t.total.lines)||isUndefined(t.total.statements)){return false}return true}));a.isJestCoverageReportAvailable=isJestCoverageReportAvailable},861:function(e,a,t){"use strict";var i=this&&this.__awaiter||function(e,a,t,i){function adopt(e){return e instanceof t?e:new t((function(a){a(e)}))}return new(t||(t=Promise))((function(t,s){function fulfilled(e){try{step(i.next(e))}catch(e){s(e)}}function rejected(e){try{step(i["throw"](e))}catch(e){s(e)}}function step(e){e.done?t(e.value):adopt(e.value).then(fulfilled,rejected)}step((i=i.apply(e,a||[])).next())}))};Object.defineProperty(a,"__esModule",{value:true});a.actionWorkflow=void 0;const s=t(8686);const o=t(212);const r=t(1065);const n=t(3333);const p=t(1706);const d=t(2321);const l=t(3516);const c=t(2972);const actionWorkflow=()=>i(void 0,void 0,void 0,(function*(){try{const e=(0,s.getInput)("no-commit")!=="true";if(e){const e=(0,p.isBranchValidForBadgesGeneration)();if(!e){return(0,s.info)("🔶 Current branch does not belong to the branches allowed for badges generation, task dropped.")}}const a=yield(0,c.isJestCoverageReportAvailable)();if(!a){return(0,s.setFailed)("🔶 Coverage report is missing. Did you forget to run tests or to add `json-summary` to coverageReporters in jest config?")}const t=yield(0,d.doBadgesExist)();const i=(0,s.getInput)("coverage-summary-path");const u=i===""?undefined:i;(0,s.info)(`🔶 Generating badges from ${u?u:"default coverage summary path"}`);const m=(0,s.getInput)("output-folder");if(m===""){yield(0,o.generateBadges)(u)}else{yield(0,o.generateBadges)(u,m)}if(!e){return(0,s.info)("🔶 `no-commit` set to true: badges won't be committed")}const v=yield(0,l.hasCoverageEvolved)(t);if(!v){return(0,s.info)("🔶 Coverage has not evolved, no action required.")}(0,s.info)("🔶 Pushing badges to the repo");yield(0,n.setGitConfig)();yield(0,r.pushBadges)()}catch(e){if(e instanceof Error){return(0,s.setFailed)(`🔶 Oh no! An error occured: ${e.message}`)}return(0,s.setFailed)(`🔶 Oh no! An unknown error occured`)}}));a.actionWorkflow=actionWorkflow},1514:function(e,a,t){"use strict";var i=this&&this.__createBinding||(Object.create?function(e,a,t,i){if(i===undefined)i=t;Object.defineProperty(e,i,{enumerable:true,get:function(){return a[t]}})}:function(e,a,t,i){if(i===undefined)i=t;e[i]=a[t]});var s=this&&this.__setModuleDefault||(Object.create?function(e,a){Object.defineProperty(e,"default",{enumerable:true,value:a})}:function(e,a){e["default"]=a});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var a={};if(e!=null)for(var t in e)if(t!=="default"&&Object.hasOwnProperty.call(e,t))i(a,e,t);s(a,e);return a};Object.defineProperty(a,"__esModule",{value:true});a.issue=a.issueCommand=void 0;const r=o(t(2037));const n=t(2660);function issueCommand(e,a,t){const i=new Command(e,a,t);process.stdout.write(i.toString()+r.EOL)}a.issueCommand=issueCommand;function issue(e,a=""){issueCommand(e,{},a)}a.issue=issue;const p="::";class Command{constructor(e,a,t){if(!e){e="missing.command"}this.command=e;this.properties=a;this.message=t}toString(){let e=p+this.command;if(this.properties&&Object.keys(this.properties).length>0){e+=" ";let a=true;for(const t in this.properties){if(this.properties.hasOwnProperty(t)){const i=this.properties[t];if(i){if(a){a=false}else{e+=","}e+=`${t}=${escapeProperty(i)}`}}}}e+=`${p}${escapeData(this.message)}`;return e}}function escapeData(e){return n.toCommandValue(e).replace(/%/g,"%25").replace(/\r/g,"%0D").replace(/\n/g,"%0A")}function escapeProperty(e){return n.toCommandValue(e).replace(/%/g,"%25").replace(/\r/g,"%0D").replace(/\n/g,"%0A").replace(/:/g,"%3A").replace(/,/g,"%2C")}},8686:function(e,a,t){"use strict";var i=this&&this.__createBinding||(Object.create?function(e,a,t,i){if(i===undefined)i=t;Object.defineProperty(e,i,{enumerable:true,get:function(){return a[t]}})}:function(e,a,t,i){if(i===undefined)i=t;e[i]=a[t]});var s=this&&this.__setModuleDefault||(Object.create?function(e,a){Object.defineProperty(e,"default",{enumerable:true,value:a})}:function(e,a){e["default"]=a});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var a={};if(e!=null)for(var t in e)if(t!=="default"&&Object.hasOwnProperty.call(e,t))i(a,e,t);s(a,e);return a};var r=this&&this.__awaiter||function(e,a,t,i){function adopt(e){return e instanceof t?e:new t((function(a){a(e)}))}return new(t||(t=Promise))((function(t,s){function fulfilled(e){try{step(i.next(e))}catch(e){s(e)}}function rejected(e){try{step(i["throw"](e))}catch(e){s(e)}}function step(e){e.done?t(e.value):adopt(e.value).then(fulfilled,rejected)}step((i=i.apply(e,a||[])).next())}))};Object.defineProperty(a,"__esModule",{value:true});a.getIDToken=a.getState=a.saveState=a.group=a.endGroup=a.startGroup=a.info=a.notice=a.warning=a.error=a.debug=a.isDebug=a.setFailed=a.setCommandEcho=a.setOutput=a.getBooleanInput=a.getMultilineInput=a.getInput=a.addPath=a.setSecret=a.exportVariable=a.ExitCode=void 0;const n=t(1514);const p=t(5635);const d=t(2660);const l=o(t(2037));const c=o(t(1017));const u=t(1569);var m;(function(e){e[e["Success"]=0]="Success";e[e["Failure"]=1]="Failure"})(m=a.ExitCode||(a.ExitCode={}));function exportVariable(e,a){const t=d.toCommandValue(a);process.env[e]=t;const i=process.env["GITHUB_ENV"]||"";if(i){return p.issueFileCommand("ENV",p.prepareKeyValueMessage(e,a))}n.issueCommand("set-env",{name:e},t)}a.exportVariable=exportVariable;function setSecret(e){n.issueCommand("add-mask",{},e)}a.setSecret=setSecret;function addPath(e){const a=process.env["GITHUB_PATH"]||"";if(a){p.issueFileCommand("PATH",e)}else{n.issueCommand("add-path",{},e)}process.env["PATH"]=`${e}${c.delimiter}${process.env["PATH"]}`}a.addPath=addPath;function getInput(e,a){const t=process.env[`INPUT_${e.replace(/ /g,"_").toUpperCase()}`]||"";if(a&&a.required&&!t){throw new Error(`Input required and not supplied: ${e}`)}if(a&&a.trimWhitespace===false){return t}return t.trim()}a.getInput=getInput;function getMultilineInput(e,a){const t=getInput(e,a).split("\n").filter((e=>e!==""));if(a&&a.trimWhitespace===false){return t}return t.map((e=>e.trim()))}a.getMultilineInput=getMultilineInput;function getBooleanInput(e,a){const t=["true","True","TRUE"];const i=["false","False","FALSE"];const s=getInput(e,a);if(t.includes(s))return true;if(i.includes(s))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\``)}a.getBooleanInput=getBooleanInput;function setOutput(e,a){const t=process.env["GITHUB_OUTPUT"]||"";if(t){return p.issueFileCommand("OUTPUT",p.prepareKeyValueMessage(e,a))}process.stdout.write(l.EOL);n.issueCommand("set-output",{name:e},d.toCommandValue(a))}a.setOutput=setOutput;function setCommandEcho(e){n.issue("echo",e?"on":"off")}a.setCommandEcho=setCommandEcho;function setFailed(e){process.exitCode=m.Failure;error(e)}a.setFailed=setFailed;function isDebug(){return process.env["RUNNER_DEBUG"]==="1"}a.isDebug=isDebug;function debug(e){n.issueCommand("debug",{},e)}a.debug=debug;function error(e,a={}){n.issueCommand("error",d.toCommandProperties(a),e instanceof Error?e.toString():e)}a.error=error;function warning(e,a={}){n.issueCommand("warning",d.toCommandProperties(a),e instanceof Error?e.toString():e)}a.warning=warning;function notice(e,a={}){n.issueCommand("notice",d.toCommandProperties(a),e instanceof Error?e.toString():e)}a.notice=notice;function info(e){process.stdout.write(e+l.EOL)}a.info=info;function startGroup(e){n.issue("group",e)}a.startGroup=startGroup;function endGroup(){n.issue("endgroup")}a.endGroup=endGroup;function group(e,a){return r(this,void 0,void 0,(function*(){startGroup(e);let t;try{t=yield a()}finally{endGroup()}return t}))}a.group=group;function saveState(e,a){const t=process.env["GITHUB_STATE"]||"";if(t){return p.issueFileCommand("STATE",p.prepareKeyValueMessage(e,a))}n.issueCommand("save-state",{name:e},d.toCommandValue(a))}a.saveState=saveState;function getState(e){return process.env[`STATE_${e}`]||""}a.getState=getState;function getIDToken(e){return r(this,void 0,void 0,(function*(){return yield u.OidcClient.getIDToken(e)}))}a.getIDToken=getIDToken;var v=t(2518);Object.defineProperty(a,"summary",{enumerable:true,get:function(){return v.summary}});var h=t(2518);Object.defineProperty(a,"markdownSummary",{enumerable:true,get:function(){return h.markdownSummary}});var g=t(2162);Object.defineProperty(a,"toPosixPath",{enumerable:true,get:function(){return g.toPosixPath}});Object.defineProperty(a,"toWin32Path",{enumerable:true,get:function(){return g.toWin32Path}});Object.defineProperty(a,"toPlatformPath",{enumerable:true,get:function(){return g.toPlatformPath}})},5635:function(e,a,t){"use strict";var i=this&&this.__createBinding||(Object.create?function(e,a,t,i){if(i===undefined)i=t;Object.defineProperty(e,i,{enumerable:true,get:function(){return a[t]}})}:function(e,a,t,i){if(i===undefined)i=t;e[i]=a[t]});var s=this&&this.__setModuleDefault||(Object.create?function(e,a){Object.defineProperty(e,"default",{enumerable:true,value:a})}:function(e,a){e["default"]=a});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var a={};if(e!=null)for(var t in e)if(t!=="default"&&Object.hasOwnProperty.call(e,t))i(a,e,t);s(a,e);return a};Object.defineProperty(a,"__esModule",{value:true});a.prepareKeyValueMessage=a.issueFileCommand=void 0;const r=o(t(7147));const n=o(t(2037));const p=t(3236);const d=t(2660);function issueFileCommand(e,a){const t=process.env[`GITHUB_${e}`];if(!t){throw new Error(`Unable to find environment variable for file command ${e}`)}if(!r.existsSync(t)){throw new Error(`Missing file at path: ${t}`)}r.appendFileSync(t,`${d.toCommandValue(a)}${n.EOL}`,{encoding:"utf8"})}a.issueFileCommand=issueFileCommand;function prepareKeyValueMessage(e,a){const t=`ghadelimiter_${p.v4()}`;const i=d.toCommandValue(a);if(e.includes(t)){throw new Error(`Unexpected input: name should not contain the delimiter "${t}"`)}if(i.includes(t)){throw new Error(`Unexpected input: value should not contain the delimiter "${t}"`)}return`${e}<<${t}${n.EOL}${i}${n.EOL}${t}`}a.prepareKeyValueMessage=prepareKeyValueMessage},1569:function(e,a,t){"use strict";var i=this&&this.__awaiter||function(e,a,t,i){function adopt(e){return e instanceof t?e:new t((function(a){a(e)}))}return new(t||(t=Promise))((function(t,s){function fulfilled(e){try{step(i.next(e))}catch(e){s(e)}}function rejected(e){try{step(i["throw"](e))}catch(e){s(e)}}function step(e){e.done?t(e.value):adopt(e.value).then(fulfilled,rejected)}step((i=i.apply(e,a||[])).next())}))};Object.defineProperty(a,"__esModule",{value:true});a.OidcClient=void 0;const s=t(8971);const o=t(3955);const r=t(8686);class OidcClient{static createHttpClient(e=true,a=10){const t={allowRetries:e,maxRetries:a};return new s.HttpClient("actions/oidc-client",[new o.BearerCredentialHandler(OidcClient.getRequestToken())],t)}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 a;return i(this,void 0,void 0,(function*(){const t=OidcClient.createHttpClient();const i=yield t.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 s=(a=i.result)===null||a===void 0?void 0:a.value;if(!s){throw new Error("Response json body do not have ID Token field")}return s}))}static getIDToken(e){return i(this,void 0,void 0,(function*(){try{let a=OidcClient.getIDTokenUrl();if(e){const t=encodeURIComponent(e);a=`${a}&audience=${t}`}r.debug(`ID token url is ${a}`);const t=yield OidcClient.getCall(a);r.setSecret(t);return t}catch(e){throw new Error(`Error message: ${e.message}`)}}))}}a.OidcClient=OidcClient},2162:function(e,a,t){"use strict";var i=this&&this.__createBinding||(Object.create?function(e,a,t,i){if(i===undefined)i=t;Object.defineProperty(e,i,{enumerable:true,get:function(){return a[t]}})}:function(e,a,t,i){if(i===undefined)i=t;e[i]=a[t]});var s=this&&this.__setModuleDefault||(Object.create?function(e,a){Object.defineProperty(e,"default",{enumerable:true,value:a})}:function(e,a){e["default"]=a});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var a={};if(e!=null)for(var t in e)if(t!=="default"&&Object.hasOwnProperty.call(e,t))i(a,e,t);s(a,e);return a};Object.defineProperty(a,"__esModule",{value:true});a.toPlatformPath=a.toWin32Path=a.toPosixPath=void 0;const r=o(t(1017));function toPosixPath(e){return e.replace(/[\\]/g,"/")}a.toPosixPath=toPosixPath;function toWin32Path(e){return e.replace(/[/]/g,"\\")}a.toWin32Path=toWin32Path;function toPlatformPath(e){return e.replace(/[/\\]/g,r.sep)}a.toPlatformPath=toPlatformPath},2518:function(e,a,t){"use strict";var i=this&&this.__awaiter||function(e,a,t,i){function adopt(e){return e instanceof t?e:new t((function(a){a(e)}))}return new(t||(t=Promise))((function(t,s){function fulfilled(e){try{step(i.next(e))}catch(e){s(e)}}function rejected(e){try{step(i["throw"](e))}catch(e){s(e)}}function step(e){e.done?t(e.value):adopt(e.value).then(fulfilled,rejected)}step((i=i.apply(e,a||[])).next())}))};Object.defineProperty(a,"__esModule",{value:true});a.summary=a.markdownSummary=a.SUMMARY_DOCS_URL=a.SUMMARY_ENV_VAR=void 0;const s=t(2037);const o=t(7147);const{access:r,appendFile:n,writeFile:p}=o.promises;a.SUMMARY_ENV_VAR="GITHUB_STEP_SUMMARY";a.SUMMARY_DOCS_URL="https://docs.github.com/actions/using-workflows/workflow-commands-for-github-actions#adding-a-job-summary";class Summary{constructor(){this._buffer=""}filePath(){return i(this,void 0,void 0,(function*(){if(this._filePath){return this._filePath}const e=process.env[a.SUMMARY_ENV_VAR];if(!e){throw new Error(`Unable to find environment variable for $${a.SUMMARY_ENV_VAR}. Check if your runtime environment supports job summaries.`)}try{yield r(e,o.constants.R_OK|o.constants.W_OK)}catch(a){throw new Error(`Unable to access summary file: '${e}'. Check if the file has correct read/write permissions.`)}this._filePath=e;return this._filePath}))}wrap(e,a,t={}){const i=Object.entries(t).map((([e,a])=>` ${e}="${a}"`)).join("");if(!a){return`<${e}${i}>`}return`<${e}${i}>${a}`}write(e){return i(this,void 0,void 0,(function*(){const a=!!(e===null||e===void 0?void 0:e.overwrite);const t=yield this.filePath();const i=a?p:n;yield i(t,this._buffer,{encoding:"utf8"});return this.emptyBuffer()}))}clear(){return i(this,void 0,void 0,(function*(){return this.emptyBuffer().write({overwrite:true})}))}stringify(){return this._buffer}isEmptyBuffer(){return this._buffer.length===0}emptyBuffer(){this._buffer="";return this}addRaw(e,a=false){this._buffer+=e;return a?this.addEOL():this}addEOL(){return this.addRaw(s.EOL)}addCodeBlock(e,a){const t=Object.assign({},a&&{lang:a});const i=this.wrap("pre",this.wrap("code",e),t);return this.addRaw(i).addEOL()}addList(e,a=false){const t=a?"ol":"ul";const i=e.map((e=>this.wrap("li",e))).join("");const s=this.wrap(t,i);return this.addRaw(s).addEOL()}addTable(e){const a=e.map((e=>{const a=e.map((e=>{if(typeof e==="string"){return this.wrap("td",e)}const{header:a,data:t,colspan:i,rowspan:s}=e;const o=a?"th":"td";const r=Object.assign(Object.assign({},i&&{colspan:i}),s&&{rowspan:s});return this.wrap(o,t,r)})).join("");return this.wrap("tr",a)})).join("");const t=this.wrap("table",a);return this.addRaw(t).addEOL()}addDetails(e,a){const t=this.wrap("details",this.wrap("summary",e)+a);return this.addRaw(t).addEOL()}addImage(e,a,t){const{width:i,height:s}=t||{};const o=Object.assign(Object.assign({},i&&{width:i}),s&&{height:s});const r=this.wrap("img",null,Object.assign({src:e,alt:a},o));return this.addRaw(r).addEOL()}addHeading(e,a){const t=`h${a}`;const i=["h1","h2","h3","h4","h5","h6"].includes(t)?t:"h1";const s=this.wrap(i,e);return this.addRaw(s).addEOL()}addSeparator(){const e=this.wrap("hr",null);return this.addRaw(e).addEOL()}addBreak(){const e=this.wrap("br",null);return this.addRaw(e).addEOL()}addQuote(e,a){const t=Object.assign({},a&&{cite:a});const i=this.wrap("blockquote",e,t);return this.addRaw(i).addEOL()}addLink(e,a){const t=this.wrap("a",e,{href:a});return this.addRaw(t).addEOL()}}const d=new Summary;a.markdownSummary=d;a.summary=d},2660:(e,a)=>{"use strict";Object.defineProperty(a,"__esModule",{value:true});a.toCommandProperties=a.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)}a.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}}a.toCommandProperties=toCommandProperties},7697:function(e,a,t){"use strict";var i=this&&this.__createBinding||(Object.create?function(e,a,t,i){if(i===undefined)i=t;Object.defineProperty(e,i,{enumerable:true,get:function(){return a[t]}})}:function(e,a,t,i){if(i===undefined)i=t;e[i]=a[t]});var s=this&&this.__setModuleDefault||(Object.create?function(e,a){Object.defineProperty(e,"default",{enumerable:true,value:a})}:function(e,a){e["default"]=a});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var a={};if(e!=null)for(var t in e)if(t!=="default"&&Object.hasOwnProperty.call(e,t))i(a,e,t);s(a,e);return a};var r=this&&this.__awaiter||function(e,a,t,i){function adopt(e){return e instanceof t?e:new t((function(a){a(e)}))}return new(t||(t=Promise))((function(t,s){function fulfilled(e){try{step(i.next(e))}catch(e){s(e)}}function rejected(e){try{step(i["throw"](e))}catch(e){s(e)}}function step(e){e.done?t(e.value):adopt(e.value).then(fulfilled,rejected)}step((i=i.apply(e,a||[])).next())}))};Object.defineProperty(a,"__esModule",{value:true});a.getExecOutput=a.exec=void 0;const n=t(1576);const p=o(t(9438));function exec(e,a,t){return r(this,void 0,void 0,(function*(){const i=p.argStringToArray(e);if(i.length===0){throw new Error(`Parameter 'commandLine' cannot be null or empty.`)}const s=i[0];a=i.slice(1).concat(a||[]);const o=new p.ToolRunner(s,a,t);return o.exec()}))}a.exec=exec;function getExecOutput(e,a,t){var i,s;return r(this,void 0,void 0,(function*(){let o="";let r="";const p=new n.StringDecoder("utf8");const d=new n.StringDecoder("utf8");const l=(i=t===null||t===void 0?void 0:t.listeners)===null||i===void 0?void 0:i.stdout;const c=(s=t===null||t===void 0?void 0:t.listeners)===null||s===void 0?void 0:s.stderr;const stdErrListener=e=>{r+=d.write(e);if(c){c(e)}};const stdOutListener=e=>{o+=p.write(e);if(l){l(e)}};const u=Object.assign(Object.assign({},t===null||t===void 0?void 0:t.listeners),{stdout:stdOutListener,stderr:stdErrListener});const m=yield exec(e,a,Object.assign(Object.assign({},t),{listeners:u}));o+=p.end();r+=d.end();return{exitCode:m,stdout:o,stderr:r}}))}a.getExecOutput=getExecOutput},9438:function(e,a,t){"use strict";var i=this&&this.__createBinding||(Object.create?function(e,a,t,i){if(i===undefined)i=t;Object.defineProperty(e,i,{enumerable:true,get:function(){return a[t]}})}:function(e,a,t,i){if(i===undefined)i=t;e[i]=a[t]});var s=this&&this.__setModuleDefault||(Object.create?function(e,a){Object.defineProperty(e,"default",{enumerable:true,value:a})}:function(e,a){e["default"]=a});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var a={};if(e!=null)for(var t in e)if(t!=="default"&&Object.hasOwnProperty.call(e,t))i(a,e,t);s(a,e);return a};var r=this&&this.__awaiter||function(e,a,t,i){function adopt(e){return e instanceof t?e:new t((function(a){a(e)}))}return new(t||(t=Promise))((function(t,s){function fulfilled(e){try{step(i.next(e))}catch(e){s(e)}}function rejected(e){try{step(i["throw"](e))}catch(e){s(e)}}function step(e){e.done?t(e.value):adopt(e.value).then(fulfilled,rejected)}step((i=i.apply(e,a||[])).next())}))};Object.defineProperty(a,"__esModule",{value:true});a.argStringToArray=a.ToolRunner=void 0;const n=o(t(2037));const p=o(t(2361));const d=o(t(2081));const l=o(t(1017));const c=o(t(8071));const u=o(t(9464));const m=t(9512);const v=process.platform==="win32";class ToolRunner extends p.EventEmitter{constructor(e,a,t){super();if(!e){throw new Error("Parameter 'toolPath' cannot be null or empty.")}this.toolPath=e;this.args=a||[];this.options=t||{}}_debug(e){if(this.options.listeners&&this.options.listeners.debug){this.options.listeners.debug(e)}}_getCommandString(e,a){const t=this._getSpawnFileName();const i=this._getSpawnArgs(e);let s=a?"":"[command]";if(v){if(this._isCmdFile()){s+=t;for(const e of i){s+=` ${e}`}}else if(e.windowsVerbatimArguments){s+=`"${t}"`;for(const e of i){s+=` ${e}`}}else{s+=this._windowsQuoteCmdArg(t);for(const e of i){s+=` ${this._windowsQuoteCmdArg(e)}`}}}else{s+=t;for(const e of i){s+=` ${e}`}}return s}_processLineBuffer(e,a,t){try{let i=a+e.toString();let s=i.indexOf(n.EOL);while(s>-1){const e=i.substring(0,s);t(e);i=i.substring(s+n.EOL.length);s=i.indexOf(n.EOL)}return i}catch(e){this._debug(`error processing line. Failed with error ${e}`);return""}}_getSpawnFileName(){if(v){if(this._isCmdFile()){return process.env["COMSPEC"]||"cmd.exe"}}return this.toolPath}_getSpawnArgs(e){if(v){if(this._isCmdFile()){let a=`/D /S /C "${this._windowsQuoteCmdArg(this.toolPath)}`;for(const t of this.args){a+=" ";a+=e.windowsVerbatimArguments?t:this._windowsQuoteCmdArg(t)}a+='"';return[a]}}return this.args}_endsWith(e,a){return e.endsWith(a)}_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 a=[" ","\t","&","(",")","[","]","{","}","^","=",";","!","'","+",",","`","~","|","<",">",'"'];let t=false;for(const i of e){if(a.some((e=>e===i))){t=true;break}}if(!t){return e}let i='"';let s=true;for(let a=e.length;a>0;a--){i+=e[a-1];if(s&&e[a-1]==="\\"){i+="\\"}else if(e[a-1]==='"'){s=true;i+='"'}else{s=false}}i+='"';return i.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 a='"';let t=true;for(let i=e.length;i>0;i--){a+=e[i-1];if(t&&e[i-1]==="\\"){a+="\\"}else if(e[i-1]==='"'){t=true;a+="\\"}else{t=false}}a+='"';return a.split("").reverse().join("")}_cloneExecOptions(e){e=e||{};const a={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};a.outStream=e.outStream||process.stdout;a.errStream=e.errStream||process.stderr;return a}_getSpawnOptions(e,a){e=e||{};const t={};t.cwd=e.cwd;t.env=e.env;t["windowsVerbatimArguments"]=e.windowsVerbatimArguments||this._isCmdFile();if(e.windowsVerbatimArguments){t.argv0=`"${a}"`}return t}exec(){return r(this,void 0,void 0,(function*(){if(!u.isRooted(this.toolPath)&&(this.toolPath.includes("/")||v&&this.toolPath.includes("\\"))){this.toolPath=l.resolve(process.cwd(),this.options.cwd||process.cwd(),this.toolPath)}this.toolPath=yield c.which(this.toolPath,true);return new Promise(((e,a)=>r(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 t=this._cloneExecOptions(this.options);if(!t.silent&&t.outStream){t.outStream.write(this._getCommandString(t)+n.EOL)}const i=new ExecState(t,this.toolPath);i.on("debug",(e=>{this._debug(e)}));if(this.options.cwd&&!(yield u.exists(this.options.cwd))){return a(new Error(`The cwd: ${this.options.cwd} does not exist!`))}const s=this._getSpawnFileName();const o=d.spawn(s,this._getSpawnArgs(t),this._getSpawnOptions(this.options,s));let r="";if(o.stdout){o.stdout.on("data",(e=>{if(this.options.listeners&&this.options.listeners.stdout){this.options.listeners.stdout(e)}if(!t.silent&&t.outStream){t.outStream.write(e)}r=this._processLineBuffer(e,r,(e=>{if(this.options.listeners&&this.options.listeners.stdline){this.options.listeners.stdline(e)}}))}))}let p="";if(o.stderr){o.stderr.on("data",(e=>{i.processStderr=true;if(this.options.listeners&&this.options.listeners.stderr){this.options.listeners.stderr(e)}if(!t.silent&&t.errStream&&t.outStream){const a=t.failOnStdErr?t.errStream:t.outStream;a.write(e)}p=this._processLineBuffer(e,p,(e=>{if(this.options.listeners&&this.options.listeners.errline){this.options.listeners.errline(e)}}))}))}o.on("error",(e=>{i.processError=e.message;i.processExited=true;i.processClosed=true;i.CheckComplete()}));o.on("exit",(e=>{i.processExitCode=e;i.processExited=true;this._debug(`Exit code ${e} received from tool '${this.toolPath}'`);i.CheckComplete()}));o.on("close",(e=>{i.processExitCode=e;i.processExited=true;i.processClosed=true;this._debug(`STDIO streams have closed for tool '${this.toolPath}'`);i.CheckComplete()}));i.on("done",((t,i)=>{if(r.length>0){this.emit("stdline",r)}if(p.length>0){this.emit("errline",p)}o.removeAllListeners();if(t){a(t)}else{e(i)}}));if(this.options.input){if(!o.stdin){throw new Error("child process missing stdin")}o.stdin.end(this.options.input)}}))))}))}}a.ToolRunner=ToolRunner;function argStringToArray(e){const a=[];let t=false;let i=false;let s="";function append(e){if(i&&e!=='"'){s+="\\"}s+=e;i=false}for(let o=0;o0){a.push(s);s=""}continue}append(r)}if(s.length>0){a.push(s.trim())}return a}a.argStringToArray=argStringToArray;class ExecState extends p.EventEmitter{constructor(e,a){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(!a){throw new Error("toolPath must not be empty")}this.options=e;this.toolPath=a;if(e.delay){this.delay=e.delay}}CheckComplete(){if(this.done){return}if(this.processClosed){this._setResult()}else if(this.processExited){this.timeout=m.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 a=`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(a)}e._setResult()}}},1707:(e,a,t)=>{"use strict";Object.defineProperty(a,"__esModule",{value:true});a.Context=void 0;const i=t(7147);const s=t(2037);class Context{constructor(){var e,a,t;this.payload={};if(process.env.GITHUB_EVENT_PATH){if(i.existsSync(process.env.GITHUB_EVENT_PATH)){this.payload=JSON.parse(i.readFileSync(process.env.GITHUB_EVENT_PATH,{encoding:"utf8"}))}else{const e=process.env.GITHUB_EVENT_PATH;process.stdout.write(`GITHUB_EVENT_PATH ${e} does not exist${s.EOL}`)}}this.eventName=process.env.GITHUB_EVENT_NAME;this.sha=process.env.GITHUB_SHA;this.ref=process.env.GITHUB_REF;this.workflow=process.env.GITHUB_WORKFLOW;this.action=process.env.GITHUB_ACTION;this.actor=process.env.GITHUB_ACTOR;this.job=process.env.GITHUB_JOB;this.runNumber=parseInt(process.env.GITHUB_RUN_NUMBER,10);this.runId=parseInt(process.env.GITHUB_RUN_ID,10);this.apiUrl=(e=process.env.GITHUB_API_URL)!==null&&e!==void 0?e:`https://api.github.com`;this.serverUrl=(a=process.env.GITHUB_SERVER_URL)!==null&&a!==void 0?a:`https://github.com`;this.graphqlUrl=(t=process.env.GITHUB_GRAPHQL_URL)!==null&&t!==void 0?t:`https://api.github.com/graphql`}get issue(){const e=this.payload;return Object.assign(Object.assign({},this.repo),{number:(e.issue||e.pull_request||e).number})}get repo(){if(process.env.GITHUB_REPOSITORY){const[e,a]=process.env.GITHUB_REPOSITORY.split("/");return{owner:e,repo:a}}if(this.payload.repository){return{owner:this.payload.repository.owner.login,repo:this.payload.repository.name}}throw new Error("context.repo requires a GITHUB_REPOSITORY environment variable like 'owner/repo'")}}a.Context=Context},7481:function(e,a,t){"use strict";var i=this&&this.__createBinding||(Object.create?function(e,a,t,i){if(i===undefined)i=t;Object.defineProperty(e,i,{enumerable:true,get:function(){return a[t]}})}:function(e,a,t,i){if(i===undefined)i=t;e[i]=a[t]});var s=this&&this.__setModuleDefault||(Object.create?function(e,a){Object.defineProperty(e,"default",{enumerable:true,value:a})}:function(e,a){e["default"]=a});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var a={};if(e!=null)for(var t in e)if(t!=="default"&&Object.hasOwnProperty.call(e,t))i(a,e,t);s(a,e);return a};Object.defineProperty(a,"__esModule",{value:true});a.getOctokit=a.context=void 0;const r=o(t(1707));const n=t(2887);a.context=new r.Context;function getOctokit(e,a,...t){const i=n.GitHub.plugin(...t);return new i(n.getOctokitOptions(e,a))}a.getOctokit=getOctokit},194:function(e,a,t){"use strict";var i=this&&this.__createBinding||(Object.create?function(e,a,t,i){if(i===undefined)i=t;Object.defineProperty(e,i,{enumerable:true,get:function(){return a[t]}})}:function(e,a,t,i){if(i===undefined)i=t;e[i]=a[t]});var s=this&&this.__setModuleDefault||(Object.create?function(e,a){Object.defineProperty(e,"default",{enumerable:true,value:a})}:function(e,a){e["default"]=a});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var a={};if(e!=null)for(var t in e)if(t!=="default"&&Object.hasOwnProperty.call(e,t))i(a,e,t);s(a,e);return a};Object.defineProperty(a,"__esModule",{value:true});a.getApiBaseUrl=a.getProxyAgent=a.getAuthString=void 0;const r=o(t(8971));function getAuthString(e,a){if(!e&&!a.auth){throw new Error("Parameter token or opts.auth is required")}else if(e&&a.auth){throw new Error("Parameters token and opts.auth may not both be specified")}return typeof a.auth==="string"?a.auth:`token ${e}`}a.getAuthString=getAuthString;function getProxyAgent(e){const a=new r.HttpClient;return a.getAgent(e)}a.getProxyAgent=getProxyAgent;function getApiBaseUrl(){return process.env["GITHUB_API_URL"]||"https://api.github.com"}a.getApiBaseUrl=getApiBaseUrl},2887:function(e,a,t){"use strict";var i=this&&this.__createBinding||(Object.create?function(e,a,t,i){if(i===undefined)i=t;Object.defineProperty(e,i,{enumerable:true,get:function(){return a[t]}})}:function(e,a,t,i){if(i===undefined)i=t;e[i]=a[t]});var s=this&&this.__setModuleDefault||(Object.create?function(e,a){Object.defineProperty(e,"default",{enumerable:true,value:a})}:function(e,a){e["default"]=a});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var a={};if(e!=null)for(var t in e)if(t!=="default"&&Object.hasOwnProperty.call(e,t))i(a,e,t);s(a,e);return a};Object.defineProperty(a,"__esModule",{value:true});a.getOctokitOptions=a.GitHub=a.defaults=a.context=void 0;const r=o(t(1707));const n=o(t(194));const p=t(1241);const d=t(1114);const l=t(8469);a.context=new r.Context;const c=n.getApiBaseUrl();a.defaults={baseUrl:c,request:{agent:n.getProxyAgent(c)}};a.GitHub=p.Octokit.plugin(d.restEndpointMethods,l.paginateRest).defaults(a.defaults);function getOctokitOptions(e,a){const t=Object.assign({},a||{});const i=n.getAuthString(e,t);if(i){t.auth=i}return t}a.getOctokitOptions=getOctokitOptions},3955:function(e,a){"use strict";var t=this&&this.__awaiter||function(e,a,t,i){function adopt(e){return e instanceof t?e:new t((function(a){a(e)}))}return new(t||(t=Promise))((function(t,s){function fulfilled(e){try{step(i.next(e))}catch(e){s(e)}}function rejected(e){try{step(i["throw"](e))}catch(e){s(e)}}function step(e){e.done?t(e.value):adopt(e.value).then(fulfilled,rejected)}step((i=i.apply(e,a||[])).next())}))};Object.defineProperty(a,"__esModule",{value:true});a.PersonalAccessTokenCredentialHandler=a.BearerCredentialHandler=a.BasicCredentialHandler=void 0;class BasicCredentialHandler{constructor(e,a){this.username=e;this.password=a}prepareRequest(e){if(!e.headers){throw Error("The request has no headers")}e.headers["Authorization"]=`Basic ${Buffer.from(`${this.username}:${this.password}`).toString("base64")}`}canHandleAuthentication(){return false}handleAuthentication(){return t(this,void 0,void 0,(function*(){throw new Error("not implemented")}))}}a.BasicCredentialHandler=BasicCredentialHandler;class BearerCredentialHandler{constructor(e){this.token=e}prepareRequest(e){if(!e.headers){throw Error("The request has no headers")}e.headers["Authorization"]=`Bearer ${this.token}`}canHandleAuthentication(){return false}handleAuthentication(){return t(this,void 0,void 0,(function*(){throw new Error("not implemented")}))}}a.BearerCredentialHandler=BearerCredentialHandler;class PersonalAccessTokenCredentialHandler{constructor(e){this.token=e}prepareRequest(e){if(!e.headers){throw Error("The request has no headers")}e.headers["Authorization"]=`Basic ${Buffer.from(`PAT:${this.token}`).toString("base64")}`}canHandleAuthentication(){return false}handleAuthentication(){return t(this,void 0,void 0,(function*(){throw new Error("not implemented")}))}}a.PersonalAccessTokenCredentialHandler=PersonalAccessTokenCredentialHandler},8971:function(e,a,t){"use strict";var i=this&&this.__createBinding||(Object.create?function(e,a,t,i){if(i===undefined)i=t;Object.defineProperty(e,i,{enumerable:true,get:function(){return a[t]}})}:function(e,a,t,i){if(i===undefined)i=t;e[i]=a[t]});var s=this&&this.__setModuleDefault||(Object.create?function(e,a){Object.defineProperty(e,"default",{enumerable:true,value:a})}:function(e,a){e["default"]=a});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var a={};if(e!=null)for(var t in e)if(t!=="default"&&Object.hasOwnProperty.call(e,t))i(a,e,t);s(a,e);return a};var r=this&&this.__awaiter||function(e,a,t,i){function adopt(e){return e instanceof t?e:new t((function(a){a(e)}))}return new(t||(t=Promise))((function(t,s){function fulfilled(e){try{step(i.next(e))}catch(e){s(e)}}function rejected(e){try{step(i["throw"](e))}catch(e){s(e)}}function step(e){e.done?t(e.value):adopt(e.value).then(fulfilled,rejected)}step((i=i.apply(e,a||[])).next())}))};Object.defineProperty(a,"__esModule",{value:true});a.HttpClient=a.isHttps=a.HttpClientResponse=a.HttpClientError=a.getProxyUrl=a.MediaTypes=a.Headers=a.HttpCodes=void 0;const n=o(t(3685));const p=o(t(5687));const d=o(t(9446));const l=o(t(5130));var c;(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"})(c=a.HttpCodes||(a.HttpCodes={}));var u;(function(e){e["Accept"]="accept";e["ContentType"]="content-type"})(u=a.Headers||(a.Headers={}));var m;(function(e){e["ApplicationJson"]="application/json"})(m=a.MediaTypes||(a.MediaTypes={}));function getProxyUrl(e){const a=d.getProxyUrl(new URL(e));return a?a.href:""}a.getProxyUrl=getProxyUrl;const v=[c.MovedPermanently,c.ResourceMoved,c.SeeOther,c.TemporaryRedirect,c.PermanentRedirect];const h=[c.BadGateway,c.ServiceUnavailable,c.GatewayTimeout];const g=["OPTIONS","GET","DELETE","HEAD"];const b=10;const w=5;class HttpClientError extends Error{constructor(e,a){super(e);this.name="HttpClientError";this.statusCode=a;Object.setPrototypeOf(this,HttpClientError.prototype)}}a.HttpClientError=HttpClientError;class HttpClientResponse{constructor(e){this.message=e}readBody(){return r(this,void 0,void 0,(function*(){return new Promise((e=>r(this,void 0,void 0,(function*(){let a=Buffer.alloc(0);this.message.on("data",(e=>{a=Buffer.concat([a,e])}));this.message.on("end",(()=>{e(a.toString())}))}))))}))}}a.HttpClientResponse=HttpClientResponse;function isHttps(e){const a=new URL(e);return a.protocol==="https:"}a.isHttps=isHttps;class HttpClient{constructor(e,a,t){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=a||[];this.requestOptions=t;if(t){if(t.ignoreSslError!=null){this._ignoreSslError=t.ignoreSslError}this._socketTimeout=t.socketTimeout;if(t.allowRedirects!=null){this._allowRedirects=t.allowRedirects}if(t.allowRedirectDowngrade!=null){this._allowRedirectDowngrade=t.allowRedirectDowngrade}if(t.maxRedirects!=null){this._maxRedirects=Math.max(t.maxRedirects,0)}if(t.keepAlive!=null){this._keepAlive=t.keepAlive}if(t.allowRetries!=null){this._allowRetries=t.allowRetries}if(t.maxRetries!=null){this._maxRetries=t.maxRetries}}}options(e,a){return r(this,void 0,void 0,(function*(){return this.request("OPTIONS",e,null,a||{})}))}get(e,a){return r(this,void 0,void 0,(function*(){return this.request("GET",e,null,a||{})}))}del(e,a){return r(this,void 0,void 0,(function*(){return this.request("DELETE",e,null,a||{})}))}post(e,a,t){return r(this,void 0,void 0,(function*(){return this.request("POST",e,a,t||{})}))}patch(e,a,t){return r(this,void 0,void 0,(function*(){return this.request("PATCH",e,a,t||{})}))}put(e,a,t){return r(this,void 0,void 0,(function*(){return this.request("PUT",e,a,t||{})}))}head(e,a){return r(this,void 0,void 0,(function*(){return this.request("HEAD",e,null,a||{})}))}sendStream(e,a,t,i){return r(this,void 0,void 0,(function*(){return this.request(e,a,t,i)}))}getJson(e,a={}){return r(this,void 0,void 0,(function*(){a[u.Accept]=this._getExistingOrDefaultHeader(a,u.Accept,m.ApplicationJson);const t=yield this.get(e,a);return this._processResponse(t,this.requestOptions)}))}postJson(e,a,t={}){return r(this,void 0,void 0,(function*(){const i=JSON.stringify(a,null,2);t[u.Accept]=this._getExistingOrDefaultHeader(t,u.Accept,m.ApplicationJson);t[u.ContentType]=this._getExistingOrDefaultHeader(t,u.ContentType,m.ApplicationJson);const s=yield this.post(e,i,t);return this._processResponse(s,this.requestOptions)}))}putJson(e,a,t={}){return r(this,void 0,void 0,(function*(){const i=JSON.stringify(a,null,2);t[u.Accept]=this._getExistingOrDefaultHeader(t,u.Accept,m.ApplicationJson);t[u.ContentType]=this._getExistingOrDefaultHeader(t,u.ContentType,m.ApplicationJson);const s=yield this.put(e,i,t);return this._processResponse(s,this.requestOptions)}))}patchJson(e,a,t={}){return r(this,void 0,void 0,(function*(){const i=JSON.stringify(a,null,2);t[u.Accept]=this._getExistingOrDefaultHeader(t,u.Accept,m.ApplicationJson);t[u.ContentType]=this._getExistingOrDefaultHeader(t,u.ContentType,m.ApplicationJson);const s=yield this.patch(e,i,t);return this._processResponse(s,this.requestOptions)}))}request(e,a,t,i){return r(this,void 0,void 0,(function*(){if(this._disposed){throw new Error("Client has already been disposed.")}const s=new URL(a);let o=this._prepareRequest(e,s,i);const r=this._allowRetries&&g.includes(e)?this._maxRetries+1:1;let n=0;let p;do{p=yield this.requestRaw(o,t);if(p&&p.message&&p.message.statusCode===c.Unauthorized){let e;for(const a of this.handlers){if(a.canHandleAuthentication(p)){e=a;break}}if(e){return e.handleAuthentication(this,o,t)}else{return p}}let a=this._maxRedirects;while(p.message.statusCode&&v.includes(p.message.statusCode)&&this._allowRedirects&&a>0){const r=p.message.headers["location"];if(!r){break}const n=new URL(r);if(s.protocol==="https:"&&s.protocol!==n.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.")}yield p.readBody();if(n.hostname!==s.hostname){for(const e in i){if(e.toLowerCase()==="authorization"){delete i[e]}}}o=this._prepareRequest(e,n,i);p=yield this.requestRaw(o,t);a--}if(!p.message.statusCode||!h.includes(p.message.statusCode)){return p}n+=1;if(n{function callbackForResult(e,a){if(e){i(e)}else if(!a){i(new Error("Unknown error"))}else{t(a)}}this.requestRawWithCallback(e,a,callbackForResult)}))}))}requestRawWithCallback(e,a,t){if(typeof a==="string"){if(!e.options.headers){e.options.headers={}}e.options.headers["Content-Length"]=Buffer.byteLength(a,"utf8")}let i=false;function handleResult(e,a){if(!i){i=true;t(e,a)}}const s=e.httpModule.request(e.options,(e=>{const a=new HttpClientResponse(e);handleResult(undefined,a)}));let o;s.on("socket",(e=>{o=e}));s.setTimeout(this._socketTimeout||3*6e4,(()=>{if(o){o.end()}handleResult(new Error(`Request timeout: ${e.options.path}`))}));s.on("error",(function(e){handleResult(e)}));if(a&&typeof a==="string"){s.write(a,"utf8")}if(a&&typeof a!=="string"){a.on("close",(function(){s.end()}));a.pipe(s)}else{s.end()}}getAgent(e){const a=new URL(e);return this._getAgent(a)}_prepareRequest(e,a,t){const i={};i.parsedUrl=a;const s=i.parsedUrl.protocol==="https:";i.httpModule=s?p:n;const o=s?443:80;i.options={};i.options.host=i.parsedUrl.hostname;i.options.port=i.parsedUrl.port?parseInt(i.parsedUrl.port):o;i.options.path=(i.parsedUrl.pathname||"")+(i.parsedUrl.search||"");i.options.method=e;i.options.headers=this._mergeHeaders(t);if(this.userAgent!=null){i.options.headers["user-agent"]=this.userAgent}i.options.agent=this._getAgent(i.parsedUrl);if(this.handlers){for(const e of this.handlers){e.prepareRequest(i.options)}}return i}_mergeHeaders(e){if(this.requestOptions&&this.requestOptions.headers){return Object.assign({},lowercaseKeys(this.requestOptions.headers),lowercaseKeys(e||{}))}return lowercaseKeys(e||{})}_getExistingOrDefaultHeader(e,a,t){let i;if(this.requestOptions&&this.requestOptions.headers){i=lowercaseKeys(this.requestOptions.headers)[a]}return e[a]||i||t}_getAgent(e){let a;const t=d.getProxyUrl(e);const i=t&&t.hostname;if(this._keepAlive&&i){a=this._proxyAgent}if(this._keepAlive&&!i){a=this._agent}if(a){return a}const s=e.protocol==="https:";let o=100;if(this.requestOptions){o=this.requestOptions.maxSockets||n.globalAgent.maxSockets}if(t&&t.hostname){const e={maxSockets:o,keepAlive:this._keepAlive,proxy:Object.assign(Object.assign({},(t.username||t.password)&&{proxyAuth:`${t.username}:${t.password}`}),{host:t.hostname,port:t.port})};let i;const r=t.protocol==="https:";if(s){i=r?l.httpsOverHttps:l.httpsOverHttp}else{i=r?l.httpOverHttps:l.httpOverHttp}a=i(e);this._proxyAgent=a}if(this._keepAlive&&!a){const e={keepAlive:this._keepAlive,maxSockets:o};a=s?new p.Agent(e):new n.Agent(e);this._agent=a}if(!a){a=s?p.globalAgent:n.globalAgent}if(s&&this._ignoreSslError){a.options=Object.assign(a.options||{},{rejectUnauthorized:false})}return a}_performExponentialBackoff(e){return r(this,void 0,void 0,(function*(){e=Math.min(b,e);const a=w*Math.pow(2,e);return new Promise((e=>setTimeout((()=>e()),a)))}))}_processResponse(e,a){return r(this,void 0,void 0,(function*(){return new Promise(((t,i)=>r(this,void 0,void 0,(function*(){const s=e.message.statusCode||0;const o={statusCode:s,result:null,headers:{}};if(s===c.NotFound){t(o)}function dateTimeDeserializer(e,a){if(typeof a==="string"){const e=new Date(a);if(!isNaN(e.valueOf())){return e}}return a}let r;let n;try{n=yield e.readBody();if(n&&n.length>0){if(a&&a.deserializeDates){r=JSON.parse(n,dateTimeDeserializer)}else{r=JSON.parse(n)}o.result=r}o.headers=e.message.headers}catch(e){}if(s>299){let e;if(r&&r.message){e=r.message}else if(n&&n.length>0){e=n}else{e=`Failed request: (${s})`}const a=new HttpClientError(e,s);a.result=o.result;i(a)}else{t(o)}}))))}))}}a.HttpClient=HttpClient;const lowercaseKeys=e=>Object.keys(e).reduce(((a,t)=>(a[t.toLowerCase()]=e[t],a)),{})},9446:(e,a)=>{"use strict";Object.defineProperty(a,"__esModule",{value:true});a.checkBypass=a.getProxyUrl=void 0;function getProxyUrl(e){const a=e.protocol==="https:";if(checkBypass(e)){return undefined}const t=(()=>{if(a){return process.env["https_proxy"]||process.env["HTTPS_PROXY"]}else{return process.env["http_proxy"]||process.env["HTTP_PROXY"]}})();if(t){return new URL(t)}else{return undefined}}a.getProxyUrl=getProxyUrl;function checkBypass(e){if(!e.hostname){return false}const a=process.env["no_proxy"]||process.env["NO_PROXY"]||"";if(!a){return false}let t;if(e.port){t=Number(e.port)}else if(e.protocol==="http:"){t=80}else if(e.protocol==="https:"){t=443}const i=[e.hostname.toUpperCase()];if(typeof t==="number"){i.push(`${i[0]}:${t}`)}for(const e of a.split(",").map((e=>e.trim().toUpperCase())).filter((e=>e))){if(i.some((a=>a===e))){return true}}return false}a.checkBypass=checkBypass},9464:function(e,a,t){"use strict";var i=this&&this.__createBinding||(Object.create?function(e,a,t,i){if(i===undefined)i=t;Object.defineProperty(e,i,{enumerable:true,get:function(){return a[t]}})}:function(e,a,t,i){if(i===undefined)i=t;e[i]=a[t]});var s=this&&this.__setModuleDefault||(Object.create?function(e,a){Object.defineProperty(e,"default",{enumerable:true,value:a})}:function(e,a){e["default"]=a});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var a={};if(e!=null)for(var t in e)if(t!=="default"&&Object.hasOwnProperty.call(e,t))i(a,e,t);s(a,e);return a};var r=this&&this.__awaiter||function(e,a,t,i){function adopt(e){return e instanceof t?e:new t((function(a){a(e)}))}return new(t||(t=Promise))((function(t,s){function fulfilled(e){try{step(i.next(e))}catch(e){s(e)}}function rejected(e){try{step(i["throw"](e))}catch(e){s(e)}}function step(e){e.done?t(e.value):adopt(e.value).then(fulfilled,rejected)}step((i=i.apply(e,a||[])).next())}))};var n;Object.defineProperty(a,"__esModule",{value:true});a.getCmdPath=a.tryGetExecutablePath=a.isRooted=a.isDirectory=a.exists=a.IS_WINDOWS=a.unlink=a.symlink=a.stat=a.rmdir=a.rename=a.readlink=a.readdir=a.mkdir=a.lstat=a.copyFile=a.chmod=void 0;const p=o(t(7147));const d=o(t(1017));n=p.promises,a.chmod=n.chmod,a.copyFile=n.copyFile,a.lstat=n.lstat,a.mkdir=n.mkdir,a.readdir=n.readdir,a.readlink=n.readlink,a.rename=n.rename,a.rmdir=n.rmdir,a.stat=n.stat,a.symlink=n.symlink,a.unlink=n.unlink;a.IS_WINDOWS=process.platform==="win32";function exists(e){return r(this,void 0,void 0,(function*(){try{yield a.stat(e)}catch(e){if(e.code==="ENOENT"){return false}throw e}return true}))}a.exists=exists;function isDirectory(e,t=false){return r(this,void 0,void 0,(function*(){const i=t?yield a.stat(e):yield a.lstat(e);return i.isDirectory()}))}a.isDirectory=isDirectory;function isRooted(e){e=normalizeSeparators(e);if(!e){throw new Error('isRooted() parameter "p" cannot be empty')}if(a.IS_WINDOWS){return e.startsWith("\\")||/^[A-Z]:/i.test(e)}return e.startsWith("/")}a.isRooted=isRooted;function tryGetExecutablePath(e,t){return r(this,void 0,void 0,(function*(){let i=undefined;try{i=yield a.stat(e)}catch(a){if(a.code!=="ENOENT"){console.log(`Unexpected error attempting to determine if executable file exists '${e}': ${a}`)}}if(i&&i.isFile()){if(a.IS_WINDOWS){const a=d.extname(e).toUpperCase();if(t.some((e=>e.toUpperCase()===a))){return e}}else{if(isUnixExecutable(i)){return e}}}const s=e;for(const o of t){e=s+o;i=undefined;try{i=yield a.stat(e)}catch(a){if(a.code!=="ENOENT"){console.log(`Unexpected error attempting to determine if executable file exists '${e}': ${a}`)}}if(i&&i.isFile()){if(a.IS_WINDOWS){try{const t=d.dirname(e);const i=d.basename(e).toUpperCase();for(const s of yield a.readdir(t)){if(i===s.toUpperCase()){e=d.join(t,s);break}}}catch(a){console.log(`Unexpected error attempting to determine the actual case of the file '${e}': ${a}`)}return e}else{if(isUnixExecutable(i)){return e}}}}return""}))}a.tryGetExecutablePath=tryGetExecutablePath;function normalizeSeparators(e){e=e||"";if(a.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`}a.getCmdPath=getCmdPath},8071:function(e,a,t){"use strict";var i=this&&this.__createBinding||(Object.create?function(e,a,t,i){if(i===undefined)i=t;Object.defineProperty(e,i,{enumerable:true,get:function(){return a[t]}})}:function(e,a,t,i){if(i===undefined)i=t;e[i]=a[t]});var s=this&&this.__setModuleDefault||(Object.create?function(e,a){Object.defineProperty(e,"default",{enumerable:true,value:a})}:function(e,a){e["default"]=a});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var a={};if(e!=null)for(var t in e)if(t!=="default"&&Object.hasOwnProperty.call(e,t))i(a,e,t);s(a,e);return a};var r=this&&this.__awaiter||function(e,a,t,i){function adopt(e){return e instanceof t?e:new t((function(a){a(e)}))}return new(t||(t=Promise))((function(t,s){function fulfilled(e){try{step(i.next(e))}catch(e){s(e)}}function rejected(e){try{step(i["throw"](e))}catch(e){s(e)}}function step(e){e.done?t(e.value):adopt(e.value).then(fulfilled,rejected)}step((i=i.apply(e,a||[])).next())}))};Object.defineProperty(a,"__esModule",{value:true});a.findInPath=a.which=a.mkdirP=a.rmRF=a.mv=a.cp=void 0;const n=t(9491);const p=o(t(2081));const d=o(t(1017));const l=t(3837);const c=o(t(9464));const u=l.promisify(p.exec);const m=l.promisify(p.execFile);function cp(e,a,t={}){return r(this,void 0,void 0,(function*(){const{force:i,recursive:s,copySourceDirectory:o}=readCopyOptions(t);const r=(yield c.exists(a))?yield c.stat(a):null;if(r&&r.isFile()&&!i){return}const n=r&&r.isDirectory()&&o?d.join(a,d.basename(e)):a;if(!(yield c.exists(e))){throw new Error(`no such file or directory: ${e}`)}const p=yield c.stat(e);if(p.isDirectory()){if(!s){throw new Error(`Failed to copy. ${e} is a directory, but tried to copy without recursive flag.`)}else{yield cpDirRecursive(e,n,0,i)}}else{if(d.relative(e,n)===""){throw new Error(`'${n}' and '${e}' are the same file`)}yield copyFile(e,n,i)}}))}a.cp=cp;function mv(e,a,t={}){return r(this,void 0,void 0,(function*(){if(yield c.exists(a)){let i=true;if(yield c.isDirectory(a)){a=d.join(a,d.basename(e));i=yield c.exists(a)}if(i){if(t.force==null||t.force){yield rmRF(a)}else{throw new Error("Destination already exists")}}}yield mkdirP(d.dirname(a));yield c.rename(e,a)}))}a.mv=mv;function rmRF(e){return r(this,void 0,void 0,(function*(){if(c.IS_WINDOWS){if(/[*"<>|]/.test(e)){throw new Error('File path must not contain `*`, `"`, `<`, `>` or `|` on Windows')}try{const a=c.getCmdPath();if(yield c.isDirectory(e,true)){yield u(`${a} /s /c "rd /s /q "%inputPath%""`,{env:{inputPath:e}})}else{yield u(`${a} /s /c "del /f /a "%inputPath%""`,{env:{inputPath:e}})}}catch(e){if(e.code!=="ENOENT")throw e}try{yield c.unlink(e)}catch(e){if(e.code!=="ENOENT")throw e}}else{let a=false;try{a=yield c.isDirectory(e)}catch(e){if(e.code!=="ENOENT")throw e;return}if(a){yield m(`rm`,[`-rf`,`${e}`])}else{yield c.unlink(e)}}}))}a.rmRF=rmRF;function mkdirP(e){return r(this,void 0,void 0,(function*(){n.ok(e,"a path argument must be provided");yield c.mkdir(e,{recursive:true})}))}a.mkdirP=mkdirP;function which(e,a){return r(this,void 0,void 0,(function*(){if(!e){throw new Error("parameter 'tool' is required")}if(a){const a=yield which(e,false);if(!a){if(c.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 a}const t=yield findInPath(e);if(t&&t.length>0){return t[0]}return""}))}a.which=which;function findInPath(e){return r(this,void 0,void 0,(function*(){if(!e){throw new Error("parameter 'tool' is required")}const a=[];if(c.IS_WINDOWS&&process.env["PATHEXT"]){for(const e of process.env["PATHEXT"].split(d.delimiter)){if(e){a.push(e)}}}if(c.isRooted(e)){const t=yield c.tryGetExecutablePath(e,a);if(t){return[t]}return[]}if(e.includes(d.sep)){return[]}const t=[];if(process.env.PATH){for(const e of process.env.PATH.split(d.delimiter)){if(e){t.push(e)}}}const i=[];for(const s of t){const t=yield c.tryGetExecutablePath(d.join(s,e),a);if(t){i.push(t)}}return i}))}a.findInPath=findInPath;function readCopyOptions(e){const a=e.force==null?true:e.force;const t=Boolean(e.recursive);const i=e.copySourceDirectory==null?true:Boolean(e.copySourceDirectory);return{force:a,recursive:t,copySourceDirectory:i}}function cpDirRecursive(e,a,t,i){return r(this,void 0,void 0,(function*(){if(t>=255)return;t++;yield mkdirP(a);const s=yield c.readdir(e);for(const o of s){const s=`${e}/${o}`;const r=`${a}/${o}`;const n=yield c.lstat(s);if(n.isDirectory()){yield cpDirRecursive(s,r,t,i)}else{yield copyFile(s,r,i)}}yield c.chmod(a,(yield c.stat(e)).mode)}))}function copyFile(e,a,t){return r(this,void 0,void 0,(function*(){if((yield c.lstat(e)).isSymbolicLink()){try{yield c.lstat(a);yield c.unlink(a)}catch(e){if(e.code==="EPERM"){yield c.chmod(a,"0666");yield c.unlink(a)}}const t=yield c.readlink(e);yield c.symlink(t,a,c.IS_WINDOWS?"junction":null)}else if(!(yield c.exists(a))||t){yield c.copyFile(e,a)}}))}},5983:(e,a)=>{"use strict";Object.defineProperty(a,"__esModule",{value:true});const t=/^v1\./;const i=/^ghs_/;const s=/^ghu_/;async function auth(e){const a=e.split(/\./).length===3;const o=t.test(e)||i.test(e);const r=s.test(e);const n=a?"app":o?"installation":r?"user-to-server":"oauth";return{type:"token",token:e,tokenType:n}}function withAuthorizationPrefix(e){if(e.split(/\./).length===3){return`bearer ${e}`}return`token ${e}`}async function hook(e,a,t,i){const s=a.endpoint.merge(t,i);s.headers.authorization=withAuthorizationPrefix(e);return a(s)}const o=function createTokenAuth(e){if(!e){throw new Error("[@octokit/auth-token] No token passed to createTokenAuth")}if(typeof e!=="string"){throw new Error("[@octokit/auth-token] Token passed to createTokenAuth is not a string")}e=e.replace(/^(token|bearer) +/i,"");return Object.assign(auth.bind(null,e),{hook:hook.bind(null,e)})};a.createTokenAuth=o},1241:(e,a,t)=>{"use strict";Object.defineProperty(a,"__esModule",{value:true});var i=t(499);var s=t(9591);var o=t(7201);var r=t(6320);var n=t(5983);function _objectWithoutPropertiesLoose(e,a){if(e==null)return{};var t={};var i=Object.keys(e);var s,o;for(o=0;o=0)continue;t[s]=e[s]}return t}function _objectWithoutProperties(e,a){if(e==null)return{};var t=_objectWithoutPropertiesLoose(e,a);var i,s;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(s=0;s=0)continue;if(!Object.prototype.propertyIsEnumerable.call(e,i))continue;t[i]=e[i]}}return t}const p="3.6.0";const d=["authStrategy"];class Octokit{constructor(e={}){const a=new s.Collection;const t={baseUrl:o.request.endpoint.DEFAULTS.baseUrl,headers:{},request:Object.assign({},e.request,{hook:a.bind(null,"request")}),mediaType:{previews:[],format:""}};t.headers["user-agent"]=[e.userAgent,`octokit-core.js/${p} ${i.getUserAgent()}`].filter(Boolean).join(" ");if(e.baseUrl){t.baseUrl=e.baseUrl}if(e.previews){t.mediaType.previews=e.previews}if(e.timeZone){t.headers["time-zone"]=e.timeZone}this.request=o.request.defaults(t);this.graphql=r.withCustomRequest(this.request).defaults(t);this.log=Object.assign({debug:()=>{},info:()=>{},warn:console.warn.bind(console),error:console.error.bind(console)},e.log);this.hook=a;if(!e.authStrategy){if(!e.auth){this.auth=async()=>({type:"unauthenticated"})}else{const t=n.createTokenAuth(e.auth);a.wrap("request",t.hook);this.auth=t}}else{const{authStrategy:t}=e,i=_objectWithoutProperties(e,d);const s=t(Object.assign({request:this.request,log:this.log,octokit:this,octokitOptions:i},e.auth));a.wrap("request",s.hook);this.auth=s}const l=this.constructor;l.plugins.forEach((a=>{Object.assign(this,a(this,e))}))}static defaults(e){const a=class extends(this){constructor(...a){const t=a[0]||{};if(typeof e==="function"){super(e(t));return}super(Object.assign({},e,t,t.userAgent&&e.userAgent?{userAgent:`${t.userAgent} ${e.userAgent}`}:null))}};return a}static plugin(...e){var a;const t=this.plugins;const i=(a=class extends(this){},a.plugins=t.concat(e.filter((e=>!t.includes(e)))),a);return i}}Octokit.VERSION=p;Octokit.plugins=[];a.Octokit=Octokit},955:(e,a,t)=>{"use strict";Object.defineProperty(a,"__esModule",{value:true});var i=t(1410);var s=t(499);function lowercaseKeys(e){if(!e){return{}}return Object.keys(e).reduce(((a,t)=>{a[t.toLowerCase()]=e[t];return a}),{})}function mergeDeep(e,a){const t=Object.assign({},e);Object.keys(a).forEach((s=>{if(i.isPlainObject(a[s])){if(!(s in e))Object.assign(t,{[s]:a[s]});else t[s]=mergeDeep(e[s],a[s])}else{Object.assign(t,{[s]:a[s]})}}));return t}function removeUndefinedProperties(e){for(const a in e){if(e[a]===undefined){delete e[a]}}return e}function merge(e,a,t){if(typeof a==="string"){let[e,i]=a.split(" ");t=Object.assign(i?{method:e,url:i}:{url:e},t)}else{t=Object.assign({},a)}t.headers=lowercaseKeys(t.headers);removeUndefinedProperties(t);removeUndefinedProperties(t.headers);const i=mergeDeep(e||{},t);if(e&&e.mediaType.previews.length){i.mediaType.previews=e.mediaType.previews.filter((e=>!i.mediaType.previews.includes(e))).concat(i.mediaType.previews)}i.mediaType.previews=i.mediaType.previews.map((e=>e.replace(/-preview/,"")));return i}function addQueryParameters(e,a){const t=/\?/.test(e)?"&":"?";const i=Object.keys(a);if(i.length===0){return e}return e+t+i.map((e=>{if(e==="q"){return"q="+a.q.split("+").map(encodeURIComponent).join("+")}return`${e}=${encodeURIComponent(a[e])}`})).join("&")}const o=/\{[^}]+\}/g;function removeNonChars(e){return e.replace(/^\W+|\W+$/g,"").split(/,/)}function extractUrlVariableNames(e){const a=e.match(o);if(!a){return[]}return a.map(removeNonChars).reduce(((e,a)=>e.concat(a)),[])}function omit(e,a){return Object.keys(e).filter((e=>!a.includes(e))).reduce(((a,t)=>{a[t]=e[t];return a}),{})}function encodeReserved(e){return e.split(/(%[0-9A-Fa-f]{2})/g).map((function(e){if(!/%[0-9A-Fa-f]/.test(e)){e=encodeURI(e).replace(/%5B/g,"[").replace(/%5D/g,"]")}return e})).join("")}function encodeUnreserved(e){return encodeURIComponent(e).replace(/[!'()*]/g,(function(e){return"%"+e.charCodeAt(0).toString(16).toUpperCase()}))}function encodeValue(e,a,t){a=e==="+"||e==="#"?encodeReserved(a):encodeUnreserved(a);if(t){return encodeUnreserved(t)+"="+a}else{return a}}function isDefined(e){return e!==undefined&&e!==null}function isKeyOperator(e){return e===";"||e==="&"||e==="?"}function getValues(e,a,t,i){var s=e[t],o=[];if(isDefined(s)&&s!==""){if(typeof s==="string"||typeof s==="number"||typeof s==="boolean"){s=s.toString();if(i&&i!=="*"){s=s.substring(0,parseInt(i,10))}o.push(encodeValue(a,s,isKeyOperator(a)?t:""))}else{if(i==="*"){if(Array.isArray(s)){s.filter(isDefined).forEach((function(e){o.push(encodeValue(a,e,isKeyOperator(a)?t:""))}))}else{Object.keys(s).forEach((function(e){if(isDefined(s[e])){o.push(encodeValue(a,s[e],e))}}))}}else{const e=[];if(Array.isArray(s)){s.filter(isDefined).forEach((function(t){e.push(encodeValue(a,t))}))}else{Object.keys(s).forEach((function(t){if(isDefined(s[t])){e.push(encodeUnreserved(t));e.push(encodeValue(a,s[t].toString()))}}))}if(isKeyOperator(a)){o.push(encodeUnreserved(t)+"="+e.join(","))}else if(e.length!==0){o.push(e.join(","))}}}}else{if(a===";"){if(isDefined(s)){o.push(encodeUnreserved(t))}}else if(s===""&&(a==="&"||a==="?")){o.push(encodeUnreserved(t)+"=")}else if(s===""){o.push("")}}return o}function parseUrl(e){return{expand:expand.bind(null,e)}}function expand(e,a){var t=["+","#",".","/",";","?","&"];return e.replace(/\{([^\{\}]+)\}|([^\{\}]+)/g,(function(e,i,s){if(i){let e="";const s=[];if(t.indexOf(i.charAt(0))!==-1){e=i.charAt(0);i=i.substr(1)}i.split(/,/g).forEach((function(t){var i=/([^:\*]*)(?::(\d+)|(\*))?/.exec(t);s.push(getValues(a,e,i[1],i[2]||i[3]))}));if(e&&e!=="+"){var o=",";if(e==="?"){o="&"}else if(e!=="#"){o=e}return(s.length!==0?e:"")+s.join(o)}else{return s.join(",")}}else{return encodeReserved(s)}}))}function parse(e){let a=e.method.toUpperCase();let t=(e.url||"/").replace(/:([a-z]\w+)/g,"{$1}");let i=Object.assign({},e.headers);let s;let o=omit(e,["method","baseUrl","url","headers","request","mediaType"]);const r=extractUrlVariableNames(t);t=parseUrl(t).expand(o);if(!/^http/.test(t)){t=e.baseUrl+t}const n=Object.keys(e).filter((e=>r.includes(e))).concat("baseUrl");const p=omit(o,n);const d=/application\/octet-stream/i.test(i.accept);if(!d){if(e.mediaType.format){i.accept=i.accept.split(/,/).map((a=>a.replace(/application\/vnd(\.\w+)(\.v3)?(\.\w+)?(\+json)?$/,`application/vnd$1$2.${e.mediaType.format}`))).join(",")}if(e.mediaType.previews.length){const a=i.accept.match(/[\w-]+(?=-preview)/g)||[];i.accept=a.concat(e.mediaType.previews).map((a=>{const t=e.mediaType.format?`.${e.mediaType.format}`:"+json";return`application/vnd.github.${a}-preview${t}`})).join(",")}}if(["GET","HEAD"].includes(a)){t=addQueryParameters(t,p)}else{if("data"in p){s=p.data}else{if(Object.keys(p).length){s=p}else{i["content-length"]=0}}}if(!i["content-type"]&&typeof s!=="undefined"){i["content-type"]="application/json; charset=utf-8"}if(["PATCH","PUT"].includes(a)&&typeof s==="undefined"){s=""}return Object.assign({method:a,url:t,headers:i},typeof s!=="undefined"?{body:s}:null,e.request?{request:e.request}:null)}function endpointWithDefaults(e,a,t){return parse(merge(e,a,t))}function withDefaults(e,a){const t=merge(e,a);const i=endpointWithDefaults.bind(null,t);return Object.assign(i,{DEFAULTS:t,defaults:withDefaults.bind(null,t),merge:merge.bind(null,t),parse:parse})}const r="6.0.12";const n=`octokit-endpoint.js/${r} ${s.getUserAgent()}`;const p={method:"GET",baseUrl:"https://api.github.com",headers:{accept:"application/vnd.github.v3+json","user-agent":n},mediaType:{format:"",previews:[]}};const d=withDefaults(null,p);a.endpoint=d},6320:(e,a,t)=>{"use strict";Object.defineProperty(a,"__esModule",{value:true});var i=t(7201);var s=t(499);const o="4.8.0";function _buildMessageForResponseErrors(e){return`Request failed due to following response errors:\n`+e.errors.map((e=>` - ${e.message}`)).join("\n")}class GraphqlResponseError extends Error{constructor(e,a,t){super(_buildMessageForResponseErrors(t));this.request=e;this.headers=a;this.response=t;this.name="GraphqlResponseError";this.errors=t.errors;this.data=t.data;if(Error.captureStackTrace){Error.captureStackTrace(this,this.constructor)}}}const r=["method","baseUrl","url","headers","request","query","mediaType"];const n=["query","method","url"];const p=/\/api\/v3\/?$/;function graphql(e,a,t){if(t){if(typeof a==="string"&&"query"in t){return Promise.reject(new Error(`[@octokit/graphql] "query" cannot be used as variable name`))}for(const e in t){if(!n.includes(e))continue;return Promise.reject(new Error(`[@octokit/graphql] "${e}" cannot be used as variable name`))}}const i=typeof a==="string"?Object.assign({query:a},t):a;const s=Object.keys(i).reduce(((e,a)=>{if(r.includes(a)){e[a]=i[a];return e}if(!e.variables){e.variables={}}e.variables[a]=i[a];return e}),{});const o=i.baseUrl||e.endpoint.DEFAULTS.baseUrl;if(p.test(o)){s.url=o.replace(p,"/api/graphql")}return e(s).then((e=>{if(e.data.errors){const a={};for(const t of Object.keys(e.headers)){a[t]=e.headers[t]}throw new GraphqlResponseError(s,a,e.data)}return e.data.data}))}function withDefaults(e,a){const t=e.defaults(a);const newApi=(e,a)=>graphql(t,e,a);return Object.assign(newApi,{defaults:withDefaults.bind(null,t),endpoint:i.request.endpoint})}const d=withDefaults(i.request,{headers:{"user-agent":`octokit-graphql.js/${o} ${s.getUserAgent()}`},method:"POST",url:"/graphql"});function withCustomRequest(e){return withDefaults(e,{method:"POST",url:"/graphql"})}a.GraphqlResponseError=GraphqlResponseError;a.graphql=d;a.withCustomRequest=withCustomRequest},8469:(e,a)=>{"use strict";Object.defineProperty(a,"__esModule",{value:true});const t="2.21.3";function ownKeys(e,a){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);a&&(i=i.filter((function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable}))),t.push.apply(t,i)}return t}function _objectSpread2(e){for(var a=1;a({async next(){if(!n)return{done:true};try{const e=await s({method:o,url:n,headers:r});const a=normalizePaginatedListResponse(e);n=((a.headers.link||"").match(/<([^>]+)>;\s*rel="next"/)||[])[1];return{value:a}}catch(e){if(e.status!==409)throw e;n="";return{value:{status:200,headers:{},data:[]}}}}})}}function paginate(e,a,t,i){if(typeof t==="function"){i=t;t=undefined}return gather(e,[],iterator(e,a,t)[Symbol.asyncIterator](),i)}function gather(e,a,t,i){return t.next().then((s=>{if(s.done){return a}let o=false;function done(){o=true}a=a.concat(i?i(s.value,done):s.value.data);if(o){return a}return gather(e,a,t,i)}))}const i=Object.assign(paginate,{iterator:iterator});const s=["GET /app/hook/deliveries","GET /app/installations","GET /applications/grants","GET /authorizations","GET /enterprises/{enterprise}/actions/permissions/organizations","GET /enterprises/{enterprise}/actions/runner-groups","GET /enterprises/{enterprise}/actions/runner-groups/{runner_group_id}/organizations","GET /enterprises/{enterprise}/actions/runner-groups/{runner_group_id}/runners","GET /enterprises/{enterprise}/actions/runners","GET /enterprises/{enterprise}/audit-log","GET /enterprises/{enterprise}/secret-scanning/alerts","GET /enterprises/{enterprise}/settings/billing/advanced-security","GET /events","GET /gists","GET /gists/public","GET /gists/starred","GET /gists/{gist_id}/comments","GET /gists/{gist_id}/commits","GET /gists/{gist_id}/forks","GET /installation/repositories","GET /issues","GET /licenses","GET /marketplace_listing/plans","GET /marketplace_listing/plans/{plan_id}/accounts","GET /marketplace_listing/stubbed/plans","GET /marketplace_listing/stubbed/plans/{plan_id}/accounts","GET /networks/{owner}/{repo}/events","GET /notifications","GET /organizations","GET /orgs/{org}/actions/cache/usage-by-repository","GET /orgs/{org}/actions/permissions/repositories","GET /orgs/{org}/actions/runner-groups","GET /orgs/{org}/actions/runner-groups/{runner_group_id}/repositories","GET /orgs/{org}/actions/runner-groups/{runner_group_id}/runners","GET /orgs/{org}/actions/runners","GET /orgs/{org}/actions/secrets","GET /orgs/{org}/actions/secrets/{secret_name}/repositories","GET /orgs/{org}/audit-log","GET /orgs/{org}/blocks","GET /orgs/{org}/code-scanning/alerts","GET /orgs/{org}/codespaces","GET /orgs/{org}/credential-authorizations","GET /orgs/{org}/dependabot/secrets","GET /orgs/{org}/dependabot/secrets/{secret_name}/repositories","GET /orgs/{org}/events","GET /orgs/{org}/external-groups","GET /orgs/{org}/failed_invitations","GET /orgs/{org}/hooks","GET /orgs/{org}/hooks/{hook_id}/deliveries","GET /orgs/{org}/installations","GET /orgs/{org}/invitations","GET /orgs/{org}/invitations/{invitation_id}/teams","GET /orgs/{org}/issues","GET /orgs/{org}/members","GET /orgs/{org}/migrations","GET /orgs/{org}/migrations/{migration_id}/repositories","GET /orgs/{org}/outside_collaborators","GET /orgs/{org}/packages","GET /orgs/{org}/packages/{package_type}/{package_name}/versions","GET /orgs/{org}/projects","GET /orgs/{org}/public_members","GET /orgs/{org}/repos","GET /orgs/{org}/secret-scanning/alerts","GET /orgs/{org}/settings/billing/advanced-security","GET /orgs/{org}/team-sync/groups","GET /orgs/{org}/teams","GET /orgs/{org}/teams/{team_slug}/discussions","GET /orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/comments","GET /orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/comments/{comment_number}/reactions","GET /orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/reactions","GET /orgs/{org}/teams/{team_slug}/invitations","GET /orgs/{org}/teams/{team_slug}/members","GET /orgs/{org}/teams/{team_slug}/projects","GET /orgs/{org}/teams/{team_slug}/repos","GET /orgs/{org}/teams/{team_slug}/teams","GET /projects/columns/{column_id}/cards","GET /projects/{project_id}/collaborators","GET /projects/{project_id}/columns","GET /repos/{owner}/{repo}/actions/artifacts","GET /repos/{owner}/{repo}/actions/caches","GET /repos/{owner}/{repo}/actions/runners","GET /repos/{owner}/{repo}/actions/runs","GET /repos/{owner}/{repo}/actions/runs/{run_id}/artifacts","GET /repos/{owner}/{repo}/actions/runs/{run_id}/attempts/{attempt_number}/jobs","GET /repos/{owner}/{repo}/actions/runs/{run_id}/jobs","GET /repos/{owner}/{repo}/actions/secrets","GET /repos/{owner}/{repo}/actions/workflows","GET /repos/{owner}/{repo}/actions/workflows/{workflow_id}/runs","GET /repos/{owner}/{repo}/assignees","GET /repos/{owner}/{repo}/branches","GET /repos/{owner}/{repo}/check-runs/{check_run_id}/annotations","GET /repos/{owner}/{repo}/check-suites/{check_suite_id}/check-runs","GET /repos/{owner}/{repo}/code-scanning/alerts","GET /repos/{owner}/{repo}/code-scanning/alerts/{alert_number}/instances","GET /repos/{owner}/{repo}/code-scanning/analyses","GET /repos/{owner}/{repo}/codespaces","GET /repos/{owner}/{repo}/codespaces/devcontainers","GET /repos/{owner}/{repo}/codespaces/secrets","GET /repos/{owner}/{repo}/collaborators","GET /repos/{owner}/{repo}/comments","GET /repos/{owner}/{repo}/comments/{comment_id}/reactions","GET /repos/{owner}/{repo}/commits","GET /repos/{owner}/{repo}/commits/{commit_sha}/comments","GET /repos/{owner}/{repo}/commits/{commit_sha}/pulls","GET /repos/{owner}/{repo}/commits/{ref}/check-runs","GET /repos/{owner}/{repo}/commits/{ref}/check-suites","GET /repos/{owner}/{repo}/commits/{ref}/status","GET /repos/{owner}/{repo}/commits/{ref}/statuses","GET /repos/{owner}/{repo}/contributors","GET /repos/{owner}/{repo}/dependabot/secrets","GET /repos/{owner}/{repo}/deployments","GET /repos/{owner}/{repo}/deployments/{deployment_id}/statuses","GET /repos/{owner}/{repo}/environments","GET /repos/{owner}/{repo}/events","GET /repos/{owner}/{repo}/forks","GET /repos/{owner}/{repo}/git/matching-refs/{ref}","GET /repos/{owner}/{repo}/hooks","GET /repos/{owner}/{repo}/hooks/{hook_id}/deliveries","GET /repos/{owner}/{repo}/invitations","GET /repos/{owner}/{repo}/issues","GET /repos/{owner}/{repo}/issues/comments","GET /repos/{owner}/{repo}/issues/comments/{comment_id}/reactions","GET /repos/{owner}/{repo}/issues/events","GET /repos/{owner}/{repo}/issues/{issue_number}/comments","GET /repos/{owner}/{repo}/issues/{issue_number}/events","GET /repos/{owner}/{repo}/issues/{issue_number}/labels","GET /repos/{owner}/{repo}/issues/{issue_number}/reactions","GET /repos/{owner}/{repo}/issues/{issue_number}/timeline","GET /repos/{owner}/{repo}/keys","GET /repos/{owner}/{repo}/labels","GET /repos/{owner}/{repo}/milestones","GET /repos/{owner}/{repo}/milestones/{milestone_number}/labels","GET /repos/{owner}/{repo}/notifications","GET /repos/{owner}/{repo}/pages/builds","GET /repos/{owner}/{repo}/projects","GET /repos/{owner}/{repo}/pulls","GET /repos/{owner}/{repo}/pulls/comments","GET /repos/{owner}/{repo}/pulls/comments/{comment_id}/reactions","GET /repos/{owner}/{repo}/pulls/{pull_number}/comments","GET /repos/{owner}/{repo}/pulls/{pull_number}/commits","GET /repos/{owner}/{repo}/pulls/{pull_number}/files","GET /repos/{owner}/{repo}/pulls/{pull_number}/requested_reviewers","GET /repos/{owner}/{repo}/pulls/{pull_number}/reviews","GET /repos/{owner}/{repo}/pulls/{pull_number}/reviews/{review_id}/comments","GET /repos/{owner}/{repo}/releases","GET /repos/{owner}/{repo}/releases/{release_id}/assets","GET /repos/{owner}/{repo}/releases/{release_id}/reactions","GET /repos/{owner}/{repo}/secret-scanning/alerts","GET /repos/{owner}/{repo}/secret-scanning/alerts/{alert_number}/locations","GET /repos/{owner}/{repo}/stargazers","GET /repos/{owner}/{repo}/subscribers","GET /repos/{owner}/{repo}/tags","GET /repos/{owner}/{repo}/teams","GET /repos/{owner}/{repo}/topics","GET /repositories","GET /repositories/{repository_id}/environments/{environment_name}/secrets","GET /search/code","GET /search/commits","GET /search/issues","GET /search/labels","GET /search/repositories","GET /search/topics","GET /search/users","GET /teams/{team_id}/discussions","GET /teams/{team_id}/discussions/{discussion_number}/comments","GET /teams/{team_id}/discussions/{discussion_number}/comments/{comment_number}/reactions","GET /teams/{team_id}/discussions/{discussion_number}/reactions","GET /teams/{team_id}/invitations","GET /teams/{team_id}/members","GET /teams/{team_id}/projects","GET /teams/{team_id}/repos","GET /teams/{team_id}/teams","GET /user/blocks","GET /user/codespaces","GET /user/codespaces/secrets","GET /user/emails","GET /user/followers","GET /user/following","GET /user/gpg_keys","GET /user/installations","GET /user/installations/{installation_id}/repositories","GET /user/issues","GET /user/keys","GET /user/marketplace_purchases","GET /user/marketplace_purchases/stubbed","GET /user/memberships/orgs","GET /user/migrations","GET /user/migrations/{migration_id}/repositories","GET /user/orgs","GET /user/packages","GET /user/packages/{package_type}/{package_name}/versions","GET /user/public_emails","GET /user/repos","GET /user/repository_invitations","GET /user/starred","GET /user/subscriptions","GET /user/teams","GET /users","GET /users/{username}/events","GET /users/{username}/events/orgs/{org}","GET /users/{username}/events/public","GET /users/{username}/followers","GET /users/{username}/following","GET /users/{username}/gists","GET /users/{username}/gpg_keys","GET /users/{username}/keys","GET /users/{username}/orgs","GET /users/{username}/packages","GET /users/{username}/projects","GET /users/{username}/received_events","GET /users/{username}/received_events/public","GET /users/{username}/repos","GET /users/{username}/starred","GET /users/{username}/subscriptions"];function isPaginatingEndpoint(e){if(typeof e==="string"){return s.includes(e)}else{return false}}function paginateRest(e){return{paginate:Object.assign(paginate.bind(null,e),{iterator:iterator.bind(null,e)})}}paginateRest.VERSION=t;a.composePaginateRest=i;a.isPaginatingEndpoint=isPaginatingEndpoint;a.paginateRest=paginateRest;a.paginatingEndpoints=s},1114:(e,a)=>{"use strict";Object.defineProperty(a,"__esModule",{value:true});function ownKeys(e,a){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);if(a){i=i.filter((function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable}))}t.push.apply(t,i)}return t}function _objectSpread2(e){for(var a=1;a{"use strict";Object.defineProperty(a,"__esModule",{value:true});function _interopDefault(e){return e&&typeof e==="object"&&"default"in e?e["default"]:e}var i=t(718);var s=_interopDefault(t(3197));const o=s((e=>console.warn(e)));const r=s((e=>console.warn(e)));class RequestError extends Error{constructor(e,a,t){super(e);if(Error.captureStackTrace){Error.captureStackTrace(this,this.constructor)}this.name="HttpError";this.status=a;let s;if("headers"in t&&typeof t.headers!=="undefined"){s=t.headers}if("response"in t){this.response=t.response;s=t.response.headers}const n=Object.assign({},t.request);if(t.request.headers.authorization){n.headers=Object.assign({},t.request.headers,{authorization:t.request.headers.authorization.replace(/ .*$/," [REDACTED]")})}n.url=n.url.replace(/\bclient_secret=\w+/g,"client_secret=[REDACTED]").replace(/\baccess_token=\w+/g,"access_token=[REDACTED]");this.request=n;Object.defineProperty(this,"code",{get(){o(new i.Deprecation("[@octokit/request-error] `error.code` is deprecated, use `error.status`."));return a}});Object.defineProperty(this,"headers",{get(){r(new i.Deprecation("[@octokit/request-error] `error.headers` is deprecated, use `error.response.headers`."));return s||{}}})}}a.RequestError=RequestError},7201:(e,a,t)=>{"use strict";Object.defineProperty(a,"__esModule",{value:true});function _interopDefault(e){return e&&typeof e==="object"&&"default"in e?e["default"]:e}var i=t(955);var s=t(499);var o=t(1410);var r=_interopDefault(t(9681));var n=t(8829);const p="5.6.3";function getBufferResponse(e){return e.arrayBuffer()}function fetchWrapper(e){const a=e.request&&e.request.log?e.request.log:console;if(o.isPlainObject(e.body)||Array.isArray(e.body)){e.body=JSON.stringify(e.body)}let t={};let i;let s;const p=e.request&&e.request.fetch||r;return p(e.url,Object.assign({method:e.method,body:e.body,headers:e.headers,redirect:e.redirect},e.request)).then((async o=>{s=o.url;i=o.status;for(const e of o.headers){t[e[0]]=e[1]}if("deprecation"in t){const i=t.link&&t.link.match(/<([^>]+)>; rel="deprecation"/);const s=i&&i.pop();a.warn(`[@octokit/request] "${e.method} ${e.url}" is deprecated. It is scheduled to be removed on ${t.sunset}${s?`. See ${s}`:""}`)}if(i===204||i===205){return}if(e.method==="HEAD"){if(i<400){return}throw new n.RequestError(o.statusText,i,{response:{url:s,status:i,headers:t,data:undefined},request:e})}if(i===304){throw new n.RequestError("Not modified",i,{response:{url:s,status:i,headers:t,data:await getResponseData(o)},request:e})}if(i>=400){const a=await getResponseData(o);const r=new n.RequestError(toErrorMessage(a),i,{response:{url:s,status:i,headers:t,data:a},request:e});throw r}return getResponseData(o)})).then((e=>({status:i,url:s,headers:t,data:e}))).catch((a=>{if(a instanceof n.RequestError)throw a;throw new n.RequestError(a.message,500,{request:e})}))}async function getResponseData(e){const a=e.headers.get("content-type");if(/application\/json/.test(a)){return e.json()}if(!a||/^text\/|charset=utf-8$/.test(a)){return e.text()}return getBufferResponse(e)}function toErrorMessage(e){if(typeof e==="string")return e;if("message"in e){if(Array.isArray(e.errors)){return`${e.message}: ${e.errors.map(JSON.stringify).join(", ")}`}return e.message}return`Unknown error: ${JSON.stringify(e)}`}function withDefaults(e,a){const t=e.defaults(a);const newApi=function(e,a){const i=t.merge(e,a);if(!i.request||!i.request.hook){return fetchWrapper(t.parse(i))}const request=(e,a)=>fetchWrapper(t.parse(t.merge(e,a)));Object.assign(request,{endpoint:t,defaults:withDefaults.bind(null,t)});return i.request.hook(request,i)};return Object.assign(newApi,{endpoint:t,defaults:withDefaults.bind(null,t)})}const d=withDefaults(i.endpoint,{headers:{"user-agent":`octokit-request.js/${p} ${s.getUserAgent()}`}});a.request=d},7758:(e,a,t)=>{e.exports={parallel:t(9342),serial:t(3741),serialOrdered:t(3637)}},4931:e=>{e.exports=abort;function abort(e){Object.keys(e.jobs).forEach(clean.bind(e));e.jobs={}}function clean(e){if(typeof this.jobs[e]=="function"){this.jobs[e]()}}},9645:(e,a,t)=>{var i=t(3218);e.exports=async;function async(e){var a=false;i((function(){a=true}));return function async_callback(t,s){if(a){e(t,s)}else{i((function nextTick_callback(){e(t,s)}))}}}},3218:e=>{e.exports=defer;function defer(e){var a=typeof setImmediate=="function"?setImmediate:typeof process=="object"&&typeof process.nextTick=="function"?process.nextTick:null;if(a){a(e)}else{setTimeout(e,0)}}},4447:(e,a,t)=>{var i=t(9645),s=t(4931);e.exports=iterate;function iterate(e,a,t,i){var o=t["keyedList"]?t["keyedList"][t.index]:t.index;t.jobs[o]=runJob(a,o,e[o],(function(e,a){if(!(o in t.jobs)){return}delete t.jobs[o];if(e){s(t)}else{t.results[o]=a}i(e,t.results)}))}function runJob(e,a,t,s){var o;if(e.length==2){o=e(t,i(s))}else{o=e(t,a,i(s))}return o}},6156:e=>{e.exports=state;function state(e,a){var t=!Array.isArray(e),i={index:0,keyedList:t||a?Object.keys(e):null,jobs:{},results:t?{}:[],size:t?Object.keys(e).length:e.length};if(a){i.keyedList.sort(t?a:function(t,i){return a(e[t],e[i])})}return i}},1250:(e,a,t)=>{var i=t(4931),s=t(9645);e.exports=terminator;function terminator(e){if(!Object.keys(this.jobs).length){return}this.index=this.size;i(this);s(e)(null,this.results)}},9342:(e,a,t)=>{var i=t(4447),s=t(6156),o=t(1250);e.exports=parallel;function parallel(e,a,t){var r=s(e);while(r.index<(r["keyedList"]||e).length){i(e,a,r,(function(e,a){if(e){t(e,a);return}if(Object.keys(r.jobs).length===0){t(null,r.results);return}}));r.index++}return o.bind(r,t)}},3741:(e,a,t)=>{var i=t(3637);e.exports=serial;function serial(e,a,t){return i(e,a,null,t)}},3637:(e,a,t)=>{var i=t(4447),s=t(6156),o=t(1250);e.exports=serialOrdered;e.exports.ascending=ascending;e.exports.descending=descending;function serialOrdered(e,a,t,r){var n=s(e,t);i(e,a,n,(function iteratorHandler(t,s){if(t){r(t,s);return}n.index++;if(n.index<(n["keyedList"]||e).length){i(e,a,n,iteratorHandler);return}r(null,n.results)}));return o.bind(n,r)}function ascending(e,a){return ea?1:0}function descending(e,a){return-1*ascending(e,a)}},9591:(e,a,t)=>{var i=t(2838);var s=t(5338);var o=t(296);var r=Function.bind;var n=r.bind(r);function bindApi(e,a,t){var i=n(o,null).apply(null,t?[a,t]:[a]);e.api={remove:i};e.remove=i;["before","error","after","wrap"].forEach((function(i){var o=t?[a,i,t]:[a,i];e[i]=e.api[i]=n(s,null).apply(null,o)}))}function HookSingular(){var e="h";var a={registry:{}};var t=i.bind(null,a,e);bindApi(t,a,e);return t}function HookCollection(){var e={registry:{}};var a=i.bind(null,e);bindApi(a,e);return a}var p=false;function Hook(){if(!p){console.warn('[before-after-hook]: "Hook()" repurposing warning, use "Hook.Collection()". Read more: https://git.io/upgrade-before-after-hook-to-1.4');p=true}return HookCollection()}Hook.Singular=HookSingular.bind();Hook.Collection=HookCollection.bind();e.exports=Hook;e.exports.Hook=Hook;e.exports.Singular=Hook.Singular;e.exports.Collection=Hook.Collection},5338:e=>{e.exports=addHook;function addHook(e,a,t,i){var s=i;if(!e.registry[t]){e.registry[t]=[]}if(a==="before"){i=function(e,a){return Promise.resolve().then(s.bind(null,a)).then(e.bind(null,a))}}if(a==="after"){i=function(e,a){var t;return Promise.resolve().then(e.bind(null,a)).then((function(e){t=e;return s(t,a)})).then((function(){return t}))}}if(a==="error"){i=function(e,a){return Promise.resolve().then(e.bind(null,a)).catch((function(e){return s(e,a)}))}}e.registry[t].push({hook:i,orig:s})}},2838:e=>{e.exports=register;function register(e,a,t,i){if(typeof t!=="function"){throw new Error("method for before hook must be a function")}if(!i){i={}}if(Array.isArray(a)){return a.reverse().reduce((function(a,t){return register.bind(null,e,t,a,i)}),t)()}return Promise.resolve().then((function(){if(!e.registry[a]){return t(i)}return e.registry[a].reduce((function(e,a){return a.hook.bind(null,e,i)}),t)()}))}},296:e=>{e.exports=removeHook;function removeHook(e,a,t){if(!e.registry[a]){return}var i=e.registry[a].map((function(e){return e.orig})).indexOf(t);if(i===-1){return}e.registry[a].splice(i,1)}},500:(e,a,t)=>{var i=t(3837);var s=t(2781).Stream;var o=t(4058);e.exports=CombinedStream;function CombinedStream(){this.writable=false;this.readable=true;this.dataSize=0;this.maxDataSize=2*1024*1024;this.pauseStreams=true;this._released=false;this._streams=[];this._currentStream=null;this._insideLoop=false;this._pendingNext=false}i.inherits(CombinedStream,s);CombinedStream.create=function(e){var a=new this;e=e||{};for(var t in e){a[t]=e[t]}return a};CombinedStream.isStreamLike=function(e){return typeof e!=="function"&&typeof e!=="string"&&typeof e!=="boolean"&&typeof e!=="number"&&!Buffer.isBuffer(e)};CombinedStream.prototype.append=function(e){var a=CombinedStream.isStreamLike(e);if(a){if(!(e instanceof o)){var t=o.create(e,{maxDataSize:Infinity,pauseStream:this.pauseStreams});e.on("data",this._checkDataSize.bind(this));e=t}this._handleErrors(e);if(this.pauseStreams){e.pause()}}this._streams.push(e);return this};CombinedStream.prototype.pipe=function(e,a){s.prototype.pipe.call(this,e,a);this.resume();return e};CombinedStream.prototype._getNext=function(){this._currentStream=null;if(this._insideLoop){this._pendingNext=true;return}this._insideLoop=true;try{do{this._pendingNext=false;this._realGetNext()}while(this._pendingNext)}finally{this._insideLoop=false}};CombinedStream.prototype._realGetNext=function(){var e=this._streams.shift();if(typeof e=="undefined"){this.end();return}if(typeof e!=="function"){this._pipeNext(e);return}var a=e;a(function(e){var a=CombinedStream.isStreamLike(e);if(a){e.on("data",this._checkDataSize.bind(this));this._handleErrors(e)}this._pipeNext(e)}.bind(this))};CombinedStream.prototype._pipeNext=function(e){this._currentStream=e;var a=CombinedStream.isStreamLike(e);if(a){e.on("end",this._getNext.bind(this));e.pipe(this,{end:false});return}var t=e;this.write(t);this._getNext()};CombinedStream.prototype._handleErrors=function(e){var a=this;e.on("error",(function(e){a._emitError(e)}))};CombinedStream.prototype.write=function(e){this.emit("data",e)};CombinedStream.prototype.pause=function(){if(!this.pauseStreams){return}if(this.pauseStreams&&this._currentStream&&typeof this._currentStream.pause=="function")this._currentStream.pause();this.emit("pause")};CombinedStream.prototype.resume=function(){if(!this._released){this._released=true;this.writable=true;this._getNext()}if(this.pauseStreams&&this._currentStream&&typeof this._currentStream.resume=="function")this._currentStream.resume();this.emit("resume")};CombinedStream.prototype.end=function(){this._reset();this.emit("end")};CombinedStream.prototype.destroy=function(){this._reset();this.emit("close")};CombinedStream.prototype._reset=function(){this.writable=false;this._streams=[];this._currentStream=null};CombinedStream.prototype._checkDataSize=function(){this._updateDataSize();if(this.dataSize<=this.maxDataSize){return}var e="DelayedStream#maxDataSize of "+this.maxDataSize+" bytes exceeded.";this._emitError(new Error(e))};CombinedStream.prototype._updateDataSize=function(){this.dataSize=0;var e=this;this._streams.forEach((function(a){if(!a.dataSize){return}e.dataSize+=a.dataSize}));if(this._currentStream&&this._currentStream.dataSize){this.dataSize+=this._currentStream.dataSize}};CombinedStream.prototype._emitError=function(e){this._reset();this.emit("error",e)}},589:(e,a,t)=>{a.formatArgs=formatArgs;a.save=save;a.load=load;a.useColors=useColors;a.storage=localstorage();a.destroy=(()=>{let e=false;return()=>{if(!e){e=true;console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.")}}})();a.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"];function useColors(){if(typeof window!=="undefined"&&window.process&&(window.process.type==="renderer"||window.process.__nwjs)){return true}if(typeof navigator!=="undefined"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/)){return false}return typeof document!=="undefined"&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||typeof window!=="undefined"&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||typeof navigator!=="undefined"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||typeof navigator!=="undefined"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)}function formatArgs(a){a[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+a[0]+(this.useColors?"%c ":" ")+"+"+e.exports.humanize(this.diff);if(!this.useColors){return}const t="color: "+this.color;a.splice(1,0,t,"color: inherit");let i=0;let s=0;a[0].replace(/%[a-zA-Z%]/g,(e=>{if(e==="%%"){return}i++;if(e==="%c"){s=i}}));a.splice(s,0,t)}a.log=console.debug||console.log||(()=>{});function save(e){try{if(e){a.storage.setItem("debug",e)}else{a.storage.removeItem("debug")}}catch(e){}}function load(){let e;try{e=a.storage.getItem("debug")}catch(e){}if(!e&&typeof process!=="undefined"&&"env"in process){e=process.env.DEBUG}return e}function localstorage(){try{return localStorage}catch(e){}}e.exports=t(2072)(a);const{formatters:i}=e.exports;i.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}}},2072:(e,a,t)=>{function setup(e){createDebug.debug=createDebug;createDebug.default=createDebug;createDebug.coerce=coerce;createDebug.disable=disable;createDebug.enable=enable;createDebug.enabled=enabled;createDebug.humanize=t(5097);createDebug.destroy=destroy;Object.keys(e).forEach((a=>{createDebug[a]=e[a]}));createDebug.names=[];createDebug.skips=[];createDebug.formatters={};function selectColor(e){let a=0;for(let t=0;t{if(a==="%%"){return"%"}o++;const s=createDebug.formatters[i];if(typeof s==="function"){const i=e[o];a=s.call(t,i);e.splice(o,1);o--}return a}));createDebug.formatArgs.call(t,e);const r=t.log||createDebug.log;r.apply(t,e)}debug.namespace=e;debug.useColors=createDebug.useColors();debug.color=createDebug.selectColor(e);debug.extend=extend;debug.destroy=createDebug.destroy;Object.defineProperty(debug,"enabled",{enumerable:true,configurable:false,get:()=>{if(t!==null){return t}if(i!==createDebug.namespaces){i=createDebug.namespaces;s=createDebug.enabled(e)}return s},set:e=>{t=e}});if(typeof createDebug.init==="function"){createDebug.init(debug)}return debug}function extend(e,a){const t=createDebug(this.namespace+(typeof a==="undefined"?":":a)+e);t.log=this.log;return t}function enable(e){createDebug.save(e);createDebug.namespaces=e;createDebug.names=[];createDebug.skips=[];let a;const t=(typeof e==="string"?e:"").split(/[\s,]+/);const i=t.length;for(a=0;a"-"+e))].join(",");createDebug.enable("");return e}function enabled(e){if(e[e.length-1]==="*"){return true}let a;let t;for(a=0,t=createDebug.skips.length;a{if(typeof process==="undefined"||process.type==="renderer"||process.browser===true||process.__nwjs){e.exports=t(589)}else{e.exports=t(8380)}},8380:(e,a,t)=>{const i=t(6224);const s=t(3837);a.init=init;a.log=log;a.formatArgs=formatArgs;a.save=save;a.load=load;a.useColors=useColors;a.destroy=s.deprecate((()=>{}),"Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.");a.colors=[6,2,3,4,5,1];try{const e=t(2914);if(e&&(e.stderr||e).level>=2){a.colors=[20,21,26,27,32,33,38,39,40,41,42,43,44,45,56,57,62,63,68,69,74,75,76,77,78,79,80,81,92,93,98,99,112,113,128,129,134,135,148,149,160,161,162,163,164,165,166,167,168,169,170,171,172,173,178,179,184,185,196,197,198,199,200,201,202,203,204,205,206,207,208,209,214,215,220,221]}}catch(e){}a.inspectOpts=Object.keys(process.env).filter((e=>/^debug_/i.test(e))).reduce(((e,a)=>{const t=a.substring(6).toLowerCase().replace(/_([a-z])/g,((e,a)=>a.toUpperCase()));let i=process.env[a];if(/^(yes|on|true|enabled)$/i.test(i)){i=true}else if(/^(no|off|false|disabled)$/i.test(i)){i=false}else if(i==="null"){i=null}else{i=Number(i)}e[t]=i;return e}),{});function useColors(){return"colors"in a.inspectOpts?Boolean(a.inspectOpts.colors):i.isatty(process.stderr.fd)}function formatArgs(a){const{namespace:t,useColors:i}=this;if(i){const i=this.color;const s="[3"+(i<8?i:"8;5;"+i);const o=` ${s};1m${t} `;a[0]=o+a[0].split("\n").join("\n"+o);a.push(s+"m+"+e.exports.humanize(this.diff)+"")}else{a[0]=getDate()+t+" "+a[0]}}function getDate(){if(a.inspectOpts.hideDate){return""}return(new Date).toISOString()+" "}function log(...e){return process.stderr.write(s.format(...e)+"\n")}function save(e){if(e){process.env.DEBUG=e}else{delete process.env.DEBUG}}function load(){return process.env.DEBUG}function init(e){e.inspectOpts={};const t=Object.keys(a.inspectOpts);for(let i=0;ie.trim())).join(" ")};o.O=function(e){this.inspectOpts.colors=this.useColors;return s.inspect(e,this.inspectOpts)}},4058:(e,a,t)=>{var i=t(2781).Stream;var s=t(3837);e.exports=DelayedStream;function DelayedStream(){this.source=null;this.dataSize=0;this.maxDataSize=1024*1024;this.pauseStream=true;this._maxDataSizeExceeded=false;this._released=false;this._bufferedEvents=[]}s.inherits(DelayedStream,i);DelayedStream.create=function(e,a){var t=new this;a=a||{};for(var i in a){t[i]=a[i]}t.source=e;var s=e.emit;e.emit=function(){t._handleEmit(arguments);return s.apply(e,arguments)};e.on("error",(function(){}));if(t.pauseStream){e.pause()}return t};Object.defineProperty(DelayedStream.prototype,"readable",{configurable:true,enumerable:true,get:function(){return this.source.readable}});DelayedStream.prototype.setEncoding=function(){return this.source.setEncoding.apply(this.source,arguments)};DelayedStream.prototype.resume=function(){if(!this._released){this.release()}this.source.resume()};DelayedStream.prototype.pause=function(){this.source.pause()};DelayedStream.prototype.release=function(){this._released=true;this._bufferedEvents.forEach(function(e){this.emit.apply(this,e)}.bind(this));this._bufferedEvents=[]};DelayedStream.prototype.pipe=function(){var e=i.prototype.pipe.apply(this,arguments);this.resume();return e};DelayedStream.prototype._handleEmit=function(e){if(this._released){this.emit.apply(this,e);return}if(e[0]==="data"){this.dataSize+=e[1].length;this._checkIfMaxDataSizeExceeded()}this._bufferedEvents.push(e)};DelayedStream.prototype._checkIfMaxDataSizeExceeded=function(){if(this._maxDataSizeExceeded){return}if(this.dataSize<=this.maxDataSize){return}this._maxDataSizeExceeded=true;var e="DelayedStream#maxDataSize of "+this.maxDataSize+" bytes exceeded.";this.emit("error",new Error(e))}},718:(e,a)=>{"use strict";Object.defineProperty(a,"__esModule",{value:true});class Deprecation extends Error{constructor(e){super(e);if(Error.captureStackTrace){Error.captureStackTrace(this,this.constructor)}this.name="Deprecation"}}a.Deprecation=Deprecation},7191:(e,a,t)=>{var i;e.exports=function(){if(!i){try{i=t(7244)("follow-redirects")}catch(e){}if(typeof i!=="function"){i=function(){}}}i.apply(null,arguments)}},4322:(e,a,t)=>{var i=t(7310);var s=i.URL;var o=t(3685);var r=t(5687);var n=t(2781).Writable;var p=t(9491);var d=t(7191);var l=["abort","aborted","connect","error","socket","timeout"];var c=Object.create(null);l.forEach((function(e){c[e]=function(a,t,i){this._redirectable.emit(e,a,t,i)}}));var u=createErrorType("ERR_INVALID_URL","Invalid URL",TypeError);var m=createErrorType("ERR_FR_REDIRECTION_FAILURE","Redirected request failed");var v=createErrorType("ERR_FR_TOO_MANY_REDIRECTS","Maximum number of redirects exceeded");var h=createErrorType("ERR_FR_MAX_BODY_LENGTH_EXCEEDED","Request body larger than maxBodyLength limit");var g=createErrorType("ERR_STREAM_WRITE_AFTER_END","write after end");function RedirectableRequest(e,a){n.call(this);this._sanitizeOptions(e);this._options=e;this._ended=false;this._ending=false;this._redirectCount=0;this._redirects=[];this._requestBodyLength=0;this._requestBodyBuffers=[];if(a){this.on("response",a)}var t=this;this._onNativeResponse=function(e){t._processResponse(e)};this._performRequest()}RedirectableRequest.prototype=Object.create(n.prototype);RedirectableRequest.prototype.abort=function(){abortRequest(this._currentRequest);this.emit("abort")};RedirectableRequest.prototype.write=function(e,a,t){if(this._ending){throw new g}if(!isString(e)&&!isBuffer(e)){throw new TypeError("data should be a string, Buffer or Uint8Array")}if(isFunction(a)){t=a;a=null}if(e.length===0){if(t){t()}return}if(this._requestBodyLength+e.length<=this._options.maxBodyLength){this._requestBodyLength+=e.length;this._requestBodyBuffers.push({data:e,encoding:a});this._currentRequest.write(e,a,t)}else{this.emit("error",new h);this.abort()}};RedirectableRequest.prototype.end=function(e,a,t){if(isFunction(e)){t=e;e=a=null}else if(isFunction(a)){t=a;a=null}if(!e){this._ended=this._ending=true;this._currentRequest.end(null,null,t)}else{var i=this;var s=this._currentRequest;this.write(e,a,(function(){i._ended=true;s.end(null,null,t)}));this._ending=true}};RedirectableRequest.prototype.setHeader=function(e,a){this._options.headers[e]=a;this._currentRequest.setHeader(e,a)};RedirectableRequest.prototype.removeHeader=function(e){delete this._options.headers[e];this._currentRequest.removeHeader(e)};RedirectableRequest.prototype.setTimeout=function(e,a){var t=this;function destroyOnTimeout(a){a.setTimeout(e);a.removeListener("timeout",a.destroy);a.addListener("timeout",a.destroy)}function startTimer(a){if(t._timeout){clearTimeout(t._timeout)}t._timeout=setTimeout((function(){t.emit("timeout");clearTimer()}),e);destroyOnTimeout(a)}function clearTimer(){if(t._timeout){clearTimeout(t._timeout);t._timeout=null}t.removeListener("abort",clearTimer);t.removeListener("error",clearTimer);t.removeListener("response",clearTimer);if(a){t.removeListener("timeout",a)}if(!t.socket){t._currentRequest.removeListener("socket",startTimer)}}if(a){this.on("timeout",a)}if(this.socket){startTimer(this.socket)}else{this._currentRequest.once("socket",startTimer)}this.on("socket",destroyOnTimeout);this.on("abort",clearTimer);this.on("error",clearTimer);this.on("response",clearTimer);return this};["flushHeaders","getHeader","setNoDelay","setSocketKeepAlive"].forEach((function(e){RedirectableRequest.prototype[e]=function(a,t){return this._currentRequest[e](a,t)}}));["aborted","connection","socket"].forEach((function(e){Object.defineProperty(RedirectableRequest.prototype,e,{get:function(){return this._currentRequest[e]}})}));RedirectableRequest.prototype._sanitizeOptions=function(e){if(!e.headers){e.headers={}}if(e.host){if(!e.hostname){e.hostname=e.host}delete e.host}if(!e.pathname&&e.path){var a=e.path.indexOf("?");if(a<0){e.pathname=e.path}else{e.pathname=e.path.substring(0,a);e.search=e.path.substring(a)}}};RedirectableRequest.prototype._performRequest=function(){var e=this._options.protocol;var a=this._options.nativeProtocols[e];if(!a){this.emit("error",new TypeError("Unsupported protocol "+e));return}if(this._options.agents){var t=e.slice(0,-1);this._options.agent=this._options.agents[t]}var s=this._currentRequest=a.request(this._options,this._onNativeResponse);s._redirectable=this;for(var o of l){s.on(o,c[o])}this._currentUrl=/^\//.test(this._options.path)?i.format(this._options):this._options.path;if(this._isRedirect){var r=0;var n=this;var p=this._requestBodyBuffers;(function writeNext(e){if(s===n._currentRequest){if(e){n.emit("error",e)}else if(r=400){e.responseUrl=this._currentUrl;e.redirects=this._redirects;this.emit("response",e);this._requestBodyBuffers=[];return}abortRequest(this._currentRequest);e.destroy();if(++this._redirectCount>this._options.maxRedirects){this.emit("error",new v);return}var s;var o=this._options.beforeRedirect;if(o){s=Object.assign({Host:e.req.getHeader("host")},this._options.headers)}var r=this._options.method;if((a===301||a===302)&&this._options.method==="POST"||a===303&&!/^(?:GET|HEAD)$/.test(this._options.method)){this._options.method="GET";this._requestBodyBuffers=[];removeMatchingHeaders(/^content-/i,this._options.headers)}var n=removeMatchingHeaders(/^host$/i,this._options.headers);var p=i.parse(this._currentUrl);var l=n||p.host;var c=/^\w+:/.test(t)?this._currentUrl:i.format(Object.assign(p,{host:l}));var u;try{u=i.resolve(c,t)}catch(e){this.emit("error",new m({cause:e}));return}d("redirecting to",u);this._isRedirect=true;var h=i.parse(u);Object.assign(this._options,h);if(h.protocol!==p.protocol&&h.protocol!=="https:"||h.host!==l&&!isSubdomain(h.host,l)){removeMatchingHeaders(/^(?:authorization|cookie)$/i,this._options.headers)}if(isFunction(o)){var g={headers:e.headers,statusCode:a};var b={url:c,method:r,headers:s};try{o(this._options,g,b)}catch(e){this.emit("error",e);return}this._sanitizeOptions(this._options)}try{this._performRequest()}catch(e){this.emit("error",new m({cause:e}))}};function wrap(e){var a={maxRedirects:21,maxBodyLength:10*1024*1024};var t={};Object.keys(e).forEach((function(o){var r=o+":";var n=t[r]=e[o];var l=a[o]=Object.create(n);function request(e,o,n){if(isString(e)){var l;try{l=urlToOptions(new s(e))}catch(a){l=i.parse(e)}if(!isString(l.protocol)){throw new u({input:e})}e=l}else if(s&&e instanceof s){e=urlToOptions(e)}else{n=o;o=e;e={protocol:r}}if(isFunction(o)){n=o;o=null}o=Object.assign({maxRedirects:a.maxRedirects,maxBodyLength:a.maxBodyLength},e,o);o.nativeProtocols=t;if(!isString(o.host)&&!isString(o.hostname)){o.hostname="::1"}p.equal(o.protocol,r,"protocol mismatch");d("options",o);return new RedirectableRequest(o,n)}function get(e,a,t){var i=l.request(e,a,t);i.end();return i}Object.defineProperties(l,{request:{value:request,configurable:true,enumerable:true,writable:true},get:{value:get,configurable:true,enumerable:true,writable:true}})}));return a}function noop(){}function urlToOptions(e){var a={protocol:e.protocol,hostname:e.hostname.startsWith("[")?e.hostname.slice(1,-1):e.hostname,hash:e.hash,search:e.search,pathname:e.pathname,path:e.pathname+e.search,href:e.href};if(e.port!==""){a.port=Number(e.port)}return a}function removeMatchingHeaders(e,a){var t;for(var i in a){if(e.test(i)){t=a[i];delete a[i]}}return t===null||typeof t==="undefined"?undefined:String(t).trim()}function createErrorType(e,a,t){function CustomError(t){Error.captureStackTrace(this,this.constructor);Object.assign(this,t||{});this.code=e;this.message=this.cause?a+": "+this.cause.message:a}CustomError.prototype=new(t||Error);CustomError.prototype.constructor=CustomError;CustomError.prototype.name="Error ["+e+"]";return CustomError}function abortRequest(e){for(var a of l){e.removeListener(a,c[a])}e.on("error",noop);e.abort()}function isSubdomain(e,a){p(isString(e)&&isString(a));var t=e.length-a.length-1;return t>0&&e[t]==="."&&e.endsWith(a)}function isString(e){return typeof e==="string"||e instanceof String}function isFunction(e){return typeof e==="function"}function isBuffer(e){return typeof e==="object"&&"length"in e}e.exports=wrap({http:o,https:r});e.exports.wrap=wrap},6862:(e,a,t)=>{var i=t(500);var s=t(3837);var o=t(1017);var r=t(3685);var n=t(5687);var p=t(7310).parse;var d=t(7147);var l=t(2781).Stream;var c=t(2262);var u=t(7758);var m=t(6250);e.exports=FormData;s.inherits(FormData,i);function FormData(e){if(!(this instanceof FormData)){return new FormData(e)}this._overheadLength=0;this._valueLength=0;this._valuesToMeasure=[];i.call(this);e=e||{};for(var a in e){this[a]=e[a]}}FormData.LINE_BREAK="\r\n";FormData.DEFAULT_CONTENT_TYPE="application/octet-stream";FormData.prototype.append=function(e,a,t){t=t||{};if(typeof t=="string"){t={filename:t}}var o=i.prototype.append.bind(this);if(typeof a=="number"){a=""+a}if(s.isArray(a)){this._error(new Error("Arrays are not supported."));return}var r=this._multiPartHeader(e,a,t);var n=this._multiPartFooter();o(r);o(a);o(n);this._trackLength(r,a,t)};FormData.prototype._trackLength=function(e,a,t){var i=0;if(t.knownLength!=null){i+=+t.knownLength}else if(Buffer.isBuffer(a)){i=a.length}else if(typeof a==="string"){i=Buffer.byteLength(a)}this._valueLength+=i;this._overheadLength+=Buffer.byteLength(e)+FormData.LINE_BREAK.length;if(!a||!a.path&&!(a.readable&&a.hasOwnProperty("httpVersion"))&&!(a instanceof l)){return}if(!t.knownLength){this._valuesToMeasure.push(a)}};FormData.prototype._lengthRetriever=function(e,a){if(e.hasOwnProperty("fd")){if(e.end!=undefined&&e.end!=Infinity&&e.start!=undefined){a(null,e.end+1-(e.start?e.start:0))}else{d.stat(e.path,(function(t,i){var s;if(t){a(t);return}s=i.size-(e.start?e.start:0);a(null,s)}))}}else if(e.hasOwnProperty("httpVersion")){a(null,+e.headers["content-length"])}else if(e.hasOwnProperty("httpModule")){e.on("response",(function(t){e.pause();a(null,+t.headers["content-length"])}));e.resume()}else{a("Unknown stream")}};FormData.prototype._multiPartHeader=function(e,a,t){if(typeof t.header=="string"){return t.header}var i=this._getContentDisposition(a,t);var s=this._getContentType(a,t);var o="";var r={"Content-Disposition":["form-data",'name="'+e+'"'].concat(i||[]),"Content-Type":[].concat(s||[])};if(typeof t.header=="object"){m(r,t.header)}var n;for(var p in r){if(!r.hasOwnProperty(p))continue;n=r[p];if(n==null){continue}if(!Array.isArray(n)){n=[n]}if(n.length){o+=p+": "+n.join("; ")+FormData.LINE_BREAK}}return"--"+this.getBoundary()+FormData.LINE_BREAK+o+FormData.LINE_BREAK};FormData.prototype._getContentDisposition=function(e,a){var t,i;if(typeof a.filepath==="string"){t=o.normalize(a.filepath).replace(/\\/g,"/")}else if(a.filename||e.name||e.path){t=o.basename(a.filename||e.name||e.path)}else if(e.readable&&e.hasOwnProperty("httpVersion")){t=o.basename(e.client._httpMessage.path||"")}if(t){i='filename="'+t+'"'}return i};FormData.prototype._getContentType=function(e,a){var t=a.contentType;if(!t&&e.name){t=c.lookup(e.name)}if(!t&&e.path){t=c.lookup(e.path)}if(!t&&e.readable&&e.hasOwnProperty("httpVersion")){t=e.headers["content-type"]}if(!t&&(a.filepath||a.filename)){t=c.lookup(a.filepath||a.filename)}if(!t&&typeof e=="object"){t=FormData.DEFAULT_CONTENT_TYPE}return t};FormData.prototype._multiPartFooter=function(){return function(e){var a=FormData.LINE_BREAK;var t=this._streams.length===0;if(t){a+=this._lastBoundary()}e(a)}.bind(this)};FormData.prototype._lastBoundary=function(){return"--"+this.getBoundary()+"--"+FormData.LINE_BREAK};FormData.prototype.getHeaders=function(e){var a;var t={"content-type":"multipart/form-data; boundary="+this.getBoundary()};for(a in e){if(e.hasOwnProperty(a)){t[a.toLowerCase()]=e[a]}}return t};FormData.prototype.setBoundary=function(e){this._boundary=e};FormData.prototype.getBoundary=function(){if(!this._boundary){this._generateBoundary()}return this._boundary};FormData.prototype.getBuffer=function(){var e=new Buffer.alloc(0);var a=this.getBoundary();for(var t=0,i=this._streams.length;t{e.exports=function(e,a){Object.keys(a).forEach((function(t){e[t]=e[t]||a[t]}));return e}},9473:(e,a,t)=>{"use strict";const i=t(8559);const s=t(1017);const o=t(9251).mkdirsSync;const r=t(2274).utimesMillisSync;const n=t(2418);function copySync(e,a,t){if(typeof t==="function"){t={filter:t}}t=t||{};t.clobber="clobber"in t?!!t.clobber:true;t.overwrite="overwrite"in t?!!t.overwrite:t.clobber;if(t.preserveTimestamps&&process.arch==="ia32"){process.emitWarning("Using the preserveTimestamps option in 32-bit node is not recommended;\n\n"+"\tsee https://github.com/jprichardson/node-fs-extra/issues/269","Warning","fs-extra-WARN0002")}const{srcStat:r,destStat:p}=n.checkPathsSync(e,a,"copy",t);n.checkParentPathsSync(e,r,a,"copy");if(t.filter&&!t.filter(e,a))return;const d=s.dirname(a);if(!i.existsSync(d))o(d);return getStats(p,e,a,t)}function getStats(e,a,t,s){const o=s.dereference?i.statSync:i.lstatSync;const r=o(a);if(r.isDirectory())return onDir(r,e,a,t,s);else if(r.isFile()||r.isCharacterDevice()||r.isBlockDevice())return onFile(r,e,a,t,s);else if(r.isSymbolicLink())return onLink(e,a,t,s);else if(r.isSocket())throw new Error(`Cannot copy a socket file: ${a}`);else if(r.isFIFO())throw new Error(`Cannot copy a FIFO pipe: ${a}`);throw new Error(`Unknown file: ${a}`)}function onFile(e,a,t,i,s){if(!a)return copyFile(e,t,i,s);return mayCopyFile(e,t,i,s)}function mayCopyFile(e,a,t,s){if(s.overwrite){i.unlinkSync(t);return copyFile(e,a,t,s)}else if(s.errorOnExist){throw new Error(`'${t}' already exists`)}}function copyFile(e,a,t,s){i.copyFileSync(a,t);if(s.preserveTimestamps)handleTimestamps(e.mode,a,t);return setDestMode(t,e.mode)}function handleTimestamps(e,a,t){if(fileIsNotWritable(e))makeFileWritable(t,e);return setDestTimestamps(a,t)}function fileIsNotWritable(e){return(e&128)===0}function makeFileWritable(e,a){return setDestMode(e,a|128)}function setDestMode(e,a){return i.chmodSync(e,a)}function setDestTimestamps(e,a){const t=i.statSync(e);return r(a,t.atime,t.mtime)}function onDir(e,a,t,i,s){if(!a)return mkDirAndCopy(e.mode,t,i,s);return copyDir(t,i,s)}function mkDirAndCopy(e,a,t,s){i.mkdirSync(t);copyDir(a,t,s);return setDestMode(t,e)}function copyDir(e,a,t){i.readdirSync(e).forEach((i=>copyDirItem(i,e,a,t)))}function copyDirItem(e,a,t,i){const o=s.join(a,e);const r=s.join(t,e);if(i.filter&&!i.filter(o,r))return;const{destStat:p}=n.checkPathsSync(o,r,"copy",i);return getStats(p,o,r,i)}function onLink(e,a,t,o){let r=i.readlinkSync(a);if(o.dereference){r=s.resolve(process.cwd(),r)}if(!e){return i.symlinkSync(r,t)}else{let e;try{e=i.readlinkSync(t)}catch(e){if(e.code==="EINVAL"||e.code==="UNKNOWN")return i.symlinkSync(r,t);throw e}if(o.dereference){e=s.resolve(process.cwd(),e)}if(n.isSrcSubdir(r,e)){throw new Error(`Cannot copy '${r}' to a subdirectory of itself, '${e}'.`)}if(n.isSrcSubdir(e,r)){throw new Error(`Cannot overwrite '${e}' with '${r}'.`)}return copyLink(r,t)}}function copyLink(e,a){i.unlinkSync(a);return i.symlinkSync(e,a)}e.exports=copySync},6382:(e,a,t)=>{"use strict";const i=t(8559);const s=t(1017);const o=t(9251).mkdirs;const r=t(5082).pathExists;const n=t(2274).utimesMillis;const p=t(2418);function copy(e,a,t,i){if(typeof t==="function"&&!i){i=t;t={}}else if(typeof t==="function"){t={filter:t}}i=i||function(){};t=t||{};t.clobber="clobber"in t?!!t.clobber:true;t.overwrite="overwrite"in t?!!t.overwrite:t.clobber;if(t.preserveTimestamps&&process.arch==="ia32"){process.emitWarning("Using the preserveTimestamps option in 32-bit node is not recommended;\n\n"+"\tsee https://github.com/jprichardson/node-fs-extra/issues/269","Warning","fs-extra-WARN0001")}p.checkPaths(e,a,"copy",t,((s,o)=>{if(s)return i(s);const{srcStat:r,destStat:n}=o;p.checkParentPaths(e,r,a,"copy",(s=>{if(s)return i(s);runFilter(e,a,t,((s,o)=>{if(s)return i(s);if(!o)return i();checkParentDir(n,e,a,t,i)}))}))}))}function checkParentDir(e,a,t,i,n){const p=s.dirname(t);r(p,((s,r)=>{if(s)return n(s);if(r)return getStats(e,a,t,i,n);o(p,(s=>{if(s)return n(s);return getStats(e,a,t,i,n)}))}))}function runFilter(e,a,t,i){if(!t.filter)return i(null,true);Promise.resolve(t.filter(e,a)).then((e=>i(null,e)),(e=>i(e)))}function getStats(e,a,t,s,o){const r=s.dereference?i.stat:i.lstat;r(a,((i,r)=>{if(i)return o(i);if(r.isDirectory())return onDir(r,e,a,t,s,o);else if(r.isFile()||r.isCharacterDevice()||r.isBlockDevice())return onFile(r,e,a,t,s,o);else if(r.isSymbolicLink())return onLink(e,a,t,s,o);else if(r.isSocket())return o(new Error(`Cannot copy a socket file: ${a}`));else if(r.isFIFO())return o(new Error(`Cannot copy a FIFO pipe: ${a}`));return o(new Error(`Unknown file: ${a}`))}))}function onFile(e,a,t,i,s,o){if(!a)return copyFile(e,t,i,s,o);return mayCopyFile(e,t,i,s,o)}function mayCopyFile(e,a,t,s,o){if(s.overwrite){i.unlink(t,(i=>{if(i)return o(i);return copyFile(e,a,t,s,o)}))}else if(s.errorOnExist){return o(new Error(`'${t}' already exists`))}else return o()}function copyFile(e,a,t,s,o){i.copyFile(a,t,(i=>{if(i)return o(i);if(s.preserveTimestamps)return handleTimestampsAndMode(e.mode,a,t,o);return setDestMode(t,e.mode,o)}))}function handleTimestampsAndMode(e,a,t,i){if(fileIsNotWritable(e)){return makeFileWritable(t,e,(s=>{if(s)return i(s);return setDestTimestampsAndMode(e,a,t,i)}))}return setDestTimestampsAndMode(e,a,t,i)}function fileIsNotWritable(e){return(e&128)===0}function makeFileWritable(e,a,t){return setDestMode(e,a|128,t)}function setDestTimestampsAndMode(e,a,t,i){setDestTimestamps(a,t,(a=>{if(a)return i(a);return setDestMode(t,e,i)}))}function setDestMode(e,a,t){return i.chmod(e,a,t)}function setDestTimestamps(e,a,t){i.stat(e,((e,i)=>{if(e)return t(e);return n(a,i.atime,i.mtime,t)}))}function onDir(e,a,t,i,s,o){if(!a)return mkDirAndCopy(e.mode,t,i,s,o);return copyDir(t,i,s,o)}function mkDirAndCopy(e,a,t,s,o){i.mkdir(t,(i=>{if(i)return o(i);copyDir(a,t,s,(a=>{if(a)return o(a);return setDestMode(t,e,o)}))}))}function copyDir(e,a,t,s){i.readdir(e,((i,o)=>{if(i)return s(i);return copyDirItems(o,e,a,t,s)}))}function copyDirItems(e,a,t,i,s){const o=e.pop();if(!o)return s();return copyDirItem(e,o,a,t,i,s)}function copyDirItem(e,a,t,i,o,r){const n=s.join(t,a);const d=s.join(i,a);runFilter(n,d,o,((a,s)=>{if(a)return r(a);if(!s)return copyDirItems(e,t,i,o,r);p.checkPaths(n,d,"copy",o,((a,s)=>{if(a)return r(a);const{destStat:p}=s;getStats(p,n,d,o,(a=>{if(a)return r(a);return copyDirItems(e,t,i,o,r)}))}))}))}function onLink(e,a,t,o,r){i.readlink(a,((a,n)=>{if(a)return r(a);if(o.dereference){n=s.resolve(process.cwd(),n)}if(!e){return i.symlink(n,t,r)}else{i.readlink(t,((e,a)=>{if(e){if(e.code==="EINVAL"||e.code==="UNKNOWN")return i.symlink(n,t,r);return r(e)}if(o.dereference){a=s.resolve(process.cwd(),a)}if(p.isSrcSubdir(n,a)){return r(new Error(`Cannot copy '${n}' to a subdirectory of itself, '${a}'.`))}if(p.isSrcSubdir(a,n)){return r(new Error(`Cannot overwrite '${a}' with '${n}'.`))}return copyLink(n,t,r)}))}}))}function copyLink(e,a,t){i.unlink(a,(s=>{if(s)return t(s);return i.symlink(e,a,t)}))}e.exports=copy},1144:(e,a,t)=>{"use strict";const i=t(2003).fromCallback;e.exports={copy:i(t(6382)),copySync:t(9473)}},7868:(e,a,t)=>{"use strict";const i=t(2003).fromPromise;const s=t(5055);const o=t(1017);const r=t(9251);const n=t(8006);const p=i((async function emptyDir(e){let a;try{a=await s.readdir(e)}catch{return r.mkdirs(e)}return Promise.all(a.map((a=>n.remove(o.join(e,a)))))}));function emptyDirSync(e){let a;try{a=s.readdirSync(e)}catch{return r.mkdirsSync(e)}a.forEach((a=>{a=o.join(e,a);n.removeSync(a)}))}e.exports={emptyDirSync:emptyDirSync,emptydirSync:emptyDirSync,emptyDir:p,emptydir:p}},7173:(e,a,t)=>{"use strict";const i=t(2003).fromCallback;const s=t(1017);const o=t(8559);const r=t(9251);function createFile(e,a){function makeFile(){o.writeFile(e,"",(e=>{if(e)return a(e);a()}))}o.stat(e,((t,i)=>{if(!t&&i.isFile())return a();const n=s.dirname(e);o.stat(n,((e,t)=>{if(e){if(e.code==="ENOENT"){return r.mkdirs(n,(e=>{if(e)return a(e);makeFile()}))}return a(e)}if(t.isDirectory())makeFile();else{o.readdir(n,(e=>{if(e)return a(e)}))}}))}))}function createFileSync(e){let a;try{a=o.statSync(e)}catch{}if(a&&a.isFile())return;const t=s.dirname(e);try{if(!o.statSync(t).isDirectory()){o.readdirSync(t)}}catch(e){if(e&&e.code==="ENOENT")r.mkdirsSync(t);else throw e}o.writeFileSync(e,"")}e.exports={createFile:i(createFile),createFileSync:createFileSync}},6561:(e,a,t)=>{"use strict";const{createFile:i,createFileSync:s}=t(7173);const{createLink:o,createLinkSync:r}=t(3224);const{createSymlink:n,createSymlinkSync:p}=t(2157);e.exports={createFile:i,createFileSync:s,ensureFile:i,ensureFileSync:s,createLink:o,createLinkSync:r,ensureLink:o,ensureLinkSync:r,createSymlink:n,createSymlinkSync:p,ensureSymlink:n,ensureSymlinkSync:p}},3224:(e,a,t)=>{"use strict";const i=t(2003).fromCallback;const s=t(1017);const o=t(8559);const r=t(9251);const n=t(5082).pathExists;const{areIdentical:p}=t(2418);function createLink(e,a,t){function makeLink(e,a){o.link(e,a,(e=>{if(e)return t(e);t(null)}))}o.lstat(a,((i,d)=>{o.lstat(e,((i,o)=>{if(i){i.message=i.message.replace("lstat","ensureLink");return t(i)}if(d&&p(o,d))return t(null);const l=s.dirname(a);n(l,((i,s)=>{if(i)return t(i);if(s)return makeLink(e,a);r.mkdirs(l,(i=>{if(i)return t(i);makeLink(e,a)}))}))}))}))}function createLinkSync(e,a){let t;try{t=o.lstatSync(a)}catch{}try{const a=o.lstatSync(e);if(t&&p(a,t))return}catch(e){e.message=e.message.replace("lstat","ensureLink");throw e}const i=s.dirname(a);const n=o.existsSync(i);if(n)return o.linkSync(e,a);r.mkdirsSync(i);return o.linkSync(e,a)}e.exports={createLink:i(createLink),createLinkSync:createLinkSync}},4469:(e,a,t)=>{"use strict";const i=t(1017);const s=t(8559);const o=t(5082).pathExists;function symlinkPaths(e,a,t){if(i.isAbsolute(e)){return s.lstat(e,(a=>{if(a){a.message=a.message.replace("lstat","ensureSymlink");return t(a)}return t(null,{toCwd:e,toDst:e})}))}else{const r=i.dirname(a);const n=i.join(r,e);return o(n,((a,o)=>{if(a)return t(a);if(o){return t(null,{toCwd:n,toDst:e})}else{return s.lstat(e,(a=>{if(a){a.message=a.message.replace("lstat","ensureSymlink");return t(a)}return t(null,{toCwd:e,toDst:i.relative(r,e)})}))}}))}}function symlinkPathsSync(e,a){let t;if(i.isAbsolute(e)){t=s.existsSync(e);if(!t)throw new Error("absolute srcpath does not exist");return{toCwd:e,toDst:e}}else{const o=i.dirname(a);const r=i.join(o,e);t=s.existsSync(r);if(t){return{toCwd:r,toDst:e}}else{t=s.existsSync(e);if(!t)throw new Error("relative srcpath does not exist");return{toCwd:e,toDst:i.relative(o,e)}}}}e.exports={symlinkPaths:symlinkPaths,symlinkPathsSync:symlinkPathsSync}},5682:(e,a,t)=>{"use strict";const i=t(8559);function symlinkType(e,a,t){t=typeof a==="function"?a:t;a=typeof a==="function"?false:a;if(a)return t(null,a);i.lstat(e,((e,i)=>{if(e)return t(null,"file");a=i&&i.isDirectory()?"dir":"file";t(null,a)}))}function symlinkTypeSync(e,a){let t;if(a)return a;try{t=i.lstatSync(e)}catch{return"file"}return t&&t.isDirectory()?"dir":"file"}e.exports={symlinkType:symlinkType,symlinkTypeSync:symlinkTypeSync}},2157:(e,a,t)=>{"use strict";const i=t(2003).fromCallback;const s=t(1017);const o=t(5055);const r=t(9251);const n=r.mkdirs;const p=r.mkdirsSync;const d=t(4469);const l=d.symlinkPaths;const c=d.symlinkPathsSync;const u=t(5682);const m=u.symlinkType;const v=u.symlinkTypeSync;const h=t(5082).pathExists;const{areIdentical:g}=t(2418);function createSymlink(e,a,t,i){i=typeof t==="function"?t:i;t=typeof t==="function"?false:t;o.lstat(a,((s,r)=>{if(!s&&r.isSymbolicLink()){Promise.all([o.stat(e),o.stat(a)]).then((([s,o])=>{if(g(s,o))return i(null);_createSymlink(e,a,t,i)}))}else _createSymlink(e,a,t,i)}))}function _createSymlink(e,a,t,i){l(e,a,((r,p)=>{if(r)return i(r);e=p.toDst;m(p.toCwd,t,((t,r)=>{if(t)return i(t);const p=s.dirname(a);h(p,((t,s)=>{if(t)return i(t);if(s)return o.symlink(e,a,r,i);n(p,(t=>{if(t)return i(t);o.symlink(e,a,r,i)}))}))}))}))}function createSymlinkSync(e,a,t){let i;try{i=o.lstatSync(a)}catch{}if(i&&i.isSymbolicLink()){const t=o.statSync(e);const i=o.statSync(a);if(g(t,i))return}const r=c(e,a);e=r.toDst;t=v(r.toCwd,t);const n=s.dirname(a);const d=o.existsSync(n);if(d)return o.symlinkSync(e,a,t);p(n);return o.symlinkSync(e,a,t)}e.exports={createSymlink:i(createSymlink),createSymlinkSync:createSymlinkSync}},5055:(e,a,t)=>{"use strict";const i=t(2003).fromCallback;const s=t(8559);const o=["access","appendFile","chmod","chown","close","copyFile","fchmod","fchown","fdatasync","fstat","fsync","ftruncate","futimes","lchmod","lchown","link","lstat","mkdir","mkdtemp","open","opendir","readdir","readFile","readlink","realpath","rename","rm","rmdir","stat","symlink","truncate","unlink","utimes","writeFile"].filter((e=>typeof s[e]==="function"));Object.assign(a,s);o.forEach((e=>{a[e]=i(s[e])}));a.exists=function(e,a){if(typeof a==="function"){return s.exists(e,a)}return new Promise((a=>s.exists(e,a)))};a.read=function(e,a,t,i,o,r){if(typeof r==="function"){return s.read(e,a,t,i,o,r)}return new Promise(((r,n)=>{s.read(e,a,t,i,o,((e,a,t)=>{if(e)return n(e);r({bytesRead:a,buffer:t})}))}))};a.write=function(e,a,...t){if(typeof t[t.length-1]==="function"){return s.write(e,a,...t)}return new Promise(((i,o)=>{s.write(e,a,...t,((e,a,t)=>{if(e)return o(e);i({bytesWritten:a,buffer:t})}))}))};a.readv=function(e,a,...t){if(typeof t[t.length-1]==="function"){return s.readv(e,a,...t)}return new Promise(((i,o)=>{s.readv(e,a,...t,((e,a,t)=>{if(e)return o(e);i({bytesRead:a,buffers:t})}))}))};a.writev=function(e,a,...t){if(typeof t[t.length-1]==="function"){return s.writev(e,a,...t)}return new Promise(((i,o)=>{s.writev(e,a,...t,((e,a,t)=>{if(e)return o(e);i({bytesWritten:a,buffers:t})}))}))};if(typeof s.realpath.native==="function"){a.realpath.native=i(s.realpath.native)}else{process.emitWarning("fs.realpath.native is not a function. Is fs being monkey-patched?","Warning","fs-extra-WARN0003")}},3848:(e,a,t)=>{"use strict";e.exports={...t(5055),...t(1144),...t(7868),...t(6561),...t(9835),...t(9251),...t(2783),...t(3064),...t(5082),...t(8006)}},9835:(e,a,t)=>{"use strict";const i=t(2003).fromPromise;const s=t(550);s.outputJson=i(t(3408));s.outputJsonSync=t(2669);s.outputJSON=s.outputJson;s.outputJSONSync=s.outputJsonSync;s.writeJSON=s.writeJson;s.writeJSONSync=s.writeJsonSync;s.readJSON=s.readJson;s.readJSONSync=s.readJsonSync;e.exports=s},550:(e,a,t)=>{"use strict";const i=t(7229);e.exports={readJson:i.readFile,readJsonSync:i.readFileSync,writeJson:i.writeFile,writeJsonSync:i.writeFileSync}},2669:(e,a,t)=>{"use strict";const{stringify:i}=t(8691);const{outputFileSync:s}=t(3064);function outputJsonSync(e,a,t){const o=i(a,t);s(e,o,t)}e.exports=outputJsonSync},3408:(e,a,t)=>{"use strict";const{stringify:i}=t(8691);const{outputFile:s}=t(3064);async function outputJson(e,a,t={}){const o=i(a,t);await s(e,o,t)}e.exports=outputJson},9251:(e,a,t)=>{"use strict";const i=t(2003).fromPromise;const{makeDir:s,makeDirSync:o}=t(8846);const r=i(s);e.exports={mkdirs:r,mkdirsSync:o,mkdirp:r,mkdirpSync:o,ensureDir:r,ensureDirSync:o}},8846:(e,a,t)=>{"use strict";const i=t(5055);const{checkPath:s}=t(3922);const getMode=e=>{const a={mode:511};if(typeof e==="number")return e;return{...a,...e}.mode};e.exports.makeDir=async(e,a)=>{s(e);return i.mkdir(e,{mode:getMode(a),recursive:true})};e.exports.makeDirSync=(e,a)=>{s(e);return i.mkdirSync(e,{mode:getMode(a),recursive:true})}},3922:(e,a,t)=>{"use strict";const i=t(1017);e.exports.checkPath=function checkPath(e){if(process.platform==="win32"){const a=/[<>:"|?*]/.test(e.replace(i.parse(e).root,""));if(a){const a=new Error(`Path contains invalid characters: ${e}`);a.code="EINVAL";throw a}}}},2783:(e,a,t)=>{"use strict";const i=t(2003).fromCallback;e.exports={move:i(t(307)),moveSync:t(5389)}},5389:(e,a,t)=>{"use strict";const i=t(8559);const s=t(1017);const o=t(1144).copySync;const r=t(8006).removeSync;const n=t(9251).mkdirpSync;const p=t(2418);function moveSync(e,a,t){t=t||{};const i=t.overwrite||t.clobber||false;const{srcStat:o,isChangingCase:r=false}=p.checkPathsSync(e,a,"move",t);p.checkParentPathsSync(e,o,a,"move");if(!isParentRoot(a))n(s.dirname(a));return doRename(e,a,i,r)}function isParentRoot(e){const a=s.dirname(e);const t=s.parse(a);return t.root===a}function doRename(e,a,t,s){if(s)return rename(e,a,t);if(t){r(a);return rename(e,a,t)}if(i.existsSync(a))throw new Error("dest already exists.");return rename(e,a,t)}function rename(e,a,t){try{i.renameSync(e,a)}catch(i){if(i.code!=="EXDEV")throw i;return moveAcrossDevice(e,a,t)}}function moveAcrossDevice(e,a,t){const i={overwrite:t,errorOnExist:true};o(e,a,i);return r(e)}e.exports=moveSync},307:(e,a,t)=>{"use strict";const i=t(8559);const s=t(1017);const o=t(1144).copy;const r=t(8006).remove;const n=t(9251).mkdirp;const p=t(5082).pathExists;const d=t(2418);function move(e,a,t,i){if(typeof t==="function"){i=t;t={}}t=t||{};const o=t.overwrite||t.clobber||false;d.checkPaths(e,a,"move",t,((t,r)=>{if(t)return i(t);const{srcStat:p,isChangingCase:l=false}=r;d.checkParentPaths(e,p,a,"move",(t=>{if(t)return i(t);if(isParentRoot(a))return doRename(e,a,o,l,i);n(s.dirname(a),(t=>{if(t)return i(t);return doRename(e,a,o,l,i)}))}))}))}function isParentRoot(e){const a=s.dirname(e);const t=s.parse(a);return t.root===a}function doRename(e,a,t,i,s){if(i)return rename(e,a,t,s);if(t){return r(a,(i=>{if(i)return s(i);return rename(e,a,t,s)}))}p(a,((i,o)=>{if(i)return s(i);if(o)return s(new Error("dest already exists."));return rename(e,a,t,s)}))}function rename(e,a,t,s){i.rename(e,a,(i=>{if(!i)return s();if(i.code!=="EXDEV")return s(i);return moveAcrossDevice(e,a,t,s)}))}function moveAcrossDevice(e,a,t,i){const s={overwrite:t,errorOnExist:true};o(e,a,s,(a=>{if(a)return i(a);return r(e,i)}))}e.exports=move},3064:(e,a,t)=>{"use strict";const i=t(2003).fromCallback;const s=t(8559);const o=t(1017);const r=t(9251);const n=t(5082).pathExists;function outputFile(e,a,t,i){if(typeof t==="function"){i=t;t="utf8"}const p=o.dirname(e);n(p,((o,n)=>{if(o)return i(o);if(n)return s.writeFile(e,a,t,i);r.mkdirs(p,(o=>{if(o)return i(o);s.writeFile(e,a,t,i)}))}))}function outputFileSync(e,...a){const t=o.dirname(e);if(s.existsSync(t)){return s.writeFileSync(e,...a)}r.mkdirsSync(t);s.writeFileSync(e,...a)}e.exports={outputFile:i(outputFile),outputFileSync:outputFileSync}},5082:(e,a,t)=>{"use strict";const i=t(2003).fromPromise;const s=t(5055);function pathExists(e){return s.access(e).then((()=>true)).catch((()=>false))}e.exports={pathExists:i(pathExists),pathExistsSync:s.existsSync}},8006:(e,a,t)=>{"use strict";const i=t(8559);const s=t(2003).fromCallback;function remove(e,a){i.rm(e,{recursive:true,force:true},a)}function removeSync(e){i.rmSync(e,{recursive:true,force:true})}e.exports={remove:s(remove),removeSync:removeSync}},2418:(e,a,t)=>{"use strict";const i=t(5055);const s=t(1017);const o=t(3837);function getStats(e,a,t){const s=t.dereference?e=>i.stat(e,{bigint:true}):e=>i.lstat(e,{bigint:true});return Promise.all([s(e),s(a).catch((e=>{if(e.code==="ENOENT")return null;throw e}))]).then((([e,a])=>({srcStat:e,destStat:a})))}function getStatsSync(e,a,t){let s;const o=t.dereference?e=>i.statSync(e,{bigint:true}):e=>i.lstatSync(e,{bigint:true});const r=o(e);try{s=o(a)}catch(e){if(e.code==="ENOENT")return{srcStat:r,destStat:null};throw e}return{srcStat:r,destStat:s}}function checkPaths(e,a,t,i,r){o.callbackify(getStats)(e,a,i,((i,o)=>{if(i)return r(i);const{srcStat:n,destStat:p}=o;if(p){if(areIdentical(n,p)){const i=s.basename(e);const o=s.basename(a);if(t==="move"&&i!==o&&i.toLowerCase()===o.toLowerCase()){return r(null,{srcStat:n,destStat:p,isChangingCase:true})}return r(new Error("Source and destination must not be the same."))}if(n.isDirectory()&&!p.isDirectory()){return r(new Error(`Cannot overwrite non-directory '${a}' with directory '${e}'.`))}if(!n.isDirectory()&&p.isDirectory()){return r(new Error(`Cannot overwrite directory '${a}' with non-directory '${e}'.`))}}if(n.isDirectory()&&isSrcSubdir(e,a)){return r(new Error(errMsg(e,a,t)))}return r(null,{srcStat:n,destStat:p})}))}function checkPathsSync(e,a,t,i){const{srcStat:o,destStat:r}=getStatsSync(e,a,i);if(r){if(areIdentical(o,r)){const i=s.basename(e);const n=s.basename(a);if(t==="move"&&i!==n&&i.toLowerCase()===n.toLowerCase()){return{srcStat:o,destStat:r,isChangingCase:true}}throw new Error("Source and destination must not be the same.")}if(o.isDirectory()&&!r.isDirectory()){throw new Error(`Cannot overwrite non-directory '${a}' with directory '${e}'.`)}if(!o.isDirectory()&&r.isDirectory()){throw new Error(`Cannot overwrite directory '${a}' with non-directory '${e}'.`)}}if(o.isDirectory()&&isSrcSubdir(e,a)){throw new Error(errMsg(e,a,t))}return{srcStat:o,destStat:r}}function checkParentPaths(e,a,t,o,r){const n=s.resolve(s.dirname(e));const p=s.resolve(s.dirname(t));if(p===n||p===s.parse(p).root)return r();i.stat(p,{bigint:true},((i,s)=>{if(i){if(i.code==="ENOENT")return r();return r(i)}if(areIdentical(a,s)){return r(new Error(errMsg(e,t,o)))}return checkParentPaths(e,a,p,o,r)}))}function checkParentPathsSync(e,a,t,o){const r=s.resolve(s.dirname(e));const n=s.resolve(s.dirname(t));if(n===r||n===s.parse(n).root)return;let p;try{p=i.statSync(n,{bigint:true})}catch(e){if(e.code==="ENOENT")return;throw e}if(areIdentical(a,p)){throw new Error(errMsg(e,t,o))}return checkParentPathsSync(e,a,n,o)}function areIdentical(e,a){return a.ino&&a.dev&&a.ino===e.ino&&a.dev===e.dev}function isSrcSubdir(e,a){const t=s.resolve(e).split(s.sep).filter((e=>e));const i=s.resolve(a).split(s.sep).filter((e=>e));return t.reduce(((e,a,t)=>e&&i[t]===a),true)}function errMsg(e,a,t){return`Cannot ${t} '${e}' to a subdirectory of itself, '${a}'.`}e.exports={checkPaths:checkPaths,checkPathsSync:checkPathsSync,checkParentPaths:checkParentPaths,checkParentPathsSync:checkParentPathsSync,isSrcSubdir:isSrcSubdir,areIdentical:areIdentical}},2274:(e,a,t)=>{"use strict";const i=t(8559);function utimesMillis(e,a,t,s){i.open(e,"r+",((e,o)=>{if(e)return s(e);i.futimes(o,a,t,(e=>{i.close(o,(a=>{if(s)s(e||a)}))}))}))}function utimesMillisSync(e,a,t){const s=i.openSync(e,"r+");i.futimesSync(s,a,t);return i.closeSync(s)}e.exports={utimesMillis:utimesMillis,utimesMillisSync:utimesMillisSync}},3163:e=>{"use strict";e.exports=clone;var a=Object.getPrototypeOf||function(e){return e.__proto__};function clone(e){if(e===null||typeof e!=="object")return e;if(e instanceof Object)var t={__proto__:a(e)};else var t=Object.create(null);Object.getOwnPropertyNames(e).forEach((function(a){Object.defineProperty(t,a,Object.getOwnPropertyDescriptor(e,a))}));return t}},8559:(e,a,t)=>{var i=t(7147);var s=t(8393);var o=t(9562);var r=t(3163);var n=t(3837);var p;var d;if(typeof Symbol==="function"&&typeof Symbol.for==="function"){p=Symbol.for("graceful-fs.queue");d=Symbol.for("graceful-fs.previous")}else{p="___graceful-fs.queue";d="___graceful-fs.previous"}function noop(){}function publishQueue(e,a){Object.defineProperty(e,p,{get:function(){return a}})}var l=noop;if(n.debuglog)l=n.debuglog("gfs4");else if(/\bgfs4\b/i.test(process.env.NODE_DEBUG||""))l=function(){var e=n.format.apply(n,arguments);e="GFS4: "+e.split(/\n/).join("\nGFS4: ");console.error(e)};if(!i[p]){var c=global[p]||[];publishQueue(i,c);i.close=function(e){function close(a,t){return e.call(i,a,(function(e){if(!e){resetQueue()}if(typeof t==="function")t.apply(this,arguments)}))}Object.defineProperty(close,d,{value:e});return close}(i.close);i.closeSync=function(e){function closeSync(a){e.apply(i,arguments);resetQueue()}Object.defineProperty(closeSync,d,{value:e});return closeSync}(i.closeSync);if(/\bgfs4\b/i.test(process.env.NODE_DEBUG||"")){process.on("exit",(function(){l(i[p]);t(9491).equal(i[p].length,0)}))}}if(!global[p]){publishQueue(global,i[p])}e.exports=patch(r(i));if(process.env.TEST_GRACEFUL_FS_GLOBAL_PATCH&&!i.__patched){e.exports=patch(i);i.__patched=true}function patch(e){s(e);e.gracefulify=patch;e.createReadStream=createReadStream;e.createWriteStream=createWriteStream;var a=e.readFile;e.readFile=readFile;function readFile(e,t,i){if(typeof t==="function")i=t,t=null;return go$readFile(e,t,i);function go$readFile(e,t,i,s){return a(e,t,(function(a){if(a&&(a.code==="EMFILE"||a.code==="ENFILE"))enqueue([go$readFile,[e,t,i],a,s||Date.now(),Date.now()]);else{if(typeof i==="function")i.apply(this,arguments)}}))}}var t=e.writeFile;e.writeFile=writeFile;function writeFile(e,a,i,s){if(typeof i==="function")s=i,i=null;return go$writeFile(e,a,i,s);function go$writeFile(e,a,i,s,o){return t(e,a,i,(function(t){if(t&&(t.code==="EMFILE"||t.code==="ENFILE"))enqueue([go$writeFile,[e,a,i,s],t,o||Date.now(),Date.now()]);else{if(typeof s==="function")s.apply(this,arguments)}}))}}var i=e.appendFile;if(i)e.appendFile=appendFile;function appendFile(e,a,t,s){if(typeof t==="function")s=t,t=null;return go$appendFile(e,a,t,s);function go$appendFile(e,a,t,s,o){return i(e,a,t,(function(i){if(i&&(i.code==="EMFILE"||i.code==="ENFILE"))enqueue([go$appendFile,[e,a,t,s],i,o||Date.now(),Date.now()]);else{if(typeof s==="function")s.apply(this,arguments)}}))}}var r=e.copyFile;if(r)e.copyFile=copyFile;function copyFile(e,a,t,i){if(typeof t==="function"){i=t;t=0}return go$copyFile(e,a,t,i);function go$copyFile(e,a,t,i,s){return r(e,a,t,(function(o){if(o&&(o.code==="EMFILE"||o.code==="ENFILE"))enqueue([go$copyFile,[e,a,t,i],o,s||Date.now(),Date.now()]);else{if(typeof i==="function")i.apply(this,arguments)}}))}}var n=e.readdir;e.readdir=readdir;var p=/^v[0-5]\./;function readdir(e,a,t){if(typeof a==="function")t=a,a=null;var i=p.test(process.version)?function go$readdir(e,a,t,i){return n(e,fs$readdirCallback(e,a,t,i))}:function go$readdir(e,a,t,i){return n(e,a,fs$readdirCallback(e,a,t,i))};return i(e,a,t);function fs$readdirCallback(e,a,t,s){return function(o,r){if(o&&(o.code==="EMFILE"||o.code==="ENFILE"))enqueue([i,[e,a,t],o,s||Date.now(),Date.now()]);else{if(r&&r.sort)r.sort();if(typeof t==="function")t.call(this,o,r)}}}}if(process.version.substr(0,4)==="v0.8"){var d=o(e);ReadStream=d.ReadStream;WriteStream=d.WriteStream}var l=e.ReadStream;if(l){ReadStream.prototype=Object.create(l.prototype);ReadStream.prototype.open=ReadStream$open}var c=e.WriteStream;if(c){WriteStream.prototype=Object.create(c.prototype);WriteStream.prototype.open=WriteStream$open}Object.defineProperty(e,"ReadStream",{get:function(){return ReadStream},set:function(e){ReadStream=e},enumerable:true,configurable:true});Object.defineProperty(e,"WriteStream",{get:function(){return WriteStream},set:function(e){WriteStream=e},enumerable:true,configurable:true});var u=ReadStream;Object.defineProperty(e,"FileReadStream",{get:function(){return u},set:function(e){u=e},enumerable:true,configurable:true});var m=WriteStream;Object.defineProperty(e,"FileWriteStream",{get:function(){return m},set:function(e){m=e},enumerable:true,configurable:true});function ReadStream(e,a){if(this instanceof ReadStream)return l.apply(this,arguments),this;else return ReadStream.apply(Object.create(ReadStream.prototype),arguments)}function ReadStream$open(){var e=this;open(e.path,e.flags,e.mode,(function(a,t){if(a){if(e.autoClose)e.destroy();e.emit("error",a)}else{e.fd=t;e.emit("open",t);e.read()}}))}function WriteStream(e,a){if(this instanceof WriteStream)return c.apply(this,arguments),this;else return WriteStream.apply(Object.create(WriteStream.prototype),arguments)}function WriteStream$open(){var e=this;open(e.path,e.flags,e.mode,(function(a,t){if(a){e.destroy();e.emit("error",a)}else{e.fd=t;e.emit("open",t)}}))}function createReadStream(a,t){return new e.ReadStream(a,t)}function createWriteStream(a,t){return new e.WriteStream(a,t)}var v=e.open;e.open=open;function open(e,a,t,i){if(typeof t==="function")i=t,t=null;return go$open(e,a,t,i);function go$open(e,a,t,i,s){return v(e,a,t,(function(o,r){if(o&&(o.code==="EMFILE"||o.code==="ENFILE"))enqueue([go$open,[e,a,t,i],o,s||Date.now(),Date.now()]);else{if(typeof i==="function")i.apply(this,arguments)}}))}}return e}function enqueue(e){l("ENQUEUE",e[0].name,e[1]);i[p].push(e);retry()}var u;function resetQueue(){var e=Date.now();for(var a=0;a2){i[p][a][3]=e;i[p][a][4]=e}}retry()}function retry(){clearTimeout(u);u=undefined;if(i[p].length===0)return;var e=i[p].shift();var a=e[0];var t=e[1];var s=e[2];var o=e[3];var r=e[4];if(o===undefined){l("RETRY",a.name,t);a.apply(null,t)}else if(Date.now()-o>=6e4){l("TIMEOUT",a.name,t);var n=t.pop();if(typeof n==="function")n.call(null,s)}else{var d=Date.now()-r;var c=Math.max(r-o,1);var m=Math.min(c*1.2,100);if(d>=m){l("RETRY",a.name,t);a.apply(null,t.concat([o]))}else{i[p].push(e)}}if(u===undefined){u=setTimeout(retry,0)}}},9562:(e,a,t)=>{var i=t(2781).Stream;e.exports=legacy;function legacy(e){return{ReadStream:ReadStream,WriteStream:WriteStream};function ReadStream(a,t){if(!(this instanceof ReadStream))return new ReadStream(a,t);i.call(this);var s=this;this.path=a;this.fd=null;this.readable=true;this.paused=false;this.flags="r";this.mode=438;this.bufferSize=64*1024;t=t||{};var o=Object.keys(t);for(var r=0,n=o.length;rthis.end){throw new Error("start must be <= end")}this.pos=this.start}if(this.fd!==null){process.nextTick((function(){s._read()}));return}e.open(this.path,this.flags,this.mode,(function(e,a){if(e){s.emit("error",e);s.readable=false;return}s.fd=a;s.emit("open",a);s._read()}))}function WriteStream(a,t){if(!(this instanceof WriteStream))return new WriteStream(a,t);i.call(this);this.path=a;this.fd=null;this.writable=true;this.flags="w";this.encoding="binary";this.mode=438;this.bytesWritten=0;t=t||{};var s=Object.keys(t);for(var o=0,r=s.length;o= zero")}this.pos=this.start}this.busy=false;this._queue=[];if(this.fd===null){this._open=e.open;this._queue.push([this._open,this.path,this.flags,this.mode,undefined]);this.flush()}}}},8393:(e,a,t)=>{var i=t(2057);var s=process.cwd;var o=null;var r=process.env.GRACEFUL_FS_PLATFORM||process.platform;process.cwd=function(){if(!o)o=s.call(process);return o};try{process.cwd()}catch(e){}if(typeof process.chdir==="function"){var n=process.chdir;process.chdir=function(e){o=null;n.call(process,e)};if(Object.setPrototypeOf)Object.setPrototypeOf(process.chdir,n)}e.exports=patch;function patch(e){if(i.hasOwnProperty("O_SYMLINK")&&process.version.match(/^v0\.6\.[0-2]|^v0\.5\./)){patchLchmod(e)}if(!e.lutimes){patchLutimes(e)}e.chown=chownFix(e.chown);e.fchown=chownFix(e.fchown);e.lchown=chownFix(e.lchown);e.chmod=chmodFix(e.chmod);e.fchmod=chmodFix(e.fchmod);e.lchmod=chmodFix(e.lchmod);e.chownSync=chownFixSync(e.chownSync);e.fchownSync=chownFixSync(e.fchownSync);e.lchownSync=chownFixSync(e.lchownSync);e.chmodSync=chmodFixSync(e.chmodSync);e.fchmodSync=chmodFixSync(e.fchmodSync);e.lchmodSync=chmodFixSync(e.lchmodSync);e.stat=statFix(e.stat);e.fstat=statFix(e.fstat);e.lstat=statFix(e.lstat);e.statSync=statFixSync(e.statSync);e.fstatSync=statFixSync(e.fstatSync);e.lstatSync=statFixSync(e.lstatSync);if(e.chmod&&!e.lchmod){e.lchmod=function(e,a,t){if(t)process.nextTick(t)};e.lchmodSync=function(){}}if(e.chown&&!e.lchown){e.lchown=function(e,a,t,i){if(i)process.nextTick(i)};e.lchownSync=function(){}}if(r==="win32"){e.rename=typeof e.rename!=="function"?e.rename:function(a){function rename(t,i,s){var o=Date.now();var r=0;a(t,i,(function CB(n){if(n&&(n.code==="EACCES"||n.code==="EPERM")&&Date.now()-o<6e4){setTimeout((function(){e.stat(i,(function(e,o){if(e&&e.code==="ENOENT")a(t,i,CB);else s(n)}))}),r);if(r<100)r+=10;return}if(s)s(n)}))}if(Object.setPrototypeOf)Object.setPrototypeOf(rename,a);return rename}(e.rename)}e.read=typeof e.read!=="function"?e.read:function(a){function read(t,i,s,o,r,n){var p;if(n&&typeof n==="function"){var d=0;p=function(l,c,u){if(l&&l.code==="EAGAIN"&&d<10){d++;return a.call(e,t,i,s,o,r,p)}n.apply(this,arguments)}}return a.call(e,t,i,s,o,r,p)}if(Object.setPrototypeOf)Object.setPrototypeOf(read,a);return read}(e.read);e.readSync=typeof e.readSync!=="function"?e.readSync:function(a){return function(t,i,s,o,r){var n=0;while(true){try{return a.call(e,t,i,s,o,r)}catch(e){if(e.code==="EAGAIN"&&n<10){n++;continue}throw e}}}}(e.readSync);function patchLchmod(e){e.lchmod=function(a,t,s){e.open(a,i.O_WRONLY|i.O_SYMLINK,t,(function(a,i){if(a){if(s)s(a);return}e.fchmod(i,t,(function(a){e.close(i,(function(e){if(s)s(a||e)}))}))}))};e.lchmodSync=function(a,t){var s=e.openSync(a,i.O_WRONLY|i.O_SYMLINK,t);var o=true;var r;try{r=e.fchmodSync(s,t);o=false}finally{if(o){try{e.closeSync(s)}catch(e){}}else{e.closeSync(s)}}return r}}function patchLutimes(e){if(i.hasOwnProperty("O_SYMLINK")&&e.futimes){e.lutimes=function(a,t,s,o){e.open(a,i.O_SYMLINK,(function(a,i){if(a){if(o)o(a);return}e.futimes(i,t,s,(function(a){e.close(i,(function(e){if(o)o(a||e)}))}))}))};e.lutimesSync=function(a,t,s){var o=e.openSync(a,i.O_SYMLINK);var r;var n=true;try{r=e.futimesSync(o,t,s);n=false}finally{if(n){try{e.closeSync(o)}catch(e){}}else{e.closeSync(o)}}return r}}else if(e.futimes){e.lutimes=function(e,a,t,i){if(i)process.nextTick(i)};e.lutimesSync=function(){}}}function chmodFix(a){if(!a)return a;return function(t,i,s){return a.call(e,t,i,(function(e){if(chownErOk(e))e=null;if(s)s.apply(this,arguments)}))}}function chmodFixSync(a){if(!a)return a;return function(t,i){try{return a.call(e,t,i)}catch(e){if(!chownErOk(e))throw e}}}function chownFix(a){if(!a)return a;return function(t,i,s,o){return a.call(e,t,i,s,(function(e){if(chownErOk(e))e=null;if(o)o.apply(this,arguments)}))}}function chownFixSync(a){if(!a)return a;return function(t,i,s){try{return a.call(e,t,i,s)}catch(e){if(!chownErOk(e))throw e}}}function statFix(a){if(!a)return a;return function(t,i,s){if(typeof i==="function"){s=i;i=null}function callback(e,a){if(a){if(a.uid<0)a.uid+=4294967296;if(a.gid<0)a.gid+=4294967296}if(s)s.apply(this,arguments)}return i?a.call(e,t,i,callback):a.call(e,t,callback)}}function statFixSync(a){if(!a)return a;return function(t,i){var s=i?a.call(e,t,i):a.call(e,t);if(s){if(s.uid<0)s.uid+=4294967296;if(s.gid<0)s.gid+=4294967296}return s}}function chownErOk(e){if(!e)return true;if(e.code==="ENOSYS")return true;var a=!process.getuid||process.getuid()!==0;if(a){if(e.code==="EINVAL"||e.code==="EPERM")return true}return false}}},748:e=>{"use strict";e.exports=(e,a=process.argv)=>{const t=e.startsWith("-")?"":e.length===1?"-":"--";const i=a.indexOf(t+e);const s=a.indexOf("--");return i!==-1&&(s===-1||i{"use strict";Object.defineProperty(a,"__esModule",{value:true}); +(()=>{var __webpack_modules__={1065:function(e,a,t){"use strict";var i=this&&this.__awaiter||function(e,a,t,i){function adopt(e){return e instanceof t?e:new t((function(a){a(e)}))}return new(t||(t=Promise))((function(t,s){function fulfilled(e){try{step(i.next(e))}catch(e){s(e)}}function rejected(e){try{step(i["throw"](e))}catch(e){s(e)}}function step(e){e.done?t(e.value):adopt(e.value).then(fulfilled,rejected)}step((i=i.apply(e,a||[])).next())}))};Object.defineProperty(a,"__esModule",{value:true});a.pushBadges=void 0;const s=t(8686);const o=t(7697);const pushBadges=(e="./badges")=>i(void 0,void 0,void 0,(function*(){yield(0,o.exec)("git add",[e]);yield(0,o.exec)("git commit",["-m",(0,s.getInput)("commit-message")]);yield(0,o.exec)("git push")}));a.pushBadges=pushBadges},3333:function(e,a,t){"use strict";var i=this&&this.__awaiter||function(e,a,t,i){function adopt(e){return e instanceof t?e:new t((function(a){a(e)}))}return new(t||(t=Promise))((function(t,s){function fulfilled(e){try{step(i.next(e))}catch(e){s(e)}}function rejected(e){try{step(i["throw"](e))}catch(e){s(e)}}function step(e){e.done?t(e.value):adopt(e.value).then(fulfilled,rejected)}step((i=i.apply(e,a||[])).next())}))};Object.defineProperty(a,"__esModule",{value:true});a.setGitConfig=void 0;const s=t(8686);const o=t(7697);const r=t(7481);const setGitConfig=()=>i(void 0,void 0,void 0,(function*(){const e=(0,s.getInput)("commit-user-email");const a=(0,s.getInput)("commit-user");yield(0,o.exec)("git config",["--global","user.name",a.length===0?r.context.actor:a]);yield(0,o.exec)("git config",["--global","user.email",e.length===0?`${r.context.actor}@users.noreply.github.com`:e])}));a.setGitConfig=setGitConfig},1864:(e,a,t)=>{"use strict";Object.defineProperty(a,"__esModule",{value:true});a.getCurrentBranch=void 0;const i=t(3848);const getCurrentBranch=()=>{var e;let a;try{a=JSON.parse((0,i.readFileSync)(process.env.GITHUB_EVENT_PATH,{encoding:"utf8"}))}catch(e){return undefined}const t=(e=a.ref)===null||e===void 0?void 0:e.split("/").slice(2).join("/");return t};a.getCurrentBranch=getCurrentBranch},1706:(e,a,t)=>{"use strict";Object.defineProperty(a,"__esModule",{value:true});a.isBranchValidForBadgesGeneration=void 0;const i=t(8686);const s=t(1864);const isBranchValidForBadgesGeneration=()=>{const e=(0,s.getCurrentBranch)();if(!e){(0,i.error)(`🔶 Unable to get current branch from github event.`);return false}let a=(0,i.getInput)("branches").split(",");if(a.length===1&&a[0].length===0){(0,i.info)(`🔶 No branches specified, defaulting to master and main`);a=["master","main"]}return a.includes(e)};a.isBranchValidForBadgesGeneration=isBranchValidForBadgesGeneration},2321:function(e,a,t){"use strict";var i=this&&this.__awaiter||function(e,a,t,i){function adopt(e){return e instanceof t?e:new t((function(a){a(e)}))}return new(t||(t=Promise))((function(t,s){function fulfilled(e){try{step(i.next(e))}catch(e){s(e)}}function rejected(e){try{step(i["throw"](e))}catch(e){s(e)}}function step(e){e.done?t(e.value):adopt(e.value).then(fulfilled,rejected)}step((i=i.apply(e,a||[])).next())}))};Object.defineProperty(a,"__esModule",{value:true});a.doBadgesExist=void 0;const s=t(3848);const doBadgesExist=e=>i(void 0,void 0,void 0,(function*(){const a=["coverage-branches.svg","coverage-functions.svg","coverage-jest coverage.svg","coverage-lines.svg","coverage-statements.svg"];const t=yield Promise.all(a.map((a=>(0,s.pathExists)(`${e}/${a}`))));return t.every((e=>e===true))}));a.doBadgesExist=doBadgesExist},3516:function(e,a,t){"use strict";var i=this&&this.__awaiter||function(e,a,t,i){function adopt(e){return e instanceof t?e:new t((function(a){a(e)}))}return new(t||(t=Promise))((function(t,s){function fulfilled(e){try{step(i.next(e))}catch(e){s(e)}}function rejected(e){try{step(i["throw"](e))}catch(e){s(e)}}function step(e){e.done?t(e.value):adopt(e.value).then(fulfilled,rejected)}step((i=i.apply(e,a||[])).next())}))};Object.defineProperty(a,"__esModule",{value:true});a.hasCoverageEvolved=void 0;const s=t(7697);const hasCoverageEvolved=(e,a)=>i(void 0,void 0,void 0,(function*(){if(!e){return true}const t=yield(0,s.exec)("git diff",["--quiet",`${a}/*`],{ignoreReturnCode:true});const i=t===1;return i}));a.hasCoverageEvolved=hasCoverageEvolved},2972:function(e,a,t){"use strict";var i=this&&this.__awaiter||function(e,a,t,i){function adopt(e){return e instanceof t?e:new t((function(a){a(e)}))}return new(t||(t=Promise))((function(t,s){function fulfilled(e){try{step(i.next(e))}catch(e){s(e)}}function rejected(e){try{step(i["throw"](e))}catch(e){s(e)}}function step(e){e.done?t(e.value):adopt(e.value).then(fulfilled,rejected)}step((i=i.apply(e,a||[])).next())}))};Object.defineProperty(a,"__esModule",{value:true});a.isJestCoverageReportAvailable=void 0;const s=t(8686);const o=t(3848);const isUndefined=e=>(e===null||e===void 0?void 0:e.pct)===undefined;const isJestCoverageReportAvailable=()=>i(void 0,void 0,void 0,(function*(){const e=(0,s.getInput)("coverage-summary-path");const a=yield(0,o.pathExists)(e);if(!a){return false}const t=yield(0,o.readJson)(e);if(!t||!t.total){return false}if(isUndefined(t.total.branches)||isUndefined(t.total.functions)||isUndefined(t.total.lines)||isUndefined(t.total.statements)){return false}return true}));a.isJestCoverageReportAvailable=isJestCoverageReportAvailable},861:function(e,a,t){"use strict";var i=this&&this.__awaiter||function(e,a,t,i){function adopt(e){return e instanceof t?e:new t((function(a){a(e)}))}return new(t||(t=Promise))((function(t,s){function fulfilled(e){try{step(i.next(e))}catch(e){s(e)}}function rejected(e){try{step(i["throw"](e))}catch(e){s(e)}}function step(e){e.done?t(e.value):adopt(e.value).then(fulfilled,rejected)}step((i=i.apply(e,a||[])).next())}))};Object.defineProperty(a,"__esModule",{value:true});a.actionWorkflow=void 0;const s=t(8686);const o=t(212);const r=t(1065);const n=t(3333);const p=t(1706);const d=t(2321);const l=t(3516);const c=t(2972);const actionWorkflow=()=>i(void 0,void 0,void 0,(function*(){try{const e=(0,s.getInput)("no-commit")!=="true";if(e){const e=(0,p.isBranchValidForBadgesGeneration)();if(!e){return(0,s.info)("🔶 Current branch does not belong to the branches allowed for badges generation, task dropped.")}}const a=yield(0,c.isJestCoverageReportAvailable)();if(!a){return(0,s.setFailed)("🔶 Coverage report is missing. Did you forget to run tests or to add `json-summary` to coverageReporters in jest config?")}const t=(0,s.getInput)("coverage-summary-path");const i=t===""?undefined:t;const u=(0,s.getInput)("output-folder");const m=yield(0,d.doBadgesExist)(u);(0,s.info)(`🔶 Generating badges from ${i?i:"default coverage summary path"}`);yield(0,o.generateBadges)(i,u);if(!e){return(0,s.info)("🔶 `no-commit` set to true: badges won't be committed")}const v=yield(0,l.hasCoverageEvolved)(m,u);if(!v){return(0,s.info)("🔶 Coverage has not evolved, no action required.")}(0,s.info)("🔶 Pushing badges to the repo");yield(0,n.setGitConfig)();yield(0,r.pushBadges)(u)}catch(e){if(e instanceof Error){return(0,s.setFailed)(`🔶 Oh no! An error occured: ${e.message}`)}return(0,s.setFailed)(`🔶 Oh no! An unknown error occured`)}}));a.actionWorkflow=actionWorkflow},1514:function(e,a,t){"use strict";var i=this&&this.__createBinding||(Object.create?function(e,a,t,i){if(i===undefined)i=t;Object.defineProperty(e,i,{enumerable:true,get:function(){return a[t]}})}:function(e,a,t,i){if(i===undefined)i=t;e[i]=a[t]});var s=this&&this.__setModuleDefault||(Object.create?function(e,a){Object.defineProperty(e,"default",{enumerable:true,value:a})}:function(e,a){e["default"]=a});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var a={};if(e!=null)for(var t in e)if(t!=="default"&&Object.hasOwnProperty.call(e,t))i(a,e,t);s(a,e);return a};Object.defineProperty(a,"__esModule",{value:true});a.issue=a.issueCommand=void 0;const r=o(t(2037));const n=t(2660);function issueCommand(e,a,t){const i=new Command(e,a,t);process.stdout.write(i.toString()+r.EOL)}a.issueCommand=issueCommand;function issue(e,a=""){issueCommand(e,{},a)}a.issue=issue;const p="::";class Command{constructor(e,a,t){if(!e){e="missing.command"}this.command=e;this.properties=a;this.message=t}toString(){let e=p+this.command;if(this.properties&&Object.keys(this.properties).length>0){e+=" ";let a=true;for(const t in this.properties){if(this.properties.hasOwnProperty(t)){const i=this.properties[t];if(i){if(a){a=false}else{e+=","}e+=`${t}=${escapeProperty(i)}`}}}}e+=`${p}${escapeData(this.message)}`;return e}}function escapeData(e){return n.toCommandValue(e).replace(/%/g,"%25").replace(/\r/g,"%0D").replace(/\n/g,"%0A")}function escapeProperty(e){return n.toCommandValue(e).replace(/%/g,"%25").replace(/\r/g,"%0D").replace(/\n/g,"%0A").replace(/:/g,"%3A").replace(/,/g,"%2C")}},8686:function(e,a,t){"use strict";var i=this&&this.__createBinding||(Object.create?function(e,a,t,i){if(i===undefined)i=t;Object.defineProperty(e,i,{enumerable:true,get:function(){return a[t]}})}:function(e,a,t,i){if(i===undefined)i=t;e[i]=a[t]});var s=this&&this.__setModuleDefault||(Object.create?function(e,a){Object.defineProperty(e,"default",{enumerable:true,value:a})}:function(e,a){e["default"]=a});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var a={};if(e!=null)for(var t in e)if(t!=="default"&&Object.hasOwnProperty.call(e,t))i(a,e,t);s(a,e);return a};var r=this&&this.__awaiter||function(e,a,t,i){function adopt(e){return e instanceof t?e:new t((function(a){a(e)}))}return new(t||(t=Promise))((function(t,s){function fulfilled(e){try{step(i.next(e))}catch(e){s(e)}}function rejected(e){try{step(i["throw"](e))}catch(e){s(e)}}function step(e){e.done?t(e.value):adopt(e.value).then(fulfilled,rejected)}step((i=i.apply(e,a||[])).next())}))};Object.defineProperty(a,"__esModule",{value:true});a.getIDToken=a.getState=a.saveState=a.group=a.endGroup=a.startGroup=a.info=a.notice=a.warning=a.error=a.debug=a.isDebug=a.setFailed=a.setCommandEcho=a.setOutput=a.getBooleanInput=a.getMultilineInput=a.getInput=a.addPath=a.setSecret=a.exportVariable=a.ExitCode=void 0;const n=t(1514);const p=t(5635);const d=t(2660);const l=o(t(2037));const c=o(t(1017));const u=t(1569);var m;(function(e){e[e["Success"]=0]="Success";e[e["Failure"]=1]="Failure"})(m=a.ExitCode||(a.ExitCode={}));function exportVariable(e,a){const t=d.toCommandValue(a);process.env[e]=t;const i=process.env["GITHUB_ENV"]||"";if(i){return p.issueFileCommand("ENV",p.prepareKeyValueMessage(e,a))}n.issueCommand("set-env",{name:e},t)}a.exportVariable=exportVariable;function setSecret(e){n.issueCommand("add-mask",{},e)}a.setSecret=setSecret;function addPath(e){const a=process.env["GITHUB_PATH"]||"";if(a){p.issueFileCommand("PATH",e)}else{n.issueCommand("add-path",{},e)}process.env["PATH"]=`${e}${c.delimiter}${process.env["PATH"]}`}a.addPath=addPath;function getInput(e,a){const t=process.env[`INPUT_${e.replace(/ /g,"_").toUpperCase()}`]||"";if(a&&a.required&&!t){throw new Error(`Input required and not supplied: ${e}`)}if(a&&a.trimWhitespace===false){return t}return t.trim()}a.getInput=getInput;function getMultilineInput(e,a){const t=getInput(e,a).split("\n").filter((e=>e!==""));if(a&&a.trimWhitespace===false){return t}return t.map((e=>e.trim()))}a.getMultilineInput=getMultilineInput;function getBooleanInput(e,a){const t=["true","True","TRUE"];const i=["false","False","FALSE"];const s=getInput(e,a);if(t.includes(s))return true;if(i.includes(s))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\``)}a.getBooleanInput=getBooleanInput;function setOutput(e,a){const t=process.env["GITHUB_OUTPUT"]||"";if(t){return p.issueFileCommand("OUTPUT",p.prepareKeyValueMessage(e,a))}process.stdout.write(l.EOL);n.issueCommand("set-output",{name:e},d.toCommandValue(a))}a.setOutput=setOutput;function setCommandEcho(e){n.issue("echo",e?"on":"off")}a.setCommandEcho=setCommandEcho;function setFailed(e){process.exitCode=m.Failure;error(e)}a.setFailed=setFailed;function isDebug(){return process.env["RUNNER_DEBUG"]==="1"}a.isDebug=isDebug;function debug(e){n.issueCommand("debug",{},e)}a.debug=debug;function error(e,a={}){n.issueCommand("error",d.toCommandProperties(a),e instanceof Error?e.toString():e)}a.error=error;function warning(e,a={}){n.issueCommand("warning",d.toCommandProperties(a),e instanceof Error?e.toString():e)}a.warning=warning;function notice(e,a={}){n.issueCommand("notice",d.toCommandProperties(a),e instanceof Error?e.toString():e)}a.notice=notice;function info(e){process.stdout.write(e+l.EOL)}a.info=info;function startGroup(e){n.issue("group",e)}a.startGroup=startGroup;function endGroup(){n.issue("endgroup")}a.endGroup=endGroup;function group(e,a){return r(this,void 0,void 0,(function*(){startGroup(e);let t;try{t=yield a()}finally{endGroup()}return t}))}a.group=group;function saveState(e,a){const t=process.env["GITHUB_STATE"]||"";if(t){return p.issueFileCommand("STATE",p.prepareKeyValueMessage(e,a))}n.issueCommand("save-state",{name:e},d.toCommandValue(a))}a.saveState=saveState;function getState(e){return process.env[`STATE_${e}`]||""}a.getState=getState;function getIDToken(e){return r(this,void 0,void 0,(function*(){return yield u.OidcClient.getIDToken(e)}))}a.getIDToken=getIDToken;var v=t(2518);Object.defineProperty(a,"summary",{enumerable:true,get:function(){return v.summary}});var h=t(2518);Object.defineProperty(a,"markdownSummary",{enumerable:true,get:function(){return h.markdownSummary}});var g=t(2162);Object.defineProperty(a,"toPosixPath",{enumerable:true,get:function(){return g.toPosixPath}});Object.defineProperty(a,"toWin32Path",{enumerable:true,get:function(){return g.toWin32Path}});Object.defineProperty(a,"toPlatformPath",{enumerable:true,get:function(){return g.toPlatformPath}})},5635:function(e,a,t){"use strict";var i=this&&this.__createBinding||(Object.create?function(e,a,t,i){if(i===undefined)i=t;Object.defineProperty(e,i,{enumerable:true,get:function(){return a[t]}})}:function(e,a,t,i){if(i===undefined)i=t;e[i]=a[t]});var s=this&&this.__setModuleDefault||(Object.create?function(e,a){Object.defineProperty(e,"default",{enumerable:true,value:a})}:function(e,a){e["default"]=a});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var a={};if(e!=null)for(var t in e)if(t!=="default"&&Object.hasOwnProperty.call(e,t))i(a,e,t);s(a,e);return a};Object.defineProperty(a,"__esModule",{value:true});a.prepareKeyValueMessage=a.issueFileCommand=void 0;const r=o(t(7147));const n=o(t(2037));const p=t(3236);const d=t(2660);function issueFileCommand(e,a){const t=process.env[`GITHUB_${e}`];if(!t){throw new Error(`Unable to find environment variable for file command ${e}`)}if(!r.existsSync(t)){throw new Error(`Missing file at path: ${t}`)}r.appendFileSync(t,`${d.toCommandValue(a)}${n.EOL}`,{encoding:"utf8"})}a.issueFileCommand=issueFileCommand;function prepareKeyValueMessage(e,a){const t=`ghadelimiter_${p.v4()}`;const i=d.toCommandValue(a);if(e.includes(t)){throw new Error(`Unexpected input: name should not contain the delimiter "${t}"`)}if(i.includes(t)){throw new Error(`Unexpected input: value should not contain the delimiter "${t}"`)}return`${e}<<${t}${n.EOL}${i}${n.EOL}${t}`}a.prepareKeyValueMessage=prepareKeyValueMessage},1569:function(e,a,t){"use strict";var i=this&&this.__awaiter||function(e,a,t,i){function adopt(e){return e instanceof t?e:new t((function(a){a(e)}))}return new(t||(t=Promise))((function(t,s){function fulfilled(e){try{step(i.next(e))}catch(e){s(e)}}function rejected(e){try{step(i["throw"](e))}catch(e){s(e)}}function step(e){e.done?t(e.value):adopt(e.value).then(fulfilled,rejected)}step((i=i.apply(e,a||[])).next())}))};Object.defineProperty(a,"__esModule",{value:true});a.OidcClient=void 0;const s=t(8971);const o=t(3955);const r=t(8686);class OidcClient{static createHttpClient(e=true,a=10){const t={allowRetries:e,maxRetries:a};return new s.HttpClient("actions/oidc-client",[new o.BearerCredentialHandler(OidcClient.getRequestToken())],t)}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 a;return i(this,void 0,void 0,(function*(){const t=OidcClient.createHttpClient();const i=yield t.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 s=(a=i.result)===null||a===void 0?void 0:a.value;if(!s){throw new Error("Response json body do not have ID Token field")}return s}))}static getIDToken(e){return i(this,void 0,void 0,(function*(){try{let a=OidcClient.getIDTokenUrl();if(e){const t=encodeURIComponent(e);a=`${a}&audience=${t}`}r.debug(`ID token url is ${a}`);const t=yield OidcClient.getCall(a);r.setSecret(t);return t}catch(e){throw new Error(`Error message: ${e.message}`)}}))}}a.OidcClient=OidcClient},2162:function(e,a,t){"use strict";var i=this&&this.__createBinding||(Object.create?function(e,a,t,i){if(i===undefined)i=t;Object.defineProperty(e,i,{enumerable:true,get:function(){return a[t]}})}:function(e,a,t,i){if(i===undefined)i=t;e[i]=a[t]});var s=this&&this.__setModuleDefault||(Object.create?function(e,a){Object.defineProperty(e,"default",{enumerable:true,value:a})}:function(e,a){e["default"]=a});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var a={};if(e!=null)for(var t in e)if(t!=="default"&&Object.hasOwnProperty.call(e,t))i(a,e,t);s(a,e);return a};Object.defineProperty(a,"__esModule",{value:true});a.toPlatformPath=a.toWin32Path=a.toPosixPath=void 0;const r=o(t(1017));function toPosixPath(e){return e.replace(/[\\]/g,"/")}a.toPosixPath=toPosixPath;function toWin32Path(e){return e.replace(/[/]/g,"\\")}a.toWin32Path=toWin32Path;function toPlatformPath(e){return e.replace(/[/\\]/g,r.sep)}a.toPlatformPath=toPlatformPath},2518:function(e,a,t){"use strict";var i=this&&this.__awaiter||function(e,a,t,i){function adopt(e){return e instanceof t?e:new t((function(a){a(e)}))}return new(t||(t=Promise))((function(t,s){function fulfilled(e){try{step(i.next(e))}catch(e){s(e)}}function rejected(e){try{step(i["throw"](e))}catch(e){s(e)}}function step(e){e.done?t(e.value):adopt(e.value).then(fulfilled,rejected)}step((i=i.apply(e,a||[])).next())}))};Object.defineProperty(a,"__esModule",{value:true});a.summary=a.markdownSummary=a.SUMMARY_DOCS_URL=a.SUMMARY_ENV_VAR=void 0;const s=t(2037);const o=t(7147);const{access:r,appendFile:n,writeFile:p}=o.promises;a.SUMMARY_ENV_VAR="GITHUB_STEP_SUMMARY";a.SUMMARY_DOCS_URL="https://docs.github.com/actions/using-workflows/workflow-commands-for-github-actions#adding-a-job-summary";class Summary{constructor(){this._buffer=""}filePath(){return i(this,void 0,void 0,(function*(){if(this._filePath){return this._filePath}const e=process.env[a.SUMMARY_ENV_VAR];if(!e){throw new Error(`Unable to find environment variable for $${a.SUMMARY_ENV_VAR}. Check if your runtime environment supports job summaries.`)}try{yield r(e,o.constants.R_OK|o.constants.W_OK)}catch(a){throw new Error(`Unable to access summary file: '${e}'. Check if the file has correct read/write permissions.`)}this._filePath=e;return this._filePath}))}wrap(e,a,t={}){const i=Object.entries(t).map((([e,a])=>` ${e}="${a}"`)).join("");if(!a){return`<${e}${i}>`}return`<${e}${i}>${a}`}write(e){return i(this,void 0,void 0,(function*(){const a=!!(e===null||e===void 0?void 0:e.overwrite);const t=yield this.filePath();const i=a?p:n;yield i(t,this._buffer,{encoding:"utf8"});return this.emptyBuffer()}))}clear(){return i(this,void 0,void 0,(function*(){return this.emptyBuffer().write({overwrite:true})}))}stringify(){return this._buffer}isEmptyBuffer(){return this._buffer.length===0}emptyBuffer(){this._buffer="";return this}addRaw(e,a=false){this._buffer+=e;return a?this.addEOL():this}addEOL(){return this.addRaw(s.EOL)}addCodeBlock(e,a){const t=Object.assign({},a&&{lang:a});const i=this.wrap("pre",this.wrap("code",e),t);return this.addRaw(i).addEOL()}addList(e,a=false){const t=a?"ol":"ul";const i=e.map((e=>this.wrap("li",e))).join("");const s=this.wrap(t,i);return this.addRaw(s).addEOL()}addTable(e){const a=e.map((e=>{const a=e.map((e=>{if(typeof e==="string"){return this.wrap("td",e)}const{header:a,data:t,colspan:i,rowspan:s}=e;const o=a?"th":"td";const r=Object.assign(Object.assign({},i&&{colspan:i}),s&&{rowspan:s});return this.wrap(o,t,r)})).join("");return this.wrap("tr",a)})).join("");const t=this.wrap("table",a);return this.addRaw(t).addEOL()}addDetails(e,a){const t=this.wrap("details",this.wrap("summary",e)+a);return this.addRaw(t).addEOL()}addImage(e,a,t){const{width:i,height:s}=t||{};const o=Object.assign(Object.assign({},i&&{width:i}),s&&{height:s});const r=this.wrap("img",null,Object.assign({src:e,alt:a},o));return this.addRaw(r).addEOL()}addHeading(e,a){const t=`h${a}`;const i=["h1","h2","h3","h4","h5","h6"].includes(t)?t:"h1";const s=this.wrap(i,e);return this.addRaw(s).addEOL()}addSeparator(){const e=this.wrap("hr",null);return this.addRaw(e).addEOL()}addBreak(){const e=this.wrap("br",null);return this.addRaw(e).addEOL()}addQuote(e,a){const t=Object.assign({},a&&{cite:a});const i=this.wrap("blockquote",e,t);return this.addRaw(i).addEOL()}addLink(e,a){const t=this.wrap("a",e,{href:a});return this.addRaw(t).addEOL()}}const d=new Summary;a.markdownSummary=d;a.summary=d},2660:(e,a)=>{"use strict";Object.defineProperty(a,"__esModule",{value:true});a.toCommandProperties=a.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)}a.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}}a.toCommandProperties=toCommandProperties},7697:function(e,a,t){"use strict";var i=this&&this.__createBinding||(Object.create?function(e,a,t,i){if(i===undefined)i=t;Object.defineProperty(e,i,{enumerable:true,get:function(){return a[t]}})}:function(e,a,t,i){if(i===undefined)i=t;e[i]=a[t]});var s=this&&this.__setModuleDefault||(Object.create?function(e,a){Object.defineProperty(e,"default",{enumerable:true,value:a})}:function(e,a){e["default"]=a});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var a={};if(e!=null)for(var t in e)if(t!=="default"&&Object.hasOwnProperty.call(e,t))i(a,e,t);s(a,e);return a};var r=this&&this.__awaiter||function(e,a,t,i){function adopt(e){return e instanceof t?e:new t((function(a){a(e)}))}return new(t||(t=Promise))((function(t,s){function fulfilled(e){try{step(i.next(e))}catch(e){s(e)}}function rejected(e){try{step(i["throw"](e))}catch(e){s(e)}}function step(e){e.done?t(e.value):adopt(e.value).then(fulfilled,rejected)}step((i=i.apply(e,a||[])).next())}))};Object.defineProperty(a,"__esModule",{value:true});a.getExecOutput=a.exec=void 0;const n=t(1576);const p=o(t(9438));function exec(e,a,t){return r(this,void 0,void 0,(function*(){const i=p.argStringToArray(e);if(i.length===0){throw new Error(`Parameter 'commandLine' cannot be null or empty.`)}const s=i[0];a=i.slice(1).concat(a||[]);const o=new p.ToolRunner(s,a,t);return o.exec()}))}a.exec=exec;function getExecOutput(e,a,t){var i,s;return r(this,void 0,void 0,(function*(){let o="";let r="";const p=new n.StringDecoder("utf8");const d=new n.StringDecoder("utf8");const l=(i=t===null||t===void 0?void 0:t.listeners)===null||i===void 0?void 0:i.stdout;const c=(s=t===null||t===void 0?void 0:t.listeners)===null||s===void 0?void 0:s.stderr;const stdErrListener=e=>{r+=d.write(e);if(c){c(e)}};const stdOutListener=e=>{o+=p.write(e);if(l){l(e)}};const u=Object.assign(Object.assign({},t===null||t===void 0?void 0:t.listeners),{stdout:stdOutListener,stderr:stdErrListener});const m=yield exec(e,a,Object.assign(Object.assign({},t),{listeners:u}));o+=p.end();r+=d.end();return{exitCode:m,stdout:o,stderr:r}}))}a.getExecOutput=getExecOutput},9438:function(e,a,t){"use strict";var i=this&&this.__createBinding||(Object.create?function(e,a,t,i){if(i===undefined)i=t;Object.defineProperty(e,i,{enumerable:true,get:function(){return a[t]}})}:function(e,a,t,i){if(i===undefined)i=t;e[i]=a[t]});var s=this&&this.__setModuleDefault||(Object.create?function(e,a){Object.defineProperty(e,"default",{enumerable:true,value:a})}:function(e,a){e["default"]=a});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var a={};if(e!=null)for(var t in e)if(t!=="default"&&Object.hasOwnProperty.call(e,t))i(a,e,t);s(a,e);return a};var r=this&&this.__awaiter||function(e,a,t,i){function adopt(e){return e instanceof t?e:new t((function(a){a(e)}))}return new(t||(t=Promise))((function(t,s){function fulfilled(e){try{step(i.next(e))}catch(e){s(e)}}function rejected(e){try{step(i["throw"](e))}catch(e){s(e)}}function step(e){e.done?t(e.value):adopt(e.value).then(fulfilled,rejected)}step((i=i.apply(e,a||[])).next())}))};Object.defineProperty(a,"__esModule",{value:true});a.argStringToArray=a.ToolRunner=void 0;const n=o(t(2037));const p=o(t(2361));const d=o(t(2081));const l=o(t(1017));const c=o(t(8071));const u=o(t(9464));const m=t(9512);const v=process.platform==="win32";class ToolRunner extends p.EventEmitter{constructor(e,a,t){super();if(!e){throw new Error("Parameter 'toolPath' cannot be null or empty.")}this.toolPath=e;this.args=a||[];this.options=t||{}}_debug(e){if(this.options.listeners&&this.options.listeners.debug){this.options.listeners.debug(e)}}_getCommandString(e,a){const t=this._getSpawnFileName();const i=this._getSpawnArgs(e);let s=a?"":"[command]";if(v){if(this._isCmdFile()){s+=t;for(const e of i){s+=` ${e}`}}else if(e.windowsVerbatimArguments){s+=`"${t}"`;for(const e of i){s+=` ${e}`}}else{s+=this._windowsQuoteCmdArg(t);for(const e of i){s+=` ${this._windowsQuoteCmdArg(e)}`}}}else{s+=t;for(const e of i){s+=` ${e}`}}return s}_processLineBuffer(e,a,t){try{let i=a+e.toString();let s=i.indexOf(n.EOL);while(s>-1){const e=i.substring(0,s);t(e);i=i.substring(s+n.EOL.length);s=i.indexOf(n.EOL)}return i}catch(e){this._debug(`error processing line. Failed with error ${e}`);return""}}_getSpawnFileName(){if(v){if(this._isCmdFile()){return process.env["COMSPEC"]||"cmd.exe"}}return this.toolPath}_getSpawnArgs(e){if(v){if(this._isCmdFile()){let a=`/D /S /C "${this._windowsQuoteCmdArg(this.toolPath)}`;for(const t of this.args){a+=" ";a+=e.windowsVerbatimArguments?t:this._windowsQuoteCmdArg(t)}a+='"';return[a]}}return this.args}_endsWith(e,a){return e.endsWith(a)}_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 a=[" ","\t","&","(",")","[","]","{","}","^","=",";","!","'","+",",","`","~","|","<",">",'"'];let t=false;for(const i of e){if(a.some((e=>e===i))){t=true;break}}if(!t){return e}let i='"';let s=true;for(let a=e.length;a>0;a--){i+=e[a-1];if(s&&e[a-1]==="\\"){i+="\\"}else if(e[a-1]==='"'){s=true;i+='"'}else{s=false}}i+='"';return i.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 a='"';let t=true;for(let i=e.length;i>0;i--){a+=e[i-1];if(t&&e[i-1]==="\\"){a+="\\"}else if(e[i-1]==='"'){t=true;a+="\\"}else{t=false}}a+='"';return a.split("").reverse().join("")}_cloneExecOptions(e){e=e||{};const a={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};a.outStream=e.outStream||process.stdout;a.errStream=e.errStream||process.stderr;return a}_getSpawnOptions(e,a){e=e||{};const t={};t.cwd=e.cwd;t.env=e.env;t["windowsVerbatimArguments"]=e.windowsVerbatimArguments||this._isCmdFile();if(e.windowsVerbatimArguments){t.argv0=`"${a}"`}return t}exec(){return r(this,void 0,void 0,(function*(){if(!u.isRooted(this.toolPath)&&(this.toolPath.includes("/")||v&&this.toolPath.includes("\\"))){this.toolPath=l.resolve(process.cwd(),this.options.cwd||process.cwd(),this.toolPath)}this.toolPath=yield c.which(this.toolPath,true);return new Promise(((e,a)=>r(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 t=this._cloneExecOptions(this.options);if(!t.silent&&t.outStream){t.outStream.write(this._getCommandString(t)+n.EOL)}const i=new ExecState(t,this.toolPath);i.on("debug",(e=>{this._debug(e)}));if(this.options.cwd&&!(yield u.exists(this.options.cwd))){return a(new Error(`The cwd: ${this.options.cwd} does not exist!`))}const s=this._getSpawnFileName();const o=d.spawn(s,this._getSpawnArgs(t),this._getSpawnOptions(this.options,s));let r="";if(o.stdout){o.stdout.on("data",(e=>{if(this.options.listeners&&this.options.listeners.stdout){this.options.listeners.stdout(e)}if(!t.silent&&t.outStream){t.outStream.write(e)}r=this._processLineBuffer(e,r,(e=>{if(this.options.listeners&&this.options.listeners.stdline){this.options.listeners.stdline(e)}}))}))}let p="";if(o.stderr){o.stderr.on("data",(e=>{i.processStderr=true;if(this.options.listeners&&this.options.listeners.stderr){this.options.listeners.stderr(e)}if(!t.silent&&t.errStream&&t.outStream){const a=t.failOnStdErr?t.errStream:t.outStream;a.write(e)}p=this._processLineBuffer(e,p,(e=>{if(this.options.listeners&&this.options.listeners.errline){this.options.listeners.errline(e)}}))}))}o.on("error",(e=>{i.processError=e.message;i.processExited=true;i.processClosed=true;i.CheckComplete()}));o.on("exit",(e=>{i.processExitCode=e;i.processExited=true;this._debug(`Exit code ${e} received from tool '${this.toolPath}'`);i.CheckComplete()}));o.on("close",(e=>{i.processExitCode=e;i.processExited=true;i.processClosed=true;this._debug(`STDIO streams have closed for tool '${this.toolPath}'`);i.CheckComplete()}));i.on("done",((t,i)=>{if(r.length>0){this.emit("stdline",r)}if(p.length>0){this.emit("errline",p)}o.removeAllListeners();if(t){a(t)}else{e(i)}}));if(this.options.input){if(!o.stdin){throw new Error("child process missing stdin")}o.stdin.end(this.options.input)}}))))}))}}a.ToolRunner=ToolRunner;function argStringToArray(e){const a=[];let t=false;let i=false;let s="";function append(e){if(i&&e!=='"'){s+="\\"}s+=e;i=false}for(let o=0;o0){a.push(s);s=""}continue}append(r)}if(s.length>0){a.push(s.trim())}return a}a.argStringToArray=argStringToArray;class ExecState extends p.EventEmitter{constructor(e,a){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(!a){throw new Error("toolPath must not be empty")}this.options=e;this.toolPath=a;if(e.delay){this.delay=e.delay}}CheckComplete(){if(this.done){return}if(this.processClosed){this._setResult()}else if(this.processExited){this.timeout=m.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 a=`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(a)}e._setResult()}}},1707:(e,a,t)=>{"use strict";Object.defineProperty(a,"__esModule",{value:true});a.Context=void 0;const i=t(7147);const s=t(2037);class Context{constructor(){var e,a,t;this.payload={};if(process.env.GITHUB_EVENT_PATH){if(i.existsSync(process.env.GITHUB_EVENT_PATH)){this.payload=JSON.parse(i.readFileSync(process.env.GITHUB_EVENT_PATH,{encoding:"utf8"}))}else{const e=process.env.GITHUB_EVENT_PATH;process.stdout.write(`GITHUB_EVENT_PATH ${e} does not exist${s.EOL}`)}}this.eventName=process.env.GITHUB_EVENT_NAME;this.sha=process.env.GITHUB_SHA;this.ref=process.env.GITHUB_REF;this.workflow=process.env.GITHUB_WORKFLOW;this.action=process.env.GITHUB_ACTION;this.actor=process.env.GITHUB_ACTOR;this.job=process.env.GITHUB_JOB;this.runNumber=parseInt(process.env.GITHUB_RUN_NUMBER,10);this.runId=parseInt(process.env.GITHUB_RUN_ID,10);this.apiUrl=(e=process.env.GITHUB_API_URL)!==null&&e!==void 0?e:`https://api.github.com`;this.serverUrl=(a=process.env.GITHUB_SERVER_URL)!==null&&a!==void 0?a:`https://github.com`;this.graphqlUrl=(t=process.env.GITHUB_GRAPHQL_URL)!==null&&t!==void 0?t:`https://api.github.com/graphql`}get issue(){const e=this.payload;return Object.assign(Object.assign({},this.repo),{number:(e.issue||e.pull_request||e).number})}get repo(){if(process.env.GITHUB_REPOSITORY){const[e,a]=process.env.GITHUB_REPOSITORY.split("/");return{owner:e,repo:a}}if(this.payload.repository){return{owner:this.payload.repository.owner.login,repo:this.payload.repository.name}}throw new Error("context.repo requires a GITHUB_REPOSITORY environment variable like 'owner/repo'")}}a.Context=Context},7481:function(e,a,t){"use strict";var i=this&&this.__createBinding||(Object.create?function(e,a,t,i){if(i===undefined)i=t;Object.defineProperty(e,i,{enumerable:true,get:function(){return a[t]}})}:function(e,a,t,i){if(i===undefined)i=t;e[i]=a[t]});var s=this&&this.__setModuleDefault||(Object.create?function(e,a){Object.defineProperty(e,"default",{enumerable:true,value:a})}:function(e,a){e["default"]=a});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var a={};if(e!=null)for(var t in e)if(t!=="default"&&Object.hasOwnProperty.call(e,t))i(a,e,t);s(a,e);return a};Object.defineProperty(a,"__esModule",{value:true});a.getOctokit=a.context=void 0;const r=o(t(1707));const n=t(2887);a.context=new r.Context;function getOctokit(e,a,...t){const i=n.GitHub.plugin(...t);return new i(n.getOctokitOptions(e,a))}a.getOctokit=getOctokit},194:function(e,a,t){"use strict";var i=this&&this.__createBinding||(Object.create?function(e,a,t,i){if(i===undefined)i=t;Object.defineProperty(e,i,{enumerable:true,get:function(){return a[t]}})}:function(e,a,t,i){if(i===undefined)i=t;e[i]=a[t]});var s=this&&this.__setModuleDefault||(Object.create?function(e,a){Object.defineProperty(e,"default",{enumerable:true,value:a})}:function(e,a){e["default"]=a});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var a={};if(e!=null)for(var t in e)if(t!=="default"&&Object.hasOwnProperty.call(e,t))i(a,e,t);s(a,e);return a};Object.defineProperty(a,"__esModule",{value:true});a.getApiBaseUrl=a.getProxyAgent=a.getAuthString=void 0;const r=o(t(8971));function getAuthString(e,a){if(!e&&!a.auth){throw new Error("Parameter token or opts.auth is required")}else if(e&&a.auth){throw new Error("Parameters token and opts.auth may not both be specified")}return typeof a.auth==="string"?a.auth:`token ${e}`}a.getAuthString=getAuthString;function getProxyAgent(e){const a=new r.HttpClient;return a.getAgent(e)}a.getProxyAgent=getProxyAgent;function getApiBaseUrl(){return process.env["GITHUB_API_URL"]||"https://api.github.com"}a.getApiBaseUrl=getApiBaseUrl},2887:function(e,a,t){"use strict";var i=this&&this.__createBinding||(Object.create?function(e,a,t,i){if(i===undefined)i=t;Object.defineProperty(e,i,{enumerable:true,get:function(){return a[t]}})}:function(e,a,t,i){if(i===undefined)i=t;e[i]=a[t]});var s=this&&this.__setModuleDefault||(Object.create?function(e,a){Object.defineProperty(e,"default",{enumerable:true,value:a})}:function(e,a){e["default"]=a});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var a={};if(e!=null)for(var t in e)if(t!=="default"&&Object.hasOwnProperty.call(e,t))i(a,e,t);s(a,e);return a};Object.defineProperty(a,"__esModule",{value:true});a.getOctokitOptions=a.GitHub=a.defaults=a.context=void 0;const r=o(t(1707));const n=o(t(194));const p=t(1241);const d=t(1114);const l=t(8469);a.context=new r.Context;const c=n.getApiBaseUrl();a.defaults={baseUrl:c,request:{agent:n.getProxyAgent(c)}};a.GitHub=p.Octokit.plugin(d.restEndpointMethods,l.paginateRest).defaults(a.defaults);function getOctokitOptions(e,a){const t=Object.assign({},a||{});const i=n.getAuthString(e,t);if(i){t.auth=i}return t}a.getOctokitOptions=getOctokitOptions},3955:function(e,a){"use strict";var t=this&&this.__awaiter||function(e,a,t,i){function adopt(e){return e instanceof t?e:new t((function(a){a(e)}))}return new(t||(t=Promise))((function(t,s){function fulfilled(e){try{step(i.next(e))}catch(e){s(e)}}function rejected(e){try{step(i["throw"](e))}catch(e){s(e)}}function step(e){e.done?t(e.value):adopt(e.value).then(fulfilled,rejected)}step((i=i.apply(e,a||[])).next())}))};Object.defineProperty(a,"__esModule",{value:true});a.PersonalAccessTokenCredentialHandler=a.BearerCredentialHandler=a.BasicCredentialHandler=void 0;class BasicCredentialHandler{constructor(e,a){this.username=e;this.password=a}prepareRequest(e){if(!e.headers){throw Error("The request has no headers")}e.headers["Authorization"]=`Basic ${Buffer.from(`${this.username}:${this.password}`).toString("base64")}`}canHandleAuthentication(){return false}handleAuthentication(){return t(this,void 0,void 0,(function*(){throw new Error("not implemented")}))}}a.BasicCredentialHandler=BasicCredentialHandler;class BearerCredentialHandler{constructor(e){this.token=e}prepareRequest(e){if(!e.headers){throw Error("The request has no headers")}e.headers["Authorization"]=`Bearer ${this.token}`}canHandleAuthentication(){return false}handleAuthentication(){return t(this,void 0,void 0,(function*(){throw new Error("not implemented")}))}}a.BearerCredentialHandler=BearerCredentialHandler;class PersonalAccessTokenCredentialHandler{constructor(e){this.token=e}prepareRequest(e){if(!e.headers){throw Error("The request has no headers")}e.headers["Authorization"]=`Basic ${Buffer.from(`PAT:${this.token}`).toString("base64")}`}canHandleAuthentication(){return false}handleAuthentication(){return t(this,void 0,void 0,(function*(){throw new Error("not implemented")}))}}a.PersonalAccessTokenCredentialHandler=PersonalAccessTokenCredentialHandler},8971:function(e,a,t){"use strict";var i=this&&this.__createBinding||(Object.create?function(e,a,t,i){if(i===undefined)i=t;Object.defineProperty(e,i,{enumerable:true,get:function(){return a[t]}})}:function(e,a,t,i){if(i===undefined)i=t;e[i]=a[t]});var s=this&&this.__setModuleDefault||(Object.create?function(e,a){Object.defineProperty(e,"default",{enumerable:true,value:a})}:function(e,a){e["default"]=a});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var a={};if(e!=null)for(var t in e)if(t!=="default"&&Object.hasOwnProperty.call(e,t))i(a,e,t);s(a,e);return a};var r=this&&this.__awaiter||function(e,a,t,i){function adopt(e){return e instanceof t?e:new t((function(a){a(e)}))}return new(t||(t=Promise))((function(t,s){function fulfilled(e){try{step(i.next(e))}catch(e){s(e)}}function rejected(e){try{step(i["throw"](e))}catch(e){s(e)}}function step(e){e.done?t(e.value):adopt(e.value).then(fulfilled,rejected)}step((i=i.apply(e,a||[])).next())}))};Object.defineProperty(a,"__esModule",{value:true});a.HttpClient=a.isHttps=a.HttpClientResponse=a.HttpClientError=a.getProxyUrl=a.MediaTypes=a.Headers=a.HttpCodes=void 0;const n=o(t(3685));const p=o(t(5687));const d=o(t(9446));const l=o(t(5130));var c;(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"})(c=a.HttpCodes||(a.HttpCodes={}));var u;(function(e){e["Accept"]="accept";e["ContentType"]="content-type"})(u=a.Headers||(a.Headers={}));var m;(function(e){e["ApplicationJson"]="application/json"})(m=a.MediaTypes||(a.MediaTypes={}));function getProxyUrl(e){const a=d.getProxyUrl(new URL(e));return a?a.href:""}a.getProxyUrl=getProxyUrl;const v=[c.MovedPermanently,c.ResourceMoved,c.SeeOther,c.TemporaryRedirect,c.PermanentRedirect];const h=[c.BadGateway,c.ServiceUnavailable,c.GatewayTimeout];const g=["OPTIONS","GET","DELETE","HEAD"];const b=10;const w=5;class HttpClientError extends Error{constructor(e,a){super(e);this.name="HttpClientError";this.statusCode=a;Object.setPrototypeOf(this,HttpClientError.prototype)}}a.HttpClientError=HttpClientError;class HttpClientResponse{constructor(e){this.message=e}readBody(){return r(this,void 0,void 0,(function*(){return new Promise((e=>r(this,void 0,void 0,(function*(){let a=Buffer.alloc(0);this.message.on("data",(e=>{a=Buffer.concat([a,e])}));this.message.on("end",(()=>{e(a.toString())}))}))))}))}}a.HttpClientResponse=HttpClientResponse;function isHttps(e){const a=new URL(e);return a.protocol==="https:"}a.isHttps=isHttps;class HttpClient{constructor(e,a,t){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=a||[];this.requestOptions=t;if(t){if(t.ignoreSslError!=null){this._ignoreSslError=t.ignoreSslError}this._socketTimeout=t.socketTimeout;if(t.allowRedirects!=null){this._allowRedirects=t.allowRedirects}if(t.allowRedirectDowngrade!=null){this._allowRedirectDowngrade=t.allowRedirectDowngrade}if(t.maxRedirects!=null){this._maxRedirects=Math.max(t.maxRedirects,0)}if(t.keepAlive!=null){this._keepAlive=t.keepAlive}if(t.allowRetries!=null){this._allowRetries=t.allowRetries}if(t.maxRetries!=null){this._maxRetries=t.maxRetries}}}options(e,a){return r(this,void 0,void 0,(function*(){return this.request("OPTIONS",e,null,a||{})}))}get(e,a){return r(this,void 0,void 0,(function*(){return this.request("GET",e,null,a||{})}))}del(e,a){return r(this,void 0,void 0,(function*(){return this.request("DELETE",e,null,a||{})}))}post(e,a,t){return r(this,void 0,void 0,(function*(){return this.request("POST",e,a,t||{})}))}patch(e,a,t){return r(this,void 0,void 0,(function*(){return this.request("PATCH",e,a,t||{})}))}put(e,a,t){return r(this,void 0,void 0,(function*(){return this.request("PUT",e,a,t||{})}))}head(e,a){return r(this,void 0,void 0,(function*(){return this.request("HEAD",e,null,a||{})}))}sendStream(e,a,t,i){return r(this,void 0,void 0,(function*(){return this.request(e,a,t,i)}))}getJson(e,a={}){return r(this,void 0,void 0,(function*(){a[u.Accept]=this._getExistingOrDefaultHeader(a,u.Accept,m.ApplicationJson);const t=yield this.get(e,a);return this._processResponse(t,this.requestOptions)}))}postJson(e,a,t={}){return r(this,void 0,void 0,(function*(){const i=JSON.stringify(a,null,2);t[u.Accept]=this._getExistingOrDefaultHeader(t,u.Accept,m.ApplicationJson);t[u.ContentType]=this._getExistingOrDefaultHeader(t,u.ContentType,m.ApplicationJson);const s=yield this.post(e,i,t);return this._processResponse(s,this.requestOptions)}))}putJson(e,a,t={}){return r(this,void 0,void 0,(function*(){const i=JSON.stringify(a,null,2);t[u.Accept]=this._getExistingOrDefaultHeader(t,u.Accept,m.ApplicationJson);t[u.ContentType]=this._getExistingOrDefaultHeader(t,u.ContentType,m.ApplicationJson);const s=yield this.put(e,i,t);return this._processResponse(s,this.requestOptions)}))}patchJson(e,a,t={}){return r(this,void 0,void 0,(function*(){const i=JSON.stringify(a,null,2);t[u.Accept]=this._getExistingOrDefaultHeader(t,u.Accept,m.ApplicationJson);t[u.ContentType]=this._getExistingOrDefaultHeader(t,u.ContentType,m.ApplicationJson);const s=yield this.patch(e,i,t);return this._processResponse(s,this.requestOptions)}))}request(e,a,t,i){return r(this,void 0,void 0,(function*(){if(this._disposed){throw new Error("Client has already been disposed.")}const s=new URL(a);let o=this._prepareRequest(e,s,i);const r=this._allowRetries&&g.includes(e)?this._maxRetries+1:1;let n=0;let p;do{p=yield this.requestRaw(o,t);if(p&&p.message&&p.message.statusCode===c.Unauthorized){let e;for(const a of this.handlers){if(a.canHandleAuthentication(p)){e=a;break}}if(e){return e.handleAuthentication(this,o,t)}else{return p}}let a=this._maxRedirects;while(p.message.statusCode&&v.includes(p.message.statusCode)&&this._allowRedirects&&a>0){const r=p.message.headers["location"];if(!r){break}const n=new URL(r);if(s.protocol==="https:"&&s.protocol!==n.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.")}yield p.readBody();if(n.hostname!==s.hostname){for(const e in i){if(e.toLowerCase()==="authorization"){delete i[e]}}}o=this._prepareRequest(e,n,i);p=yield this.requestRaw(o,t);a--}if(!p.message.statusCode||!h.includes(p.message.statusCode)){return p}n+=1;if(n{function callbackForResult(e,a){if(e){i(e)}else if(!a){i(new Error("Unknown error"))}else{t(a)}}this.requestRawWithCallback(e,a,callbackForResult)}))}))}requestRawWithCallback(e,a,t){if(typeof a==="string"){if(!e.options.headers){e.options.headers={}}e.options.headers["Content-Length"]=Buffer.byteLength(a,"utf8")}let i=false;function handleResult(e,a){if(!i){i=true;t(e,a)}}const s=e.httpModule.request(e.options,(e=>{const a=new HttpClientResponse(e);handleResult(undefined,a)}));let o;s.on("socket",(e=>{o=e}));s.setTimeout(this._socketTimeout||3*6e4,(()=>{if(o){o.end()}handleResult(new Error(`Request timeout: ${e.options.path}`))}));s.on("error",(function(e){handleResult(e)}));if(a&&typeof a==="string"){s.write(a,"utf8")}if(a&&typeof a!=="string"){a.on("close",(function(){s.end()}));a.pipe(s)}else{s.end()}}getAgent(e){const a=new URL(e);return this._getAgent(a)}_prepareRequest(e,a,t){const i={};i.parsedUrl=a;const s=i.parsedUrl.protocol==="https:";i.httpModule=s?p:n;const o=s?443:80;i.options={};i.options.host=i.parsedUrl.hostname;i.options.port=i.parsedUrl.port?parseInt(i.parsedUrl.port):o;i.options.path=(i.parsedUrl.pathname||"")+(i.parsedUrl.search||"");i.options.method=e;i.options.headers=this._mergeHeaders(t);if(this.userAgent!=null){i.options.headers["user-agent"]=this.userAgent}i.options.agent=this._getAgent(i.parsedUrl);if(this.handlers){for(const e of this.handlers){e.prepareRequest(i.options)}}return i}_mergeHeaders(e){if(this.requestOptions&&this.requestOptions.headers){return Object.assign({},lowercaseKeys(this.requestOptions.headers),lowercaseKeys(e||{}))}return lowercaseKeys(e||{})}_getExistingOrDefaultHeader(e,a,t){let i;if(this.requestOptions&&this.requestOptions.headers){i=lowercaseKeys(this.requestOptions.headers)[a]}return e[a]||i||t}_getAgent(e){let a;const t=d.getProxyUrl(e);const i=t&&t.hostname;if(this._keepAlive&&i){a=this._proxyAgent}if(this._keepAlive&&!i){a=this._agent}if(a){return a}const s=e.protocol==="https:";let o=100;if(this.requestOptions){o=this.requestOptions.maxSockets||n.globalAgent.maxSockets}if(t&&t.hostname){const e={maxSockets:o,keepAlive:this._keepAlive,proxy:Object.assign(Object.assign({},(t.username||t.password)&&{proxyAuth:`${t.username}:${t.password}`}),{host:t.hostname,port:t.port})};let i;const r=t.protocol==="https:";if(s){i=r?l.httpsOverHttps:l.httpsOverHttp}else{i=r?l.httpOverHttps:l.httpOverHttp}a=i(e);this._proxyAgent=a}if(this._keepAlive&&!a){const e={keepAlive:this._keepAlive,maxSockets:o};a=s?new p.Agent(e):new n.Agent(e);this._agent=a}if(!a){a=s?p.globalAgent:n.globalAgent}if(s&&this._ignoreSslError){a.options=Object.assign(a.options||{},{rejectUnauthorized:false})}return a}_performExponentialBackoff(e){return r(this,void 0,void 0,(function*(){e=Math.min(b,e);const a=w*Math.pow(2,e);return new Promise((e=>setTimeout((()=>e()),a)))}))}_processResponse(e,a){return r(this,void 0,void 0,(function*(){return new Promise(((t,i)=>r(this,void 0,void 0,(function*(){const s=e.message.statusCode||0;const o={statusCode:s,result:null,headers:{}};if(s===c.NotFound){t(o)}function dateTimeDeserializer(e,a){if(typeof a==="string"){const e=new Date(a);if(!isNaN(e.valueOf())){return e}}return a}let r;let n;try{n=yield e.readBody();if(n&&n.length>0){if(a&&a.deserializeDates){r=JSON.parse(n,dateTimeDeserializer)}else{r=JSON.parse(n)}o.result=r}o.headers=e.message.headers}catch(e){}if(s>299){let e;if(r&&r.message){e=r.message}else if(n&&n.length>0){e=n}else{e=`Failed request: (${s})`}const a=new HttpClientError(e,s);a.result=o.result;i(a)}else{t(o)}}))))}))}}a.HttpClient=HttpClient;const lowercaseKeys=e=>Object.keys(e).reduce(((a,t)=>(a[t.toLowerCase()]=e[t],a)),{})},9446:(e,a)=>{"use strict";Object.defineProperty(a,"__esModule",{value:true});a.checkBypass=a.getProxyUrl=void 0;function getProxyUrl(e){const a=e.protocol==="https:";if(checkBypass(e)){return undefined}const t=(()=>{if(a){return process.env["https_proxy"]||process.env["HTTPS_PROXY"]}else{return process.env["http_proxy"]||process.env["HTTP_PROXY"]}})();if(t){return new URL(t)}else{return undefined}}a.getProxyUrl=getProxyUrl;function checkBypass(e){if(!e.hostname){return false}const a=process.env["no_proxy"]||process.env["NO_PROXY"]||"";if(!a){return false}let t;if(e.port){t=Number(e.port)}else if(e.protocol==="http:"){t=80}else if(e.protocol==="https:"){t=443}const i=[e.hostname.toUpperCase()];if(typeof t==="number"){i.push(`${i[0]}:${t}`)}for(const e of a.split(",").map((e=>e.trim().toUpperCase())).filter((e=>e))){if(i.some((a=>a===e))){return true}}return false}a.checkBypass=checkBypass},9464:function(e,a,t){"use strict";var i=this&&this.__createBinding||(Object.create?function(e,a,t,i){if(i===undefined)i=t;Object.defineProperty(e,i,{enumerable:true,get:function(){return a[t]}})}:function(e,a,t,i){if(i===undefined)i=t;e[i]=a[t]});var s=this&&this.__setModuleDefault||(Object.create?function(e,a){Object.defineProperty(e,"default",{enumerable:true,value:a})}:function(e,a){e["default"]=a});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var a={};if(e!=null)for(var t in e)if(t!=="default"&&Object.hasOwnProperty.call(e,t))i(a,e,t);s(a,e);return a};var r=this&&this.__awaiter||function(e,a,t,i){function adopt(e){return e instanceof t?e:new t((function(a){a(e)}))}return new(t||(t=Promise))((function(t,s){function fulfilled(e){try{step(i.next(e))}catch(e){s(e)}}function rejected(e){try{step(i["throw"](e))}catch(e){s(e)}}function step(e){e.done?t(e.value):adopt(e.value).then(fulfilled,rejected)}step((i=i.apply(e,a||[])).next())}))};var n;Object.defineProperty(a,"__esModule",{value:true});a.getCmdPath=a.tryGetExecutablePath=a.isRooted=a.isDirectory=a.exists=a.IS_WINDOWS=a.unlink=a.symlink=a.stat=a.rmdir=a.rename=a.readlink=a.readdir=a.mkdir=a.lstat=a.copyFile=a.chmod=void 0;const p=o(t(7147));const d=o(t(1017));n=p.promises,a.chmod=n.chmod,a.copyFile=n.copyFile,a.lstat=n.lstat,a.mkdir=n.mkdir,a.readdir=n.readdir,a.readlink=n.readlink,a.rename=n.rename,a.rmdir=n.rmdir,a.stat=n.stat,a.symlink=n.symlink,a.unlink=n.unlink;a.IS_WINDOWS=process.platform==="win32";function exists(e){return r(this,void 0,void 0,(function*(){try{yield a.stat(e)}catch(e){if(e.code==="ENOENT"){return false}throw e}return true}))}a.exists=exists;function isDirectory(e,t=false){return r(this,void 0,void 0,(function*(){const i=t?yield a.stat(e):yield a.lstat(e);return i.isDirectory()}))}a.isDirectory=isDirectory;function isRooted(e){e=normalizeSeparators(e);if(!e){throw new Error('isRooted() parameter "p" cannot be empty')}if(a.IS_WINDOWS){return e.startsWith("\\")||/^[A-Z]:/i.test(e)}return e.startsWith("/")}a.isRooted=isRooted;function tryGetExecutablePath(e,t){return r(this,void 0,void 0,(function*(){let i=undefined;try{i=yield a.stat(e)}catch(a){if(a.code!=="ENOENT"){console.log(`Unexpected error attempting to determine if executable file exists '${e}': ${a}`)}}if(i&&i.isFile()){if(a.IS_WINDOWS){const a=d.extname(e).toUpperCase();if(t.some((e=>e.toUpperCase()===a))){return e}}else{if(isUnixExecutable(i)){return e}}}const s=e;for(const o of t){e=s+o;i=undefined;try{i=yield a.stat(e)}catch(a){if(a.code!=="ENOENT"){console.log(`Unexpected error attempting to determine if executable file exists '${e}': ${a}`)}}if(i&&i.isFile()){if(a.IS_WINDOWS){try{const t=d.dirname(e);const i=d.basename(e).toUpperCase();for(const s of yield a.readdir(t)){if(i===s.toUpperCase()){e=d.join(t,s);break}}}catch(a){console.log(`Unexpected error attempting to determine the actual case of the file '${e}': ${a}`)}return e}else{if(isUnixExecutable(i)){return e}}}}return""}))}a.tryGetExecutablePath=tryGetExecutablePath;function normalizeSeparators(e){e=e||"";if(a.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`}a.getCmdPath=getCmdPath},8071:function(e,a,t){"use strict";var i=this&&this.__createBinding||(Object.create?function(e,a,t,i){if(i===undefined)i=t;Object.defineProperty(e,i,{enumerable:true,get:function(){return a[t]}})}:function(e,a,t,i){if(i===undefined)i=t;e[i]=a[t]});var s=this&&this.__setModuleDefault||(Object.create?function(e,a){Object.defineProperty(e,"default",{enumerable:true,value:a})}:function(e,a){e["default"]=a});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var a={};if(e!=null)for(var t in e)if(t!=="default"&&Object.hasOwnProperty.call(e,t))i(a,e,t);s(a,e);return a};var r=this&&this.__awaiter||function(e,a,t,i){function adopt(e){return e instanceof t?e:new t((function(a){a(e)}))}return new(t||(t=Promise))((function(t,s){function fulfilled(e){try{step(i.next(e))}catch(e){s(e)}}function rejected(e){try{step(i["throw"](e))}catch(e){s(e)}}function step(e){e.done?t(e.value):adopt(e.value).then(fulfilled,rejected)}step((i=i.apply(e,a||[])).next())}))};Object.defineProperty(a,"__esModule",{value:true});a.findInPath=a.which=a.mkdirP=a.rmRF=a.mv=a.cp=void 0;const n=t(9491);const p=o(t(2081));const d=o(t(1017));const l=t(3837);const c=o(t(9464));const u=l.promisify(p.exec);const m=l.promisify(p.execFile);function cp(e,a,t={}){return r(this,void 0,void 0,(function*(){const{force:i,recursive:s,copySourceDirectory:o}=readCopyOptions(t);const r=(yield c.exists(a))?yield c.stat(a):null;if(r&&r.isFile()&&!i){return}const n=r&&r.isDirectory()&&o?d.join(a,d.basename(e)):a;if(!(yield c.exists(e))){throw new Error(`no such file or directory: ${e}`)}const p=yield c.stat(e);if(p.isDirectory()){if(!s){throw new Error(`Failed to copy. ${e} is a directory, but tried to copy without recursive flag.`)}else{yield cpDirRecursive(e,n,0,i)}}else{if(d.relative(e,n)===""){throw new Error(`'${n}' and '${e}' are the same file`)}yield copyFile(e,n,i)}}))}a.cp=cp;function mv(e,a,t={}){return r(this,void 0,void 0,(function*(){if(yield c.exists(a)){let i=true;if(yield c.isDirectory(a)){a=d.join(a,d.basename(e));i=yield c.exists(a)}if(i){if(t.force==null||t.force){yield rmRF(a)}else{throw new Error("Destination already exists")}}}yield mkdirP(d.dirname(a));yield c.rename(e,a)}))}a.mv=mv;function rmRF(e){return r(this,void 0,void 0,(function*(){if(c.IS_WINDOWS){if(/[*"<>|]/.test(e)){throw new Error('File path must not contain `*`, `"`, `<`, `>` or `|` on Windows')}try{const a=c.getCmdPath();if(yield c.isDirectory(e,true)){yield u(`${a} /s /c "rd /s /q "%inputPath%""`,{env:{inputPath:e}})}else{yield u(`${a} /s /c "del /f /a "%inputPath%""`,{env:{inputPath:e}})}}catch(e){if(e.code!=="ENOENT")throw e}try{yield c.unlink(e)}catch(e){if(e.code!=="ENOENT")throw e}}else{let a=false;try{a=yield c.isDirectory(e)}catch(e){if(e.code!=="ENOENT")throw e;return}if(a){yield m(`rm`,[`-rf`,`${e}`])}else{yield c.unlink(e)}}}))}a.rmRF=rmRF;function mkdirP(e){return r(this,void 0,void 0,(function*(){n.ok(e,"a path argument must be provided");yield c.mkdir(e,{recursive:true})}))}a.mkdirP=mkdirP;function which(e,a){return r(this,void 0,void 0,(function*(){if(!e){throw new Error("parameter 'tool' is required")}if(a){const a=yield which(e,false);if(!a){if(c.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 a}const t=yield findInPath(e);if(t&&t.length>0){return t[0]}return""}))}a.which=which;function findInPath(e){return r(this,void 0,void 0,(function*(){if(!e){throw new Error("parameter 'tool' is required")}const a=[];if(c.IS_WINDOWS&&process.env["PATHEXT"]){for(const e of process.env["PATHEXT"].split(d.delimiter)){if(e){a.push(e)}}}if(c.isRooted(e)){const t=yield c.tryGetExecutablePath(e,a);if(t){return[t]}return[]}if(e.includes(d.sep)){return[]}const t=[];if(process.env.PATH){for(const e of process.env.PATH.split(d.delimiter)){if(e){t.push(e)}}}const i=[];for(const s of t){const t=yield c.tryGetExecutablePath(d.join(s,e),a);if(t){i.push(t)}}return i}))}a.findInPath=findInPath;function readCopyOptions(e){const a=e.force==null?true:e.force;const t=Boolean(e.recursive);const i=e.copySourceDirectory==null?true:Boolean(e.copySourceDirectory);return{force:a,recursive:t,copySourceDirectory:i}}function cpDirRecursive(e,a,t,i){return r(this,void 0,void 0,(function*(){if(t>=255)return;t++;yield mkdirP(a);const s=yield c.readdir(e);for(const o of s){const s=`${e}/${o}`;const r=`${a}/${o}`;const n=yield c.lstat(s);if(n.isDirectory()){yield cpDirRecursive(s,r,t,i)}else{yield copyFile(s,r,i)}}yield c.chmod(a,(yield c.stat(e)).mode)}))}function copyFile(e,a,t){return r(this,void 0,void 0,(function*(){if((yield c.lstat(e)).isSymbolicLink()){try{yield c.lstat(a);yield c.unlink(a)}catch(e){if(e.code==="EPERM"){yield c.chmod(a,"0666");yield c.unlink(a)}}const t=yield c.readlink(e);yield c.symlink(t,a,c.IS_WINDOWS?"junction":null)}else if(!(yield c.exists(a))||t){yield c.copyFile(e,a)}}))}},5983:(e,a)=>{"use strict";Object.defineProperty(a,"__esModule",{value:true});const t=/^v1\./;const i=/^ghs_/;const s=/^ghu_/;async function auth(e){const a=e.split(/\./).length===3;const o=t.test(e)||i.test(e);const r=s.test(e);const n=a?"app":o?"installation":r?"user-to-server":"oauth";return{type:"token",token:e,tokenType:n}}function withAuthorizationPrefix(e){if(e.split(/\./).length===3){return`bearer ${e}`}return`token ${e}`}async function hook(e,a,t,i){const s=a.endpoint.merge(t,i);s.headers.authorization=withAuthorizationPrefix(e);return a(s)}const o=function createTokenAuth(e){if(!e){throw new Error("[@octokit/auth-token] No token passed to createTokenAuth")}if(typeof e!=="string"){throw new Error("[@octokit/auth-token] Token passed to createTokenAuth is not a string")}e=e.replace(/^(token|bearer) +/i,"");return Object.assign(auth.bind(null,e),{hook:hook.bind(null,e)})};a.createTokenAuth=o},1241:(e,a,t)=>{"use strict";Object.defineProperty(a,"__esModule",{value:true});var i=t(499);var s=t(9591);var o=t(7201);var r=t(6320);var n=t(5983);function _objectWithoutPropertiesLoose(e,a){if(e==null)return{};var t={};var i=Object.keys(e);var s,o;for(o=0;o=0)continue;t[s]=e[s]}return t}function _objectWithoutProperties(e,a){if(e==null)return{};var t=_objectWithoutPropertiesLoose(e,a);var i,s;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(s=0;s=0)continue;if(!Object.prototype.propertyIsEnumerable.call(e,i))continue;t[i]=e[i]}}return t}const p="3.6.0";const d=["authStrategy"];class Octokit{constructor(e={}){const a=new s.Collection;const t={baseUrl:o.request.endpoint.DEFAULTS.baseUrl,headers:{},request:Object.assign({},e.request,{hook:a.bind(null,"request")}),mediaType:{previews:[],format:""}};t.headers["user-agent"]=[e.userAgent,`octokit-core.js/${p} ${i.getUserAgent()}`].filter(Boolean).join(" ");if(e.baseUrl){t.baseUrl=e.baseUrl}if(e.previews){t.mediaType.previews=e.previews}if(e.timeZone){t.headers["time-zone"]=e.timeZone}this.request=o.request.defaults(t);this.graphql=r.withCustomRequest(this.request).defaults(t);this.log=Object.assign({debug:()=>{},info:()=>{},warn:console.warn.bind(console),error:console.error.bind(console)},e.log);this.hook=a;if(!e.authStrategy){if(!e.auth){this.auth=async()=>({type:"unauthenticated"})}else{const t=n.createTokenAuth(e.auth);a.wrap("request",t.hook);this.auth=t}}else{const{authStrategy:t}=e,i=_objectWithoutProperties(e,d);const s=t(Object.assign({request:this.request,log:this.log,octokit:this,octokitOptions:i},e.auth));a.wrap("request",s.hook);this.auth=s}const l=this.constructor;l.plugins.forEach((a=>{Object.assign(this,a(this,e))}))}static defaults(e){const a=class extends(this){constructor(...a){const t=a[0]||{};if(typeof e==="function"){super(e(t));return}super(Object.assign({},e,t,t.userAgent&&e.userAgent?{userAgent:`${t.userAgent} ${e.userAgent}`}:null))}};return a}static plugin(...e){var a;const t=this.plugins;const i=(a=class extends(this){},a.plugins=t.concat(e.filter((e=>!t.includes(e)))),a);return i}}Octokit.VERSION=p;Octokit.plugins=[];a.Octokit=Octokit},955:(e,a,t)=>{"use strict";Object.defineProperty(a,"__esModule",{value:true});var i=t(1410);var s=t(499);function lowercaseKeys(e){if(!e){return{}}return Object.keys(e).reduce(((a,t)=>{a[t.toLowerCase()]=e[t];return a}),{})}function mergeDeep(e,a){const t=Object.assign({},e);Object.keys(a).forEach((s=>{if(i.isPlainObject(a[s])){if(!(s in e))Object.assign(t,{[s]:a[s]});else t[s]=mergeDeep(e[s],a[s])}else{Object.assign(t,{[s]:a[s]})}}));return t}function removeUndefinedProperties(e){for(const a in e){if(e[a]===undefined){delete e[a]}}return e}function merge(e,a,t){if(typeof a==="string"){let[e,i]=a.split(" ");t=Object.assign(i?{method:e,url:i}:{url:e},t)}else{t=Object.assign({},a)}t.headers=lowercaseKeys(t.headers);removeUndefinedProperties(t);removeUndefinedProperties(t.headers);const i=mergeDeep(e||{},t);if(e&&e.mediaType.previews.length){i.mediaType.previews=e.mediaType.previews.filter((e=>!i.mediaType.previews.includes(e))).concat(i.mediaType.previews)}i.mediaType.previews=i.mediaType.previews.map((e=>e.replace(/-preview/,"")));return i}function addQueryParameters(e,a){const t=/\?/.test(e)?"&":"?";const i=Object.keys(a);if(i.length===0){return e}return e+t+i.map((e=>{if(e==="q"){return"q="+a.q.split("+").map(encodeURIComponent).join("+")}return`${e}=${encodeURIComponent(a[e])}`})).join("&")}const o=/\{[^}]+\}/g;function removeNonChars(e){return e.replace(/^\W+|\W+$/g,"").split(/,/)}function extractUrlVariableNames(e){const a=e.match(o);if(!a){return[]}return a.map(removeNonChars).reduce(((e,a)=>e.concat(a)),[])}function omit(e,a){return Object.keys(e).filter((e=>!a.includes(e))).reduce(((a,t)=>{a[t]=e[t];return a}),{})}function encodeReserved(e){return e.split(/(%[0-9A-Fa-f]{2})/g).map((function(e){if(!/%[0-9A-Fa-f]/.test(e)){e=encodeURI(e).replace(/%5B/g,"[").replace(/%5D/g,"]")}return e})).join("")}function encodeUnreserved(e){return encodeURIComponent(e).replace(/[!'()*]/g,(function(e){return"%"+e.charCodeAt(0).toString(16).toUpperCase()}))}function encodeValue(e,a,t){a=e==="+"||e==="#"?encodeReserved(a):encodeUnreserved(a);if(t){return encodeUnreserved(t)+"="+a}else{return a}}function isDefined(e){return e!==undefined&&e!==null}function isKeyOperator(e){return e===";"||e==="&"||e==="?"}function getValues(e,a,t,i){var s=e[t],o=[];if(isDefined(s)&&s!==""){if(typeof s==="string"||typeof s==="number"||typeof s==="boolean"){s=s.toString();if(i&&i!=="*"){s=s.substring(0,parseInt(i,10))}o.push(encodeValue(a,s,isKeyOperator(a)?t:""))}else{if(i==="*"){if(Array.isArray(s)){s.filter(isDefined).forEach((function(e){o.push(encodeValue(a,e,isKeyOperator(a)?t:""))}))}else{Object.keys(s).forEach((function(e){if(isDefined(s[e])){o.push(encodeValue(a,s[e],e))}}))}}else{const e=[];if(Array.isArray(s)){s.filter(isDefined).forEach((function(t){e.push(encodeValue(a,t))}))}else{Object.keys(s).forEach((function(t){if(isDefined(s[t])){e.push(encodeUnreserved(t));e.push(encodeValue(a,s[t].toString()))}}))}if(isKeyOperator(a)){o.push(encodeUnreserved(t)+"="+e.join(","))}else if(e.length!==0){o.push(e.join(","))}}}}else{if(a===";"){if(isDefined(s)){o.push(encodeUnreserved(t))}}else if(s===""&&(a==="&"||a==="?")){o.push(encodeUnreserved(t)+"=")}else if(s===""){o.push("")}}return o}function parseUrl(e){return{expand:expand.bind(null,e)}}function expand(e,a){var t=["+","#",".","/",";","?","&"];return e.replace(/\{([^\{\}]+)\}|([^\{\}]+)/g,(function(e,i,s){if(i){let e="";const s=[];if(t.indexOf(i.charAt(0))!==-1){e=i.charAt(0);i=i.substr(1)}i.split(/,/g).forEach((function(t){var i=/([^:\*]*)(?::(\d+)|(\*))?/.exec(t);s.push(getValues(a,e,i[1],i[2]||i[3]))}));if(e&&e!=="+"){var o=",";if(e==="?"){o="&"}else if(e!=="#"){o=e}return(s.length!==0?e:"")+s.join(o)}else{return s.join(",")}}else{return encodeReserved(s)}}))}function parse(e){let a=e.method.toUpperCase();let t=(e.url||"/").replace(/:([a-z]\w+)/g,"{$1}");let i=Object.assign({},e.headers);let s;let o=omit(e,["method","baseUrl","url","headers","request","mediaType"]);const r=extractUrlVariableNames(t);t=parseUrl(t).expand(o);if(!/^http/.test(t)){t=e.baseUrl+t}const n=Object.keys(e).filter((e=>r.includes(e))).concat("baseUrl");const p=omit(o,n);const d=/application\/octet-stream/i.test(i.accept);if(!d){if(e.mediaType.format){i.accept=i.accept.split(/,/).map((a=>a.replace(/application\/vnd(\.\w+)(\.v3)?(\.\w+)?(\+json)?$/,`application/vnd$1$2.${e.mediaType.format}`))).join(",")}if(e.mediaType.previews.length){const a=i.accept.match(/[\w-]+(?=-preview)/g)||[];i.accept=a.concat(e.mediaType.previews).map((a=>{const t=e.mediaType.format?`.${e.mediaType.format}`:"+json";return`application/vnd.github.${a}-preview${t}`})).join(",")}}if(["GET","HEAD"].includes(a)){t=addQueryParameters(t,p)}else{if("data"in p){s=p.data}else{if(Object.keys(p).length){s=p}else{i["content-length"]=0}}}if(!i["content-type"]&&typeof s!=="undefined"){i["content-type"]="application/json; charset=utf-8"}if(["PATCH","PUT"].includes(a)&&typeof s==="undefined"){s=""}return Object.assign({method:a,url:t,headers:i},typeof s!=="undefined"?{body:s}:null,e.request?{request:e.request}:null)}function endpointWithDefaults(e,a,t){return parse(merge(e,a,t))}function withDefaults(e,a){const t=merge(e,a);const i=endpointWithDefaults.bind(null,t);return Object.assign(i,{DEFAULTS:t,defaults:withDefaults.bind(null,t),merge:merge.bind(null,t),parse:parse})}const r="6.0.12";const n=`octokit-endpoint.js/${r} ${s.getUserAgent()}`;const p={method:"GET",baseUrl:"https://api.github.com",headers:{accept:"application/vnd.github.v3+json","user-agent":n},mediaType:{format:"",previews:[]}};const d=withDefaults(null,p);a.endpoint=d},6320:(e,a,t)=>{"use strict";Object.defineProperty(a,"__esModule",{value:true});var i=t(7201);var s=t(499);const o="4.8.0";function _buildMessageForResponseErrors(e){return`Request failed due to following response errors:\n`+e.errors.map((e=>` - ${e.message}`)).join("\n")}class GraphqlResponseError extends Error{constructor(e,a,t){super(_buildMessageForResponseErrors(t));this.request=e;this.headers=a;this.response=t;this.name="GraphqlResponseError";this.errors=t.errors;this.data=t.data;if(Error.captureStackTrace){Error.captureStackTrace(this,this.constructor)}}}const r=["method","baseUrl","url","headers","request","query","mediaType"];const n=["query","method","url"];const p=/\/api\/v3\/?$/;function graphql(e,a,t){if(t){if(typeof a==="string"&&"query"in t){return Promise.reject(new Error(`[@octokit/graphql] "query" cannot be used as variable name`))}for(const e in t){if(!n.includes(e))continue;return Promise.reject(new Error(`[@octokit/graphql] "${e}" cannot be used as variable name`))}}const i=typeof a==="string"?Object.assign({query:a},t):a;const s=Object.keys(i).reduce(((e,a)=>{if(r.includes(a)){e[a]=i[a];return e}if(!e.variables){e.variables={}}e.variables[a]=i[a];return e}),{});const o=i.baseUrl||e.endpoint.DEFAULTS.baseUrl;if(p.test(o)){s.url=o.replace(p,"/api/graphql")}return e(s).then((e=>{if(e.data.errors){const a={};for(const t of Object.keys(e.headers)){a[t]=e.headers[t]}throw new GraphqlResponseError(s,a,e.data)}return e.data.data}))}function withDefaults(e,a){const t=e.defaults(a);const newApi=(e,a)=>graphql(t,e,a);return Object.assign(newApi,{defaults:withDefaults.bind(null,t),endpoint:i.request.endpoint})}const d=withDefaults(i.request,{headers:{"user-agent":`octokit-graphql.js/${o} ${s.getUserAgent()}`},method:"POST",url:"/graphql"});function withCustomRequest(e){return withDefaults(e,{method:"POST",url:"/graphql"})}a.GraphqlResponseError=GraphqlResponseError;a.graphql=d;a.withCustomRequest=withCustomRequest},8469:(e,a)=>{"use strict";Object.defineProperty(a,"__esModule",{value:true});const t="2.21.3";function ownKeys(e,a){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);a&&(i=i.filter((function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable}))),t.push.apply(t,i)}return t}function _objectSpread2(e){for(var a=1;a({async next(){if(!n)return{done:true};try{const e=await s({method:o,url:n,headers:r});const a=normalizePaginatedListResponse(e);n=((a.headers.link||"").match(/<([^>]+)>;\s*rel="next"/)||[])[1];return{value:a}}catch(e){if(e.status!==409)throw e;n="";return{value:{status:200,headers:{},data:[]}}}}})}}function paginate(e,a,t,i){if(typeof t==="function"){i=t;t=undefined}return gather(e,[],iterator(e,a,t)[Symbol.asyncIterator](),i)}function gather(e,a,t,i){return t.next().then((s=>{if(s.done){return a}let o=false;function done(){o=true}a=a.concat(i?i(s.value,done):s.value.data);if(o){return a}return gather(e,a,t,i)}))}const i=Object.assign(paginate,{iterator:iterator});const s=["GET /app/hook/deliveries","GET /app/installations","GET /applications/grants","GET /authorizations","GET /enterprises/{enterprise}/actions/permissions/organizations","GET /enterprises/{enterprise}/actions/runner-groups","GET /enterprises/{enterprise}/actions/runner-groups/{runner_group_id}/organizations","GET /enterprises/{enterprise}/actions/runner-groups/{runner_group_id}/runners","GET /enterprises/{enterprise}/actions/runners","GET /enterprises/{enterprise}/audit-log","GET /enterprises/{enterprise}/secret-scanning/alerts","GET /enterprises/{enterprise}/settings/billing/advanced-security","GET /events","GET /gists","GET /gists/public","GET /gists/starred","GET /gists/{gist_id}/comments","GET /gists/{gist_id}/commits","GET /gists/{gist_id}/forks","GET /installation/repositories","GET /issues","GET /licenses","GET /marketplace_listing/plans","GET /marketplace_listing/plans/{plan_id}/accounts","GET /marketplace_listing/stubbed/plans","GET /marketplace_listing/stubbed/plans/{plan_id}/accounts","GET /networks/{owner}/{repo}/events","GET /notifications","GET /organizations","GET /orgs/{org}/actions/cache/usage-by-repository","GET /orgs/{org}/actions/permissions/repositories","GET /orgs/{org}/actions/runner-groups","GET /orgs/{org}/actions/runner-groups/{runner_group_id}/repositories","GET /orgs/{org}/actions/runner-groups/{runner_group_id}/runners","GET /orgs/{org}/actions/runners","GET /orgs/{org}/actions/secrets","GET /orgs/{org}/actions/secrets/{secret_name}/repositories","GET /orgs/{org}/audit-log","GET /orgs/{org}/blocks","GET /orgs/{org}/code-scanning/alerts","GET /orgs/{org}/codespaces","GET /orgs/{org}/credential-authorizations","GET /orgs/{org}/dependabot/secrets","GET /orgs/{org}/dependabot/secrets/{secret_name}/repositories","GET /orgs/{org}/events","GET /orgs/{org}/external-groups","GET /orgs/{org}/failed_invitations","GET /orgs/{org}/hooks","GET /orgs/{org}/hooks/{hook_id}/deliveries","GET /orgs/{org}/installations","GET /orgs/{org}/invitations","GET /orgs/{org}/invitations/{invitation_id}/teams","GET /orgs/{org}/issues","GET /orgs/{org}/members","GET /orgs/{org}/migrations","GET /orgs/{org}/migrations/{migration_id}/repositories","GET /orgs/{org}/outside_collaborators","GET /orgs/{org}/packages","GET /orgs/{org}/packages/{package_type}/{package_name}/versions","GET /orgs/{org}/projects","GET /orgs/{org}/public_members","GET /orgs/{org}/repos","GET /orgs/{org}/secret-scanning/alerts","GET /orgs/{org}/settings/billing/advanced-security","GET /orgs/{org}/team-sync/groups","GET /orgs/{org}/teams","GET /orgs/{org}/teams/{team_slug}/discussions","GET /orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/comments","GET /orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/comments/{comment_number}/reactions","GET /orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/reactions","GET /orgs/{org}/teams/{team_slug}/invitations","GET /orgs/{org}/teams/{team_slug}/members","GET /orgs/{org}/teams/{team_slug}/projects","GET /orgs/{org}/teams/{team_slug}/repos","GET /orgs/{org}/teams/{team_slug}/teams","GET /projects/columns/{column_id}/cards","GET /projects/{project_id}/collaborators","GET /projects/{project_id}/columns","GET /repos/{owner}/{repo}/actions/artifacts","GET /repos/{owner}/{repo}/actions/caches","GET /repos/{owner}/{repo}/actions/runners","GET /repos/{owner}/{repo}/actions/runs","GET /repos/{owner}/{repo}/actions/runs/{run_id}/artifacts","GET /repos/{owner}/{repo}/actions/runs/{run_id}/attempts/{attempt_number}/jobs","GET /repos/{owner}/{repo}/actions/runs/{run_id}/jobs","GET /repos/{owner}/{repo}/actions/secrets","GET /repos/{owner}/{repo}/actions/workflows","GET /repos/{owner}/{repo}/actions/workflows/{workflow_id}/runs","GET /repos/{owner}/{repo}/assignees","GET /repos/{owner}/{repo}/branches","GET /repos/{owner}/{repo}/check-runs/{check_run_id}/annotations","GET /repos/{owner}/{repo}/check-suites/{check_suite_id}/check-runs","GET /repos/{owner}/{repo}/code-scanning/alerts","GET /repos/{owner}/{repo}/code-scanning/alerts/{alert_number}/instances","GET /repos/{owner}/{repo}/code-scanning/analyses","GET /repos/{owner}/{repo}/codespaces","GET /repos/{owner}/{repo}/codespaces/devcontainers","GET /repos/{owner}/{repo}/codespaces/secrets","GET /repos/{owner}/{repo}/collaborators","GET /repos/{owner}/{repo}/comments","GET /repos/{owner}/{repo}/comments/{comment_id}/reactions","GET /repos/{owner}/{repo}/commits","GET /repos/{owner}/{repo}/commits/{commit_sha}/comments","GET /repos/{owner}/{repo}/commits/{commit_sha}/pulls","GET /repos/{owner}/{repo}/commits/{ref}/check-runs","GET /repos/{owner}/{repo}/commits/{ref}/check-suites","GET /repos/{owner}/{repo}/commits/{ref}/status","GET /repos/{owner}/{repo}/commits/{ref}/statuses","GET /repos/{owner}/{repo}/contributors","GET /repos/{owner}/{repo}/dependabot/secrets","GET /repos/{owner}/{repo}/deployments","GET /repos/{owner}/{repo}/deployments/{deployment_id}/statuses","GET /repos/{owner}/{repo}/environments","GET /repos/{owner}/{repo}/events","GET /repos/{owner}/{repo}/forks","GET /repos/{owner}/{repo}/git/matching-refs/{ref}","GET /repos/{owner}/{repo}/hooks","GET /repos/{owner}/{repo}/hooks/{hook_id}/deliveries","GET /repos/{owner}/{repo}/invitations","GET /repos/{owner}/{repo}/issues","GET /repos/{owner}/{repo}/issues/comments","GET /repos/{owner}/{repo}/issues/comments/{comment_id}/reactions","GET /repos/{owner}/{repo}/issues/events","GET /repos/{owner}/{repo}/issues/{issue_number}/comments","GET /repos/{owner}/{repo}/issues/{issue_number}/events","GET /repos/{owner}/{repo}/issues/{issue_number}/labels","GET /repos/{owner}/{repo}/issues/{issue_number}/reactions","GET /repos/{owner}/{repo}/issues/{issue_number}/timeline","GET /repos/{owner}/{repo}/keys","GET /repos/{owner}/{repo}/labels","GET /repos/{owner}/{repo}/milestones","GET /repos/{owner}/{repo}/milestones/{milestone_number}/labels","GET /repos/{owner}/{repo}/notifications","GET /repos/{owner}/{repo}/pages/builds","GET /repos/{owner}/{repo}/projects","GET /repos/{owner}/{repo}/pulls","GET /repos/{owner}/{repo}/pulls/comments","GET /repos/{owner}/{repo}/pulls/comments/{comment_id}/reactions","GET /repos/{owner}/{repo}/pulls/{pull_number}/comments","GET /repos/{owner}/{repo}/pulls/{pull_number}/commits","GET /repos/{owner}/{repo}/pulls/{pull_number}/files","GET /repos/{owner}/{repo}/pulls/{pull_number}/requested_reviewers","GET /repos/{owner}/{repo}/pulls/{pull_number}/reviews","GET /repos/{owner}/{repo}/pulls/{pull_number}/reviews/{review_id}/comments","GET /repos/{owner}/{repo}/releases","GET /repos/{owner}/{repo}/releases/{release_id}/assets","GET /repos/{owner}/{repo}/releases/{release_id}/reactions","GET /repos/{owner}/{repo}/secret-scanning/alerts","GET /repos/{owner}/{repo}/secret-scanning/alerts/{alert_number}/locations","GET /repos/{owner}/{repo}/stargazers","GET /repos/{owner}/{repo}/subscribers","GET /repos/{owner}/{repo}/tags","GET /repos/{owner}/{repo}/teams","GET /repos/{owner}/{repo}/topics","GET /repositories","GET /repositories/{repository_id}/environments/{environment_name}/secrets","GET /search/code","GET /search/commits","GET /search/issues","GET /search/labels","GET /search/repositories","GET /search/topics","GET /search/users","GET /teams/{team_id}/discussions","GET /teams/{team_id}/discussions/{discussion_number}/comments","GET /teams/{team_id}/discussions/{discussion_number}/comments/{comment_number}/reactions","GET /teams/{team_id}/discussions/{discussion_number}/reactions","GET /teams/{team_id}/invitations","GET /teams/{team_id}/members","GET /teams/{team_id}/projects","GET /teams/{team_id}/repos","GET /teams/{team_id}/teams","GET /user/blocks","GET /user/codespaces","GET /user/codespaces/secrets","GET /user/emails","GET /user/followers","GET /user/following","GET /user/gpg_keys","GET /user/installations","GET /user/installations/{installation_id}/repositories","GET /user/issues","GET /user/keys","GET /user/marketplace_purchases","GET /user/marketplace_purchases/stubbed","GET /user/memberships/orgs","GET /user/migrations","GET /user/migrations/{migration_id}/repositories","GET /user/orgs","GET /user/packages","GET /user/packages/{package_type}/{package_name}/versions","GET /user/public_emails","GET /user/repos","GET /user/repository_invitations","GET /user/starred","GET /user/subscriptions","GET /user/teams","GET /users","GET /users/{username}/events","GET /users/{username}/events/orgs/{org}","GET /users/{username}/events/public","GET /users/{username}/followers","GET /users/{username}/following","GET /users/{username}/gists","GET /users/{username}/gpg_keys","GET /users/{username}/keys","GET /users/{username}/orgs","GET /users/{username}/packages","GET /users/{username}/projects","GET /users/{username}/received_events","GET /users/{username}/received_events/public","GET /users/{username}/repos","GET /users/{username}/starred","GET /users/{username}/subscriptions"];function isPaginatingEndpoint(e){if(typeof e==="string"){return s.includes(e)}else{return false}}function paginateRest(e){return{paginate:Object.assign(paginate.bind(null,e),{iterator:iterator.bind(null,e)})}}paginateRest.VERSION=t;a.composePaginateRest=i;a.isPaginatingEndpoint=isPaginatingEndpoint;a.paginateRest=paginateRest;a.paginatingEndpoints=s},1114:(e,a)=>{"use strict";Object.defineProperty(a,"__esModule",{value:true});function ownKeys(e,a){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);if(a){i=i.filter((function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable}))}t.push.apply(t,i)}return t}function _objectSpread2(e){for(var a=1;a{"use strict";Object.defineProperty(a,"__esModule",{value:true});function _interopDefault(e){return e&&typeof e==="object"&&"default"in e?e["default"]:e}var i=t(718);var s=_interopDefault(t(3197));const o=s((e=>console.warn(e)));const r=s((e=>console.warn(e)));class RequestError extends Error{constructor(e,a,t){super(e);if(Error.captureStackTrace){Error.captureStackTrace(this,this.constructor)}this.name="HttpError";this.status=a;let s;if("headers"in t&&typeof t.headers!=="undefined"){s=t.headers}if("response"in t){this.response=t.response;s=t.response.headers}const n=Object.assign({},t.request);if(t.request.headers.authorization){n.headers=Object.assign({},t.request.headers,{authorization:t.request.headers.authorization.replace(/ .*$/," [REDACTED]")})}n.url=n.url.replace(/\bclient_secret=\w+/g,"client_secret=[REDACTED]").replace(/\baccess_token=\w+/g,"access_token=[REDACTED]");this.request=n;Object.defineProperty(this,"code",{get(){o(new i.Deprecation("[@octokit/request-error] `error.code` is deprecated, use `error.status`."));return a}});Object.defineProperty(this,"headers",{get(){r(new i.Deprecation("[@octokit/request-error] `error.headers` is deprecated, use `error.response.headers`."));return s||{}}})}}a.RequestError=RequestError},7201:(e,a,t)=>{"use strict";Object.defineProperty(a,"__esModule",{value:true});function _interopDefault(e){return e&&typeof e==="object"&&"default"in e?e["default"]:e}var i=t(955);var s=t(499);var o=t(1410);var r=_interopDefault(t(9681));var n=t(8829);const p="5.6.3";function getBufferResponse(e){return e.arrayBuffer()}function fetchWrapper(e){const a=e.request&&e.request.log?e.request.log:console;if(o.isPlainObject(e.body)||Array.isArray(e.body)){e.body=JSON.stringify(e.body)}let t={};let i;let s;const p=e.request&&e.request.fetch||r;return p(e.url,Object.assign({method:e.method,body:e.body,headers:e.headers,redirect:e.redirect},e.request)).then((async o=>{s=o.url;i=o.status;for(const e of o.headers){t[e[0]]=e[1]}if("deprecation"in t){const i=t.link&&t.link.match(/<([^>]+)>; rel="deprecation"/);const s=i&&i.pop();a.warn(`[@octokit/request] "${e.method} ${e.url}" is deprecated. It is scheduled to be removed on ${t.sunset}${s?`. See ${s}`:""}`)}if(i===204||i===205){return}if(e.method==="HEAD"){if(i<400){return}throw new n.RequestError(o.statusText,i,{response:{url:s,status:i,headers:t,data:undefined},request:e})}if(i===304){throw new n.RequestError("Not modified",i,{response:{url:s,status:i,headers:t,data:await getResponseData(o)},request:e})}if(i>=400){const a=await getResponseData(o);const r=new n.RequestError(toErrorMessage(a),i,{response:{url:s,status:i,headers:t,data:a},request:e});throw r}return getResponseData(o)})).then((e=>({status:i,url:s,headers:t,data:e}))).catch((a=>{if(a instanceof n.RequestError)throw a;throw new n.RequestError(a.message,500,{request:e})}))}async function getResponseData(e){const a=e.headers.get("content-type");if(/application\/json/.test(a)){return e.json()}if(!a||/^text\/|charset=utf-8$/.test(a)){return e.text()}return getBufferResponse(e)}function toErrorMessage(e){if(typeof e==="string")return e;if("message"in e){if(Array.isArray(e.errors)){return`${e.message}: ${e.errors.map(JSON.stringify).join(", ")}`}return e.message}return`Unknown error: ${JSON.stringify(e)}`}function withDefaults(e,a){const t=e.defaults(a);const newApi=function(e,a){const i=t.merge(e,a);if(!i.request||!i.request.hook){return fetchWrapper(t.parse(i))}const request=(e,a)=>fetchWrapper(t.parse(t.merge(e,a)));Object.assign(request,{endpoint:t,defaults:withDefaults.bind(null,t)});return i.request.hook(request,i)};return Object.assign(newApi,{endpoint:t,defaults:withDefaults.bind(null,t)})}const d=withDefaults(i.endpoint,{headers:{"user-agent":`octokit-request.js/${p} ${s.getUserAgent()}`}});a.request=d},7758:(e,a,t)=>{e.exports={parallel:t(9342),serial:t(3741),serialOrdered:t(3637)}},4931:e=>{e.exports=abort;function abort(e){Object.keys(e.jobs).forEach(clean.bind(e));e.jobs={}}function clean(e){if(typeof this.jobs[e]=="function"){this.jobs[e]()}}},9645:(e,a,t)=>{var i=t(3218);e.exports=async;function async(e){var a=false;i((function(){a=true}));return function async_callback(t,s){if(a){e(t,s)}else{i((function nextTick_callback(){e(t,s)}))}}}},3218:e=>{e.exports=defer;function defer(e){var a=typeof setImmediate=="function"?setImmediate:typeof process=="object"&&typeof process.nextTick=="function"?process.nextTick:null;if(a){a(e)}else{setTimeout(e,0)}}},4447:(e,a,t)=>{var i=t(9645),s=t(4931);e.exports=iterate;function iterate(e,a,t,i){var o=t["keyedList"]?t["keyedList"][t.index]:t.index;t.jobs[o]=runJob(a,o,e[o],(function(e,a){if(!(o in t.jobs)){return}delete t.jobs[o];if(e){s(t)}else{t.results[o]=a}i(e,t.results)}))}function runJob(e,a,t,s){var o;if(e.length==2){o=e(t,i(s))}else{o=e(t,a,i(s))}return o}},6156:e=>{e.exports=state;function state(e,a){var t=!Array.isArray(e),i={index:0,keyedList:t||a?Object.keys(e):null,jobs:{},results:t?{}:[],size:t?Object.keys(e).length:e.length};if(a){i.keyedList.sort(t?a:function(t,i){return a(e[t],e[i])})}return i}},1250:(e,a,t)=>{var i=t(4931),s=t(9645);e.exports=terminator;function terminator(e){if(!Object.keys(this.jobs).length){return}this.index=this.size;i(this);s(e)(null,this.results)}},9342:(e,a,t)=>{var i=t(4447),s=t(6156),o=t(1250);e.exports=parallel;function parallel(e,a,t){var r=s(e);while(r.index<(r["keyedList"]||e).length){i(e,a,r,(function(e,a){if(e){t(e,a);return}if(Object.keys(r.jobs).length===0){t(null,r.results);return}}));r.index++}return o.bind(r,t)}},3741:(e,a,t)=>{var i=t(3637);e.exports=serial;function serial(e,a,t){return i(e,a,null,t)}},3637:(e,a,t)=>{var i=t(4447),s=t(6156),o=t(1250);e.exports=serialOrdered;e.exports.ascending=ascending;e.exports.descending=descending;function serialOrdered(e,a,t,r){var n=s(e,t);i(e,a,n,(function iteratorHandler(t,s){if(t){r(t,s);return}n.index++;if(n.index<(n["keyedList"]||e).length){i(e,a,n,iteratorHandler);return}r(null,n.results)}));return o.bind(n,r)}function ascending(e,a){return ea?1:0}function descending(e,a){return-1*ascending(e,a)}},9591:(e,a,t)=>{var i=t(2838);var s=t(5338);var o=t(296);var r=Function.bind;var n=r.bind(r);function bindApi(e,a,t){var i=n(o,null).apply(null,t?[a,t]:[a]);e.api={remove:i};e.remove=i;["before","error","after","wrap"].forEach((function(i){var o=t?[a,i,t]:[a,i];e[i]=e.api[i]=n(s,null).apply(null,o)}))}function HookSingular(){var e="h";var a={registry:{}};var t=i.bind(null,a,e);bindApi(t,a,e);return t}function HookCollection(){var e={registry:{}};var a=i.bind(null,e);bindApi(a,e);return a}var p=false;function Hook(){if(!p){console.warn('[before-after-hook]: "Hook()" repurposing warning, use "Hook.Collection()". Read more: https://git.io/upgrade-before-after-hook-to-1.4');p=true}return HookCollection()}Hook.Singular=HookSingular.bind();Hook.Collection=HookCollection.bind();e.exports=Hook;e.exports.Hook=Hook;e.exports.Singular=Hook.Singular;e.exports.Collection=Hook.Collection},5338:e=>{e.exports=addHook;function addHook(e,a,t,i){var s=i;if(!e.registry[t]){e.registry[t]=[]}if(a==="before"){i=function(e,a){return Promise.resolve().then(s.bind(null,a)).then(e.bind(null,a))}}if(a==="after"){i=function(e,a){var t;return Promise.resolve().then(e.bind(null,a)).then((function(e){t=e;return s(t,a)})).then((function(){return t}))}}if(a==="error"){i=function(e,a){return Promise.resolve().then(e.bind(null,a)).catch((function(e){return s(e,a)}))}}e.registry[t].push({hook:i,orig:s})}},2838:e=>{e.exports=register;function register(e,a,t,i){if(typeof t!=="function"){throw new Error("method for before hook must be a function")}if(!i){i={}}if(Array.isArray(a)){return a.reverse().reduce((function(a,t){return register.bind(null,e,t,a,i)}),t)()}return Promise.resolve().then((function(){if(!e.registry[a]){return t(i)}return e.registry[a].reduce((function(e,a){return a.hook.bind(null,e,i)}),t)()}))}},296:e=>{e.exports=removeHook;function removeHook(e,a,t){if(!e.registry[a]){return}var i=e.registry[a].map((function(e){return e.orig})).indexOf(t);if(i===-1){return}e.registry[a].splice(i,1)}},500:(e,a,t)=>{var i=t(3837);var s=t(2781).Stream;var o=t(4058);e.exports=CombinedStream;function CombinedStream(){this.writable=false;this.readable=true;this.dataSize=0;this.maxDataSize=2*1024*1024;this.pauseStreams=true;this._released=false;this._streams=[];this._currentStream=null;this._insideLoop=false;this._pendingNext=false}i.inherits(CombinedStream,s);CombinedStream.create=function(e){var a=new this;e=e||{};for(var t in e){a[t]=e[t]}return a};CombinedStream.isStreamLike=function(e){return typeof e!=="function"&&typeof e!=="string"&&typeof e!=="boolean"&&typeof e!=="number"&&!Buffer.isBuffer(e)};CombinedStream.prototype.append=function(e){var a=CombinedStream.isStreamLike(e);if(a){if(!(e instanceof o)){var t=o.create(e,{maxDataSize:Infinity,pauseStream:this.pauseStreams});e.on("data",this._checkDataSize.bind(this));e=t}this._handleErrors(e);if(this.pauseStreams){e.pause()}}this._streams.push(e);return this};CombinedStream.prototype.pipe=function(e,a){s.prototype.pipe.call(this,e,a);this.resume();return e};CombinedStream.prototype._getNext=function(){this._currentStream=null;if(this._insideLoop){this._pendingNext=true;return}this._insideLoop=true;try{do{this._pendingNext=false;this._realGetNext()}while(this._pendingNext)}finally{this._insideLoop=false}};CombinedStream.prototype._realGetNext=function(){var e=this._streams.shift();if(typeof e=="undefined"){this.end();return}if(typeof e!=="function"){this._pipeNext(e);return}var a=e;a(function(e){var a=CombinedStream.isStreamLike(e);if(a){e.on("data",this._checkDataSize.bind(this));this._handleErrors(e)}this._pipeNext(e)}.bind(this))};CombinedStream.prototype._pipeNext=function(e){this._currentStream=e;var a=CombinedStream.isStreamLike(e);if(a){e.on("end",this._getNext.bind(this));e.pipe(this,{end:false});return}var t=e;this.write(t);this._getNext()};CombinedStream.prototype._handleErrors=function(e){var a=this;e.on("error",(function(e){a._emitError(e)}))};CombinedStream.prototype.write=function(e){this.emit("data",e)};CombinedStream.prototype.pause=function(){if(!this.pauseStreams){return}if(this.pauseStreams&&this._currentStream&&typeof this._currentStream.pause=="function")this._currentStream.pause();this.emit("pause")};CombinedStream.prototype.resume=function(){if(!this._released){this._released=true;this.writable=true;this._getNext()}if(this.pauseStreams&&this._currentStream&&typeof this._currentStream.resume=="function")this._currentStream.resume();this.emit("resume")};CombinedStream.prototype.end=function(){this._reset();this.emit("end")};CombinedStream.prototype.destroy=function(){this._reset();this.emit("close")};CombinedStream.prototype._reset=function(){this.writable=false;this._streams=[];this._currentStream=null};CombinedStream.prototype._checkDataSize=function(){this._updateDataSize();if(this.dataSize<=this.maxDataSize){return}var e="DelayedStream#maxDataSize of "+this.maxDataSize+" bytes exceeded.";this._emitError(new Error(e))};CombinedStream.prototype._updateDataSize=function(){this.dataSize=0;var e=this;this._streams.forEach((function(a){if(!a.dataSize){return}e.dataSize+=a.dataSize}));if(this._currentStream&&this._currentStream.dataSize){this.dataSize+=this._currentStream.dataSize}};CombinedStream.prototype._emitError=function(e){this._reset();this.emit("error",e)}},589:(e,a,t)=>{a.formatArgs=formatArgs;a.save=save;a.load=load;a.useColors=useColors;a.storage=localstorage();a.destroy=(()=>{let e=false;return()=>{if(!e){e=true;console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.")}}})();a.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"];function useColors(){if(typeof window!=="undefined"&&window.process&&(window.process.type==="renderer"||window.process.__nwjs)){return true}if(typeof navigator!=="undefined"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/)){return false}return typeof document!=="undefined"&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||typeof window!=="undefined"&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||typeof navigator!=="undefined"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||typeof navigator!=="undefined"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)}function formatArgs(a){a[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+a[0]+(this.useColors?"%c ":" ")+"+"+e.exports.humanize(this.diff);if(!this.useColors){return}const t="color: "+this.color;a.splice(1,0,t,"color: inherit");let i=0;let s=0;a[0].replace(/%[a-zA-Z%]/g,(e=>{if(e==="%%"){return}i++;if(e==="%c"){s=i}}));a.splice(s,0,t)}a.log=console.debug||console.log||(()=>{});function save(e){try{if(e){a.storage.setItem("debug",e)}else{a.storage.removeItem("debug")}}catch(e){}}function load(){let e;try{e=a.storage.getItem("debug")}catch(e){}if(!e&&typeof process!=="undefined"&&"env"in process){e=process.env.DEBUG}return e}function localstorage(){try{return localStorage}catch(e){}}e.exports=t(2072)(a);const{formatters:i}=e.exports;i.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}}},2072:(e,a,t)=>{function setup(e){createDebug.debug=createDebug;createDebug.default=createDebug;createDebug.coerce=coerce;createDebug.disable=disable;createDebug.enable=enable;createDebug.enabled=enabled;createDebug.humanize=t(5097);createDebug.destroy=destroy;Object.keys(e).forEach((a=>{createDebug[a]=e[a]}));createDebug.names=[];createDebug.skips=[];createDebug.formatters={};function selectColor(e){let a=0;for(let t=0;t{if(a==="%%"){return"%"}o++;const s=createDebug.formatters[i];if(typeof s==="function"){const i=e[o];a=s.call(t,i);e.splice(o,1);o--}return a}));createDebug.formatArgs.call(t,e);const r=t.log||createDebug.log;r.apply(t,e)}debug.namespace=e;debug.useColors=createDebug.useColors();debug.color=createDebug.selectColor(e);debug.extend=extend;debug.destroy=createDebug.destroy;Object.defineProperty(debug,"enabled",{enumerable:true,configurable:false,get:()=>{if(t!==null){return t}if(i!==createDebug.namespaces){i=createDebug.namespaces;s=createDebug.enabled(e)}return s},set:e=>{t=e}});if(typeof createDebug.init==="function"){createDebug.init(debug)}return debug}function extend(e,a){const t=createDebug(this.namespace+(typeof a==="undefined"?":":a)+e);t.log=this.log;return t}function enable(e){createDebug.save(e);createDebug.namespaces=e;createDebug.names=[];createDebug.skips=[];let a;const t=(typeof e==="string"?e:"").split(/[\s,]+/);const i=t.length;for(a=0;a"-"+e))].join(",");createDebug.enable("");return e}function enabled(e){if(e[e.length-1]==="*"){return true}let a;let t;for(a=0,t=createDebug.skips.length;a{if(typeof process==="undefined"||process.type==="renderer"||process.browser===true||process.__nwjs){e.exports=t(589)}else{e.exports=t(8380)}},8380:(e,a,t)=>{const i=t(6224);const s=t(3837);a.init=init;a.log=log;a.formatArgs=formatArgs;a.save=save;a.load=load;a.useColors=useColors;a.destroy=s.deprecate((()=>{}),"Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.");a.colors=[6,2,3,4,5,1];try{const e=t(2914);if(e&&(e.stderr||e).level>=2){a.colors=[20,21,26,27,32,33,38,39,40,41,42,43,44,45,56,57,62,63,68,69,74,75,76,77,78,79,80,81,92,93,98,99,112,113,128,129,134,135,148,149,160,161,162,163,164,165,166,167,168,169,170,171,172,173,178,179,184,185,196,197,198,199,200,201,202,203,204,205,206,207,208,209,214,215,220,221]}}catch(e){}a.inspectOpts=Object.keys(process.env).filter((e=>/^debug_/i.test(e))).reduce(((e,a)=>{const t=a.substring(6).toLowerCase().replace(/_([a-z])/g,((e,a)=>a.toUpperCase()));let i=process.env[a];if(/^(yes|on|true|enabled)$/i.test(i)){i=true}else if(/^(no|off|false|disabled)$/i.test(i)){i=false}else if(i==="null"){i=null}else{i=Number(i)}e[t]=i;return e}),{});function useColors(){return"colors"in a.inspectOpts?Boolean(a.inspectOpts.colors):i.isatty(process.stderr.fd)}function formatArgs(a){const{namespace:t,useColors:i}=this;if(i){const i=this.color;const s="[3"+(i<8?i:"8;5;"+i);const o=` ${s};1m${t} `;a[0]=o+a[0].split("\n").join("\n"+o);a.push(s+"m+"+e.exports.humanize(this.diff)+"")}else{a[0]=getDate()+t+" "+a[0]}}function getDate(){if(a.inspectOpts.hideDate){return""}return(new Date).toISOString()+" "}function log(...e){return process.stderr.write(s.format(...e)+"\n")}function save(e){if(e){process.env.DEBUG=e}else{delete process.env.DEBUG}}function load(){return process.env.DEBUG}function init(e){e.inspectOpts={};const t=Object.keys(a.inspectOpts);for(let i=0;ie.trim())).join(" ")};o.O=function(e){this.inspectOpts.colors=this.useColors;return s.inspect(e,this.inspectOpts)}},4058:(e,a,t)=>{var i=t(2781).Stream;var s=t(3837);e.exports=DelayedStream;function DelayedStream(){this.source=null;this.dataSize=0;this.maxDataSize=1024*1024;this.pauseStream=true;this._maxDataSizeExceeded=false;this._released=false;this._bufferedEvents=[]}s.inherits(DelayedStream,i);DelayedStream.create=function(e,a){var t=new this;a=a||{};for(var i in a){t[i]=a[i]}t.source=e;var s=e.emit;e.emit=function(){t._handleEmit(arguments);return s.apply(e,arguments)};e.on("error",(function(){}));if(t.pauseStream){e.pause()}return t};Object.defineProperty(DelayedStream.prototype,"readable",{configurable:true,enumerable:true,get:function(){return this.source.readable}});DelayedStream.prototype.setEncoding=function(){return this.source.setEncoding.apply(this.source,arguments)};DelayedStream.prototype.resume=function(){if(!this._released){this.release()}this.source.resume()};DelayedStream.prototype.pause=function(){this.source.pause()};DelayedStream.prototype.release=function(){this._released=true;this._bufferedEvents.forEach(function(e){this.emit.apply(this,e)}.bind(this));this._bufferedEvents=[]};DelayedStream.prototype.pipe=function(){var e=i.prototype.pipe.apply(this,arguments);this.resume();return e};DelayedStream.prototype._handleEmit=function(e){if(this._released){this.emit.apply(this,e);return}if(e[0]==="data"){this.dataSize+=e[1].length;this._checkIfMaxDataSizeExceeded()}this._bufferedEvents.push(e)};DelayedStream.prototype._checkIfMaxDataSizeExceeded=function(){if(this._maxDataSizeExceeded){return}if(this.dataSize<=this.maxDataSize){return}this._maxDataSizeExceeded=true;var e="DelayedStream#maxDataSize of "+this.maxDataSize+" bytes exceeded.";this.emit("error",new Error(e))}},718:(e,a)=>{"use strict";Object.defineProperty(a,"__esModule",{value:true});class Deprecation extends Error{constructor(e){super(e);if(Error.captureStackTrace){Error.captureStackTrace(this,this.constructor)}this.name="Deprecation"}}a.Deprecation=Deprecation},7191:(e,a,t)=>{var i;e.exports=function(){if(!i){try{i=t(7244)("follow-redirects")}catch(e){}if(typeof i!=="function"){i=function(){}}}i.apply(null,arguments)}},4322:(e,a,t)=>{var i=t(7310);var s=i.URL;var o=t(3685);var r=t(5687);var n=t(2781).Writable;var p=t(9491);var d=t(7191);var l=["abort","aborted","connect","error","socket","timeout"];var c=Object.create(null);l.forEach((function(e){c[e]=function(a,t,i){this._redirectable.emit(e,a,t,i)}}));var u=createErrorType("ERR_INVALID_URL","Invalid URL",TypeError);var m=createErrorType("ERR_FR_REDIRECTION_FAILURE","Redirected request failed");var v=createErrorType("ERR_FR_TOO_MANY_REDIRECTS","Maximum number of redirects exceeded");var h=createErrorType("ERR_FR_MAX_BODY_LENGTH_EXCEEDED","Request body larger than maxBodyLength limit");var g=createErrorType("ERR_STREAM_WRITE_AFTER_END","write after end");function RedirectableRequest(e,a){n.call(this);this._sanitizeOptions(e);this._options=e;this._ended=false;this._ending=false;this._redirectCount=0;this._redirects=[];this._requestBodyLength=0;this._requestBodyBuffers=[];if(a){this.on("response",a)}var t=this;this._onNativeResponse=function(e){t._processResponse(e)};this._performRequest()}RedirectableRequest.prototype=Object.create(n.prototype);RedirectableRequest.prototype.abort=function(){abortRequest(this._currentRequest);this.emit("abort")};RedirectableRequest.prototype.write=function(e,a,t){if(this._ending){throw new g}if(!isString(e)&&!isBuffer(e)){throw new TypeError("data should be a string, Buffer or Uint8Array")}if(isFunction(a)){t=a;a=null}if(e.length===0){if(t){t()}return}if(this._requestBodyLength+e.length<=this._options.maxBodyLength){this._requestBodyLength+=e.length;this._requestBodyBuffers.push({data:e,encoding:a});this._currentRequest.write(e,a,t)}else{this.emit("error",new h);this.abort()}};RedirectableRequest.prototype.end=function(e,a,t){if(isFunction(e)){t=e;e=a=null}else if(isFunction(a)){t=a;a=null}if(!e){this._ended=this._ending=true;this._currentRequest.end(null,null,t)}else{var i=this;var s=this._currentRequest;this.write(e,a,(function(){i._ended=true;s.end(null,null,t)}));this._ending=true}};RedirectableRequest.prototype.setHeader=function(e,a){this._options.headers[e]=a;this._currentRequest.setHeader(e,a)};RedirectableRequest.prototype.removeHeader=function(e){delete this._options.headers[e];this._currentRequest.removeHeader(e)};RedirectableRequest.prototype.setTimeout=function(e,a){var t=this;function destroyOnTimeout(a){a.setTimeout(e);a.removeListener("timeout",a.destroy);a.addListener("timeout",a.destroy)}function startTimer(a){if(t._timeout){clearTimeout(t._timeout)}t._timeout=setTimeout((function(){t.emit("timeout");clearTimer()}),e);destroyOnTimeout(a)}function clearTimer(){if(t._timeout){clearTimeout(t._timeout);t._timeout=null}t.removeListener("abort",clearTimer);t.removeListener("error",clearTimer);t.removeListener("response",clearTimer);if(a){t.removeListener("timeout",a)}if(!t.socket){t._currentRequest.removeListener("socket",startTimer)}}if(a){this.on("timeout",a)}if(this.socket){startTimer(this.socket)}else{this._currentRequest.once("socket",startTimer)}this.on("socket",destroyOnTimeout);this.on("abort",clearTimer);this.on("error",clearTimer);this.on("response",clearTimer);return this};["flushHeaders","getHeader","setNoDelay","setSocketKeepAlive"].forEach((function(e){RedirectableRequest.prototype[e]=function(a,t){return this._currentRequest[e](a,t)}}));["aborted","connection","socket"].forEach((function(e){Object.defineProperty(RedirectableRequest.prototype,e,{get:function(){return this._currentRequest[e]}})}));RedirectableRequest.prototype._sanitizeOptions=function(e){if(!e.headers){e.headers={}}if(e.host){if(!e.hostname){e.hostname=e.host}delete e.host}if(!e.pathname&&e.path){var a=e.path.indexOf("?");if(a<0){e.pathname=e.path}else{e.pathname=e.path.substring(0,a);e.search=e.path.substring(a)}}};RedirectableRequest.prototype._performRequest=function(){var e=this._options.protocol;var a=this._options.nativeProtocols[e];if(!a){this.emit("error",new TypeError("Unsupported protocol "+e));return}if(this._options.agents){var t=e.slice(0,-1);this._options.agent=this._options.agents[t]}var s=this._currentRequest=a.request(this._options,this._onNativeResponse);s._redirectable=this;for(var o of l){s.on(o,c[o])}this._currentUrl=/^\//.test(this._options.path)?i.format(this._options):this._options.path;if(this._isRedirect){var r=0;var n=this;var p=this._requestBodyBuffers;(function writeNext(e){if(s===n._currentRequest){if(e){n.emit("error",e)}else if(r=400){e.responseUrl=this._currentUrl;e.redirects=this._redirects;this.emit("response",e);this._requestBodyBuffers=[];return}abortRequest(this._currentRequest);e.destroy();if(++this._redirectCount>this._options.maxRedirects){this.emit("error",new v);return}var s;var o=this._options.beforeRedirect;if(o){s=Object.assign({Host:e.req.getHeader("host")},this._options.headers)}var r=this._options.method;if((a===301||a===302)&&this._options.method==="POST"||a===303&&!/^(?:GET|HEAD)$/.test(this._options.method)){this._options.method="GET";this._requestBodyBuffers=[];removeMatchingHeaders(/^content-/i,this._options.headers)}var n=removeMatchingHeaders(/^host$/i,this._options.headers);var p=i.parse(this._currentUrl);var l=n||p.host;var c=/^\w+:/.test(t)?this._currentUrl:i.format(Object.assign(p,{host:l}));var u;try{u=i.resolve(c,t)}catch(e){this.emit("error",new m({cause:e}));return}d("redirecting to",u);this._isRedirect=true;var h=i.parse(u);Object.assign(this._options,h);if(h.protocol!==p.protocol&&h.protocol!=="https:"||h.host!==l&&!isSubdomain(h.host,l)){removeMatchingHeaders(/^(?:authorization|cookie)$/i,this._options.headers)}if(isFunction(o)){var g={headers:e.headers,statusCode:a};var b={url:c,method:r,headers:s};try{o(this._options,g,b)}catch(e){this.emit("error",e);return}this._sanitizeOptions(this._options)}try{this._performRequest()}catch(e){this.emit("error",new m({cause:e}))}};function wrap(e){var a={maxRedirects:21,maxBodyLength:10*1024*1024};var t={};Object.keys(e).forEach((function(o){var r=o+":";var n=t[r]=e[o];var l=a[o]=Object.create(n);function request(e,o,n){if(isString(e)){var l;try{l=urlToOptions(new s(e))}catch(a){l=i.parse(e)}if(!isString(l.protocol)){throw new u({input:e})}e=l}else if(s&&e instanceof s){e=urlToOptions(e)}else{n=o;o=e;e={protocol:r}}if(isFunction(o)){n=o;o=null}o=Object.assign({maxRedirects:a.maxRedirects,maxBodyLength:a.maxBodyLength},e,o);o.nativeProtocols=t;if(!isString(o.host)&&!isString(o.hostname)){o.hostname="::1"}p.equal(o.protocol,r,"protocol mismatch");d("options",o);return new RedirectableRequest(o,n)}function get(e,a,t){var i=l.request(e,a,t);i.end();return i}Object.defineProperties(l,{request:{value:request,configurable:true,enumerable:true,writable:true},get:{value:get,configurable:true,enumerable:true,writable:true}})}));return a}function noop(){}function urlToOptions(e){var a={protocol:e.protocol,hostname:e.hostname.startsWith("[")?e.hostname.slice(1,-1):e.hostname,hash:e.hash,search:e.search,pathname:e.pathname,path:e.pathname+e.search,href:e.href};if(e.port!==""){a.port=Number(e.port)}return a}function removeMatchingHeaders(e,a){var t;for(var i in a){if(e.test(i)){t=a[i];delete a[i]}}return t===null||typeof t==="undefined"?undefined:String(t).trim()}function createErrorType(e,a,t){function CustomError(t){Error.captureStackTrace(this,this.constructor);Object.assign(this,t||{});this.code=e;this.message=this.cause?a+": "+this.cause.message:a}CustomError.prototype=new(t||Error);CustomError.prototype.constructor=CustomError;CustomError.prototype.name="Error ["+e+"]";return CustomError}function abortRequest(e){for(var a of l){e.removeListener(a,c[a])}e.on("error",noop);e.abort()}function isSubdomain(e,a){p(isString(e)&&isString(a));var t=e.length-a.length-1;return t>0&&e[t]==="."&&e.endsWith(a)}function isString(e){return typeof e==="string"||e instanceof String}function isFunction(e){return typeof e==="function"}function isBuffer(e){return typeof e==="object"&&"length"in e}e.exports=wrap({http:o,https:r});e.exports.wrap=wrap},6862:(e,a,t)=>{var i=t(500);var s=t(3837);var o=t(1017);var r=t(3685);var n=t(5687);var p=t(7310).parse;var d=t(7147);var l=t(2781).Stream;var c=t(2262);var u=t(7758);var m=t(6250);e.exports=FormData;s.inherits(FormData,i);function FormData(e){if(!(this instanceof FormData)){return new FormData(e)}this._overheadLength=0;this._valueLength=0;this._valuesToMeasure=[];i.call(this);e=e||{};for(var a in e){this[a]=e[a]}}FormData.LINE_BREAK="\r\n";FormData.DEFAULT_CONTENT_TYPE="application/octet-stream";FormData.prototype.append=function(e,a,t){t=t||{};if(typeof t=="string"){t={filename:t}}var o=i.prototype.append.bind(this);if(typeof a=="number"){a=""+a}if(s.isArray(a)){this._error(new Error("Arrays are not supported."));return}var r=this._multiPartHeader(e,a,t);var n=this._multiPartFooter();o(r);o(a);o(n);this._trackLength(r,a,t)};FormData.prototype._trackLength=function(e,a,t){var i=0;if(t.knownLength!=null){i+=+t.knownLength}else if(Buffer.isBuffer(a)){i=a.length}else if(typeof a==="string"){i=Buffer.byteLength(a)}this._valueLength+=i;this._overheadLength+=Buffer.byteLength(e)+FormData.LINE_BREAK.length;if(!a||!a.path&&!(a.readable&&a.hasOwnProperty("httpVersion"))&&!(a instanceof l)){return}if(!t.knownLength){this._valuesToMeasure.push(a)}};FormData.prototype._lengthRetriever=function(e,a){if(e.hasOwnProperty("fd")){if(e.end!=undefined&&e.end!=Infinity&&e.start!=undefined){a(null,e.end+1-(e.start?e.start:0))}else{d.stat(e.path,(function(t,i){var s;if(t){a(t);return}s=i.size-(e.start?e.start:0);a(null,s)}))}}else if(e.hasOwnProperty("httpVersion")){a(null,+e.headers["content-length"])}else if(e.hasOwnProperty("httpModule")){e.on("response",(function(t){e.pause();a(null,+t.headers["content-length"])}));e.resume()}else{a("Unknown stream")}};FormData.prototype._multiPartHeader=function(e,a,t){if(typeof t.header=="string"){return t.header}var i=this._getContentDisposition(a,t);var s=this._getContentType(a,t);var o="";var r={"Content-Disposition":["form-data",'name="'+e+'"'].concat(i||[]),"Content-Type":[].concat(s||[])};if(typeof t.header=="object"){m(r,t.header)}var n;for(var p in r){if(!r.hasOwnProperty(p))continue;n=r[p];if(n==null){continue}if(!Array.isArray(n)){n=[n]}if(n.length){o+=p+": "+n.join("; ")+FormData.LINE_BREAK}}return"--"+this.getBoundary()+FormData.LINE_BREAK+o+FormData.LINE_BREAK};FormData.prototype._getContentDisposition=function(e,a){var t,i;if(typeof a.filepath==="string"){t=o.normalize(a.filepath).replace(/\\/g,"/")}else if(a.filename||e.name||e.path){t=o.basename(a.filename||e.name||e.path)}else if(e.readable&&e.hasOwnProperty("httpVersion")){t=o.basename(e.client._httpMessage.path||"")}if(t){i='filename="'+t+'"'}return i};FormData.prototype._getContentType=function(e,a){var t=a.contentType;if(!t&&e.name){t=c.lookup(e.name)}if(!t&&e.path){t=c.lookup(e.path)}if(!t&&e.readable&&e.hasOwnProperty("httpVersion")){t=e.headers["content-type"]}if(!t&&(a.filepath||a.filename)){t=c.lookup(a.filepath||a.filename)}if(!t&&typeof e=="object"){t=FormData.DEFAULT_CONTENT_TYPE}return t};FormData.prototype._multiPartFooter=function(){return function(e){var a=FormData.LINE_BREAK;var t=this._streams.length===0;if(t){a+=this._lastBoundary()}e(a)}.bind(this)};FormData.prototype._lastBoundary=function(){return"--"+this.getBoundary()+"--"+FormData.LINE_BREAK};FormData.prototype.getHeaders=function(e){var a;var t={"content-type":"multipart/form-data; boundary="+this.getBoundary()};for(a in e){if(e.hasOwnProperty(a)){t[a.toLowerCase()]=e[a]}}return t};FormData.prototype.setBoundary=function(e){this._boundary=e};FormData.prototype.getBoundary=function(){if(!this._boundary){this._generateBoundary()}return this._boundary};FormData.prototype.getBuffer=function(){var e=new Buffer.alloc(0);var a=this.getBoundary();for(var t=0,i=this._streams.length;t{e.exports=function(e,a){Object.keys(a).forEach((function(t){e[t]=e[t]||a[t]}));return e}},9473:(e,a,t)=>{"use strict";const i=t(8559);const s=t(1017);const o=t(9251).mkdirsSync;const r=t(2274).utimesMillisSync;const n=t(2418);function copySync(e,a,t){if(typeof t==="function"){t={filter:t}}t=t||{};t.clobber="clobber"in t?!!t.clobber:true;t.overwrite="overwrite"in t?!!t.overwrite:t.clobber;if(t.preserveTimestamps&&process.arch==="ia32"){process.emitWarning("Using the preserveTimestamps option in 32-bit node is not recommended;\n\n"+"\tsee https://github.com/jprichardson/node-fs-extra/issues/269","Warning","fs-extra-WARN0002")}const{srcStat:r,destStat:p}=n.checkPathsSync(e,a,"copy",t);n.checkParentPathsSync(e,r,a,"copy");if(t.filter&&!t.filter(e,a))return;const d=s.dirname(a);if(!i.existsSync(d))o(d);return getStats(p,e,a,t)}function getStats(e,a,t,s){const o=s.dereference?i.statSync:i.lstatSync;const r=o(a);if(r.isDirectory())return onDir(r,e,a,t,s);else if(r.isFile()||r.isCharacterDevice()||r.isBlockDevice())return onFile(r,e,a,t,s);else if(r.isSymbolicLink())return onLink(e,a,t,s);else if(r.isSocket())throw new Error(`Cannot copy a socket file: ${a}`);else if(r.isFIFO())throw new Error(`Cannot copy a FIFO pipe: ${a}`);throw new Error(`Unknown file: ${a}`)}function onFile(e,a,t,i,s){if(!a)return copyFile(e,t,i,s);return mayCopyFile(e,t,i,s)}function mayCopyFile(e,a,t,s){if(s.overwrite){i.unlinkSync(t);return copyFile(e,a,t,s)}else if(s.errorOnExist){throw new Error(`'${t}' already exists`)}}function copyFile(e,a,t,s){i.copyFileSync(a,t);if(s.preserveTimestamps)handleTimestamps(e.mode,a,t);return setDestMode(t,e.mode)}function handleTimestamps(e,a,t){if(fileIsNotWritable(e))makeFileWritable(t,e);return setDestTimestamps(a,t)}function fileIsNotWritable(e){return(e&128)===0}function makeFileWritable(e,a){return setDestMode(e,a|128)}function setDestMode(e,a){return i.chmodSync(e,a)}function setDestTimestamps(e,a){const t=i.statSync(e);return r(a,t.atime,t.mtime)}function onDir(e,a,t,i,s){if(!a)return mkDirAndCopy(e.mode,t,i,s);return copyDir(t,i,s)}function mkDirAndCopy(e,a,t,s){i.mkdirSync(t);copyDir(a,t,s);return setDestMode(t,e)}function copyDir(e,a,t){i.readdirSync(e).forEach((i=>copyDirItem(i,e,a,t)))}function copyDirItem(e,a,t,i){const o=s.join(a,e);const r=s.join(t,e);if(i.filter&&!i.filter(o,r))return;const{destStat:p}=n.checkPathsSync(o,r,"copy",i);return getStats(p,o,r,i)}function onLink(e,a,t,o){let r=i.readlinkSync(a);if(o.dereference){r=s.resolve(process.cwd(),r)}if(!e){return i.symlinkSync(r,t)}else{let e;try{e=i.readlinkSync(t)}catch(e){if(e.code==="EINVAL"||e.code==="UNKNOWN")return i.symlinkSync(r,t);throw e}if(o.dereference){e=s.resolve(process.cwd(),e)}if(n.isSrcSubdir(r,e)){throw new Error(`Cannot copy '${r}' to a subdirectory of itself, '${e}'.`)}if(n.isSrcSubdir(e,r)){throw new Error(`Cannot overwrite '${e}' with '${r}'.`)}return copyLink(r,t)}}function copyLink(e,a){i.unlinkSync(a);return i.symlinkSync(e,a)}e.exports=copySync},6382:(e,a,t)=>{"use strict";const i=t(8559);const s=t(1017);const o=t(9251).mkdirs;const r=t(5082).pathExists;const n=t(2274).utimesMillis;const p=t(2418);function copy(e,a,t,i){if(typeof t==="function"&&!i){i=t;t={}}else if(typeof t==="function"){t={filter:t}}i=i||function(){};t=t||{};t.clobber="clobber"in t?!!t.clobber:true;t.overwrite="overwrite"in t?!!t.overwrite:t.clobber;if(t.preserveTimestamps&&process.arch==="ia32"){process.emitWarning("Using the preserveTimestamps option in 32-bit node is not recommended;\n\n"+"\tsee https://github.com/jprichardson/node-fs-extra/issues/269","Warning","fs-extra-WARN0001")}p.checkPaths(e,a,"copy",t,((s,o)=>{if(s)return i(s);const{srcStat:r,destStat:n}=o;p.checkParentPaths(e,r,a,"copy",(s=>{if(s)return i(s);runFilter(e,a,t,((s,o)=>{if(s)return i(s);if(!o)return i();checkParentDir(n,e,a,t,i)}))}))}))}function checkParentDir(e,a,t,i,n){const p=s.dirname(t);r(p,((s,r)=>{if(s)return n(s);if(r)return getStats(e,a,t,i,n);o(p,(s=>{if(s)return n(s);return getStats(e,a,t,i,n)}))}))}function runFilter(e,a,t,i){if(!t.filter)return i(null,true);Promise.resolve(t.filter(e,a)).then((e=>i(null,e)),(e=>i(e)))}function getStats(e,a,t,s,o){const r=s.dereference?i.stat:i.lstat;r(a,((i,r)=>{if(i)return o(i);if(r.isDirectory())return onDir(r,e,a,t,s,o);else if(r.isFile()||r.isCharacterDevice()||r.isBlockDevice())return onFile(r,e,a,t,s,o);else if(r.isSymbolicLink())return onLink(e,a,t,s,o);else if(r.isSocket())return o(new Error(`Cannot copy a socket file: ${a}`));else if(r.isFIFO())return o(new Error(`Cannot copy a FIFO pipe: ${a}`));return o(new Error(`Unknown file: ${a}`))}))}function onFile(e,a,t,i,s,o){if(!a)return copyFile(e,t,i,s,o);return mayCopyFile(e,t,i,s,o)}function mayCopyFile(e,a,t,s,o){if(s.overwrite){i.unlink(t,(i=>{if(i)return o(i);return copyFile(e,a,t,s,o)}))}else if(s.errorOnExist){return o(new Error(`'${t}' already exists`))}else return o()}function copyFile(e,a,t,s,o){i.copyFile(a,t,(i=>{if(i)return o(i);if(s.preserveTimestamps)return handleTimestampsAndMode(e.mode,a,t,o);return setDestMode(t,e.mode,o)}))}function handleTimestampsAndMode(e,a,t,i){if(fileIsNotWritable(e)){return makeFileWritable(t,e,(s=>{if(s)return i(s);return setDestTimestampsAndMode(e,a,t,i)}))}return setDestTimestampsAndMode(e,a,t,i)}function fileIsNotWritable(e){return(e&128)===0}function makeFileWritable(e,a,t){return setDestMode(e,a|128,t)}function setDestTimestampsAndMode(e,a,t,i){setDestTimestamps(a,t,(a=>{if(a)return i(a);return setDestMode(t,e,i)}))}function setDestMode(e,a,t){return i.chmod(e,a,t)}function setDestTimestamps(e,a,t){i.stat(e,((e,i)=>{if(e)return t(e);return n(a,i.atime,i.mtime,t)}))}function onDir(e,a,t,i,s,o){if(!a)return mkDirAndCopy(e.mode,t,i,s,o);return copyDir(t,i,s,o)}function mkDirAndCopy(e,a,t,s,o){i.mkdir(t,(i=>{if(i)return o(i);copyDir(a,t,s,(a=>{if(a)return o(a);return setDestMode(t,e,o)}))}))}function copyDir(e,a,t,s){i.readdir(e,((i,o)=>{if(i)return s(i);return copyDirItems(o,e,a,t,s)}))}function copyDirItems(e,a,t,i,s){const o=e.pop();if(!o)return s();return copyDirItem(e,o,a,t,i,s)}function copyDirItem(e,a,t,i,o,r){const n=s.join(t,a);const d=s.join(i,a);runFilter(n,d,o,((a,s)=>{if(a)return r(a);if(!s)return copyDirItems(e,t,i,o,r);p.checkPaths(n,d,"copy",o,((a,s)=>{if(a)return r(a);const{destStat:p}=s;getStats(p,n,d,o,(a=>{if(a)return r(a);return copyDirItems(e,t,i,o,r)}))}))}))}function onLink(e,a,t,o,r){i.readlink(a,((a,n)=>{if(a)return r(a);if(o.dereference){n=s.resolve(process.cwd(),n)}if(!e){return i.symlink(n,t,r)}else{i.readlink(t,((e,a)=>{if(e){if(e.code==="EINVAL"||e.code==="UNKNOWN")return i.symlink(n,t,r);return r(e)}if(o.dereference){a=s.resolve(process.cwd(),a)}if(p.isSrcSubdir(n,a)){return r(new Error(`Cannot copy '${n}' to a subdirectory of itself, '${a}'.`))}if(p.isSrcSubdir(a,n)){return r(new Error(`Cannot overwrite '${a}' with '${n}'.`))}return copyLink(n,t,r)}))}}))}function copyLink(e,a,t){i.unlink(a,(s=>{if(s)return t(s);return i.symlink(e,a,t)}))}e.exports=copy},1144:(e,a,t)=>{"use strict";const i=t(2003).fromCallback;e.exports={copy:i(t(6382)),copySync:t(9473)}},7868:(e,a,t)=>{"use strict";const i=t(2003).fromPromise;const s=t(5055);const o=t(1017);const r=t(9251);const n=t(8006);const p=i((async function emptyDir(e){let a;try{a=await s.readdir(e)}catch{return r.mkdirs(e)}return Promise.all(a.map((a=>n.remove(o.join(e,a)))))}));function emptyDirSync(e){let a;try{a=s.readdirSync(e)}catch{return r.mkdirsSync(e)}a.forEach((a=>{a=o.join(e,a);n.removeSync(a)}))}e.exports={emptyDirSync:emptyDirSync,emptydirSync:emptyDirSync,emptyDir:p,emptydir:p}},7173:(e,a,t)=>{"use strict";const i=t(2003).fromCallback;const s=t(1017);const o=t(8559);const r=t(9251);function createFile(e,a){function makeFile(){o.writeFile(e,"",(e=>{if(e)return a(e);a()}))}o.stat(e,((t,i)=>{if(!t&&i.isFile())return a();const n=s.dirname(e);o.stat(n,((e,t)=>{if(e){if(e.code==="ENOENT"){return r.mkdirs(n,(e=>{if(e)return a(e);makeFile()}))}return a(e)}if(t.isDirectory())makeFile();else{o.readdir(n,(e=>{if(e)return a(e)}))}}))}))}function createFileSync(e){let a;try{a=o.statSync(e)}catch{}if(a&&a.isFile())return;const t=s.dirname(e);try{if(!o.statSync(t).isDirectory()){o.readdirSync(t)}}catch(e){if(e&&e.code==="ENOENT")r.mkdirsSync(t);else throw e}o.writeFileSync(e,"")}e.exports={createFile:i(createFile),createFileSync:createFileSync}},6561:(e,a,t)=>{"use strict";const{createFile:i,createFileSync:s}=t(7173);const{createLink:o,createLinkSync:r}=t(3224);const{createSymlink:n,createSymlinkSync:p}=t(2157);e.exports={createFile:i,createFileSync:s,ensureFile:i,ensureFileSync:s,createLink:o,createLinkSync:r,ensureLink:o,ensureLinkSync:r,createSymlink:n,createSymlinkSync:p,ensureSymlink:n,ensureSymlinkSync:p}},3224:(e,a,t)=>{"use strict";const i=t(2003).fromCallback;const s=t(1017);const o=t(8559);const r=t(9251);const n=t(5082).pathExists;const{areIdentical:p}=t(2418);function createLink(e,a,t){function makeLink(e,a){o.link(e,a,(e=>{if(e)return t(e);t(null)}))}o.lstat(a,((i,d)=>{o.lstat(e,((i,o)=>{if(i){i.message=i.message.replace("lstat","ensureLink");return t(i)}if(d&&p(o,d))return t(null);const l=s.dirname(a);n(l,((i,s)=>{if(i)return t(i);if(s)return makeLink(e,a);r.mkdirs(l,(i=>{if(i)return t(i);makeLink(e,a)}))}))}))}))}function createLinkSync(e,a){let t;try{t=o.lstatSync(a)}catch{}try{const a=o.lstatSync(e);if(t&&p(a,t))return}catch(e){e.message=e.message.replace("lstat","ensureLink");throw e}const i=s.dirname(a);const n=o.existsSync(i);if(n)return o.linkSync(e,a);r.mkdirsSync(i);return o.linkSync(e,a)}e.exports={createLink:i(createLink),createLinkSync:createLinkSync}},4469:(e,a,t)=>{"use strict";const i=t(1017);const s=t(8559);const o=t(5082).pathExists;function symlinkPaths(e,a,t){if(i.isAbsolute(e)){return s.lstat(e,(a=>{if(a){a.message=a.message.replace("lstat","ensureSymlink");return t(a)}return t(null,{toCwd:e,toDst:e})}))}else{const r=i.dirname(a);const n=i.join(r,e);return o(n,((a,o)=>{if(a)return t(a);if(o){return t(null,{toCwd:n,toDst:e})}else{return s.lstat(e,(a=>{if(a){a.message=a.message.replace("lstat","ensureSymlink");return t(a)}return t(null,{toCwd:e,toDst:i.relative(r,e)})}))}}))}}function symlinkPathsSync(e,a){let t;if(i.isAbsolute(e)){t=s.existsSync(e);if(!t)throw new Error("absolute srcpath does not exist");return{toCwd:e,toDst:e}}else{const o=i.dirname(a);const r=i.join(o,e);t=s.existsSync(r);if(t){return{toCwd:r,toDst:e}}else{t=s.existsSync(e);if(!t)throw new Error("relative srcpath does not exist");return{toCwd:e,toDst:i.relative(o,e)}}}}e.exports={symlinkPaths:symlinkPaths,symlinkPathsSync:symlinkPathsSync}},5682:(e,a,t)=>{"use strict";const i=t(8559);function symlinkType(e,a,t){t=typeof a==="function"?a:t;a=typeof a==="function"?false:a;if(a)return t(null,a);i.lstat(e,((e,i)=>{if(e)return t(null,"file");a=i&&i.isDirectory()?"dir":"file";t(null,a)}))}function symlinkTypeSync(e,a){let t;if(a)return a;try{t=i.lstatSync(e)}catch{return"file"}return t&&t.isDirectory()?"dir":"file"}e.exports={symlinkType:symlinkType,symlinkTypeSync:symlinkTypeSync}},2157:(e,a,t)=>{"use strict";const i=t(2003).fromCallback;const s=t(1017);const o=t(5055);const r=t(9251);const n=r.mkdirs;const p=r.mkdirsSync;const d=t(4469);const l=d.symlinkPaths;const c=d.symlinkPathsSync;const u=t(5682);const m=u.symlinkType;const v=u.symlinkTypeSync;const h=t(5082).pathExists;const{areIdentical:g}=t(2418);function createSymlink(e,a,t,i){i=typeof t==="function"?t:i;t=typeof t==="function"?false:t;o.lstat(a,((s,r)=>{if(!s&&r.isSymbolicLink()){Promise.all([o.stat(e),o.stat(a)]).then((([s,o])=>{if(g(s,o))return i(null);_createSymlink(e,a,t,i)}))}else _createSymlink(e,a,t,i)}))}function _createSymlink(e,a,t,i){l(e,a,((r,p)=>{if(r)return i(r);e=p.toDst;m(p.toCwd,t,((t,r)=>{if(t)return i(t);const p=s.dirname(a);h(p,((t,s)=>{if(t)return i(t);if(s)return o.symlink(e,a,r,i);n(p,(t=>{if(t)return i(t);o.symlink(e,a,r,i)}))}))}))}))}function createSymlinkSync(e,a,t){let i;try{i=o.lstatSync(a)}catch{}if(i&&i.isSymbolicLink()){const t=o.statSync(e);const i=o.statSync(a);if(g(t,i))return}const r=c(e,a);e=r.toDst;t=v(r.toCwd,t);const n=s.dirname(a);const d=o.existsSync(n);if(d)return o.symlinkSync(e,a,t);p(n);return o.symlinkSync(e,a,t)}e.exports={createSymlink:i(createSymlink),createSymlinkSync:createSymlinkSync}},5055:(e,a,t)=>{"use strict";const i=t(2003).fromCallback;const s=t(8559);const o=["access","appendFile","chmod","chown","close","copyFile","fchmod","fchown","fdatasync","fstat","fsync","ftruncate","futimes","lchmod","lchown","link","lstat","mkdir","mkdtemp","open","opendir","readdir","readFile","readlink","realpath","rename","rm","rmdir","stat","symlink","truncate","unlink","utimes","writeFile"].filter((e=>typeof s[e]==="function"));Object.assign(a,s);o.forEach((e=>{a[e]=i(s[e])}));a.exists=function(e,a){if(typeof a==="function"){return s.exists(e,a)}return new Promise((a=>s.exists(e,a)))};a.read=function(e,a,t,i,o,r){if(typeof r==="function"){return s.read(e,a,t,i,o,r)}return new Promise(((r,n)=>{s.read(e,a,t,i,o,((e,a,t)=>{if(e)return n(e);r({bytesRead:a,buffer:t})}))}))};a.write=function(e,a,...t){if(typeof t[t.length-1]==="function"){return s.write(e,a,...t)}return new Promise(((i,o)=>{s.write(e,a,...t,((e,a,t)=>{if(e)return o(e);i({bytesWritten:a,buffer:t})}))}))};a.readv=function(e,a,...t){if(typeof t[t.length-1]==="function"){return s.readv(e,a,...t)}return new Promise(((i,o)=>{s.readv(e,a,...t,((e,a,t)=>{if(e)return o(e);i({bytesRead:a,buffers:t})}))}))};a.writev=function(e,a,...t){if(typeof t[t.length-1]==="function"){return s.writev(e,a,...t)}return new Promise(((i,o)=>{s.writev(e,a,...t,((e,a,t)=>{if(e)return o(e);i({bytesWritten:a,buffers:t})}))}))};if(typeof s.realpath.native==="function"){a.realpath.native=i(s.realpath.native)}else{process.emitWarning("fs.realpath.native is not a function. Is fs being monkey-patched?","Warning","fs-extra-WARN0003")}},3848:(e,a,t)=>{"use strict";e.exports={...t(5055),...t(1144),...t(7868),...t(6561),...t(9835),...t(9251),...t(2783),...t(3064),...t(5082),...t(8006)}},9835:(e,a,t)=>{"use strict";const i=t(2003).fromPromise;const s=t(550);s.outputJson=i(t(3408));s.outputJsonSync=t(2669);s.outputJSON=s.outputJson;s.outputJSONSync=s.outputJsonSync;s.writeJSON=s.writeJson;s.writeJSONSync=s.writeJsonSync;s.readJSON=s.readJson;s.readJSONSync=s.readJsonSync;e.exports=s},550:(e,a,t)=>{"use strict";const i=t(7229);e.exports={readJson:i.readFile,readJsonSync:i.readFileSync,writeJson:i.writeFile,writeJsonSync:i.writeFileSync}},2669:(e,a,t)=>{"use strict";const{stringify:i}=t(8691);const{outputFileSync:s}=t(3064);function outputJsonSync(e,a,t){const o=i(a,t);s(e,o,t)}e.exports=outputJsonSync},3408:(e,a,t)=>{"use strict";const{stringify:i}=t(8691);const{outputFile:s}=t(3064);async function outputJson(e,a,t={}){const o=i(a,t);await s(e,o,t)}e.exports=outputJson},9251:(e,a,t)=>{"use strict";const i=t(2003).fromPromise;const{makeDir:s,makeDirSync:o}=t(8846);const r=i(s);e.exports={mkdirs:r,mkdirsSync:o,mkdirp:r,mkdirpSync:o,ensureDir:r,ensureDirSync:o}},8846:(e,a,t)=>{"use strict";const i=t(5055);const{checkPath:s}=t(3922);const getMode=e=>{const a={mode:511};if(typeof e==="number")return e;return{...a,...e}.mode};e.exports.makeDir=async(e,a)=>{s(e);return i.mkdir(e,{mode:getMode(a),recursive:true})};e.exports.makeDirSync=(e,a)=>{s(e);return i.mkdirSync(e,{mode:getMode(a),recursive:true})}},3922:(e,a,t)=>{"use strict";const i=t(1017);e.exports.checkPath=function checkPath(e){if(process.platform==="win32"){const a=/[<>:"|?*]/.test(e.replace(i.parse(e).root,""));if(a){const a=new Error(`Path contains invalid characters: ${e}`);a.code="EINVAL";throw a}}}},2783:(e,a,t)=>{"use strict";const i=t(2003).fromCallback;e.exports={move:i(t(307)),moveSync:t(5389)}},5389:(e,a,t)=>{"use strict";const i=t(8559);const s=t(1017);const o=t(1144).copySync;const r=t(8006).removeSync;const n=t(9251).mkdirpSync;const p=t(2418);function moveSync(e,a,t){t=t||{};const i=t.overwrite||t.clobber||false;const{srcStat:o,isChangingCase:r=false}=p.checkPathsSync(e,a,"move",t);p.checkParentPathsSync(e,o,a,"move");if(!isParentRoot(a))n(s.dirname(a));return doRename(e,a,i,r)}function isParentRoot(e){const a=s.dirname(e);const t=s.parse(a);return t.root===a}function doRename(e,a,t,s){if(s)return rename(e,a,t);if(t){r(a);return rename(e,a,t)}if(i.existsSync(a))throw new Error("dest already exists.");return rename(e,a,t)}function rename(e,a,t){try{i.renameSync(e,a)}catch(i){if(i.code!=="EXDEV")throw i;return moveAcrossDevice(e,a,t)}}function moveAcrossDevice(e,a,t){const i={overwrite:t,errorOnExist:true};o(e,a,i);return r(e)}e.exports=moveSync},307:(e,a,t)=>{"use strict";const i=t(8559);const s=t(1017);const o=t(1144).copy;const r=t(8006).remove;const n=t(9251).mkdirp;const p=t(5082).pathExists;const d=t(2418);function move(e,a,t,i){if(typeof t==="function"){i=t;t={}}t=t||{};const o=t.overwrite||t.clobber||false;d.checkPaths(e,a,"move",t,((t,r)=>{if(t)return i(t);const{srcStat:p,isChangingCase:l=false}=r;d.checkParentPaths(e,p,a,"move",(t=>{if(t)return i(t);if(isParentRoot(a))return doRename(e,a,o,l,i);n(s.dirname(a),(t=>{if(t)return i(t);return doRename(e,a,o,l,i)}))}))}))}function isParentRoot(e){const a=s.dirname(e);const t=s.parse(a);return t.root===a}function doRename(e,a,t,i,s){if(i)return rename(e,a,t,s);if(t){return r(a,(i=>{if(i)return s(i);return rename(e,a,t,s)}))}p(a,((i,o)=>{if(i)return s(i);if(o)return s(new Error("dest already exists."));return rename(e,a,t,s)}))}function rename(e,a,t,s){i.rename(e,a,(i=>{if(!i)return s();if(i.code!=="EXDEV")return s(i);return moveAcrossDevice(e,a,t,s)}))}function moveAcrossDevice(e,a,t,i){const s={overwrite:t,errorOnExist:true};o(e,a,s,(a=>{if(a)return i(a);return r(e,i)}))}e.exports=move},3064:(e,a,t)=>{"use strict";const i=t(2003).fromCallback;const s=t(8559);const o=t(1017);const r=t(9251);const n=t(5082).pathExists;function outputFile(e,a,t,i){if(typeof t==="function"){i=t;t="utf8"}const p=o.dirname(e);n(p,((o,n)=>{if(o)return i(o);if(n)return s.writeFile(e,a,t,i);r.mkdirs(p,(o=>{if(o)return i(o);s.writeFile(e,a,t,i)}))}))}function outputFileSync(e,...a){const t=o.dirname(e);if(s.existsSync(t)){return s.writeFileSync(e,...a)}r.mkdirsSync(t);s.writeFileSync(e,...a)}e.exports={outputFile:i(outputFile),outputFileSync:outputFileSync}},5082:(e,a,t)=>{"use strict";const i=t(2003).fromPromise;const s=t(5055);function pathExists(e){return s.access(e).then((()=>true)).catch((()=>false))}e.exports={pathExists:i(pathExists),pathExistsSync:s.existsSync}},8006:(e,a,t)=>{"use strict";const i=t(8559);const s=t(2003).fromCallback;function remove(e,a){i.rm(e,{recursive:true,force:true},a)}function removeSync(e){i.rmSync(e,{recursive:true,force:true})}e.exports={remove:s(remove),removeSync:removeSync}},2418:(e,a,t)=>{"use strict";const i=t(5055);const s=t(1017);const o=t(3837);function getStats(e,a,t){const s=t.dereference?e=>i.stat(e,{bigint:true}):e=>i.lstat(e,{bigint:true});return Promise.all([s(e),s(a).catch((e=>{if(e.code==="ENOENT")return null;throw e}))]).then((([e,a])=>({srcStat:e,destStat:a})))}function getStatsSync(e,a,t){let s;const o=t.dereference?e=>i.statSync(e,{bigint:true}):e=>i.lstatSync(e,{bigint:true});const r=o(e);try{s=o(a)}catch(e){if(e.code==="ENOENT")return{srcStat:r,destStat:null};throw e}return{srcStat:r,destStat:s}}function checkPaths(e,a,t,i,r){o.callbackify(getStats)(e,a,i,((i,o)=>{if(i)return r(i);const{srcStat:n,destStat:p}=o;if(p){if(areIdentical(n,p)){const i=s.basename(e);const o=s.basename(a);if(t==="move"&&i!==o&&i.toLowerCase()===o.toLowerCase()){return r(null,{srcStat:n,destStat:p,isChangingCase:true})}return r(new Error("Source and destination must not be the same."))}if(n.isDirectory()&&!p.isDirectory()){return r(new Error(`Cannot overwrite non-directory '${a}' with directory '${e}'.`))}if(!n.isDirectory()&&p.isDirectory()){return r(new Error(`Cannot overwrite directory '${a}' with non-directory '${e}'.`))}}if(n.isDirectory()&&isSrcSubdir(e,a)){return r(new Error(errMsg(e,a,t)))}return r(null,{srcStat:n,destStat:p})}))}function checkPathsSync(e,a,t,i){const{srcStat:o,destStat:r}=getStatsSync(e,a,i);if(r){if(areIdentical(o,r)){const i=s.basename(e);const n=s.basename(a);if(t==="move"&&i!==n&&i.toLowerCase()===n.toLowerCase()){return{srcStat:o,destStat:r,isChangingCase:true}}throw new Error("Source and destination must not be the same.")}if(o.isDirectory()&&!r.isDirectory()){throw new Error(`Cannot overwrite non-directory '${a}' with directory '${e}'.`)}if(!o.isDirectory()&&r.isDirectory()){throw new Error(`Cannot overwrite directory '${a}' with non-directory '${e}'.`)}}if(o.isDirectory()&&isSrcSubdir(e,a)){throw new Error(errMsg(e,a,t))}return{srcStat:o,destStat:r}}function checkParentPaths(e,a,t,o,r){const n=s.resolve(s.dirname(e));const p=s.resolve(s.dirname(t));if(p===n||p===s.parse(p).root)return r();i.stat(p,{bigint:true},((i,s)=>{if(i){if(i.code==="ENOENT")return r();return r(i)}if(areIdentical(a,s)){return r(new Error(errMsg(e,t,o)))}return checkParentPaths(e,a,p,o,r)}))}function checkParentPathsSync(e,a,t,o){const r=s.resolve(s.dirname(e));const n=s.resolve(s.dirname(t));if(n===r||n===s.parse(n).root)return;let p;try{p=i.statSync(n,{bigint:true})}catch(e){if(e.code==="ENOENT")return;throw e}if(areIdentical(a,p)){throw new Error(errMsg(e,t,o))}return checkParentPathsSync(e,a,n,o)}function areIdentical(e,a){return a.ino&&a.dev&&a.ino===e.ino&&a.dev===e.dev}function isSrcSubdir(e,a){const t=s.resolve(e).split(s.sep).filter((e=>e));const i=s.resolve(a).split(s.sep).filter((e=>e));return t.reduce(((e,a,t)=>e&&i[t]===a),true)}function errMsg(e,a,t){return`Cannot ${t} '${e}' to a subdirectory of itself, '${a}'.`}e.exports={checkPaths:checkPaths,checkPathsSync:checkPathsSync,checkParentPaths:checkParentPaths,checkParentPathsSync:checkParentPathsSync,isSrcSubdir:isSrcSubdir,areIdentical:areIdentical}},2274:(e,a,t)=>{"use strict";const i=t(8559);function utimesMillis(e,a,t,s){i.open(e,"r+",((e,o)=>{if(e)return s(e);i.futimes(o,a,t,(e=>{i.close(o,(a=>{if(s)s(e||a)}))}))}))}function utimesMillisSync(e,a,t){const s=i.openSync(e,"r+");i.futimesSync(s,a,t);return i.closeSync(s)}e.exports={utimesMillis:utimesMillis,utimesMillisSync:utimesMillisSync}},3163:e=>{"use strict";e.exports=clone;var a=Object.getPrototypeOf||function(e){return e.__proto__};function clone(e){if(e===null||typeof e!=="object")return e;if(e instanceof Object)var t={__proto__:a(e)};else var t=Object.create(null);Object.getOwnPropertyNames(e).forEach((function(a){Object.defineProperty(t,a,Object.getOwnPropertyDescriptor(e,a))}));return t}},8559:(e,a,t)=>{var i=t(7147);var s=t(8393);var o=t(9562);var r=t(3163);var n=t(3837);var p;var d;if(typeof Symbol==="function"&&typeof Symbol.for==="function"){p=Symbol.for("graceful-fs.queue");d=Symbol.for("graceful-fs.previous")}else{p="___graceful-fs.queue";d="___graceful-fs.previous"}function noop(){}function publishQueue(e,a){Object.defineProperty(e,p,{get:function(){return a}})}var l=noop;if(n.debuglog)l=n.debuglog("gfs4");else if(/\bgfs4\b/i.test(process.env.NODE_DEBUG||""))l=function(){var e=n.format.apply(n,arguments);e="GFS4: "+e.split(/\n/).join("\nGFS4: ");console.error(e)};if(!i[p]){var c=global[p]||[];publishQueue(i,c);i.close=function(e){function close(a,t){return e.call(i,a,(function(e){if(!e){resetQueue()}if(typeof t==="function")t.apply(this,arguments)}))}Object.defineProperty(close,d,{value:e});return close}(i.close);i.closeSync=function(e){function closeSync(a){e.apply(i,arguments);resetQueue()}Object.defineProperty(closeSync,d,{value:e});return closeSync}(i.closeSync);if(/\bgfs4\b/i.test(process.env.NODE_DEBUG||"")){process.on("exit",(function(){l(i[p]);t(9491).equal(i[p].length,0)}))}}if(!global[p]){publishQueue(global,i[p])}e.exports=patch(r(i));if(process.env.TEST_GRACEFUL_FS_GLOBAL_PATCH&&!i.__patched){e.exports=patch(i);i.__patched=true}function patch(e){s(e);e.gracefulify=patch;e.createReadStream=createReadStream;e.createWriteStream=createWriteStream;var a=e.readFile;e.readFile=readFile;function readFile(e,t,i){if(typeof t==="function")i=t,t=null;return go$readFile(e,t,i);function go$readFile(e,t,i,s){return a(e,t,(function(a){if(a&&(a.code==="EMFILE"||a.code==="ENFILE"))enqueue([go$readFile,[e,t,i],a,s||Date.now(),Date.now()]);else{if(typeof i==="function")i.apply(this,arguments)}}))}}var t=e.writeFile;e.writeFile=writeFile;function writeFile(e,a,i,s){if(typeof i==="function")s=i,i=null;return go$writeFile(e,a,i,s);function go$writeFile(e,a,i,s,o){return t(e,a,i,(function(t){if(t&&(t.code==="EMFILE"||t.code==="ENFILE"))enqueue([go$writeFile,[e,a,i,s],t,o||Date.now(),Date.now()]);else{if(typeof s==="function")s.apply(this,arguments)}}))}}var i=e.appendFile;if(i)e.appendFile=appendFile;function appendFile(e,a,t,s){if(typeof t==="function")s=t,t=null;return go$appendFile(e,a,t,s);function go$appendFile(e,a,t,s,o){return i(e,a,t,(function(i){if(i&&(i.code==="EMFILE"||i.code==="ENFILE"))enqueue([go$appendFile,[e,a,t,s],i,o||Date.now(),Date.now()]);else{if(typeof s==="function")s.apply(this,arguments)}}))}}var r=e.copyFile;if(r)e.copyFile=copyFile;function copyFile(e,a,t,i){if(typeof t==="function"){i=t;t=0}return go$copyFile(e,a,t,i);function go$copyFile(e,a,t,i,s){return r(e,a,t,(function(o){if(o&&(o.code==="EMFILE"||o.code==="ENFILE"))enqueue([go$copyFile,[e,a,t,i],o,s||Date.now(),Date.now()]);else{if(typeof i==="function")i.apply(this,arguments)}}))}}var n=e.readdir;e.readdir=readdir;var p=/^v[0-5]\./;function readdir(e,a,t){if(typeof a==="function")t=a,a=null;var i=p.test(process.version)?function go$readdir(e,a,t,i){return n(e,fs$readdirCallback(e,a,t,i))}:function go$readdir(e,a,t,i){return n(e,a,fs$readdirCallback(e,a,t,i))};return i(e,a,t);function fs$readdirCallback(e,a,t,s){return function(o,r){if(o&&(o.code==="EMFILE"||o.code==="ENFILE"))enqueue([i,[e,a,t],o,s||Date.now(),Date.now()]);else{if(r&&r.sort)r.sort();if(typeof t==="function")t.call(this,o,r)}}}}if(process.version.substr(0,4)==="v0.8"){var d=o(e);ReadStream=d.ReadStream;WriteStream=d.WriteStream}var l=e.ReadStream;if(l){ReadStream.prototype=Object.create(l.prototype);ReadStream.prototype.open=ReadStream$open}var c=e.WriteStream;if(c){WriteStream.prototype=Object.create(c.prototype);WriteStream.prototype.open=WriteStream$open}Object.defineProperty(e,"ReadStream",{get:function(){return ReadStream},set:function(e){ReadStream=e},enumerable:true,configurable:true});Object.defineProperty(e,"WriteStream",{get:function(){return WriteStream},set:function(e){WriteStream=e},enumerable:true,configurable:true});var u=ReadStream;Object.defineProperty(e,"FileReadStream",{get:function(){return u},set:function(e){u=e},enumerable:true,configurable:true});var m=WriteStream;Object.defineProperty(e,"FileWriteStream",{get:function(){return m},set:function(e){m=e},enumerable:true,configurable:true});function ReadStream(e,a){if(this instanceof ReadStream)return l.apply(this,arguments),this;else return ReadStream.apply(Object.create(ReadStream.prototype),arguments)}function ReadStream$open(){var e=this;open(e.path,e.flags,e.mode,(function(a,t){if(a){if(e.autoClose)e.destroy();e.emit("error",a)}else{e.fd=t;e.emit("open",t);e.read()}}))}function WriteStream(e,a){if(this instanceof WriteStream)return c.apply(this,arguments),this;else return WriteStream.apply(Object.create(WriteStream.prototype),arguments)}function WriteStream$open(){var e=this;open(e.path,e.flags,e.mode,(function(a,t){if(a){e.destroy();e.emit("error",a)}else{e.fd=t;e.emit("open",t)}}))}function createReadStream(a,t){return new e.ReadStream(a,t)}function createWriteStream(a,t){return new e.WriteStream(a,t)}var v=e.open;e.open=open;function open(e,a,t,i){if(typeof t==="function")i=t,t=null;return go$open(e,a,t,i);function go$open(e,a,t,i,s){return v(e,a,t,(function(o,r){if(o&&(o.code==="EMFILE"||o.code==="ENFILE"))enqueue([go$open,[e,a,t,i],o,s||Date.now(),Date.now()]);else{if(typeof i==="function")i.apply(this,arguments)}}))}}return e}function enqueue(e){l("ENQUEUE",e[0].name,e[1]);i[p].push(e);retry()}var u;function resetQueue(){var e=Date.now();for(var a=0;a2){i[p][a][3]=e;i[p][a][4]=e}}retry()}function retry(){clearTimeout(u);u=undefined;if(i[p].length===0)return;var e=i[p].shift();var a=e[0];var t=e[1];var s=e[2];var o=e[3];var r=e[4];if(o===undefined){l("RETRY",a.name,t);a.apply(null,t)}else if(Date.now()-o>=6e4){l("TIMEOUT",a.name,t);var n=t.pop();if(typeof n==="function")n.call(null,s)}else{var d=Date.now()-r;var c=Math.max(r-o,1);var m=Math.min(c*1.2,100);if(d>=m){l("RETRY",a.name,t);a.apply(null,t.concat([o]))}else{i[p].push(e)}}if(u===undefined){u=setTimeout(retry,0)}}},9562:(e,a,t)=>{var i=t(2781).Stream;e.exports=legacy;function legacy(e){return{ReadStream:ReadStream,WriteStream:WriteStream};function ReadStream(a,t){if(!(this instanceof ReadStream))return new ReadStream(a,t);i.call(this);var s=this;this.path=a;this.fd=null;this.readable=true;this.paused=false;this.flags="r";this.mode=438;this.bufferSize=64*1024;t=t||{};var o=Object.keys(t);for(var r=0,n=o.length;rthis.end){throw new Error("start must be <= end")}this.pos=this.start}if(this.fd!==null){process.nextTick((function(){s._read()}));return}e.open(this.path,this.flags,this.mode,(function(e,a){if(e){s.emit("error",e);s.readable=false;return}s.fd=a;s.emit("open",a);s._read()}))}function WriteStream(a,t){if(!(this instanceof WriteStream))return new WriteStream(a,t);i.call(this);this.path=a;this.fd=null;this.writable=true;this.flags="w";this.encoding="binary";this.mode=438;this.bytesWritten=0;t=t||{};var s=Object.keys(t);for(var o=0,r=s.length;o= zero")}this.pos=this.start}this.busy=false;this._queue=[];if(this.fd===null){this._open=e.open;this._queue.push([this._open,this.path,this.flags,this.mode,undefined]);this.flush()}}}},8393:(e,a,t)=>{var i=t(2057);var s=process.cwd;var o=null;var r=process.env.GRACEFUL_FS_PLATFORM||process.platform;process.cwd=function(){if(!o)o=s.call(process);return o};try{process.cwd()}catch(e){}if(typeof process.chdir==="function"){var n=process.chdir;process.chdir=function(e){o=null;n.call(process,e)};if(Object.setPrototypeOf)Object.setPrototypeOf(process.chdir,n)}e.exports=patch;function patch(e){if(i.hasOwnProperty("O_SYMLINK")&&process.version.match(/^v0\.6\.[0-2]|^v0\.5\./)){patchLchmod(e)}if(!e.lutimes){patchLutimes(e)}e.chown=chownFix(e.chown);e.fchown=chownFix(e.fchown);e.lchown=chownFix(e.lchown);e.chmod=chmodFix(e.chmod);e.fchmod=chmodFix(e.fchmod);e.lchmod=chmodFix(e.lchmod);e.chownSync=chownFixSync(e.chownSync);e.fchownSync=chownFixSync(e.fchownSync);e.lchownSync=chownFixSync(e.lchownSync);e.chmodSync=chmodFixSync(e.chmodSync);e.fchmodSync=chmodFixSync(e.fchmodSync);e.lchmodSync=chmodFixSync(e.lchmodSync);e.stat=statFix(e.stat);e.fstat=statFix(e.fstat);e.lstat=statFix(e.lstat);e.statSync=statFixSync(e.statSync);e.fstatSync=statFixSync(e.fstatSync);e.lstatSync=statFixSync(e.lstatSync);if(e.chmod&&!e.lchmod){e.lchmod=function(e,a,t){if(t)process.nextTick(t)};e.lchmodSync=function(){}}if(e.chown&&!e.lchown){e.lchown=function(e,a,t,i){if(i)process.nextTick(i)};e.lchownSync=function(){}}if(r==="win32"){e.rename=typeof e.rename!=="function"?e.rename:function(a){function rename(t,i,s){var o=Date.now();var r=0;a(t,i,(function CB(n){if(n&&(n.code==="EACCES"||n.code==="EPERM")&&Date.now()-o<6e4){setTimeout((function(){e.stat(i,(function(e,o){if(e&&e.code==="ENOENT")a(t,i,CB);else s(n)}))}),r);if(r<100)r+=10;return}if(s)s(n)}))}if(Object.setPrototypeOf)Object.setPrototypeOf(rename,a);return rename}(e.rename)}e.read=typeof e.read!=="function"?e.read:function(a){function read(t,i,s,o,r,n){var p;if(n&&typeof n==="function"){var d=0;p=function(l,c,u){if(l&&l.code==="EAGAIN"&&d<10){d++;return a.call(e,t,i,s,o,r,p)}n.apply(this,arguments)}}return a.call(e,t,i,s,o,r,p)}if(Object.setPrototypeOf)Object.setPrototypeOf(read,a);return read}(e.read);e.readSync=typeof e.readSync!=="function"?e.readSync:function(a){return function(t,i,s,o,r){var n=0;while(true){try{return a.call(e,t,i,s,o,r)}catch(e){if(e.code==="EAGAIN"&&n<10){n++;continue}throw e}}}}(e.readSync);function patchLchmod(e){e.lchmod=function(a,t,s){e.open(a,i.O_WRONLY|i.O_SYMLINK,t,(function(a,i){if(a){if(s)s(a);return}e.fchmod(i,t,(function(a){e.close(i,(function(e){if(s)s(a||e)}))}))}))};e.lchmodSync=function(a,t){var s=e.openSync(a,i.O_WRONLY|i.O_SYMLINK,t);var o=true;var r;try{r=e.fchmodSync(s,t);o=false}finally{if(o){try{e.closeSync(s)}catch(e){}}else{e.closeSync(s)}}return r}}function patchLutimes(e){if(i.hasOwnProperty("O_SYMLINK")&&e.futimes){e.lutimes=function(a,t,s,o){e.open(a,i.O_SYMLINK,(function(a,i){if(a){if(o)o(a);return}e.futimes(i,t,s,(function(a){e.close(i,(function(e){if(o)o(a||e)}))}))}))};e.lutimesSync=function(a,t,s){var o=e.openSync(a,i.O_SYMLINK);var r;var n=true;try{r=e.futimesSync(o,t,s);n=false}finally{if(n){try{e.closeSync(o)}catch(e){}}else{e.closeSync(o)}}return r}}else if(e.futimes){e.lutimes=function(e,a,t,i){if(i)process.nextTick(i)};e.lutimesSync=function(){}}}function chmodFix(a){if(!a)return a;return function(t,i,s){return a.call(e,t,i,(function(e){if(chownErOk(e))e=null;if(s)s.apply(this,arguments)}))}}function chmodFixSync(a){if(!a)return a;return function(t,i){try{return a.call(e,t,i)}catch(e){if(!chownErOk(e))throw e}}}function chownFix(a){if(!a)return a;return function(t,i,s,o){return a.call(e,t,i,s,(function(e){if(chownErOk(e))e=null;if(o)o.apply(this,arguments)}))}}function chownFixSync(a){if(!a)return a;return function(t,i,s){try{return a.call(e,t,i,s)}catch(e){if(!chownErOk(e))throw e}}}function statFix(a){if(!a)return a;return function(t,i,s){if(typeof i==="function"){s=i;i=null}function callback(e,a){if(a){if(a.uid<0)a.uid+=4294967296;if(a.gid<0)a.gid+=4294967296}if(s)s.apply(this,arguments)}return i?a.call(e,t,i,callback):a.call(e,t,callback)}}function statFixSync(a){if(!a)return a;return function(t,i){var s=i?a.call(e,t,i):a.call(e,t);if(s){if(s.uid<0)s.uid+=4294967296;if(s.gid<0)s.gid+=4294967296}return s}}function chownErOk(e){if(!e)return true;if(e.code==="ENOSYS")return true;var a=!process.getuid||process.getuid()!==0;if(a){if(e.code==="EINVAL"||e.code==="EPERM")return true}return false}}},748:e=>{"use strict";e.exports=(e,a=process.argv)=>{const t=e.startsWith("-")?"":e.length===1?"-":"--";const i=a.indexOf(t+e);const s=a.indexOf("--");return i!==-1&&(s===-1||i{"use strict";Object.defineProperty(a,"__esModule",{value:true}); /*! * is-plain-object * diff --git a/src/logic/jest/doBadgesExist.test.ts b/src/logic/jest/doBadgesExist.test.ts index c8ac5e5..889268b 100644 --- a/src/logic/jest/doBadgesExist.test.ts +++ b/src/logic/jest/doBadgesExist.test.ts @@ -5,6 +5,8 @@ import { doBadgesExist } from './doBadgesExist'; jest.mock('fs-extra'); describe('doBadgesExist function', () => { + const outputPath = './badges'; + it('should return false if one file does not exist', async () => { jest .mocked(pathExists) @@ -14,7 +16,7 @@ describe('doBadgesExist function', () => { .mockImplementationOnce(() => true as never) .mockImplementationOnce(() => true as never); - const result = await doBadgesExist(); + const result = await doBadgesExist(outputPath); expect(result).toBe(false); }); @@ -28,7 +30,7 @@ describe('doBadgesExist function', () => { .mockImplementationOnce(() => true as never) .mockImplementationOnce(() => true as never); - const result = await doBadgesExist(); + const result = await doBadgesExist(outputPath); expect(result).toBe(true); }); diff --git a/src/logic/jest/doBadgesExist.ts b/src/logic/jest/doBadgesExist.ts index 5ed1ad5..b3dc8cb 100644 --- a/src/logic/jest/doBadgesExist.ts +++ b/src/logic/jest/doBadgesExist.ts @@ -1,8 +1,6 @@ import { pathExists } from 'fs-extra'; -export const doBadgesExist = async ( - outputPath = './badges', -): Promise => { +export const doBadgesExist = async (outputPath: string): Promise => { const files = [ 'coverage-branches.svg', 'coverage-functions.svg', diff --git a/src/logic/jest/hasCoverageEvolved.test.ts b/src/logic/jest/hasCoverageEvolved.test.ts index 34e0782..3d003c8 100644 --- a/src/logic/jest/hasCoverageEvolved.test.ts +++ b/src/logic/jest/hasCoverageEvolved.test.ts @@ -5,8 +5,10 @@ import { hasCoverageEvolved } from './hasCoverageEvolved'; jest.mock('@actions/exec'); describe('hasCoverageEvolved function', () => { + const outputPath = './badges'; + it('should return true if coverage folder does not exist', async () => { - const result = await hasCoverageEvolved(false); + const result = await hasCoverageEvolved(false, outputPath); expect(result).toBe(true); }); @@ -14,7 +16,7 @@ describe('hasCoverageEvolved function', () => { it('should return true if diff returns one', async () => { jest.mocked(exec).mockResolvedValueOnce(1); - const result = await hasCoverageEvolved(true); + const result = await hasCoverageEvolved(true, outputPath); expect(result).toBe(true); }); @@ -22,7 +24,7 @@ describe('hasCoverageEvolved function', () => { it('should return false if diff returns zero', async () => { jest.mocked(exec).mockResolvedValueOnce(0); - const result = await hasCoverageEvolved(true); + const result = await hasCoverageEvolved(true, outputPath); expect(result).toBe(false); }); diff --git a/src/logic/jest/hasCoverageEvolved.ts b/src/logic/jest/hasCoverageEvolved.ts index 4a78db3..9dd55c8 100644 --- a/src/logic/jest/hasCoverageEvolved.ts +++ b/src/logic/jest/hasCoverageEvolved.ts @@ -2,12 +2,13 @@ import { exec } from '@actions/exec'; export const hasCoverageEvolved = async ( badgesExist: boolean, + outputPath: string, ): Promise => { if (!badgesExist) { return true; } - const code = await exec('git diff', ['--quiet', './badges/*'], { + const code = await exec('git diff', ['--quiet', `${outputPath}/*`], { ignoreReturnCode: true, }); diff --git a/src/workflow/actionWorkflow.test.ts b/src/workflow/actionWorkflow.test.ts index ec11944..53e17c1 100644 --- a/src/workflow/actionWorkflow.test.ts +++ b/src/workflow/actionWorkflow.test.ts @@ -137,6 +137,9 @@ describe('actionWorkflow function', () => { }); it('should generate badges from the default summary path', async () => { + const summaryPath = './coverage/coverage-summary.json'; + const outputPath = './badges'; + jest.mocked(isBranchValidForBadgesGeneration).mockReturnValueOnce(true); jest.mocked(isJestCoverageReportAvailable).mockResolvedValueOnce(true); jest.mocked(doBadgesExist).mockResolvedValueOnce(true); @@ -144,13 +147,13 @@ describe('actionWorkflow function', () => { jest .mocked(getInput) .mockReturnValueOnce('') - .mockReturnValueOnce('') - .mockReturnValueOnce(''); + .mockReturnValueOnce(summaryPath) + .mockReturnValueOnce(outputPath); await actionWorkflow(); expect(generateBadges).toHaveBeenCalledTimes(1); - expect(generateBadges).toHaveBeenCalledWith(undefined); + expect(generateBadges).toHaveBeenCalledWith(summaryPath, outputPath); expect(setGitConfig).toHaveBeenCalledTimes(1); expect(pushBadges).toHaveBeenCalledTimes(1); diff --git a/src/workflow/actionWorkflow.ts b/src/workflow/actionWorkflow.ts index e432e8c..dda0136 100644 --- a/src/workflow/actionWorkflow.ts +++ b/src/workflow/actionWorkflow.ts @@ -30,25 +30,22 @@ export const actionWorkflow = async (): Promise => { const summaryPathInput = getInput('coverage-summary-path'); const summaryPath = summaryPathInput === '' ? undefined : summaryPathInput; + const outputPath = getInput('output-folder'); + // this must be checked before generating badges (duh!) + const badgesExist = await doBadgesExist(outputPath); + info( `🔶 Generating badges from ${ summaryPath ? summaryPath : 'default coverage summary path' }`, ); - const outputPath = getInput('output-folder'); - if (outputPath === '') { - await generateBadges(summaryPath); - } else { - await generateBadges(summaryPath, outputPath); - } + await generateBadges(summaryPath, outputPath); if (!shouldCommit) { return info("🔶 `no-commit` set to true: badges won't be committed"); } - const badgesExist = await doBadgesExist(outputPath); - - const hasEvolved = await hasCoverageEvolved(badgesExist); + const hasEvolved = await hasCoverageEvolved(badgesExist, outputPath); if (!hasEvolved) { return info('🔶 Coverage has not evolved, no action required.'); }