From 1a483dfcb5b36dfd784533a915036f7753b17361 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C3=ABl=20De=20Boey?= Date: Fri, 18 Jun 2021 13:39:11 +0200 Subject: [PATCH 1/7] feat: default `github_token` to `github.token` --- action.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/action.yml b/action.yml index 14ad0671f..58cd2772b 100644 --- a/action.yml +++ b/action.yml @@ -14,6 +14,7 @@ inputs: github_token: description: 'Set a generated GITHUB_TOKEN for pushing to the remote branch.' required: false + default: ${{ github.token }} personal_token: description: 'Set a personal access token for pushing to the remote branch.' required: false From 67ad4114f0f39e6f999d595b2763b91bf84ec4ce Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C3=ABl=20De=20Boey?= Date: Fri, 18 Jun 2021 13:45:45 +0200 Subject: [PATCH 2/7] Update README.md --- README.md | 33 --------------------------------- 1 file changed, 33 deletions(-) diff --git a/README.md b/README.md index 24246f93e..6a9cb028c 100644 --- a/README.md +++ b/README.md @@ -20,15 +20,9 @@ The next example step will deploy `./public` directory to the remote `gh-pages` - name: Deploy uses: peaceiris/actions-gh-pages@v3 with: - github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: ./public ``` -For newbies of GitHub Actions: -Note that the `GITHUB_TOKEN` is **NOT** a personal access token. -A GitHub Actions runner automatically creates a `GITHUB_TOKEN` secret to authenticate in your workflow. -So, you can start to deploy immediately without any configuration. - ## Supported Tokens @@ -157,7 +151,6 @@ jobs: uses: peaceiris/actions-gh-pages@v3 if: github.ref == 'refs/heads/main' with: - github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: ./public ``` @@ -222,7 +215,6 @@ The default is `gh-pages`. - name: Deploy uses: peaceiris/actions-gh-pages@v3 with: - github_token: ${{ secrets.GITHUB_TOKEN }} publish_branch: your-branch # default: gh-pages ``` @@ -234,7 +226,6 @@ A source directory to deploy to GitHub Pages. The default is `public`. - name: Deploy uses: peaceiris/actions-gh-pages@v3 with: - github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: ./out # default: public ``` @@ -249,7 +240,6 @@ A destination subdirectory on a publishing branch. The default is empty. - name: Deploy uses: peaceiris/actions-gh-pages@v3 with: - github_token: ${{ secrets.GITHUB_TOKEN }} destination_dir: subdir ``` @@ -266,7 +256,6 @@ Values should be split with a comma. - name: Deploy uses: peaceiris/actions-gh-pages@v3 with: - github_token: ${{ secrets.GITHUB_TOKEN }} exclude_assets: '.github,exclude-file1,exclude-file2' ``` @@ -278,7 +267,6 @@ Set `exclude_assets` to empty for including the `.github` directory to deploymen with: deploy_key: ${{ secrets.ACTIONS_DEPLOY_KEY }} # Recommended for this usage # personal_token: ${{ secrets.PERSONAL_TOKEN }} # An alternative - # github_token: ${{ secrets.GITHUB_TOKEN }} # This does not work for this usage exclude_assets: '' ``` @@ -288,7 +276,6 @@ The `exclude_assets` option supports glob patterns. - name: Deploy uses: peaceiris/actions-gh-pages@v3 with: - github_token: ${{ secrets.GITHUB_TOKEN }} exclude_assets: '.github,exclude-file.txt,exclude-dir/**.txt' ``` @@ -303,7 +290,6 @@ For more details about the `CNAME` file, read the official documentation: [Manag - name: Deploy uses: peaceiris/actions-gh-pages@v3 with: - github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: ./public cname: github.com ``` @@ -323,7 +309,6 @@ Bypassing Jekyll makes the deployment faster and is necessary if you are deployi - name: Deploy uses: peaceiris/actions-gh-pages@v3 with: - github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: ./public enable_jekyll: true ``` @@ -340,7 +325,6 @@ For example: - name: Deploy uses: peaceiris/actions-gh-pages@v3 with: - github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: ./public allow_empty_commit: true ``` @@ -360,7 +344,6 @@ For example: - name: Deploy uses: peaceiris/actions-gh-pages@v3 with: - github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: ./public keep_files: true ``` @@ -406,7 +389,6 @@ This allows you to make your publish branch with only the latest commit. - name: Deploy uses: peaceiris/actions-gh-pages@v3 with: - github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: ./public force_orphan: true ``` @@ -420,7 +402,6 @@ A commit is always created with the same user. - name: Deploy uses: peaceiris/actions-gh-pages@v3 with: - github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: ./public user_name: 'github-actions[bot]' user_email: 'github-actions[bot]@users.noreply.github.com' @@ -437,7 +418,6 @@ When we create a commit with a message `docs: Update some post`, a deployment co - name: Deploy uses: peaceiris/actions-gh-pages@v3 with: - github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: ./public commit_message: ${{ github.event.head_commit.message }} ``` @@ -451,7 +431,6 @@ use the `full_commit_message` option instead of the `commit_message` option. - name: Deploy uses: peaceiris/actions-gh-pages@v3 with: - github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: ./public full_commit_message: ${{ github.event.head_commit.message }} ``` @@ -489,7 +468,6 @@ jobs: - name: Deploy uses: peaceiris/actions-gh-pages@v3 with: - github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: ./public tag_name: ${{ steps.prepare_tag.outputs.deploy_tag_name }} tag_message: 'Deployment ${{ steps.prepare_tag.outputs.tag_name }}' @@ -661,7 +639,6 @@ jobs: uses: peaceiris/actions-gh-pages@v3 if: github.ref == 'refs/heads/main' with: - github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: ./public ``` @@ -709,7 +686,6 @@ jobs: uses: peaceiris/actions-gh-pages@v3 if: github.ref == 'refs/heads/main' with: - github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: ./public ``` @@ -762,7 +738,6 @@ jobs: uses: peaceiris/actions-gh-pages@v3 if: github.ref == 'refs/heads/main' with: - github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: ./out ``` @@ -811,7 +786,6 @@ jobs: uses: peaceiris/actions-gh-pages@v3 if: github.ref == 'refs/heads/main' with: - github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: ./dist ``` @@ -868,7 +842,6 @@ jobs: uses: peaceiris/actions-gh-pages@v3 if: github.ref == 'refs/heads/main' with: - github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: ./website/build ``` @@ -928,7 +901,6 @@ jobs: uses: peaceiris/actions-gh-pages@v3 if: github.ref == 'refs/heads/main' with: - github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: ./site ``` @@ -967,7 +939,6 @@ jobs: uses: peaceiris/actions-gh-pages@v3 if: github.ref == 'refs/heads/main' with: - github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: ./book ``` @@ -1009,7 +980,6 @@ jobs: uses: peaceiris/actions-gh-pages@v3 if: github.ref == 'refs/heads/main' with: - github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: ./build/web ``` @@ -1056,7 +1026,6 @@ jobs: uses: peaceiris/actions-gh-pages@v3 if: github.ref == 'refs/heads/main' with: - github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: ./public ``` @@ -1084,7 +1053,6 @@ jobs: - name: Deploy to GitHub Pages uses: peaceiris/actions-gh-pages@v3 with: - github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: ./ allow_empty_commit: true enable_jekyll: true @@ -1138,7 +1106,6 @@ jobs: uses: peaceiris/actions-gh-pages@v3 if: github.ref == 'refs/heads/main' with: - github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: ./Output ``` From 62e5a4cc498814c25eef5dfcfacb2a13d59bdfe0 Mon Sep 17 00:00:00 2001 From: peaceiris <30958501+peaceiris@users.noreply.github.com> Date: Thu, 9 Sep 2021 14:03:22 +0900 Subject: [PATCH 3/7] Update github_token section --- README.md | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 3a7a9cf48..c3c7dce3c 100644 --- a/README.md +++ b/README.md @@ -175,9 +175,10 @@ jobs: ### ⭐️ Set Runner's Access Token `github_token` -**This option is for `GITHUB_TOKEN`, not a personal access token.** - -A GitHub Actions runner automatically creates a `GITHUB_TOKEN` secret to use in your workflow. You can use the `GITHUB_TOKEN` to authenticate in a workflow run. +For newbies of GitHub Actions: +Note that this option is for `GITHUB_TOKEN`, **NOT** a personal access token. +A GitHub Actions runner automatically creates a `GITHUB_TOKEN` secret to authenticate in your workflow. +So, you can start to deploy immediately without any configuration. ```yaml - name: Deploy @@ -187,7 +188,7 @@ A GitHub Actions runner automatically creates a `GITHUB_TOKEN` secret to use in publish_dir: ./public ``` -For more details about `GITHUB_TOKEN`: [Authenticating with the GITHUB_TOKEN - GitHub Help](https://help.github.com/en/actions/configuring-and-managing-workflows/authenticating-with-the-github_token) +For more details about `GITHUB_TOKEN`: [Authenticating with the GITHUB_TOKEN - GitHub Help](https://docs.github.com/en/actions/reference/authentication-in-a-workflow) ### ⭐️ Set SSH Private Key `deploy_key` From 1113f71a95a5e112bd45ad8592ee33efcf5714c6 Mon Sep 17 00:00:00 2001 From: peaceiris <30958501+peaceiris@users.noreply.github.com> Date: Thu, 9 Sep 2021 21:40:37 +0900 Subject: [PATCH 4/7] Remove token inputs --- README.md | 2 -- 1 file changed, 2 deletions(-) diff --git a/README.md b/README.md index c3c7dce3c..ad0d37411 100644 --- a/README.md +++ b/README.md @@ -273,8 +273,6 @@ Set `exclude_assets` to empty for including the `.github` directory to deploymen - name: Deploy uses: peaceiris/actions-gh-pages@v3 with: - deploy_key: ${{ secrets.ACTIONS_DEPLOY_KEY }} # Recommended for this usage - # personal_token: ${{ secrets.PERSONAL_TOKEN }} # An alternative exclude_assets: '' ``` From 631dd15167d5d3dd38e31684f6234a630fbc84e9 Mon Sep 17 00:00:00 2001 From: peaceiris <30958501+peaceiris@users.noreply.github.com> Date: Thu, 9 Sep 2021 23:50:07 +0900 Subject: [PATCH 5/7] Check PersonalToken before GithubToken --- src/set-tokens.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/set-tokens.ts b/src/set-tokens.ts index 277e7fc0f..3a182c5ae 100644 --- a/src/set-tokens.ts +++ b/src/set-tokens.ts @@ -121,6 +121,8 @@ export async function setTokens(inps: Inputs): Promise { ); if (inps.DeployKey) { return setSSHKey(inps, publishRepo); + } else if (inps.PersonalToken) { + return setPersonalToken(inps.PersonalToken, publishRepo); } else if (inps.GithubToken) { const context = github.context; const ref = context.ref; @@ -133,8 +135,6 @@ export async function setTokens(inps: Inputs): Promise { ref, eventName ); - } else if (inps.PersonalToken) { - return setPersonalToken(inps.PersonalToken, publishRepo); } else { throw new Error('not found deploy key or tokens'); } From c4b29bc504fcc9e55f0947596a2a29f0a5e8d72e Mon Sep 17 00:00:00 2001 From: peaceiris <30958501+peaceiris@users.noreply.github.com> Date: Thu, 9 Sep 2021 23:58:57 +0900 Subject: [PATCH 6/7] pre-release --- lib/exec-child.js | 1 + lib/index.js | 1 + 2 files changed, 2 insertions(+) create mode 100644 lib/exec-child.js create mode 100644 lib/index.js diff --git a/lib/exec-child.js b/lib/exec-child.js new file mode 100644 index 000000000..b8598bd92 --- /dev/null +++ b/lib/exec-child.js @@ -0,0 +1 @@ +module.exports=(()=>{var e={607:(e,r,t)=>{e=t.nmd(e);if(require.main!==e){throw new Error("This file should not be required")}var i=t(129);var s=t(747);var a=process.argv[2];var d=s.readFileSync(a,"utf8");var o=JSON.parse(d);var p=o.command;var _=o.execOptions;var c=o.pipe;var u=o.stdoutFile;var n=o.stderrFile;var l=i.exec(p,_,function(e){if(!e){process.exitCode=0}else if(e.code===undefined){process.exitCode=1}else{process.exitCode=e.code}});var v=s.createWriteStream(u);var f=s.createWriteStream(n);l.stdout.pipe(v);l.stderr.pipe(f);l.stdout.pipe(process.stdout);l.stderr.pipe(process.stderr);if(c){l.stdin.end(c)}},129:e=>{"use strict";e.exports=require("child_process")},747:e=>{"use strict";e.exports=require("fs")}};var r={};function __nccwpck_require__(t){if(r[t]){return r[t].exports}var i=r[t]={id:t,loaded:false,exports:{}};var s=true;try{e[t](i,i.exports,__nccwpck_require__);s=false}finally{if(s)delete r[t]}i.loaded=true;return i.exports}(()=>{__nccwpck_require__.nmd=(e=>{e.paths=[];if(!e.children)e.children=[];return e})})();__nccwpck_require__.ab=__dirname+"/";return __nccwpck_require__(607)})(); \ No newline at end of file diff --git a/lib/index.js b/lib/index.js new file mode 100644 index 000000000..beb6c4b17 --- /dev/null +++ b/lib/index.js @@ -0,0 +1 @@ +module.exports=(()=>{var __webpack_modules__={7351:function(e,t,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,t,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,s){if(s===undefined)s=r;e[s]=t[r]});var n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))s(t,e,r);n(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.issue=t.issueCommand=void 0;const i=o(r(2087));const a=r(5278);function issueCommand(e,t,r){const s=new Command(e,t,r);process.stdout.write(s.toString()+i.EOL)}t.issueCommand=issueCommand;function issue(e,t=""){issueCommand(e,{},t)}t.issue=issue;const c="::";class Command{constructor(e,t,r){if(!e){e="missing.command"}this.command=e;this.properties=t;this.message=r}toString(){let e=c+this.command;if(this.properties&&Object.keys(this.properties).length>0){e+=" ";let t=true;for(const r in this.properties){if(this.properties.hasOwnProperty(r)){const s=this.properties[r];if(s){if(t){t=false}else{e+=","}e+=`${r}=${escapeProperty(s)}`}}}}e+=`${c}${escapeData(this.message)}`;return e}}function escapeData(e){return a.toCommandValue(e).replace(/%/g,"%25").replace(/\r/g,"%0D").replace(/\n/g,"%0A")}function escapeProperty(e){return a.toCommandValue(e).replace(/%/g,"%25").replace(/\r/g,"%0D").replace(/\n/g,"%0A").replace(/:/g,"%3A").replace(/,/g,"%2C")}},2186:function(e,t,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,t,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,s){if(s===undefined)s=r;e[s]=t[r]});var n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))s(t,e,r);n(t,e);return t};var i=this&&this.__awaiter||function(e,t,r,s){function adopt(e){return e instanceof r?e:new r(function(t){t(e)})}return new(r||(r=Promise))(function(r,n){function fulfilled(e){try{step(s.next(e))}catch(e){n(e)}}function rejected(e){try{step(s["throw"](e))}catch(e){n(e)}}function step(e){e.done?r(e.value):adopt(e.value).then(fulfilled,rejected)}step((s=s.apply(e,t||[])).next())})};Object.defineProperty(t,"__esModule",{value:true});t.getState=t.saveState=t.group=t.endGroup=t.startGroup=t.info=t.notice=t.warning=t.error=t.debug=t.isDebug=t.setFailed=t.setCommandEcho=t.setOutput=t.getBooleanInput=t.getMultilineInput=t.getInput=t.addPath=t.setSecret=t.exportVariable=t.ExitCode=void 0;const a=r(7351);const c=r(717);const u=r(5278);const l=o(r(2087));const f=o(r(5622));var p;(function(e){e[e["Success"]=0]="Success";e[e["Failure"]=1]="Failure"})(p=t.ExitCode||(t.ExitCode={}));function exportVariable(e,t){const r=u.toCommandValue(t);process.env[e]=r;const s=process.env["GITHUB_ENV"]||"";if(s){const t="_GitHubActionsFileCommandDelimeter_";const s=`${e}<<${t}${l.EOL}${r}${l.EOL}${t}`;c.issueCommand("ENV",s)}else{a.issueCommand("set-env",{name:e},r)}}t.exportVariable=exportVariable;function setSecret(e){a.issueCommand("add-mask",{},e)}t.setSecret=setSecret;function addPath(e){const t=process.env["GITHUB_PATH"]||"";if(t){c.issueCommand("PATH",e)}else{a.issueCommand("add-path",{},e)}process.env["PATH"]=`${e}${f.delimiter}${process.env["PATH"]}`}t.addPath=addPath;function getInput(e,t){const r=process.env[`INPUT_${e.replace(/ /g,"_").toUpperCase()}`]||"";if(t&&t.required&&!r){throw new Error(`Input required and not supplied: ${e}`)}if(t&&t.trimWhitespace===false){return r}return r.trim()}t.getInput=getInput;function getMultilineInput(e,t){const r=getInput(e,t).split("\n").filter(e=>e!=="");return r}t.getMultilineInput=getMultilineInput;function getBooleanInput(e,t){const r=["true","True","TRUE"];const s=["false","False","FALSE"];const n=getInput(e,t);if(r.includes(n))return true;if(s.includes(n))return false;throw new TypeError(`Input does not meet YAML 1.2 "Core Schema" specification: ${e}\n`+`Support boolean input list: \`true | True | TRUE | false | False | FALSE\``)}t.getBooleanInput=getBooleanInput;function setOutput(e,t){process.stdout.write(l.EOL);a.issueCommand("set-output",{name:e},t)}t.setOutput=setOutput;function setCommandEcho(e){a.issue("echo",e?"on":"off")}t.setCommandEcho=setCommandEcho;function setFailed(e){process.exitCode=p.Failure;error(e)}t.setFailed=setFailed;function isDebug(){return process.env["RUNNER_DEBUG"]==="1"}t.isDebug=isDebug;function debug(e){a.issueCommand("debug",{},e)}t.debug=debug;function error(e,t={}){a.issueCommand("error",u.toCommandProperties(t),e instanceof Error?e.toString():e)}t.error=error;function warning(e,t={}){a.issueCommand("warning",u.toCommandProperties(t),e instanceof Error?e.toString():e)}t.warning=warning;function notice(e,t={}){a.issueCommand("notice",u.toCommandProperties(t),e instanceof Error?e.toString():e)}t.notice=notice;function info(e){process.stdout.write(e+l.EOL)}t.info=info;function startGroup(e){a.issue("group",e)}t.startGroup=startGroup;function endGroup(){a.issue("endgroup")}t.endGroup=endGroup;function group(e,t){return i(this,void 0,void 0,function*(){startGroup(e);let r;try{r=yield t()}finally{endGroup()}return r})}t.group=group;function saveState(e,t){a.issueCommand("save-state",{name:e},t)}t.saveState=saveState;function getState(e){return process.env[`STATE_${e}`]||""}t.getState=getState},717:function(e,t,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,t,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,s){if(s===undefined)s=r;e[s]=t[r]});var n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))s(t,e,r);n(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.issueCommand=void 0;const i=o(r(5747));const a=o(r(2087));const c=r(5278);function issueCommand(e,t){const r=process.env[`GITHUB_${e}`];if(!r){throw new Error(`Unable to find environment variable for file command ${e}`)}if(!i.existsSync(r)){throw new Error(`Missing file at path: ${r}`)}i.appendFileSync(r,`${c.toCommandValue(t)}${a.EOL}`,{encoding:"utf8"})}t.issueCommand=issueCommand},5278:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.toCommandProperties=t.toCommandValue=void 0;function toCommandValue(e){if(e===null||e===undefined){return""}else if(typeof e==="string"||e instanceof String){return e}return JSON.stringify(e)}t.toCommandValue=toCommandValue;function toCommandProperties(e){if(!Object.keys(e).length){return{}}return{title:e.title,line:e.startLine,endLine:e.endLine,col:e.startColumn,endColumn:e.endColumn}}t.toCommandProperties=toCommandProperties},1514:function(e,t,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,t,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,s){if(s===undefined)s=r;e[s]=t[r]});var n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))s(t,e,r);n(t,e);return t};var i=this&&this.__awaiter||function(e,t,r,s){function adopt(e){return e instanceof r?e:new r(function(t){t(e)})}return new(r||(r=Promise))(function(r,n){function fulfilled(e){try{step(s.next(e))}catch(e){n(e)}}function rejected(e){try{step(s["throw"](e))}catch(e){n(e)}}function step(e){e.done?r(e.value):adopt(e.value).then(fulfilled,rejected)}step((s=s.apply(e,t||[])).next())})};Object.defineProperty(t,"__esModule",{value:true});t.getExecOutput=t.exec=void 0;const a=r(4304);const c=o(r(8159));function exec(e,t,r){return i(this,void 0,void 0,function*(){const s=c.argStringToArray(e);if(s.length===0){throw new Error(`Parameter 'commandLine' cannot be null or empty.`)}const n=s[0];t=s.slice(1).concat(t||[]);const o=new c.ToolRunner(n,t,r);return o.exec()})}t.exec=exec;function getExecOutput(e,t,r){var s,n;return i(this,void 0,void 0,function*(){let o="";let i="";const c=new a.StringDecoder("utf8");const u=new a.StringDecoder("utf8");const l=(s=r===null||r===void 0?void 0:r.listeners)===null||s===void 0?void 0:s.stdout;const f=(n=r===null||r===void 0?void 0:r.listeners)===null||n===void 0?void 0:n.stderr;const p=e=>{i+=u.write(e);if(f){f(e)}};const d=e=>{o+=c.write(e);if(l){l(e)}};const h=Object.assign(Object.assign({},r===null||r===void 0?void 0:r.listeners),{stdout:d,stderr:p});const g=yield exec(e,t,Object.assign(Object.assign({},r),{listeners:h}));o+=c.end();i+=u.end();return{exitCode:g,stdout:o,stderr:i}})}t.getExecOutput=getExecOutput},8159:function(e,t,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,t,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,s){if(s===undefined)s=r;e[s]=t[r]});var n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))s(t,e,r);n(t,e);return t};var i=this&&this.__awaiter||function(e,t,r,s){function adopt(e){return e instanceof r?e:new r(function(t){t(e)})}return new(r||(r=Promise))(function(r,n){function fulfilled(e){try{step(s.next(e))}catch(e){n(e)}}function rejected(e){try{step(s["throw"](e))}catch(e){n(e)}}function step(e){e.done?r(e.value):adopt(e.value).then(fulfilled,rejected)}step((s=s.apply(e,t||[])).next())})};Object.defineProperty(t,"__esModule",{value:true});t.argStringToArray=t.ToolRunner=void 0;const a=o(r(2087));const c=o(r(8614));const u=o(r(3129));const l=o(r(5622));const f=o(r(7436));const p=o(r(1962));const d=r(8213);const h=process.platform==="win32";class ToolRunner extends c.EventEmitter{constructor(e,t,r){super();if(!e){throw new Error("Parameter 'toolPath' cannot be null or empty.")}this.toolPath=e;this.args=t||[];this.options=r||{}}_debug(e){if(this.options.listeners&&this.options.listeners.debug){this.options.listeners.debug(e)}}_getCommandString(e,t){const r=this._getSpawnFileName();const s=this._getSpawnArgs(e);let n=t?"":"[command]";if(h){if(this._isCmdFile()){n+=r;for(const e of s){n+=` ${e}`}}else if(e.windowsVerbatimArguments){n+=`"${r}"`;for(const e of s){n+=` ${e}`}}else{n+=this._windowsQuoteCmdArg(r);for(const e of s){n+=` ${this._windowsQuoteCmdArg(e)}`}}}else{n+=r;for(const e of s){n+=` ${e}`}}return n}_processLineBuffer(e,t,r){try{let s=t+e.toString();let n=s.indexOf(a.EOL);while(n>-1){const e=s.substring(0,n);r(e);s=s.substring(n+a.EOL.length);n=s.indexOf(a.EOL)}return s}catch(e){this._debug(`error processing line. Failed with error ${e}`);return""}}_getSpawnFileName(){if(h){if(this._isCmdFile()){return process.env["COMSPEC"]||"cmd.exe"}}return this.toolPath}_getSpawnArgs(e){if(h){if(this._isCmdFile()){let t=`/D /S /C "${this._windowsQuoteCmdArg(this.toolPath)}`;for(const r of this.args){t+=" ";t+=e.windowsVerbatimArguments?r:this._windowsQuoteCmdArg(r)}t+='"';return[t]}}return this.args}_endsWith(e,t){return e.endsWith(t)}_isCmdFile(){const e=this.toolPath.toUpperCase();return this._endsWith(e,".CMD")||this._endsWith(e,".BAT")}_windowsQuoteCmdArg(e){if(!this._isCmdFile()){return this._uvQuoteCmdArg(e)}if(!e){return'""'}const t=[" ","\t","&","(",")","[","]","{","}","^","=",";","!","'","+",",","`","~","|","<",">",'"'];let r=false;for(const s of e){if(t.some(e=>e===s)){r=true;break}}if(!r){return e}let s='"';let n=true;for(let t=e.length;t>0;t--){s+=e[t-1];if(n&&e[t-1]==="\\"){s+="\\"}else if(e[t-1]==='"'){n=true;s+='"'}else{n=false}}s+='"';return s.split("").reverse().join("")}_uvQuoteCmdArg(e){if(!e){return'""'}if(!e.includes(" ")&&!e.includes("\t")&&!e.includes('"')){return e}if(!e.includes('"')&&!e.includes("\\")){return`"${e}"`}let t='"';let r=true;for(let s=e.length;s>0;s--){t+=e[s-1];if(r&&e[s-1]==="\\"){t+="\\"}else if(e[s-1]==='"'){r=true;t+="\\"}else{r=false}}t+='"';return t.split("").reverse().join("")}_cloneExecOptions(e){e=e||{};const t={cwd:e.cwd||process.cwd(),env:e.env||process.env,silent:e.silent||false,windowsVerbatimArguments:e.windowsVerbatimArguments||false,failOnStdErr:e.failOnStdErr||false,ignoreReturnCode:e.ignoreReturnCode||false,delay:e.delay||1e4};t.outStream=e.outStream||process.stdout;t.errStream=e.errStream||process.stderr;return t}_getSpawnOptions(e,t){e=e||{};const r={};r.cwd=e.cwd;r.env=e.env;r["windowsVerbatimArguments"]=e.windowsVerbatimArguments||this._isCmdFile();if(e.windowsVerbatimArguments){r.argv0=`"${t}"`}return r}exec(){return i(this,void 0,void 0,function*(){if(!p.isRooted(this.toolPath)&&(this.toolPath.includes("/")||h&&this.toolPath.includes("\\"))){this.toolPath=l.resolve(process.cwd(),this.options.cwd||process.cwd(),this.toolPath)}this.toolPath=yield f.which(this.toolPath,true);return new Promise((e,t)=>i(this,void 0,void 0,function*(){this._debug(`exec tool: ${this.toolPath}`);this._debug("arguments:");for(const e of this.args){this._debug(` ${e}`)}const r=this._cloneExecOptions(this.options);if(!r.silent&&r.outStream){r.outStream.write(this._getCommandString(r)+a.EOL)}const s=new ExecState(r,this.toolPath);s.on("debug",e=>{this._debug(e)});if(this.options.cwd&&!(yield p.exists(this.options.cwd))){return t(new Error(`The cwd: ${this.options.cwd} does not exist!`))}const n=this._getSpawnFileName();const o=u.spawn(n,this._getSpawnArgs(r),this._getSpawnOptions(this.options,n));let i="";if(o.stdout){o.stdout.on("data",e=>{if(this.options.listeners&&this.options.listeners.stdout){this.options.listeners.stdout(e)}if(!r.silent&&r.outStream){r.outStream.write(e)}i=this._processLineBuffer(e,i,e=>{if(this.options.listeners&&this.options.listeners.stdline){this.options.listeners.stdline(e)}})})}let c="";if(o.stderr){o.stderr.on("data",e=>{s.processStderr=true;if(this.options.listeners&&this.options.listeners.stderr){this.options.listeners.stderr(e)}if(!r.silent&&r.errStream&&r.outStream){const t=r.failOnStdErr?r.errStream:r.outStream;t.write(e)}c=this._processLineBuffer(e,c,e=>{if(this.options.listeners&&this.options.listeners.errline){this.options.listeners.errline(e)}})})}o.on("error",e=>{s.processError=e.message;s.processExited=true;s.processClosed=true;s.CheckComplete()});o.on("exit",e=>{s.processExitCode=e;s.processExited=true;this._debug(`Exit code ${e} received from tool '${this.toolPath}'`);s.CheckComplete()});o.on("close",e=>{s.processExitCode=e;s.processExited=true;s.processClosed=true;this._debug(`STDIO streams have closed for tool '${this.toolPath}'`);s.CheckComplete()});s.on("done",(r,s)=>{if(i.length>0){this.emit("stdline",i)}if(c.length>0){this.emit("errline",c)}o.removeAllListeners();if(r){t(r)}else{e(s)}});if(this.options.input){if(!o.stdin){throw new Error("child process missing stdin")}o.stdin.end(this.options.input)}}))})}}t.ToolRunner=ToolRunner;function argStringToArray(e){const t=[];let r=false;let s=false;let n="";function append(e){if(s&&e!=='"'){n+="\\"}n+=e;s=false}for(let o=0;o0){t.push(n);n=""}continue}append(i)}if(n.length>0){t.push(n.trim())}return t}t.argStringToArray=argStringToArray;class ExecState extends c.EventEmitter{constructor(e,t){super();this.processClosed=false;this.processError="";this.processExitCode=0;this.processExited=false;this.processStderr=false;this.delay=1e4;this.done=false;this.timeout=null;if(!t){throw new Error("toolPath must not be empty")}this.options=e;this.toolPath=t;if(e.delay){this.delay=e.delay}}CheckComplete(){if(this.done){return}if(this.processClosed){this._setResult()}else if(this.processExited){this.timeout=d.setTimeout(ExecState.HandleTimeout,this.delay,this)}}_debug(e){this.emit("debug",e)}_setResult(){let e;if(this.processExited){if(this.processError){e=new Error(`There was an error when attempting to execute the process '${this.toolPath}'. This may indicate the process failed to start. Error: ${this.processError}`)}else if(this.processExitCode!==0&&!this.options.ignoreReturnCode){e=new Error(`The process '${this.toolPath}' failed with exit code ${this.processExitCode}`)}else if(this.processStderr&&this.options.failOnStdErr){e=new Error(`The process '${this.toolPath}' failed because one or more lines were written to the STDERR stream`)}}if(this.timeout){clearTimeout(this.timeout);this.timeout=null}this.done=true;this.emit("done",e,this.processExitCode)}static HandleTimeout(e){if(e.done){return}if(!e.processClosed&&e.processExited){const t=`The STDIO streams did not close within ${e.delay/1e3} seconds of the exit event from process '${e.toolPath}'. This may indicate a child process inherited the STDIO streams and has not yet exited.`;e._debug(t)}e._setResult()}}},4087:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.Context=void 0;const s=r(5747);const n=r(2087);class Context{constructor(){var e,t,r;this.payload={};if(process.env.GITHUB_EVENT_PATH){if(s.existsSync(process.env.GITHUB_EVENT_PATH)){this.payload=JSON.parse(s.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${n.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=(t=process.env.GITHUB_SERVER_URL)!==null&&t!==void 0?t:`https://github.com`;this.graphqlUrl=(r=process.env.GITHUB_GRAPHQL_URL)!==null&&r!==void 0?r:`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,t]=process.env.GITHUB_REPOSITORY.split("/");return{owner:e,repo:t}}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'")}}t.Context=Context},5438:function(e,t,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,t,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,s){if(s===undefined)s=r;e[s]=t[r]});var n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))s(t,e,r);n(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.getOctokit=t.context=void 0;const i=o(r(4087));const a=r(3030);t.context=new i.Context;function getOctokit(e,t){return new a.GitHub(a.getOctokitOptions(e,t))}t.getOctokit=getOctokit},7914:function(e,t,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,t,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,s){if(s===undefined)s=r;e[s]=t[r]});var n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))s(t,e,r);n(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.getApiBaseUrl=t.getProxyAgent=t.getAuthString=void 0;const i=o(r(9925));function getAuthString(e,t){if(!e&&!t.auth){throw new Error("Parameter token or opts.auth is required")}else if(e&&t.auth){throw new Error("Parameters token and opts.auth may not both be specified")}return typeof t.auth==="string"?t.auth:`token ${e}`}t.getAuthString=getAuthString;function getProxyAgent(e){const t=new i.HttpClient;return t.getAgent(e)}t.getProxyAgent=getProxyAgent;function getApiBaseUrl(){return process.env["GITHUB_API_URL"]||"https://api.github.com"}t.getApiBaseUrl=getApiBaseUrl},3030:function(e,t,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,t,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,s){if(s===undefined)s=r;e[s]=t[r]});var n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))s(t,e,r);n(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.getOctokitOptions=t.GitHub=t.context=void 0;const i=o(r(4087));const a=o(r(7914));const c=r(6762);const u=r(3044);const l=r(4193);t.context=new i.Context;const f=a.getApiBaseUrl();const p={baseUrl:f,request:{agent:a.getProxyAgent(f)}};t.GitHub=c.Octokit.plugin(u.restEndpointMethods,l.paginateRest).defaults(p);function getOctokitOptions(e,t){const r=Object.assign({},t||{});const s=a.getAuthString(e,r);if(s){r.auth=s}return r}t.getOctokitOptions=getOctokitOptions},8090:function(e,t,r){"use strict";var s=this&&this.__awaiter||function(e,t,r,s){function adopt(e){return e instanceof r?e:new r(function(t){t(e)})}return new(r||(r=Promise))(function(r,n){function fulfilled(e){try{step(s.next(e))}catch(e){n(e)}}function rejected(e){try{step(s["throw"](e))}catch(e){n(e)}}function step(e){e.done?r(e.value):adopt(e.value).then(fulfilled,rejected)}step((s=s.apply(e,t||[])).next())})};Object.defineProperty(t,"__esModule",{value:true});t.hashFiles=t.create=void 0;const n=r(8298);const o=r(2448);function create(e,t){return s(this,void 0,void 0,function*(){return yield n.DefaultGlobber.create(e,t)})}t.create=create;function hashFiles(e,t){return s(this,void 0,void 0,function*(){let r=true;if(t&&typeof t.followSymbolicLinks==="boolean"){r=t.followSymbolicLinks}const s=yield create(e,{followSymbolicLinks:r});return o.hashFiles(s)})}t.hashFiles=hashFiles},1026:function(e,t,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,t,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,s){if(s===undefined)s=r;e[s]=t[r]});var n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))s(t,e,r);n(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.getOptions=void 0;const i=o(r(2186));function getOptions(e){const t={followSymbolicLinks:true,implicitDescendants:true,matchDirectories:true,omitBrokenSymbolicLinks:true};if(e){if(typeof e.followSymbolicLinks==="boolean"){t.followSymbolicLinks=e.followSymbolicLinks;i.debug(`followSymbolicLinks '${t.followSymbolicLinks}'`)}if(typeof e.implicitDescendants==="boolean"){t.implicitDescendants=e.implicitDescendants;i.debug(`implicitDescendants '${t.implicitDescendants}'`)}if(typeof e.matchDirectories==="boolean"){t.matchDirectories=e.matchDirectories;i.debug(`matchDirectories '${t.matchDirectories}'`)}if(typeof e.omitBrokenSymbolicLinks==="boolean"){t.omitBrokenSymbolicLinks=e.omitBrokenSymbolicLinks;i.debug(`omitBrokenSymbolicLinks '${t.omitBrokenSymbolicLinks}'`)}}return t}t.getOptions=getOptions},8298:function(e,t,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,t,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,s){if(s===undefined)s=r;e[s]=t[r]});var n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))s(t,e,r);n(t,e);return t};var i=this&&this.__awaiter||function(e,t,r,s){function adopt(e){return e instanceof r?e:new r(function(t){t(e)})}return new(r||(r=Promise))(function(r,n){function fulfilled(e){try{step(s.next(e))}catch(e){n(e)}}function rejected(e){try{step(s["throw"](e))}catch(e){n(e)}}function step(e){e.done?r(e.value):adopt(e.value).then(fulfilled,rejected)}step((s=s.apply(e,t||[])).next())})};var a=this&&this.__asyncValues||function(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t=e[Symbol.asyncIterator],r;return t?t.call(e):(e=typeof __values==="function"?__values(e):e[Symbol.iterator](),r={},verb("next"),verb("throw"),verb("return"),r[Symbol.asyncIterator]=function(){return this},r);function verb(t){r[t]=e[t]&&function(r){return new Promise(function(s,n){r=e[t](r),settle(s,n,r.done,r.value)})}}function settle(e,t,r,s){Promise.resolve(s).then(function(t){e({value:t,done:r})},t)}};var c=this&&this.__await||function(e){return this instanceof c?(this.v=e,this):new c(e)};var u=this&&this.__asyncGenerator||function(e,t,r){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var s=r.apply(e,t||[]),n,o=[];return n={},verb("next"),verb("throw"),verb("return"),n[Symbol.asyncIterator]=function(){return this},n;function verb(e){if(s[e])n[e]=function(t){return new Promise(function(r,s){o.push([e,t,r,s])>1||resume(e,t)})}}function resume(e,t){try{step(s[e](t))}catch(e){settle(o[0][3],e)}}function step(e){e.value instanceof c?Promise.resolve(e.value.v).then(fulfill,reject):settle(o[0][2],e)}function fulfill(e){resume("next",e)}function reject(e){resume("throw",e)}function settle(e,t){if(e(t),o.shift(),o.length)resume(o[0][0],o[0][1])}};Object.defineProperty(t,"__esModule",{value:true});t.DefaultGlobber=void 0;const l=o(r(2186));const f=o(r(5747));const p=o(r(1026));const d=o(r(5622));const h=o(r(9005));const g=r(1063);const m=r(4536);const y=r(9117);const v=process.platform==="win32";class DefaultGlobber{constructor(e){this.patterns=[];this.searchPaths=[];this.options=p.getOptions(e)}getSearchPaths(){return this.searchPaths.slice()}glob(){var e,t;return i(this,void 0,void 0,function*(){const r=[];try{for(var s=a(this.globGenerator()),n;n=yield s.next(),!n.done;){const e=n.value;r.push(e)}}catch(t){e={error:t}}finally{try{if(n&&!n.done&&(t=s.return))yield t.call(s)}finally{if(e)throw e.error}}return r})}globGenerator(){return u(this,arguments,function*globGenerator_1(){const e=p.getOptions(this.options);const t=[];for(const r of this.patterns){t.push(r);if(e.implicitDescendants&&(r.trailingSeparator||r.segments[r.segments.length-1]!=="**")){t.push(new m.Pattern(r.negate,true,r.segments.concat("**")))}}const r=[];for(const e of h.getSearchPaths(t)){l.debug(`Search path '${e}'`);try{yield c(f.promises.lstat(e))}catch(e){if(e.code==="ENOENT"){continue}throw e}r.unshift(new y.SearchState(e,1))}const s=[];while(r.length){const n=r.pop();const o=h.match(t,n.path);const i=!!o||h.partialMatch(t,n.path);if(!o&&!i){continue}const a=yield c(DefaultGlobber.stat(n,e,s));if(!a){continue}if(a.isDirectory()){if(o&g.MatchKind.Directory&&e.matchDirectories){yield yield c(n.path)}else if(!i){continue}const t=n.level+1;const s=(yield c(f.promises.readdir(n.path))).map(e=>new y.SearchState(d.join(n.path,e),t));r.push(...s.reverse())}else if(o&g.MatchKind.File){yield yield c(n.path)}}})}static create(e,t){return i(this,void 0,void 0,function*(){const r=new DefaultGlobber(t);if(v){e=e.replace(/\r\n/g,"\n");e=e.replace(/\r/g,"\n")}const s=e.split("\n").map(e=>e.trim());for(const e of s){if(!e||e.startsWith("#")){continue}else{r.patterns.push(new m.Pattern(e))}}r.searchPaths.push(...h.getSearchPaths(r.patterns));return r})}static stat(e,t,r){return i(this,void 0,void 0,function*(){let s;if(t.followSymbolicLinks){try{s=yield f.promises.stat(e.path)}catch(r){if(r.code==="ENOENT"){if(t.omitBrokenSymbolicLinks){l.debug(`Broken symlink '${e.path}'`);return undefined}throw new Error(`No information found for the path '${e.path}'. This may indicate a broken symbolic link.`)}throw r}}else{s=yield f.promises.lstat(e.path)}if(s.isDirectory()&&t.followSymbolicLinks){const t=yield f.promises.realpath(e.path);while(r.length>=e.level){r.pop()}if(r.some(e=>e===t)){l.debug(`Symlink cycle detected for path '${e.path}' and realpath '${t}'`);return undefined}r.push(t)}return s})}}t.DefaultGlobber=DefaultGlobber},2448:function(e,t,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,t,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,s){if(s===undefined)s=r;e[s]=t[r]});var n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))s(t,e,r);n(t,e);return t};var i=this&&this.__awaiter||function(e,t,r,s){function adopt(e){return e instanceof r?e:new r(function(t){t(e)})}return new(r||(r=Promise))(function(r,n){function fulfilled(e){try{step(s.next(e))}catch(e){n(e)}}function rejected(e){try{step(s["throw"](e))}catch(e){n(e)}}function step(e){e.done?r(e.value):adopt(e.value).then(fulfilled,rejected)}step((s=s.apply(e,t||[])).next())})};var a=this&&this.__asyncValues||function(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t=e[Symbol.asyncIterator],r;return t?t.call(e):(e=typeof __values==="function"?__values(e):e[Symbol.iterator](),r={},verb("next"),verb("throw"),verb("return"),r[Symbol.asyncIterator]=function(){return this},r);function verb(t){r[t]=e[t]&&function(r){return new Promise(function(s,n){r=e[t](r),settle(s,n,r.done,r.value)})}}function settle(e,t,r,s){Promise.resolve(s).then(function(t){e({value:t,done:r})},t)}};Object.defineProperty(t,"__esModule",{value:true});t.hashFiles=void 0;const c=o(r(6417));const u=o(r(2186));const l=o(r(5747));const f=o(r(2413));const p=o(r(1669));const d=o(r(5622));function hashFiles(e){var t,r;var s;return i(this,void 0,void 0,function*(){let n=false;const o=(s=process.env["GITHUB_WORKSPACE"])!==null&&s!==void 0?s:process.cwd();const i=c.createHash("sha256");let h=0;try{for(var g=a(e.globGenerator()),m;m=yield g.next(),!m.done;){const e=m.value;u.debug(e);if(!e.startsWith(`${o}${d.sep}`)){u.debug(`Ignore '${e}' since it is not under GITHUB_WORKSPACE.`);continue}if(l.statSync(e).isDirectory()){u.debug(`Skip directory '${e}'.`);continue}const t=c.createHash("sha256");const r=p.promisify(f.pipeline);yield r(l.createReadStream(e),t);i.write(t.digest());h++;if(!n){n=true}}}catch(e){t={error:e}}finally{try{if(m&&!m.done&&(r=g.return))yield r.call(g)}finally{if(t)throw t.error}}i.end();if(n){u.debug(`Found ${h} files to hash.`);return i.digest("hex")}else{u.debug(`No matches found for glob`);return""}})}t.hashFiles=hashFiles},1063:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.MatchKind=void 0;var r;(function(e){e[e["None"]=0]="None";e[e["Directory"]=1]="Directory";e[e["File"]=2]="File";e[e["All"]=3]="All"})(r=t.MatchKind||(t.MatchKind={}))},1849:function(e,t,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,t,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,s){if(s===undefined)s=r;e[s]=t[r]});var n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))s(t,e,r);n(t,e);return t};var i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:true});t.safeTrimTrailingSeparator=t.normalizeSeparators=t.hasRoot=t.hasAbsoluteRoot=t.ensureAbsoluteRoot=t.dirname=void 0;const a=o(r(5622));const c=i(r(2357));const u=process.platform==="win32";function dirname(e){e=safeTrimTrailingSeparator(e);if(u&&/^\\\\[^\\]+(\\[^\\]+)?$/.test(e)){return e}let t=a.dirname(e);if(u&&/^\\\\[^\\]+\\[^\\]+\\$/.test(t)){t=safeTrimTrailingSeparator(t)}return t}t.dirname=dirname;function ensureAbsoluteRoot(e,t){c.default(e,`ensureAbsoluteRoot parameter 'root' must not be empty`);c.default(t,`ensureAbsoluteRoot parameter 'itemPath' must not be empty`);if(hasAbsoluteRoot(t)){return t}if(u){if(t.match(/^[A-Z]:[^\\/]|^[A-Z]:$/i)){let e=process.cwd();c.default(e.match(/^[A-Z]:\\/i),`Expected current directory to start with an absolute drive root. Actual '${e}'`);if(t[0].toUpperCase()===e[0].toUpperCase()){if(t.length===2){return`${t[0]}:\\${e.substr(3)}`}else{if(!e.endsWith("\\")){e+="\\"}return`${t[0]}:\\${e.substr(3)}${t.substr(2)}`}}else{return`${t[0]}:\\${t.substr(2)}`}}else if(normalizeSeparators(t).match(/^\\$|^\\[^\\]/)){const e=process.cwd();c.default(e.match(/^[A-Z]:\\/i),`Expected current directory to start with an absolute drive root. Actual '${e}'`);return`${e[0]}:\\${t.substr(1)}`}}c.default(hasAbsoluteRoot(e),`ensureAbsoluteRoot parameter 'root' must have an absolute root`);if(e.endsWith("/")||u&&e.endsWith("\\")){}else{e+=a.sep}return e+t}t.ensureAbsoluteRoot=ensureAbsoluteRoot;function hasAbsoluteRoot(e){c.default(e,`hasAbsoluteRoot parameter 'itemPath' must not be empty`);e=normalizeSeparators(e);if(u){return e.startsWith("\\\\")||/^[A-Z]:\\/i.test(e)}return e.startsWith("/")}t.hasAbsoluteRoot=hasAbsoluteRoot;function hasRoot(e){c.default(e,`isRooted parameter 'itemPath' must not be empty`);e=normalizeSeparators(e);if(u){return e.startsWith("\\")||/^[A-Z]:/i.test(e)}return e.startsWith("/")}t.hasRoot=hasRoot;function normalizeSeparators(e){e=e||"";if(u){e=e.replace(/\//g,"\\");const t=/^\\\\+[^\\]/.test(e);return(t?"\\":"")+e.replace(/\\\\+/g,"\\")}return e.replace(/\/\/+/g,"/")}t.normalizeSeparators=normalizeSeparators;function safeTrimTrailingSeparator(e){if(!e){return""}e=normalizeSeparators(e);if(!e.endsWith(a.sep)){return e}if(e===a.sep){return e}if(u&&/^[A-Z]:\\$/i.test(e)){return e}return e.substr(0,e.length-1)}t.safeTrimTrailingSeparator=safeTrimTrailingSeparator},6836:function(e,t,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,t,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,s){if(s===undefined)s=r;e[s]=t[r]});var n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))s(t,e,r);n(t,e);return t};var i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:true});t.Path=void 0;const a=o(r(5622));const c=o(r(1849));const u=i(r(2357));const l=process.platform==="win32";class Path{constructor(e){this.segments=[];if(typeof e==="string"){u.default(e,`Parameter 'itemPath' must not be empty`);e=c.safeTrimTrailingSeparator(e);if(!c.hasRoot(e)){this.segments=e.split(a.sep)}else{let t=e;let r=c.dirname(t);while(r!==t){const e=a.basename(t);this.segments.unshift(e);t=r;r=c.dirname(t)}this.segments.unshift(t)}}else{u.default(e.length>0,`Parameter 'itemPath' must not be an empty array`);for(let t=0;t!e.negate);const t={};for(const r of e){const e=c?r.searchPath.toUpperCase():r.searchPath;t[e]="candidate"}const r=[];for(const s of e){const e=c?s.searchPath.toUpperCase():s.searchPath;if(t[e]==="included"){continue}let n=false;let o=e;let a=i.dirname(o);while(a!==o){if(t[a]){n=true;break}o=a;a=i.dirname(o)}if(!n){r.push(s.searchPath);t[e]="included"}}return r}t.getSearchPaths=getSearchPaths;function match(e,t){let r=a.MatchKind.None;for(const s of e){if(s.negate){r&=~s.match(t)}else{r|=s.match(t)}}return r}t.match=match;function partialMatch(e,t){return e.some(e=>!e.negate&&e.partialMatch(t))}t.partialMatch=partialMatch},4536:function(e,t,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,t,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,s){if(s===undefined)s=r;e[s]=t[r]});var n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))s(t,e,r);n(t,e);return t};var i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:true});t.Pattern=void 0;const a=o(r(2087));const c=o(r(5622));const u=o(r(1849));const l=i(r(2357));const f=r(3973);const p=r(1063);const d=r(6836);const h=process.platform==="win32";class Pattern{constructor(e,t=false,r,s){this.negate=false;let n;if(typeof e==="string"){n=e.trim()}else{r=r||[];l.default(r.length,`Parameter 'segments' must not empty`);const t=Pattern.getLiteral(r[0]);l.default(t&&u.hasAbsoluteRoot(t),`Parameter 'segments' first element must be a root path`);n=new d.Path(r).toString().trim();if(e){n=`!${n}`}}while(n.startsWith("!")){this.negate=!this.negate;n=n.substr(1).trim()}n=Pattern.fixupPattern(n,s);this.segments=new d.Path(n).segments;this.trailingSeparator=u.normalizeSeparators(n).endsWith(c.sep);n=u.safeTrimTrailingSeparator(n);let o=false;const i=this.segments.map(e=>Pattern.getLiteral(e)).filter(e=>!o&&!(o=e===""));this.searchPath=new d.Path(i).toString();this.rootRegExp=new RegExp(Pattern.regExpEscape(i[0]),h?"i":"");this.isImplicitPattern=t;const a={dot:true,nobrace:true,nocase:h,nocomment:true,noext:true,nonegate:true};n=h?n.replace(/\\/g,"/"):n;this.minimatch=new f.Minimatch(n,a)}match(e){if(this.segments[this.segments.length-1]==="**"){e=u.normalizeSeparators(e);if(!e.endsWith(c.sep)&&this.isImplicitPattern===false){e=`${e}${c.sep}`}}else{e=u.safeTrimTrailingSeparator(e)}if(this.minimatch.match(e)){return this.trailingSeparator?p.MatchKind.Directory:p.MatchKind.All}return p.MatchKind.None}partialMatch(e){e=u.safeTrimTrailingSeparator(e);if(u.dirname(e)===e){return this.rootRegExp.test(e)}return this.minimatch.matchOne(e.split(h?/\\+/:/\/+/),this.minimatch.set[0],true)}static globEscape(e){return(h?e:e.replace(/\\/g,"\\\\")).replace(/(\[)(?=[^/]+\])/g,"[[]").replace(/\?/g,"[?]").replace(/\*/g,"[*]")}static fixupPattern(e,t){l.default(e,"pattern cannot be empty");const r=new d.Path(e).segments.map(e=>Pattern.getLiteral(e));l.default(r.every((e,t)=>(e!=="."||t===0)&&e!==".."),`Invalid pattern '${e}'. Relative pathing '.' and '..' is not allowed.`);l.default(!u.hasRoot(e)||r[0],`Invalid pattern '${e}'. Root segment must not contain globs.`);e=u.normalizeSeparators(e);if(e==="."||e.startsWith(`.${c.sep}`)){e=Pattern.globEscape(process.cwd())+e.substr(1)}else if(e==="~"||e.startsWith(`~${c.sep}`)){t=t||a.homedir();l.default(t,"Unable to determine HOME directory");l.default(u.hasAbsoluteRoot(t),`Expected HOME directory to be a rooted path. Actual '${t}'`);e=Pattern.globEscape(t)+e.substr(1)}else if(h&&(e.match(/^[A-Z]:$/i)||e.match(/^[A-Z]:[^\\]/i))){let t=u.ensureAbsoluteRoot("C:\\dummy-root",e.substr(0,2));if(e.length>2&&!t.endsWith("\\")){t+="\\"}e=Pattern.globEscape(t)+e.substr(2)}else if(h&&(e==="\\"||e.match(/^\\[^\\]/))){let t=u.ensureAbsoluteRoot("C:\\dummy-root","\\");if(!t.endsWith("\\")){t+="\\"}e=Pattern.globEscape(t)+e.substr(1)}else{e=u.ensureAbsoluteRoot(Pattern.globEscape(process.cwd()),e)}return u.normalizeSeparators(e)}static getLiteral(e){let t="";for(let r=0;r=0){if(s.length>1){return""}if(s){t+=s;r=n;continue}}}t+=s}return t}static regExpEscape(e){return e.replace(/[[\\^$.|?*+()]/g,"\\$&")}}t.Pattern=Pattern},9117:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.SearchState=void 0;class SearchState{constructor(e,t){this.path=e;this.level=t}}t.SearchState=SearchState},9925:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const s=r(8605);const n=r(7211);const o=r(6443);let i;var a;(function(e){e[e["OK"]=200]="OK";e[e["MultipleChoices"]=300]="MultipleChoices";e[e["MovedPermanently"]=301]="MovedPermanently";e[e["ResourceMoved"]=302]="ResourceMoved";e[e["SeeOther"]=303]="SeeOther";e[e["NotModified"]=304]="NotModified";e[e["UseProxy"]=305]="UseProxy";e[e["SwitchProxy"]=306]="SwitchProxy";e[e["TemporaryRedirect"]=307]="TemporaryRedirect";e[e["PermanentRedirect"]=308]="PermanentRedirect";e[e["BadRequest"]=400]="BadRequest";e[e["Unauthorized"]=401]="Unauthorized";e[e["PaymentRequired"]=402]="PaymentRequired";e[e["Forbidden"]=403]="Forbidden";e[e["NotFound"]=404]="NotFound";e[e["MethodNotAllowed"]=405]="MethodNotAllowed";e[e["NotAcceptable"]=406]="NotAcceptable";e[e["ProxyAuthenticationRequired"]=407]="ProxyAuthenticationRequired";e[e["RequestTimeout"]=408]="RequestTimeout";e[e["Conflict"]=409]="Conflict";e[e["Gone"]=410]="Gone";e[e["TooManyRequests"]=429]="TooManyRequests";e[e["InternalServerError"]=500]="InternalServerError";e[e["NotImplemented"]=501]="NotImplemented";e[e["BadGateway"]=502]="BadGateway";e[e["ServiceUnavailable"]=503]="ServiceUnavailable";e[e["GatewayTimeout"]=504]="GatewayTimeout"})(a=t.HttpCodes||(t.HttpCodes={}));var c;(function(e){e["Accept"]="accept";e["ContentType"]="content-type"})(c=t.Headers||(t.Headers={}));var u;(function(e){e["ApplicationJson"]="application/json"})(u=t.MediaTypes||(t.MediaTypes={}));function getProxyUrl(e){let t=o.getProxyUrl(new URL(e));return t?t.href:""}t.getProxyUrl=getProxyUrl;const l=[a.MovedPermanently,a.ResourceMoved,a.SeeOther,a.TemporaryRedirect,a.PermanentRedirect];const f=[a.BadGateway,a.ServiceUnavailable,a.GatewayTimeout];const p=["OPTIONS","GET","DELETE","HEAD"];const d=10;const h=5;class HttpClientError extends Error{constructor(e,t){super(e);this.name="HttpClientError";this.statusCode=t;Object.setPrototypeOf(this,HttpClientError.prototype)}}t.HttpClientError=HttpClientError;class HttpClientResponse{constructor(e){this.message=e}readBody(){return new Promise(async(e,t)=>{let r=Buffer.alloc(0);this.message.on("data",e=>{r=Buffer.concat([r,e])});this.message.on("end",()=>{e(r.toString())})})}}t.HttpClientResponse=HttpClientResponse;function isHttps(e){let t=new URL(e);return t.protocol==="https:"}t.isHttps=isHttps;class HttpClient{constructor(e,t,r){this._ignoreSslError=false;this._allowRedirects=true;this._allowRedirectDowngrade=false;this._maxRedirects=50;this._allowRetries=false;this._maxRetries=1;this._keepAlive=false;this._disposed=false;this.userAgent=e;this.handlers=t||[];this.requestOptions=r;if(r){if(r.ignoreSslError!=null){this._ignoreSslError=r.ignoreSslError}this._socketTimeout=r.socketTimeout;if(r.allowRedirects!=null){this._allowRedirects=r.allowRedirects}if(r.allowRedirectDowngrade!=null){this._allowRedirectDowngrade=r.allowRedirectDowngrade}if(r.maxRedirects!=null){this._maxRedirects=Math.max(r.maxRedirects,0)}if(r.keepAlive!=null){this._keepAlive=r.keepAlive}if(r.allowRetries!=null){this._allowRetries=r.allowRetries}if(r.maxRetries!=null){this._maxRetries=r.maxRetries}}}options(e,t){return this.request("OPTIONS",e,null,t||{})}get(e,t){return this.request("GET",e,null,t||{})}del(e,t){return this.request("DELETE",e,null,t||{})}post(e,t,r){return this.request("POST",e,t,r||{})}patch(e,t,r){return this.request("PATCH",e,t,r||{})}put(e,t,r){return this.request("PUT",e,t,r||{})}head(e,t){return this.request("HEAD",e,null,t||{})}sendStream(e,t,r,s){return this.request(e,t,r,s)}async getJson(e,t={}){t[c.Accept]=this._getExistingOrDefaultHeader(t,c.Accept,u.ApplicationJson);let r=await this.get(e,t);return this._processResponse(r,this.requestOptions)}async postJson(e,t,r={}){let s=JSON.stringify(t,null,2);r[c.Accept]=this._getExistingOrDefaultHeader(r,c.Accept,u.ApplicationJson);r[c.ContentType]=this._getExistingOrDefaultHeader(r,c.ContentType,u.ApplicationJson);let n=await this.post(e,s,r);return this._processResponse(n,this.requestOptions)}async putJson(e,t,r={}){let s=JSON.stringify(t,null,2);r[c.Accept]=this._getExistingOrDefaultHeader(r,c.Accept,u.ApplicationJson);r[c.ContentType]=this._getExistingOrDefaultHeader(r,c.ContentType,u.ApplicationJson);let n=await this.put(e,s,r);return this._processResponse(n,this.requestOptions)}async patchJson(e,t,r={}){let s=JSON.stringify(t,null,2);r[c.Accept]=this._getExistingOrDefaultHeader(r,c.Accept,u.ApplicationJson);r[c.ContentType]=this._getExistingOrDefaultHeader(r,c.ContentType,u.ApplicationJson);let n=await this.patch(e,s,r);return this._processResponse(n,this.requestOptions)}async request(e,t,r,s){if(this._disposed){throw new Error("Client has already been disposed.")}let n=new URL(t);let o=this._prepareRequest(e,n,s);let i=this._allowRetries&&p.indexOf(e)!=-1?this._maxRetries+1:1;let c=0;let u;while(c0){const i=u.message.headers["location"];if(!i){break}let a=new URL(i);if(n.protocol=="https:"&&n.protocol!=a.protocol&&!this._allowRedirectDowngrade){throw new Error("Redirect from HTTPS to HTTP protocol. This downgrade is not allowed for security reasons. If you want to allow this behavior, set the allowRedirectDowngrade option to true.")}await u.readBody();if(a.hostname!==n.hostname){for(let e in s){if(e.toLowerCase()==="authorization"){delete s[e]}}}o=this._prepareRequest(e,a,s);u=await this.requestRaw(o,r);t--}if(f.indexOf(u.message.statusCode)==-1){return u}c+=1;if(c{let n=function(e,t){if(e){s(e)}r(t)};this.requestRawWithCallback(e,t,n)})}requestRawWithCallback(e,t,r){let s;if(typeof t==="string"){e.options.headers["Content-Length"]=Buffer.byteLength(t,"utf8")}let n=false;let o=(e,t)=>{if(!n){n=true;r(e,t)}};let i=e.httpModule.request(e.options,e=>{let t=new HttpClientResponse(e);o(null,t)});i.on("socket",e=>{s=e});i.setTimeout(this._socketTimeout||3*6e4,()=>{if(s){s.end()}o(new Error("Request timeout: "+e.options.path),null)});i.on("error",function(e){o(e,null)});if(t&&typeof t==="string"){i.write(t,"utf8")}if(t&&typeof t!=="string"){t.on("close",function(){i.end()});t.pipe(i)}else{i.end()}}getAgent(e){let t=new URL(e);return this._getAgent(t)}_prepareRequest(e,t,r){const o={};o.parsedUrl=t;const i=o.parsedUrl.protocol==="https:";o.httpModule=i?n:s;const a=i?443:80;o.options={};o.options.host=o.parsedUrl.hostname;o.options.port=o.parsedUrl.port?parseInt(o.parsedUrl.port):a;o.options.path=(o.parsedUrl.pathname||"")+(o.parsedUrl.search||"");o.options.method=e;o.options.headers=this._mergeHeaders(r);if(this.userAgent!=null){o.options.headers["user-agent"]=this.userAgent}o.options.agent=this._getAgent(o.parsedUrl);if(this.handlers){this.handlers.forEach(e=>{e.prepareRequest(o.options)})}return o}_mergeHeaders(e){const t=e=>Object.keys(e).reduce((t,r)=>(t[r.toLowerCase()]=e[r],t),{});if(this.requestOptions&&this.requestOptions.headers){return Object.assign({},t(this.requestOptions.headers),t(e))}return t(e||{})}_getExistingOrDefaultHeader(e,t,r){const s=e=>Object.keys(e).reduce((t,r)=>(t[r.toLowerCase()]=e[r],t),{});let n;if(this.requestOptions&&this.requestOptions.headers){n=s(this.requestOptions.headers)[t]}return e[t]||n||r}_getAgent(e){let t;let a=o.getProxyUrl(e);let c=a&&a.hostname;if(this._keepAlive&&c){t=this._proxyAgent}if(this._keepAlive&&!c){t=this._agent}if(!!t){return t}const u=e.protocol==="https:";let l=100;if(!!this.requestOptions){l=this.requestOptions.maxSockets||s.globalAgent.maxSockets}if(c){if(!i){i=r(4294)}const e={maxSockets:l,keepAlive:this._keepAlive,proxy:{...(a.username||a.password)&&{proxyAuth:`${a.username}:${a.password}`},host:a.hostname,port:a.port}};let s;const n=a.protocol==="https:";if(u){s=n?i.httpsOverHttps:i.httpsOverHttp}else{s=n?i.httpOverHttps:i.httpOverHttp}t=s(e);this._proxyAgent=t}if(this._keepAlive&&!t){const e={keepAlive:this._keepAlive,maxSockets:l};t=u?new n.Agent(e):new s.Agent(e);this._agent=t}if(!t){t=u?n.globalAgent:s.globalAgent}if(u&&this._ignoreSslError){t.options=Object.assign(t.options||{},{rejectUnauthorized:false})}return t}_performExponentialBackoff(e){e=Math.min(d,e);const t=h*Math.pow(2,e);return new Promise(e=>setTimeout(()=>e(),t))}static dateTimeDeserializer(e,t){if(typeof t==="string"){let e=new Date(t);if(!isNaN(e.valueOf())){return e}}return t}async _processResponse(e,t){return new Promise(async(r,s)=>{const n=e.message.statusCode;const o={statusCode:n,result:null,headers:{}};if(n==a.NotFound){r(o)}let i;let c;try{c=await e.readBody();if(c&&c.length>0){if(t&&t.deserializeDates){i=JSON.parse(c,HttpClient.dateTimeDeserializer)}else{i=JSON.parse(c)}o.result=i}o.headers=e.message.headers}catch(e){}if(n>299){let e;if(i&&i.message){e=i.message}else if(c&&c.length>0){e=c}else{e="Failed request: ("+n+")"}let t=new HttpClientError(e,n);t.result=o.result;s(t)}else{r(o)}})}}t.HttpClient=HttpClient},6443:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});function getProxyUrl(e){let t=e.protocol==="https:";let r;if(checkBypass(e)){return r}let s;if(t){s=process.env["https_proxy"]||process.env["HTTPS_PROXY"]}else{s=process.env["http_proxy"]||process.env["HTTP_PROXY"]}if(s){r=new URL(s)}return r}t.getProxyUrl=getProxyUrl;function checkBypass(e){if(!e.hostname){return false}let t=process.env["no_proxy"]||process.env["NO_PROXY"]||"";if(!t){return false}let r;if(e.port){r=Number(e.port)}else if(e.protocol==="http:"){r=80}else if(e.protocol==="https:"){r=443}let s=[e.hostname.toUpperCase()];if(typeof r==="number"){s.push(`${s[0]}:${r}`)}for(let e of t.split(",").map(e=>e.trim().toUpperCase()).filter(e=>e)){if(s.some(t=>t===e)){return true}}return false}t.checkBypass=checkBypass},1962:function(e,t,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,t,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,s){if(s===undefined)s=r;e[s]=t[r]});var n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))s(t,e,r);n(t,e);return t};var i=this&&this.__awaiter||function(e,t,r,s){function adopt(e){return e instanceof r?e:new r(function(t){t(e)})}return new(r||(r=Promise))(function(r,n){function fulfilled(e){try{step(s.next(e))}catch(e){n(e)}}function rejected(e){try{step(s["throw"](e))}catch(e){n(e)}}function step(e){e.done?r(e.value):adopt(e.value).then(fulfilled,rejected)}step((s=s.apply(e,t||[])).next())})};var a;Object.defineProperty(t,"__esModule",{value:true});t.getCmdPath=t.tryGetExecutablePath=t.isRooted=t.isDirectory=t.exists=t.IS_WINDOWS=t.unlink=t.symlink=t.stat=t.rmdir=t.rename=t.readlink=t.readdir=t.mkdir=t.lstat=t.copyFile=t.chmod=void 0;const c=o(r(5747));const u=o(r(5622));a=c.promises,t.chmod=a.chmod,t.copyFile=a.copyFile,t.lstat=a.lstat,t.mkdir=a.mkdir,t.readdir=a.readdir,t.readlink=a.readlink,t.rename=a.rename,t.rmdir=a.rmdir,t.stat=a.stat,t.symlink=a.symlink,t.unlink=a.unlink;t.IS_WINDOWS=process.platform==="win32";function exists(e){return i(this,void 0,void 0,function*(){try{yield t.stat(e)}catch(e){if(e.code==="ENOENT"){return false}throw e}return true})}t.exists=exists;function isDirectory(e,r=false){return i(this,void 0,void 0,function*(){const s=r?yield t.stat(e):yield t.lstat(e);return s.isDirectory()})}t.isDirectory=isDirectory;function isRooted(e){e=normalizeSeparators(e);if(!e){throw new Error('isRooted() parameter "p" cannot be empty')}if(t.IS_WINDOWS){return e.startsWith("\\")||/^[A-Z]:/i.test(e)}return e.startsWith("/")}t.isRooted=isRooted;function tryGetExecutablePath(e,r){return i(this,void 0,void 0,function*(){let s=undefined;try{s=yield t.stat(e)}catch(t){if(t.code!=="ENOENT"){console.log(`Unexpected error attempting to determine if executable file exists '${e}': ${t}`)}}if(s&&s.isFile()){if(t.IS_WINDOWS){const t=u.extname(e).toUpperCase();if(r.some(e=>e.toUpperCase()===t)){return e}}else{if(isUnixExecutable(s)){return e}}}const n=e;for(const o of r){e=n+o;s=undefined;try{s=yield t.stat(e)}catch(t){if(t.code!=="ENOENT"){console.log(`Unexpected error attempting to determine if executable file exists '${e}': ${t}`)}}if(s&&s.isFile()){if(t.IS_WINDOWS){try{const r=u.dirname(e);const s=u.basename(e).toUpperCase();for(const n of yield t.readdir(r)){if(s===n.toUpperCase()){e=u.join(r,n);break}}}catch(t){console.log(`Unexpected error attempting to determine the actual case of the file '${e}': ${t}`)}return e}else{if(isUnixExecutable(s)){return e}}}}return""})}t.tryGetExecutablePath=tryGetExecutablePath;function normalizeSeparators(e){e=e||"";if(t.IS_WINDOWS){e=e.replace(/\//g,"\\");return e.replace(/\\\\+/g,"\\")}return e.replace(/\/\/+/g,"/")}function isUnixExecutable(e){return(e.mode&1)>0||(e.mode&8)>0&&e.gid===process.getgid()||(e.mode&64)>0&&e.uid===process.getuid()}function getCmdPath(){var e;return(e=process.env["COMSPEC"])!==null&&e!==void 0?e:`cmd.exe`}t.getCmdPath=getCmdPath},7436:function(e,t,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,t,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,s){if(s===undefined)s=r;e[s]=t[r]});var n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))s(t,e,r);n(t,e);return t};var i=this&&this.__awaiter||function(e,t,r,s){function adopt(e){return e instanceof r?e:new r(function(t){t(e)})}return new(r||(r=Promise))(function(r,n){function fulfilled(e){try{step(s.next(e))}catch(e){n(e)}}function rejected(e){try{step(s["throw"](e))}catch(e){n(e)}}function step(e){e.done?r(e.value):adopt(e.value).then(fulfilled,rejected)}step((s=s.apply(e,t||[])).next())})};Object.defineProperty(t,"__esModule",{value:true});t.findInPath=t.which=t.mkdirP=t.rmRF=t.mv=t.cp=void 0;const a=r(2357);const c=o(r(3129));const u=o(r(5622));const l=r(1669);const f=o(r(1962));const p=l.promisify(c.exec);const d=l.promisify(c.execFile);function cp(e,t,r={}){return i(this,void 0,void 0,function*(){const{force:s,recursive:n,copySourceDirectory:o}=readCopyOptions(r);const i=(yield f.exists(t))?yield f.stat(t):null;if(i&&i.isFile()&&!s){return}const a=i&&i.isDirectory()&&o?u.join(t,u.basename(e)):t;if(!(yield f.exists(e))){throw new Error(`no such file or directory: ${e}`)}const c=yield f.stat(e);if(c.isDirectory()){if(!n){throw new Error(`Failed to copy. ${e} is a directory, but tried to copy without recursive flag.`)}else{yield cpDirRecursive(e,a,0,s)}}else{if(u.relative(e,a)===""){throw new Error(`'${a}' and '${e}' are the same file`)}yield copyFile(e,a,s)}})}t.cp=cp;function mv(e,t,r={}){return i(this,void 0,void 0,function*(){if(yield f.exists(t)){let s=true;if(yield f.isDirectory(t)){t=u.join(t,u.basename(e));s=yield f.exists(t)}if(s){if(r.force==null||r.force){yield rmRF(t)}else{throw new Error("Destination already exists")}}}yield mkdirP(u.dirname(t));yield f.rename(e,t)})}t.mv=mv;function rmRF(e){return i(this,void 0,void 0,function*(){if(f.IS_WINDOWS){if(/[*"<>|]/.test(e)){throw new Error('File path must not contain `*`, `"`, `<`, `>` or `|` on Windows')}try{const t=f.getCmdPath();if(yield f.isDirectory(e,true)){yield p(`${t} /s /c "rd /s /q "%inputPath%""`,{env:{inputPath:e}})}else{yield p(`${t} /s /c "del /f /a "%inputPath%""`,{env:{inputPath:e}})}}catch(e){if(e.code!=="ENOENT")throw e}try{yield f.unlink(e)}catch(e){if(e.code!=="ENOENT")throw e}}else{let t=false;try{t=yield f.isDirectory(e)}catch(e){if(e.code!=="ENOENT")throw e;return}if(t){yield d(`rm`,[`-rf`,`${e}`])}else{yield f.unlink(e)}}})}t.rmRF=rmRF;function mkdirP(e){return i(this,void 0,void 0,function*(){a.ok(e,"a path argument must be provided");yield f.mkdir(e,{recursive:true})})}t.mkdirP=mkdirP;function which(e,t){return i(this,void 0,void 0,function*(){if(!e){throw new Error("parameter 'tool' is required")}if(t){const t=yield which(e,false);if(!t){if(f.IS_WINDOWS){throw new Error(`Unable to locate executable file: ${e}. Please verify either the file path exists or the file can be found within a directory specified by the PATH environment variable. Also verify the file has a valid extension for an executable file.`)}else{throw new Error(`Unable to locate executable file: ${e}. Please verify either the file path exists or the file can be found within a directory specified by the PATH environment variable. Also check the file mode to verify the file is executable.`)}}return t}const r=yield findInPath(e);if(r&&r.length>0){return r[0]}return""})}t.which=which;function findInPath(e){return i(this,void 0,void 0,function*(){if(!e){throw new Error("parameter 'tool' is required")}const t=[];if(f.IS_WINDOWS&&process.env["PATHEXT"]){for(const e of process.env["PATHEXT"].split(u.delimiter)){if(e){t.push(e)}}}if(f.isRooted(e)){const r=yield f.tryGetExecutablePath(e,t);if(r){return[r]}return[]}if(e.includes(u.sep)){return[]}const r=[];if(process.env.PATH){for(const e of process.env.PATH.split(u.delimiter)){if(e){r.push(e)}}}const s=[];for(const n of r){const r=yield f.tryGetExecutablePath(u.join(n,e),t);if(r){s.push(r)}}return s})}t.findInPath=findInPath;function readCopyOptions(e){const t=e.force==null?true:e.force;const r=Boolean(e.recursive);const s=e.copySourceDirectory==null?true:Boolean(e.copySourceDirectory);return{force:t,recursive:r,copySourceDirectory:s}}function cpDirRecursive(e,t,r,s){return i(this,void 0,void 0,function*(){if(r>=255)return;r++;yield mkdirP(t);const n=yield f.readdir(e);for(const o of n){const n=`${e}/${o}`;const i=`${t}/${o}`;const a=yield f.lstat(n);if(a.isDirectory()){yield cpDirRecursive(n,i,r,s)}else{yield copyFile(n,i,s)}}yield f.chmod(t,(yield f.stat(e)).mode)})}function copyFile(e,t,r){return i(this,void 0,void 0,function*(){if((yield f.lstat(e)).isSymbolicLink()){try{yield f.lstat(t);yield f.unlink(t)}catch(e){if(e.code==="EPERM"){yield f.chmod(t,"0666");yield f.unlink(t)}}const r=yield f.readlink(e);yield f.symlink(r,t,f.IS_WINDOWS?"junction":null)}else if(!(yield f.exists(t))||r){yield f.copyFile(e,t)}})}},334:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});async function auth(e){const t=e.split(/\./).length===3?"app":/^v\d+\./.test(e)?"installation":"oauth";return{type:"token",token:e,tokenType:t}}function withAuthorizationPrefix(e){if(e.split(/\./).length===3){return`bearer ${e}`}return`token ${e}`}async function hook(e,t,r,s){const n=t.endpoint.merge(r,s);n.headers.authorization=withAuthorizationPrefix(e);return t(n)}const r=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)})};t.createTokenAuth=r},6762:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var s=r(5030);var n=r(3682);var o=r(6234);var i=r(8467);var a=r(334);function _objectWithoutPropertiesLoose(e,t){if(e==null)return{};var r={};var s=Object.keys(e);var n,o;for(o=0;o=0)continue;r[n]=e[n]}return r}function _objectWithoutProperties(e,t){if(e==null)return{};var r=_objectWithoutPropertiesLoose(e,t);var s,n;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(n=0;n=0)continue;if(!Object.prototype.propertyIsEnumerable.call(e,s))continue;r[s]=e[s]}}return r}const c="3.5.1";const u=["authStrategy"];class Octokit{constructor(e={}){const t=new n.Collection;const r={baseUrl:o.request.endpoint.DEFAULTS.baseUrl,headers:{},request:Object.assign({},e.request,{hook:t.bind(null,"request")}),mediaType:{previews:[],format:""}};r.headers["user-agent"]=[e.userAgent,`octokit-core.js/${c} ${s.getUserAgent()}`].filter(Boolean).join(" ");if(e.baseUrl){r.baseUrl=e.baseUrl}if(e.previews){r.mediaType.previews=e.previews}if(e.timeZone){r.headers["time-zone"]=e.timeZone}this.request=o.request.defaults(r);this.graphql=i.withCustomRequest(this.request).defaults(r);this.log=Object.assign({debug:()=>{},info:()=>{},warn:console.warn.bind(console),error:console.error.bind(console)},e.log);this.hook=t;if(!e.authStrategy){if(!e.auth){this.auth=(async()=>({type:"unauthenticated"}))}else{const r=a.createTokenAuth(e.auth);t.wrap("request",r.hook);this.auth=r}}else{const{authStrategy:r}=e,s=_objectWithoutProperties(e,u);const n=r(Object.assign({request:this.request,log:this.log,octokit:this,octokitOptions:s},e.auth));t.wrap("request",n.hook);this.auth=n}const l=this.constructor;l.plugins.forEach(t=>{Object.assign(this,t(this,e))})}static defaults(e){const t=class extends(this){constructor(...t){const r=t[0]||{};if(typeof e==="function"){super(e(r));return}super(Object.assign({},e,r,r.userAgent&&e.userAgent?{userAgent:`${r.userAgent} ${e.userAgent}`}:null))}};return t}static plugin(...e){var t;const r=this.plugins;const s=(t=class extends(this){},t.plugins=r.concat(e.filter(e=>!r.includes(e))),t);return s}}Octokit.VERSION=c;Octokit.plugins=[];t.Octokit=Octokit},9440:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var s=r(3287);var n=r(5030);function lowercaseKeys(e){if(!e){return{}}return Object.keys(e).reduce((t,r)=>{t[r.toLowerCase()]=e[r];return t},{})}function mergeDeep(e,t){const r=Object.assign({},e);Object.keys(t).forEach(n=>{if(s.isPlainObject(t[n])){if(!(n in e))Object.assign(r,{[n]:t[n]});else r[n]=mergeDeep(e[n],t[n])}else{Object.assign(r,{[n]:t[n]})}});return r}function removeUndefinedProperties(e){for(const t in e){if(e[t]===undefined){delete e[t]}}return e}function merge(e,t,r){if(typeof t==="string"){let[e,s]=t.split(" ");r=Object.assign(s?{method:e,url:s}:{url:e},r)}else{r=Object.assign({},t)}r.headers=lowercaseKeys(r.headers);removeUndefinedProperties(r);removeUndefinedProperties(r.headers);const s=mergeDeep(e||{},r);if(e&&e.mediaType.previews.length){s.mediaType.previews=e.mediaType.previews.filter(e=>!s.mediaType.previews.includes(e)).concat(s.mediaType.previews)}s.mediaType.previews=s.mediaType.previews.map(e=>e.replace(/-preview/,""));return s}function addQueryParameters(e,t){const r=/\?/.test(e)?"&":"?";const s=Object.keys(t);if(s.length===0){return e}return e+r+s.map(e=>{if(e==="q"){return"q="+t.q.split("+").map(encodeURIComponent).join("+")}return`${e}=${encodeURIComponent(t[e])}`}).join("&")}const o=/\{[^}]+\}/g;function removeNonChars(e){return e.replace(/^\W+|\W+$/g,"").split(/,/)}function extractUrlVariableNames(e){const t=e.match(o);if(!t){return[]}return t.map(removeNonChars).reduce((e,t)=>e.concat(t),[])}function omit(e,t){return Object.keys(e).filter(e=>!t.includes(e)).reduce((t,r)=>{t[r]=e[r];return t},{})}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,t,r){t=e==="+"||e==="#"?encodeReserved(t):encodeUnreserved(t);if(r){return encodeUnreserved(r)+"="+t}else{return t}}function isDefined(e){return e!==undefined&&e!==null}function isKeyOperator(e){return e===";"||e==="&"||e==="?"}function getValues(e,t,r,s){var n=e[r],o=[];if(isDefined(n)&&n!==""){if(typeof n==="string"||typeof n==="number"||typeof n==="boolean"){n=n.toString();if(s&&s!=="*"){n=n.substring(0,parseInt(s,10))}o.push(encodeValue(t,n,isKeyOperator(t)?r:""))}else{if(s==="*"){if(Array.isArray(n)){n.filter(isDefined).forEach(function(e){o.push(encodeValue(t,e,isKeyOperator(t)?r:""))})}else{Object.keys(n).forEach(function(e){if(isDefined(n[e])){o.push(encodeValue(t,n[e],e))}})}}else{const e=[];if(Array.isArray(n)){n.filter(isDefined).forEach(function(r){e.push(encodeValue(t,r))})}else{Object.keys(n).forEach(function(r){if(isDefined(n[r])){e.push(encodeUnreserved(r));e.push(encodeValue(t,n[r].toString()))}})}if(isKeyOperator(t)){o.push(encodeUnreserved(r)+"="+e.join(","))}else if(e.length!==0){o.push(e.join(","))}}}}else{if(t===";"){if(isDefined(n)){o.push(encodeUnreserved(r))}}else if(n===""&&(t==="&"||t==="?")){o.push(encodeUnreserved(r)+"=")}else if(n===""){o.push("")}}return o}function parseUrl(e){return{expand:expand.bind(null,e)}}function expand(e,t){var r=["+","#",".","/",";","?","&"];return e.replace(/\{([^\{\}]+)\}|([^\{\}]+)/g,function(e,s,n){if(s){let e="";const n=[];if(r.indexOf(s.charAt(0))!==-1){e=s.charAt(0);s=s.substr(1)}s.split(/,/g).forEach(function(r){var s=/([^:\*]*)(?::(\d+)|(\*))?/.exec(r);n.push(getValues(t,e,s[1],s[2]||s[3]))});if(e&&e!=="+"){var o=",";if(e==="?"){o="&"}else if(e!=="#"){o=e}return(n.length!==0?e:"")+n.join(o)}else{return n.join(",")}}else{return encodeReserved(n)}})}function parse(e){let t=e.method.toUpperCase();let r=(e.url||"/").replace(/:([a-z]\w+)/g,"{$1}");let s=Object.assign({},e.headers);let n;let o=omit(e,["method","baseUrl","url","headers","request","mediaType"]);const i=extractUrlVariableNames(r);r=parseUrl(r).expand(o);if(!/^http/.test(r)){r=e.baseUrl+r}const a=Object.keys(e).filter(e=>i.includes(e)).concat("baseUrl");const c=omit(o,a);const u=/application\/octet-stream/i.test(s.accept);if(!u){if(e.mediaType.format){s.accept=s.accept.split(/,/).map(t=>t.replace(/application\/vnd(\.\w+)(\.v3)?(\.\w+)?(\+json)?$/,`application/vnd$1$2.${e.mediaType.format}`)).join(",")}if(e.mediaType.previews.length){const t=s.accept.match(/[\w-]+(?=-preview)/g)||[];s.accept=t.concat(e.mediaType.previews).map(t=>{const r=e.mediaType.format?`.${e.mediaType.format}`:"+json";return`application/vnd.github.${t}-preview${r}`}).join(",")}}if(["GET","HEAD"].includes(t)){r=addQueryParameters(r,c)}else{if("data"in c){n=c.data}else{if(Object.keys(c).length){n=c}else{s["content-length"]=0}}}if(!s["content-type"]&&typeof n!=="undefined"){s["content-type"]="application/json; charset=utf-8"}if(["PATCH","PUT"].includes(t)&&typeof n==="undefined"){n=""}return Object.assign({method:t,url:r,headers:s},typeof n!=="undefined"?{body:n}:null,e.request?{request:e.request}:null)}function endpointWithDefaults(e,t,r){return parse(merge(e,t,r))}function withDefaults(e,t){const r=merge(e,t);const s=endpointWithDefaults.bind(null,r);return Object.assign(s,{DEFAULTS:r,defaults:withDefaults.bind(null,r),merge:merge.bind(null,r),parse:parse})}const i="6.0.12";const a=`octokit-endpoint.js/${i} ${n.getUserAgent()}`;const c={method:"GET",baseUrl:"https://api.github.com",headers:{accept:"application/vnd.github.v3+json","user-agent":a},mediaType:{format:"",previews:[]}};const u=withDefaults(null,c);t.endpoint=u},8467:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var s=r(6234);var n=r(5030);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,t,r){super(_buildMessageForResponseErrors(r));this.request=e;this.headers=t;this.response=r;this.name="GraphqlResponseError";this.errors=r.errors;this.data=r.data;if(Error.captureStackTrace){Error.captureStackTrace(this,this.constructor)}}}const i=["method","baseUrl","url","headers","request","query","mediaType"];const a=["query","method","url"];const c=/\/api\/v3\/?$/;function graphql(e,t,r){if(r){if(typeof t==="string"&&"query"in r){return Promise.reject(new Error(`[@octokit/graphql] "query" cannot be used as variable name`))}for(const e in r){if(!a.includes(e))continue;return Promise.reject(new Error(`[@octokit/graphql] "${e}" cannot be used as variable name`))}}const s=typeof t==="string"?Object.assign({query:t},r):t;const n=Object.keys(s).reduce((e,t)=>{if(i.includes(t)){e[t]=s[t];return e}if(!e.variables){e.variables={}}e.variables[t]=s[t];return e},{});const o=s.baseUrl||e.endpoint.DEFAULTS.baseUrl;if(c.test(o)){n.url=o.replace(c,"/api/graphql")}return e(n).then(e=>{if(e.data.errors){const t={};for(const r of Object.keys(e.headers)){t[r]=e.headers[r]}throw new GraphqlResponseError(n,t,e.data)}return e.data.data})}function withDefaults(e,t){const r=e.defaults(t);const n=(e,t)=>{return graphql(r,e,t)};return Object.assign(n,{defaults:withDefaults.bind(null,r),endpoint:s.request.endpoint})}const u=withDefaults(s.request,{headers:{"user-agent":`octokit-graphql.js/${o} ${n.getUserAgent()}`},method:"POST",url:"/graphql"});function withCustomRequest(e){return withDefaults(e,{method:"POST",url:"/graphql"})}t.GraphqlResponseError=GraphqlResponseError;t.graphql=u;t.withCustomRequest=withCustomRequest},4193:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const r="2.16.0";function ownKeys(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(e);if(t){s=s.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})}r.push.apply(r,s)}return r}function _objectSpread2(e){for(var t=1;t({async next(){if(!a)return{done:true};try{const e=await n({method:o,url:a,headers:i});const t=normalizePaginatedListResponse(e);a=((t.headers.link||"").match(/<([^>]+)>;\s*rel="next"/)||[])[1];return{value:t}}catch(e){if(e.status!==409)throw e;a="";return{value:{status:200,headers:{},data:[]}}}}})}}function paginate(e,t,r,s){if(typeof r==="function"){s=r;r=undefined}return gather(e,[],iterator(e,t,r)[Symbol.asyncIterator](),s)}function gather(e,t,r,s){return r.next().then(n=>{if(n.done){return t}let o=false;function done(){o=true}t=t.concat(s?s(n.value,done):n.value.data);if(o){return t}return gather(e,t,r,s)})}const s=Object.assign(paginate,{iterator:iterator});const n=["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}/actions/runners/downloads","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 /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/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/runners/downloads","GET /orgs/{org}/actions/secrets","GET /orgs/{org}/actions/secrets/{secret_name}/repositories","GET /orgs/{org}/blocks","GET /orgs/{org}/credential-authorizations","GET /orgs/{org}/events","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}/projects","GET /orgs/{org}/public_members","GET /orgs/{org}/repos","GET /orgs/{org}/secret-scanning/alerts","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}/team-sync/group-mappings","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/runners","GET /repos/{owner}/{repo}/actions/runners/downloads","GET /repos/{owner}/{repo}/actions/runs","GET /repos/{owner}/{repo}/actions/runs/{run_id}/artifacts","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}/autolinks","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}/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}/branches-where-head","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}/statuses","GET /repos/{owner}/{repo}/contributors","GET /repos/{owner}/{repo}/deployments","GET /repos/{owner}/{repo}/deployments/{deployment_id}/statuses","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}/secret-scanning/alerts","GET /repos/{owner}/{repo}/stargazers","GET /repos/{owner}/{repo}/subscribers","GET /repos/{owner}/{repo}/tags","GET /repos/{owner}/{repo}/teams","GET /repositories","GET /repositories/{repository_id}/environments/{environment_name}/secrets","GET /scim/v2/enterprises/{enterprise}/Groups","GET /scim/v2/enterprises/{enterprise}/Users","GET /scim/v2/organizations/{org}/Users","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}/team-sync/group-mappings","GET /teams/{team_id}/teams","GET /user/blocks","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/public_emails","GET /user/repos","GET /user/repository_invitations","GET /user/starred","GET /user/subscriptions","GET /user/teams","GET /user/{username}/packages","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}/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 n.includes(e)}else{return false}}function paginateRest(e){return{paginate:Object.assign(paginate.bind(null,e),{iterator:iterator.bind(null,e)})}}paginateRest.VERSION=r;t.composePaginateRest=s;t.isPaginatingEndpoint=isPaginatingEndpoint;t.paginateRest=paginateRest;t.paginatingEndpoints=n},3044:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});function ownKeys(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(e);if(t){s=s.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})}r.push.apply(r,s)}return r}function _objectSpread2(e){for(var t=1;t{"use strict";Object.defineProperty(t,"__esModule",{value:true});function _interopDefault(e){return e&&typeof e==="object"&&"default"in e?e["default"]:e}var s=r(8932);var n=_interopDefault(r(1223));const o=n(e=>console.warn(e));const i=n(e=>console.warn(e));class RequestError extends Error{constructor(e,t,r){super(e);if(Error.captureStackTrace){Error.captureStackTrace(this,this.constructor)}this.name="HttpError";this.status=t;let n;if("headers"in r&&typeof r.headers!=="undefined"){n=r.headers}if("response"in r){this.response=r.response;n=r.response.headers}const a=Object.assign({},r.request);if(r.request.headers.authorization){a.headers=Object.assign({},r.request.headers,{authorization:r.request.headers.authorization.replace(/ .*$/," [REDACTED]")})}a.url=a.url.replace(/\bclient_secret=\w+/g,"client_secret=[REDACTED]").replace(/\baccess_token=\w+/g,"access_token=[REDACTED]");this.request=a;Object.defineProperty(this,"code",{get(){o(new s.Deprecation("[@octokit/request-error] `error.code` is deprecated, use `error.status`."));return t}});Object.defineProperty(this,"headers",{get(){i(new s.Deprecation("[@octokit/request-error] `error.headers` is deprecated, use `error.response.headers`."));return n||{}}})}}t.RequestError=RequestError},6234:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});function _interopDefault(e){return e&&typeof e==="object"&&"default"in e?e["default"]:e}var s=r(9440);var n=r(5030);var o=r(3287);var i=_interopDefault(r(467));var a=r(537);const c="5.6.1";function getBufferResponse(e){return e.arrayBuffer()}function fetchWrapper(e){const t=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 r={};let s;let n;const c=e.request&&e.request.fetch||i;return c(e.url,Object.assign({method:e.method,body:e.body,headers:e.headers,redirect:e.redirect},e.request)).then(async o=>{n=o.url;s=o.status;for(const e of o.headers){r[e[0]]=e[1]}if("deprecation"in r){const s=r.link&&r.link.match(/<([^>]+)>; rel="deprecation"/);const n=s&&s.pop();t.warn(`[@octokit/request] "${e.method} ${e.url}" is deprecated. It is scheduled to be removed on ${r.sunset}${n?`. See ${n}`:""}`)}if(s===204||s===205){return}if(e.method==="HEAD"){if(s<400){return}throw new a.RequestError(o.statusText,s,{response:{url:n,status:s,headers:r,data:undefined},request:e})}if(s===304){throw new a.RequestError("Not modified",s,{response:{url:n,status:s,headers:r,data:await getResponseData(o)},request:e})}if(s>=400){const t=await getResponseData(o);const i=new a.RequestError(toErrorMessage(t),s,{response:{url:n,status:s,headers:r,data:t},request:e});throw i}return getResponseData(o)}).then(e=>{return{status:s,url:n,headers:r,data:e}}).catch(t=>{if(t instanceof a.RequestError)throw t;throw new a.RequestError(t.message,500,{request:e})})}async function getResponseData(e){const t=e.headers.get("content-type");if(/application\/json/.test(t)){return e.json()}if(!t||/^text\/|charset=utf-8$/.test(t)){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,t){const r=e.defaults(t);const s=function(e,t){const s=r.merge(e,t);if(!s.request||!s.request.hook){return fetchWrapper(r.parse(s))}const n=(e,t)=>{return fetchWrapper(r.parse(r.merge(e,t)))};Object.assign(n,{endpoint:r,defaults:withDefaults.bind(null,r)});return s.request.hook(n,s)};return Object.assign(s,{endpoint:r,defaults:withDefaults.bind(null,r)})}const u=withDefaults(s.endpoint,{headers:{"user-agent":`octokit-request.js/${c} ${n.getUserAgent()}`}});t.request=u},9417:e=>{"use strict";e.exports=balanced;function balanced(e,t,r){if(e instanceof RegExp)e=maybeMatch(e,r);if(t instanceof RegExp)t=maybeMatch(t,r);var s=range(e,t,r);return s&&{start:s[0],end:s[1],pre:r.slice(0,s[0]),body:r.slice(s[0]+e.length,s[1]),post:r.slice(s[1]+t.length)}}function maybeMatch(e,t){var r=t.match(e);return r?r[0]:null}balanced.range=range;function range(e,t,r){var s,n,o,i,a;var c=r.indexOf(e);var u=r.indexOf(t,c+1);var l=c;if(c>=0&&u>0){s=[];o=r.length;while(l>=0&&!a){if(l==c){s.push(l);c=r.indexOf(e,l+1)}else if(s.length==1){a=[s.pop(),u]}else{n=s.pop();if(n=0?c:u}if(s.length){a=[o,i]}}return a}},3682:(e,t,r)=>{var s=r(4670);var n=r(5549);var o=r(6819);var i=Function.bind;var a=i.bind(i);function bindApi(e,t,r){var s=a(o,null).apply(null,r?[t,r]:[t]);e.api={remove:s};e.remove=s;["before","error","after","wrap"].forEach(function(s){var o=r?[t,s,r]:[t,s];e[s]=e.api[s]=a(n,null).apply(null,o)})}function HookSingular(){var e="h";var t={registry:{}};var r=s.bind(null,t,e);bindApi(r,t,e);return r}function HookCollection(){var e={registry:{}};var t=s.bind(null,e);bindApi(t,e);return t}var c=false;function Hook(){if(!c){console.warn('[before-after-hook]: "Hook()" repurposing warning, use "Hook.Collection()". Read more: https://git.io/upgrade-before-after-hook-to-1.4');c=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},5549:e=>{e.exports=addHook;function addHook(e,t,r,s){var n=s;if(!e.registry[r]){e.registry[r]=[]}if(t==="before"){s=function(e,t){return Promise.resolve().then(n.bind(null,t)).then(e.bind(null,t))}}if(t==="after"){s=function(e,t){var r;return Promise.resolve().then(e.bind(null,t)).then(function(e){r=e;return n(r,t)}).then(function(){return r})}}if(t==="error"){s=function(e,t){return Promise.resolve().then(e.bind(null,t)).catch(function(e){return n(e,t)})}}e.registry[r].push({hook:s,orig:n})}},4670:e=>{e.exports=register;function register(e,t,r,s){if(typeof r!=="function"){throw new Error("method for before hook must be a function")}if(!s){s={}}if(Array.isArray(t)){return t.reverse().reduce(function(t,r){return register.bind(null,e,r,t,s)},r)()}return Promise.resolve().then(function(){if(!e.registry[t]){return r(s)}return e.registry[t].reduce(function(e,t){return t.hook.bind(null,e,s)},r)()})}},6819:e=>{e.exports=removeHook;function removeHook(e,t,r){if(!e.registry[t]){return}var s=e.registry[t].map(function(e){return e.orig}).indexOf(r);if(s===-1){return}e.registry[t].splice(s,1)}},3717:(e,t,r)=>{var s=r(6891);var n=r(9417);e.exports=expandTop;var o="\0SLASH"+Math.random()+"\0";var i="\0OPEN"+Math.random()+"\0";var a="\0CLOSE"+Math.random()+"\0";var c="\0COMMA"+Math.random()+"\0";var u="\0PERIOD"+Math.random()+"\0";function numeric(e){return parseInt(e,10)==e?parseInt(e,10):e.charCodeAt(0)}function escapeBraces(e){return e.split("\\\\").join(o).split("\\{").join(i).split("\\}").join(a).split("\\,").join(c).split("\\.").join(u)}function unescapeBraces(e){return e.split(o).join("\\").split(i).join("{").split(a).join("}").split(c).join(",").split(u).join(".")}function parseCommaParts(e){if(!e)return[""];var t=[];var r=n("{","}",e);if(!r)return e.split(",");var s=r.pre;var o=r.body;var i=r.post;var a=s.split(",");a[a.length-1]+="{"+o+"}";var c=parseCommaParts(i);if(i.length){a[a.length-1]+=c.shift();a.push.apply(a,c)}t.push.apply(t,a);return t}function expandTop(e){if(!e)return[];if(e.substr(0,2)==="{}"){e="\\{\\}"+e.substr(2)}return expand(escapeBraces(e),true).map(unescapeBraces)}function identity(e){return e}function embrace(e){return"{"+e+"}"}function isPadded(e){return/^-?0\d/.test(e)}function lte(e,t){return e<=t}function gte(e,t){return e>=t}function expand(e,t){var r=[];var o=n("{","}",e);if(!o||/\$$/.test(o.pre))return[e];var i=/^-?\d+\.\.-?\d+(?:\.\.-?\d+)?$/.test(o.body);var c=/^[a-zA-Z]\.\.[a-zA-Z](?:\.\.-?\d+)?$/.test(o.body);var u=i||c;var l=o.body.indexOf(",")>=0;if(!u&&!l){if(o.post.match(/,.*\}/)){e=o.pre+"{"+o.body+a+o.post;return expand(e)}return[e]}var f;if(u){f=o.body.split(/\.\./)}else{f=parseCommaParts(o.body);if(f.length===1){f=expand(f[0],false).map(embrace);if(f.length===1){var p=o.post.length?expand(o.post,false):[""];return p.map(function(e){return o.pre+f[0]+e})}}}var d=o.pre;var p=o.post.length?expand(o.post,false):[""];var h;if(u){var g=numeric(f[0]);var m=numeric(f[1]);var y=Math.max(f[0].length,f[1].length);var v=f.length==3?Math.abs(numeric(f[2])):1;var b=lte;var w=m0){var S=new Array(O+1).join("0");if(T<0)_="-"+S+_.slice(1);else _=S+_}}}h.push(_)}}else{h=s(f,function(e){return expand(e,false)})}for(var G=0;G{e.exports=function(e,r){var s=[];for(var n=0;n{"use strict";Object.defineProperty(t,"__esModule",{value:true});class Deprecation extends Error{constructor(e){super(e);if(Error.captureStackTrace){Error.captureStackTrace(this,this.constructor)}this.name="Deprecation"}}t.Deprecation=Deprecation},6863:(e,t,r)=>{e.exports=realpath;realpath.realpath=realpath;realpath.sync=realpathSync;realpath.realpathSync=realpathSync;realpath.monkeypatch=monkeypatch;realpath.unmonkeypatch=unmonkeypatch;var s=r(5747);var n=s.realpath;var o=s.realpathSync;var i=process.version;var a=/^v[0-5]\./.test(i);var c=r(1734);function newError(e){return e&&e.syscall==="realpath"&&(e.code==="ELOOP"||e.code==="ENOMEM"||e.code==="ENAMETOOLONG")}function realpath(e,t,r){if(a){return n(e,t,r)}if(typeof t==="function"){r=t;t=null}n(e,t,function(s,n){if(newError(s)){c.realpath(e,t,r)}else{r(s,n)}})}function realpathSync(e,t){if(a){return o(e,t)}try{return o(e,t)}catch(r){if(newError(r)){return c.realpathSync(e,t)}else{throw r}}}function monkeypatch(){s.realpath=realpath;s.realpathSync=realpathSync}function unmonkeypatch(){s.realpath=n;s.realpathSync=o}},1734:(e,t,r)=>{var s=r(5622);var n=process.platform==="win32";var o=r(5747);var i=process.env.NODE_DEBUG&&/fs/.test(process.env.NODE_DEBUG);function rethrow(){var e;if(i){var t=new Error;e=debugCallback}else e=missingCallback;return e;function debugCallback(e){if(e){t.message=e.message;e=t;missingCallback(e)}}function missingCallback(e){if(e){if(process.throwDeprecation)throw e;else if(!process.noDeprecation){var t="fs: missing callback "+(e.stack||e.message);if(process.traceDeprecation)console.trace(t);else console.error(t)}}}}function maybeCallback(e){return typeof e==="function"?e:rethrow()}var a=s.normalize;if(n){var c=/(.*?)(?:[\/\\]+|$)/g}else{var c=/(.*?)(?:[\/]+|$)/g}if(n){var u=/^(?:[a-zA-Z]:|[\\\/]{2}[^\\\/]+[\\\/][^\\\/]+)?[\\\/]*/}else{var u=/^[\/]*/}t.realpathSync=function realpathSync(e,t){e=s.resolve(e);if(t&&Object.prototype.hasOwnProperty.call(t,e)){return t[e]}var r=e,i={},a={};var l;var f;var p;var d;start();function start(){var t=u.exec(e);l=t[0].length;f=t[0];p=t[0];d="";if(n&&!a[p]){o.lstatSync(p);a[p]=true}}while(l=e.length){if(t)t[i]=e;return r(null,e)}c.lastIndex=f;var s=c.exec(e);h=p;p+=s[0];d=h+s[1];f=c.lastIndex;if(l[d]||t&&t[d]===d){return process.nextTick(LOOP)}if(t&&Object.prototype.hasOwnProperty.call(t,d)){return gotResolvedLink(t[d])}return o.lstat(d,gotStat)}function gotStat(e,s){if(e)return r(e);if(!s.isSymbolicLink()){l[d]=true;if(t)t[d]=d;return process.nextTick(LOOP)}if(!n){var i=s.dev.toString(32)+":"+s.ino.toString(32);if(a.hasOwnProperty(i)){return gotTarget(null,a[i],d)}}o.stat(d,function(e){if(e)return r(e);o.readlink(d,function(e,t){if(!n)a[i]=t;gotTarget(e,t)})})}function gotTarget(e,n,o){if(e)return r(e);var i=s.resolve(h,n);if(t)t[o]=i;gotResolvedLink(i)}function gotResolvedLink(t){e=s.resolve(t,e.slice(f));start()}}},7625:(e,t,r)=>{t.alphasort=alphasort;t.alphasorti=alphasorti;t.setopts=setopts;t.ownProp=ownProp;t.makeAbs=makeAbs;t.finish=finish;t.mark=mark;t.isIgnored=isIgnored;t.childrenIgnored=childrenIgnored;function ownProp(e,t){return Object.prototype.hasOwnProperty.call(e,t)}var s=r(5622);var n=r(3973);var o=r(8714);var i=n.Minimatch;function alphasorti(e,t){return e.toLowerCase().localeCompare(t.toLowerCase())}function alphasort(e,t){return e.localeCompare(t)}function setupIgnores(e,t){e.ignore=t.ignore||[];if(!Array.isArray(e.ignore))e.ignore=[e.ignore];if(e.ignore.length){e.ignore=e.ignore.map(ignoreMap)}}function ignoreMap(e){var t=null;if(e.slice(-3)==="/**"){var r=e.replace(/(\/\*\*)+$/,"");t=new i(r,{dot:true})}return{matcher:new i(e,{dot:true}),gmatcher:t}}function setopts(e,t,r){if(!r)r={};if(r.matchBase&&-1===t.indexOf("/")){if(r.noglobstar){throw new Error("base matching requires globstar")}t="**/"+t}e.silent=!!r.silent;e.pattern=t;e.strict=r.strict!==false;e.realpath=!!r.realpath;e.realpathCache=r.realpathCache||Object.create(null);e.follow=!!r.follow;e.dot=!!r.dot;e.mark=!!r.mark;e.nodir=!!r.nodir;if(e.nodir)e.mark=true;e.sync=!!r.sync;e.nounique=!!r.nounique;e.nonull=!!r.nonull;e.nosort=!!r.nosort;e.nocase=!!r.nocase;e.stat=!!r.stat;e.noprocess=!!r.noprocess;e.absolute=!!r.absolute;e.maxLength=r.maxLength||Infinity;e.cache=r.cache||Object.create(null);e.statCache=r.statCache||Object.create(null);e.symlinks=r.symlinks||Object.create(null);setupIgnores(e,r);e.changedCwd=false;var n=process.cwd();if(!ownProp(r,"cwd"))e.cwd=n;else{e.cwd=s.resolve(r.cwd);e.changedCwd=e.cwd!==n}e.root=r.root||s.resolve(e.cwd,"/");e.root=s.resolve(e.root);if(process.platform==="win32")e.root=e.root.replace(/\\/g,"/");e.cwdAbs=o(e.cwd)?e.cwd:makeAbs(e,e.cwd);if(process.platform==="win32")e.cwdAbs=e.cwdAbs.replace(/\\/g,"/");e.nomount=!!r.nomount;r.nonegate=true;r.nocomment=true;e.minimatch=new i(t,r);e.options=e.minimatch.options}function finish(e){var t=e.nounique;var r=t?[]:Object.create(null);for(var s=0,n=e.matches.length;s{e.exports=glob;var s=r(5747);var n=r(6863);var o=r(3973);var i=o.Minimatch;var a=r(4124);var c=r(8614).EventEmitter;var u=r(5622);var l=r(2357);var f=r(8714);var p=r(9010);var d=r(7625);var h=d.alphasort;var g=d.alphasorti;var m=d.setopts;var y=d.ownProp;var v=r(2492);var b=r(1669);var w=d.childrenIgnored;var E=d.isIgnored;var T=r(1223);function glob(e,t,r){if(typeof t==="function")r=t,t={};if(!t)t={};if(t.sync){if(r)throw new TypeError("callback provided to sync glob");return p(e,t)}return new Glob(e,t,r)}glob.sync=p;var _=glob.GlobSync=p.GlobSync;glob.glob=glob;function extend(e,t){if(t===null||typeof t!=="object"){return e}var r=Object.keys(t);var s=r.length;while(s--){e[r[s]]=t[r[s]]}return e}glob.hasMagic=function(e,t){var r=extend({},t);r.noprocess=true;var s=new Glob(e,r);var n=s.minimatch.set;if(!e)return false;if(n.length>1)return true;for(var o=0;othis.maxLength)return t();if(!this.stat&&y(this.cache,r)){var o=this.cache[r];if(Array.isArray(o))o="DIR";if(!n||o==="DIR")return t(null,o);if(n&&o==="FILE")return t()}var i;var a=this.statCache[r];if(a!==undefined){if(a===false)return t(null,a);else{var c=a.isDirectory()?"DIR":"FILE";if(n&&c==="FILE")return t();else return t(null,c,a)}}var u=this;var l=v("stat\0"+r,lstatcb_);if(l)s.lstat(r,l);function lstatcb_(n,o){if(o&&o.isSymbolicLink()){return s.stat(r,function(s,n){if(s)u._stat2(e,r,null,o,t);else u._stat2(e,r,s,n,t)})}else{u._stat2(e,r,n,o,t)}}};Glob.prototype._stat2=function(e,t,r,s,n){if(r&&(r.code==="ENOENT"||r.code==="ENOTDIR")){this.statCache[t]=false;return n()}var o=e.slice(-1)==="/";this.statCache[t]=s;if(t.slice(-1)==="/"&&s&&!s.isDirectory())return n(null,false,s);var i=true;if(s)i=s.isDirectory()?"DIR":"FILE";this.cache[t]=this.cache[t]||i;if(o&&i==="FILE")return n();return n(null,i,s)}},9010:(e,t,r)=>{e.exports=globSync;globSync.GlobSync=GlobSync;var s=r(5747);var n=r(6863);var o=r(3973);var i=o.Minimatch;var a=r(1957).Glob;var c=r(1669);var u=r(5622);var l=r(2357);var f=r(8714);var p=r(7625);var d=p.alphasort;var h=p.alphasorti;var g=p.setopts;var m=p.ownProp;var y=p.childrenIgnored;var v=p.isIgnored;function globSync(e,t){if(typeof t==="function"||arguments.length===3)throw new TypeError("callback provided to sync glob\n"+"See: https://github.com/isaacs/node-glob/issues/167");return new GlobSync(e,t).found}function GlobSync(e,t){if(!e)throw new Error("must provide pattern");if(typeof t==="function"||arguments.length===3)throw new TypeError("callback provided to sync glob\n"+"See: https://github.com/isaacs/node-glob/issues/167");if(!(this instanceof GlobSync))return new GlobSync(e,t);g(this,e,t);if(this.noprocess)return this;var r=this.minimatch.set.length;this.matches=new Array(r);for(var s=0;sthis.maxLength)return false;if(!this.stat&&m(this.cache,t)){var n=this.cache[t];if(Array.isArray(n))n="DIR";if(!r||n==="DIR")return n;if(r&&n==="FILE")return false}var o;var i=this.statCache[t];if(!i){var a;try{a=s.lstatSync(t)}catch(e){if(e&&(e.code==="ENOENT"||e.code==="ENOTDIR")){this.statCache[t]=false;return false}}if(a&&a.isSymbolicLink()){try{i=s.statSync(t)}catch(e){i=a}}else{i=a}}this.statCache[t]=i;var n=true;if(i)n=i.isDirectory()?"DIR":"FILE";this.cache[t]=this.cache[t]||n;if(r&&n==="FILE")return false;return n};GlobSync.prototype._mark=function(e){return p.mark(this,e)};GlobSync.prototype._makeAbs=function(e){return p.makeAbs(this,e)}},2492:(e,t,r)=>{var s=r(2940);var n=Object.create(null);var o=r(1223);e.exports=s(inflight);function inflight(e,t){if(n[e]){n[e].push(t);return null}else{n[e]=[t];return makeres(e)}}function makeres(e){return o(function RES(){var t=n[e];var r=t.length;var s=slice(arguments);try{for(var o=0;or){t.splice(0,r);process.nextTick(function(){RES.apply(null,s)})}else{delete n[e]}}})}function slice(e){var t=e.length;var r=[];for(var s=0;s{try{var s=r(1669);if(typeof s.inherits!=="function")throw"";e.exports=s.inherits}catch(t){e.exports=r(8544)}},8544:e=>{if(typeof Object.create==="function"){e.exports=function inherits(e,t){if(t){e.super_=t;e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:false,writable:true,configurable:true}})}}}else{e.exports=function inherits(e,t){if(t){e.super_=t;var r=function(){};r.prototype=t.prototype;e.prototype=new r;e.prototype.constructor=e}}}},3287:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});function isObject(e){return Object.prototype.toString.call(e)==="[object Object]"}function isPlainObject(e){var t,r;if(isObject(e)===false)return false;t=e.constructor;if(t===undefined)return true;r=t.prototype;if(isObject(r)===false)return false;if(r.hasOwnProperty("isPrototypeOf")===false){return false}return true}t.isPlainObject=isPlainObject},3973:(e,t,r)=>{e.exports=minimatch;minimatch.Minimatch=Minimatch;var s={sep:"/"};try{s=r(5622)}catch(e){}var n=minimatch.GLOBSTAR=Minimatch.GLOBSTAR={};var o=r(3717);var i={"!":{open:"(?:(?!(?:",close:"))[^/]*?)"},"?":{open:"(?:",close:")?"},"+":{open:"(?:",close:")+"},"*":{open:"(?:",close:")*"},"@":{open:"(?:",close:")"}};var a="[^/]";var c=a+"*?";var u="(?:(?!(?:\\/|^)(?:\\.{1,2})($|\\/)).)*?";var l="(?:(?!(?:\\/|^)\\.).)*?";var f=charSet("().*{}+?[]^$\\!");function charSet(e){return e.split("").reduce(function(e,t){e[t]=true;return e},{})}var p=/\/+/;minimatch.filter=filter;function filter(e,t){t=t||{};return function(r,s,n){return minimatch(r,e,t)}}function ext(e,t){e=e||{};t=t||{};var r={};Object.keys(t).forEach(function(e){r[e]=t[e]});Object.keys(e).forEach(function(t){r[t]=e[t]});return r}minimatch.defaults=function(e){if(!e||!Object.keys(e).length)return minimatch;var t=minimatch;var r=function minimatch(r,s,n){return t.minimatch(r,s,ext(e,n))};r.Minimatch=function Minimatch(r,s){return new t.Minimatch(r,ext(e,s))};return r};Minimatch.defaults=function(e){if(!e||!Object.keys(e).length)return Minimatch;return minimatch.defaults(e).Minimatch};function minimatch(e,t,r){if(typeof t!=="string"){throw new TypeError("glob pattern string required")}if(!r)r={};if(!r.nocomment&&t.charAt(0)==="#"){return false}if(t.trim()==="")return e==="";return new Minimatch(t,r).match(e)}function Minimatch(e,t){if(!(this instanceof Minimatch)){return new Minimatch(e,t)}if(typeof e!=="string"){throw new TypeError("glob pattern string required")}if(!t)t={};e=e.trim();if(s.sep!=="/"){e=e.split(s.sep).join("/")}this.options=t;this.set=[];this.pattern=e;this.regexp=null;this.negate=false;this.comment=false;this.empty=false;this.make()}Minimatch.prototype.debug=function(){};Minimatch.prototype.make=make;function make(){if(this._made)return;var e=this.pattern;var t=this.options;if(!t.nocomment&&e.charAt(0)==="#"){this.comment=true;return}if(!e){this.empty=true;return}this.parseNegate();var r=this.globSet=this.braceExpand();if(t.debug)this.debug=console.error;this.debug(this.pattern,r);r=this.globParts=r.map(function(e){return e.split(p)});this.debug(this.pattern,r);r=r.map(function(e,t,r){return e.map(this.parse,this)},this);this.debug(this.pattern,r);r=r.filter(function(e){return e.indexOf(false)===-1});this.debug(this.pattern,r);this.set=r}Minimatch.prototype.parseNegate=parseNegate;function parseNegate(){var e=this.pattern;var t=false;var r=this.options;var s=0;if(r.nonegate)return;for(var n=0,o=e.length;n1024*64){throw new TypeError("pattern is too long")}var r=this.options;if(!r.noglobstar&&e==="**")return n;if(e==="")return"";var s="";var o=!!r.nocase;var u=false;var l=[];var p=[];var h;var g=false;var m=-1;var y=-1;var v=e.charAt(0)==="."?"":r.dot?"(?!(?:^|\\/)\\.{1,2}(?:$|\\/))":"(?!\\.)";var b=this;function clearStateChar(){if(h){switch(h){case"*":s+=c;o=true;break;case"?":s+=a;o=true;break;default:s+="\\"+h;break}b.debug("clearStateChar %j %j",h,s);h=false}}for(var w=0,E=e.length,T;w-1;C--){var j=p[C];var P=s.slice(0,j.reStart);var D=s.slice(j.reStart,j.reEnd-8);var F=s.slice(j.reEnd-8,j.reEnd);var R=s.slice(j.reEnd);F+=R;var x=P.split("(").length-1;var I=R;for(w=0;w=0;i--){o=e[i];if(o)break}for(i=0;i>> no match, partial?",e,f,t,p);if(f===a)return true}return false}var h;if(typeof u==="string"){if(s.nocase){h=l.toLowerCase()===u.toLowerCase()}else{h=l===u}this.debug("string match",u,l,h)}else{h=l.match(u);this.debug("pattern match",u,l,h)}if(!h)return false}if(o===a&&i===c){return true}else if(o===a){return r}else if(i===c){var g=o===a-1&&e[o]==="";return g}throw new Error("wtf?")};function globUnescape(e){return e.replace(/\\(.)/g,"$1")}function regExpEscape(e){return e.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&")}},467:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});function _interopDefault(e){return e&&typeof e==="object"&&"default"in e?e["default"]:e}var s=_interopDefault(r(2413));var n=_interopDefault(r(8605));var o=_interopDefault(r(8835));var i=_interopDefault(r(7211));var a=_interopDefault(r(8761));const c=s.Readable;const u=Symbol("buffer");const l=Symbol("type");class Blob{constructor(){this[l]="";const e=arguments[0];const t=arguments[1];const r=[];let s=0;if(e){const t=e;const n=Number(t.length);for(let e=0;e1&&arguments[1]!==undefined?arguments[1]:{},n=r.size;let o=n===undefined?0:n;var i=r.timeout;let a=i===undefined?0:i;if(e==null){e=null}else if(isURLSearchParams(e)){e=Buffer.from(e.toString())}else if(isBlob(e)) ;else if(Buffer.isBuffer(e)) ;else if(Object.prototype.toString.call(e)==="[object ArrayBuffer]"){e=Buffer.from(e)}else if(ArrayBuffer.isView(e)){e=Buffer.from(e.buffer,e.byteOffset,e.byteLength)}else if(e instanceof s) ;else{e=Buffer.from(String(e))}this[p]={body:e,disturbed:false,error:null};this.size=o;this.timeout=a;if(e instanceof s){e.on("error",function(e){const r=e.name==="AbortError"?e:new FetchError(`Invalid response body while trying to fetch ${t.url}: ${e.message}`,"system",e);t[p].error=r})}}Body.prototype={get body(){return this[p].body},get bodyUsed(){return this[p].disturbed},arrayBuffer(){return consumeBody.call(this).then(function(e){return e.buffer.slice(e.byteOffset,e.byteOffset+e.byteLength)})},blob(){let e=this.headers&&this.headers.get("content-type")||"";return consumeBody.call(this).then(function(t){return Object.assign(new Blob([],{type:e.toLowerCase()}),{[u]:t})})},json(){var e=this;return consumeBody.call(this).then(function(t){try{return JSON.parse(t.toString())}catch(t){return Body.Promise.reject(new FetchError(`invalid json response body at ${e.url} reason: ${t.message}`,"invalid-json"))}})},text(){return consumeBody.call(this).then(function(e){return e.toString()})},buffer(){return consumeBody.call(this)},textConverted(){var e=this;return consumeBody.call(this).then(function(t){return convertBody(t,e.headers)})}};Object.defineProperties(Body.prototype,{body:{enumerable:true},bodyUsed:{enumerable:true},arrayBuffer:{enumerable:true},blob:{enumerable:true},json:{enumerable:true},text:{enumerable:true}});Body.mixIn=function(e){for(const t of Object.getOwnPropertyNames(Body.prototype)){if(!(t in e)){const r=Object.getOwnPropertyDescriptor(Body.prototype,t);Object.defineProperty(e,t,r)}}};function consumeBody(){var e=this;if(this[p].disturbed){return Body.Promise.reject(new TypeError(`body used already for: ${this.url}`))}this[p].disturbed=true;if(this[p].error){return Body.Promise.reject(this[p].error)}let t=this.body;if(t===null){return Body.Promise.resolve(Buffer.alloc(0))}if(isBlob(t)){t=t.stream()}if(Buffer.isBuffer(t)){return Body.Promise.resolve(t)}if(!(t instanceof s)){return Body.Promise.resolve(Buffer.alloc(0))}let r=[];let n=0;let o=false;return new Body.Promise(function(s,i){let a;if(e.timeout){a=setTimeout(function(){o=true;i(new FetchError(`Response timeout while trying to fetch ${e.url} (over ${e.timeout}ms)`,"body-timeout"))},e.timeout)}t.on("error",function(t){if(t.name==="AbortError"){o=true;i(t)}else{i(new FetchError(`Invalid response body while trying to fetch ${e.url}: ${t.message}`,"system",t))}});t.on("data",function(t){if(o||t===null){return}if(e.size&&n+t.length>e.size){o=true;i(new FetchError(`content size at ${e.url} over limit: ${e.size}`,"max-size"));return}n+=t.length;r.push(t)});t.on("end",function(){if(o){return}clearTimeout(a);try{s(Buffer.concat(r,n))}catch(t){i(new FetchError(`Could not create Buffer from response body for ${e.url}: ${t.message}`,"system",t))}})})}function convertBody(e,t){if(typeof f!=="function"){throw new Error("The package `encoding` must be installed to use the textConverted() function")}const r=t.get("content-type");let s="utf-8";let n,o;if(r){n=/charset=([^;]*)/i.exec(r)}o=e.slice(0,1024).toString();if(!n&&o){n=/0&&arguments[0]!==undefined?arguments[0]:undefined;this[m]=Object.create(null);if(e instanceof Headers){const t=e.raw();const r=Object.keys(t);for(const e of r){for(const r of t[e]){this.append(e,r)}}return}if(e==null) ;else if(typeof e==="object"){const t=e[Symbol.iterator];if(t!=null){if(typeof t!=="function"){throw new TypeError("Header pairs must be iterable")}const r=[];for(const t of e){if(typeof t!=="object"||typeof t[Symbol.iterator]!=="function"){throw new TypeError("Each header pair must be iterable")}r.push(Array.from(t))}for(const e of r){if(e.length!==2){throw new TypeError("Each header pair must be a name/value tuple")}this.append(e[0],e[1])}}else{for(const t of Object.keys(e)){const r=e[t];this.append(t,r)}}}else{throw new TypeError("Provided initializer must be an object")}}get(e){e=`${e}`;validateName(e);const t=find(this[m],e);if(t===undefined){return null}return this[m][t].join(", ")}forEach(e){let t=arguments.length>1&&arguments[1]!==undefined?arguments[1]:undefined;let r=getHeaders(this);let s=0;while(s1&&arguments[1]!==undefined?arguments[1]:"key+value";const r=Object.keys(e[m]).sort();return r.map(t==="key"?function(e){return e.toLowerCase()}:t==="value"?function(t){return e[m][t].join(", ")}:function(t){return[t.toLowerCase(),e[m][t].join(", ")]})}const y=Symbol("internal");function createHeadersIterator(e,t){const r=Object.create(v);r[y]={target:e,kind:t,index:0};return r}const v=Object.setPrototypeOf({next(){if(!this||Object.getPrototypeOf(this)!==v){throw new TypeError("Value of `this` is not a HeadersIterator")}var e=this[y];const t=e.target,r=e.kind,s=e.index;const n=getHeaders(t,r);const o=n.length;if(s>=o){return{value:undefined,done:true}}this[y].index=s+1;return{value:n[s],done:false}}},Object.getPrototypeOf(Object.getPrototypeOf([][Symbol.iterator]())));Object.defineProperty(v,Symbol.toStringTag,{value:"HeadersIterator",writable:false,enumerable:false,configurable:true});function exportNodeCompatibleHeaders(e){const t=Object.assign({__proto__:null},e[m]);const r=find(e[m],"Host");if(r!==undefined){t[r]=t[r][0]}return t}function createHeadersLenient(e){const t=new Headers;for(const r of Object.keys(e)){if(h.test(r)){continue}if(Array.isArray(e[r])){for(const s of e[r]){if(g.test(s)){continue}if(t[m][r]===undefined){t[m][r]=[s]}else{t[m][r].push(s)}}}else if(!g.test(e[r])){t[m][r]=[e[r]]}}return t}const b=Symbol("Response internals");const w=n.STATUS_CODES;class Response{constructor(){let e=arguments.length>0&&arguments[0]!==undefined?arguments[0]:null;let t=arguments.length>1&&arguments[1]!==undefined?arguments[1]:{};Body.call(this,e,t);const r=t.status||200;const s=new Headers(t.headers);if(e!=null&&!s.has("Content-Type")){const t=extractContentType(e);if(t){s.append("Content-Type",t)}}this[b]={url:t.url,status:r,statusText:t.statusText||w[r],headers:s,counter:t.counter}}get url(){return this[b].url||""}get status(){return this[b].status}get ok(){return this[b].status>=200&&this[b].status<300}get redirected(){return this[b].counter>0}get statusText(){return this[b].statusText}get headers(){return this[b].headers}clone(){return new Response(clone(this),{url:this.url,status:this.status,statusText:this.statusText,headers:this.headers,ok:this.ok,redirected:this.redirected})}}Body.mixIn(Response.prototype);Object.defineProperties(Response.prototype,{url:{enumerable:true},status:{enumerable:true},ok:{enumerable:true},redirected:{enumerable:true},statusText:{enumerable:true},headers:{enumerable:true},clone:{enumerable:true}});Object.defineProperty(Response.prototype,Symbol.toStringTag,{value:"Response",writable:false,enumerable:false,configurable:true});const E=Symbol("Request internals");const T=o.parse;const _=o.format;const O="destroy"in s.Readable.prototype;function isRequest(e){return typeof e==="object"&&typeof e[E]==="object"}function isAbortSignal(e){const t=e&&typeof e==="object"&&Object.getPrototypeOf(e);return!!(t&&t.constructor.name==="AbortSignal")}class Request{constructor(e){let t=arguments.length>1&&arguments[1]!==undefined?arguments[1]:{};let r;if(!isRequest(e)){if(e&&e.href){r=T(e.href)}else{r=T(`${e}`)}e={}}else{r=T(e.url)}let s=t.method||e.method||"GET";s=s.toUpperCase();if((t.body!=null||isRequest(e)&&e.body!==null)&&(s==="GET"||s==="HEAD")){throw new TypeError("Request with GET/HEAD method cannot have body")}let n=t.body!=null?t.body:isRequest(e)&&e.body!==null?clone(e):null;Body.call(this,n,{timeout:t.timeout||e.timeout||0,size:t.size||e.size||0});const o=new Headers(t.headers||e.headers||{});if(n!=null&&!o.has("Content-Type")){const e=extractContentType(n);if(e){o.append("Content-Type",e)}}let i=isRequest(e)?e.signal:null;if("signal"in t)i=t.signal;if(i!=null&&!isAbortSignal(i)){throw new TypeError("Expected signal to be an instanceof AbortSignal")}this[E]={method:s,redirect:t.redirect||e.redirect||"follow",headers:o,parsedURL:r,signal:i};this.follow=t.follow!==undefined?t.follow:e.follow!==undefined?e.follow:20;this.compress=t.compress!==undefined?t.compress:e.compress!==undefined?e.compress:true;this.counter=t.counter||e.counter||0;this.agent=t.agent||e.agent}get method(){return this[E].method}get url(){return _(this[E].parsedURL)}get headers(){return this[E].headers}get redirect(){return this[E].redirect}get signal(){return this[E].signal}clone(){return new Request(this)}}Body.mixIn(Request.prototype);Object.defineProperty(Request.prototype,Symbol.toStringTag,{value:"Request",writable:false,enumerable:false,configurable:true});Object.defineProperties(Request.prototype,{method:{enumerable:true},url:{enumerable:true},headers:{enumerable:true},redirect:{enumerable:true},clone:{enumerable:true},signal:{enumerable:true}});function getNodeRequestOptions(e){const t=e[E].parsedURL;const r=new Headers(e[E].headers);if(!r.has("Accept")){r.set("Accept","*/*")}if(!t.protocol||!t.hostname){throw new TypeError("Only absolute URLs are supported")}if(!/^https?:$/.test(t.protocol)){throw new TypeError("Only HTTP(S) protocols are supported")}if(e.signal&&e.body instanceof s.Readable&&!O){throw new Error("Cancellation of streamed requests with AbortSignal is not supported in node < 8")}let n=null;if(e.body==null&&/^(POST|PUT)$/i.test(e.method)){n="0"}if(e.body!=null){const t=getTotalBytes(e);if(typeof t==="number"){n=String(t)}}if(n){r.set("Content-Length",n)}if(!r.has("User-Agent")){r.set("User-Agent","node-fetch/1.0 (+https://github.com/bitinn/node-fetch)")}if(e.compress&&!r.has("Accept-Encoding")){r.set("Accept-Encoding","gzip,deflate")}let o=e.agent;if(typeof o==="function"){o=o(t)}if(!r.has("Connection")&&!o){r.set("Connection","close")}return Object.assign({},t,{method:e.method,headers:exportNodeCompatibleHeaders(r),agent:o})}function AbortError(e){Error.call(this,e);this.type="aborted";this.message=e;Error.captureStackTrace(this,this.constructor)}AbortError.prototype=Object.create(Error.prototype);AbortError.prototype.constructor=AbortError;AbortError.prototype.name="AbortError";const S=s.PassThrough;const G=o.resolve;function fetch(e,t){if(!fetch.Promise){throw new Error("native promise missing, set fetch.Promise to your favorite alternative")}Body.Promise=fetch.Promise;return new fetch.Promise(function(r,o){const c=new Request(e,t);const u=getNodeRequestOptions(c);const l=(u.protocol==="https:"?i:n).request;const f=c.signal;let p=null;const d=function abort(){let e=new AbortError("The user aborted a request.");o(e);if(c.body&&c.body instanceof s.Readable){c.body.destroy(e)}if(!p||!p.body)return;p.body.emit("error",e)};if(f&&f.aborted){d();return}const h=function abortAndFinalize(){d();finalize()};const g=l(u);let m;if(f){f.addEventListener("abort",h)}function finalize(){g.abort();if(f)f.removeEventListener("abort",h);clearTimeout(m)}if(c.timeout){g.once("socket",function(e){m=setTimeout(function(){o(new FetchError(`network timeout at: ${c.url}`,"request-timeout"));finalize()},c.timeout)})}g.on("error",function(e){o(new FetchError(`request to ${c.url} failed, reason: ${e.message}`,"system",e));finalize()});g.on("response",function(e){clearTimeout(m);const t=createHeadersLenient(e.headers);if(fetch.isRedirect(e.statusCode)){const s=t.get("Location");const n=s===null?null:G(c.url,s);switch(c.redirect){case"error":o(new FetchError(`uri requested responds with a redirect, redirect mode is set to error: ${c.url}`,"no-redirect"));finalize();return;case"manual":if(n!==null){try{t.set("Location",n)}catch(e){o(e)}}break;case"follow":if(n===null){break}if(c.counter>=c.follow){o(new FetchError(`maximum redirect reached at: ${c.url}`,"max-redirect"));finalize();return}const s={headers:new Headers(c.headers),follow:c.follow,counter:c.counter+1,agent:c.agent,compress:c.compress,method:c.method,body:c.body,signal:c.signal,timeout:c.timeout,size:c.size};if(e.statusCode!==303&&c.body&&getTotalBytes(c)===null){o(new FetchError("Cannot follow redirect with body being a readable stream","unsupported-redirect"));finalize();return}if(e.statusCode===303||(e.statusCode===301||e.statusCode===302)&&c.method==="POST"){s.method="GET";s.body=undefined;s.headers.delete("content-length")}r(fetch(new Request(n,s)));finalize();return}}e.once("end",function(){if(f)f.removeEventListener("abort",h)});let s=e.pipe(new S);const n={url:c.url,status:e.statusCode,statusText:e.statusMessage,headers:t,size:c.size,timeout:c.timeout,counter:c.counter};const i=t.get("Content-Encoding");if(!c.compress||c.method==="HEAD"||i===null||e.statusCode===204||e.statusCode===304){p=new Response(s,n);r(p);return}const u={flush:a.Z_SYNC_FLUSH,finishFlush:a.Z_SYNC_FLUSH};if(i=="gzip"||i=="x-gzip"){s=s.pipe(a.createGunzip(u));p=new Response(s,n);r(p);return}if(i=="deflate"||i=="x-deflate"){const t=e.pipe(new S);t.once("data",function(e){if((e[0]&15)===8){s=s.pipe(a.createInflate())}else{s=s.pipe(a.createInflateRaw())}p=new Response(s,n);r(p)});return}if(i=="br"&&typeof a.createBrotliDecompress==="function"){s=s.pipe(a.createBrotliDecompress());p=new Response(s,n);r(p);return}p=new Response(s,n);r(p)});writeToStream(g,c)})}fetch.isRedirect=function(e){return e===301||e===302||e===303||e===307||e===308};fetch.Promise=global.Promise;e.exports=t=fetch;Object.defineProperty(t,"__esModule",{value:true});t.default=t;t.Headers=Headers;t.Request=Request;t.Response=Response;t.FetchError=FetchError},1223:(e,t,r)=>{var s=r(2940);e.exports=s(once);e.exports.strict=s(onceStrict);once.proto=once(function(){Object.defineProperty(Function.prototype,"once",{value:function(){return once(this)},configurable:true});Object.defineProperty(Function.prototype,"onceStrict",{value:function(){return onceStrict(this)},configurable:true})});function once(e){var t=function(){if(t.called)return t.value;t.called=true;return t.value=e.apply(this,arguments)};t.called=false;return t}function onceStrict(e){var t=function(){if(t.called)throw new Error(t.onceError);t.called=true;return t.value=e.apply(this,arguments)};var r=e.name||"Function wrapped with `once`";t.onceError=r+" shouldn't be called more than once";t.called=false;return t}},8714:e=>{"use strict";function posix(e){return e.charAt(0)==="/"}function win32(e){var t=/^([a-zA-Z]:|[\\\/]{2}[^\\\/]+[\\\/]+[^\\\/]+)?([\\\/])?([\s\S]*?)$/;var r=t.exec(e);var s=r[1]||"";var n=Boolean(s&&s.charAt(1)!==":");return Boolean(r[2]||n)}e.exports=process.platform==="win32"?win32:posix;e.exports.posix=posix;e.exports.win32=win32},5123:e=>{e.exports=["cat","cd","chmod","cp","dirs","echo","exec","find","grep","head","ln","ls","mkdir","mv","pwd","rm","sed","set","sort","tail","tempdir","test","to","toEnd","touch","uniq","which"]},3516:(e,t,r)=>{function __ncc_wildcard$0(e){if(e==="cat.js"||e==="cat")return r(271);else if(e==="cd.js"||e==="cd")return r(2051);else if(e==="chmod.js"||e==="chmod")return r(4975);else if(e==="common.js"||e==="common")return r(3687);else if(e==="cp.js"||e==="cp")return r(4932);else if(e==="dirs.js"||e==="dirs")return r(1178);else if(e==="echo.js"||e==="echo")return r(243);else if(e==="error.js"||e==="error")return r(232);else if(e==="exec-child.js"||e==="exec-child")return r(9607);else if(e==="exec.js"||e==="exec")return r(896);else if(e==="find.js"||e==="find")return r(7838);else if(e==="grep.js"||e==="grep")return r(7417);else if(e==="head.js"||e==="head")return r(6613);else if(e==="ln.js"||e==="ln")return r(5787);else if(e==="ls.js"||e==="ls")return r(5561);else if(e==="mkdir.js"||e==="mkdir")return r(2695);else if(e==="mv.js"||e==="mv")return r(9849);else if(e==="popd.js"||e==="popd")return r(227);else if(e==="pushd.js"||e==="pushd")return r(4177);else if(e==="pwd.js"||e==="pwd")return r(8553);else if(e==="rm.js"||e==="rm")return r(2830);else if(e==="sed.js"||e==="sed")return r(5899);else if(e==="set.js"||e==="set")return r(1411);else if(e==="sort.js"||e==="sort")return r(2116);else if(e==="tail.js"||e==="tail")return r(2284);else if(e==="tempdir.js"||e==="tempdir")return r(6150);else if(e==="test.js"||e==="test")return r(9723);else if(e==="to.js"||e==="to")return r(1961);else if(e==="toEnd.js"||e==="toEnd")return r(3736);else if(e==="touch.js"||e==="touch")return r(8358);else if(e==="uniq.js"||e==="uniq")return r(7286);else if(e==="which.js"||e==="which")return r(4766)}var s=r(3687);r(5123).forEach(function(e){__ncc_wildcard$0(e)});t.exit=process.exit;t.error=r(232);t.ShellString=s.ShellString;t.env=process.env;t.config=s.config},271:(e,t,r)=>{var s=r(3687);var n=r(5747);s.register("cat",_cat,{canReceivePipe:true,cmdOptions:{n:"number"}});function _cat(e,t){var r=s.readFromPipe();if(!t&&!r)s.error("no paths given");t=[].slice.call(arguments,1);t.forEach(function(e){if(!n.existsSync(e)){s.error("no such file or directory: "+e)}else if(s.statFollowLinks(e).isDirectory()){s.error(e+": Is a directory")}r+=n.readFileSync(e,"utf8")});if(e.number){r=addNumbers(r)}return r}e.exports=_cat;function addNumbers(e){var t=e.split("\n");var r=t.pop();t=t.map(function(e,t){return numberedLine(t+1,e)});if(r.length){r=numberedLine(t.length+1,r)}t.push(r);return t.join("\n")}function numberedLine(e,t){var r=(" "+e).slice(-6)+"\t";return r+t}},2051:(e,t,r)=>{var s=r(2087);var n=r(3687);n.register("cd",_cd,{});function _cd(e,t){if(!t)t=s.homedir();if(t==="-"){if(!process.env.OLDPWD){n.error("could not find previous directory")}else{t=process.env.OLDPWD}}try{var r=process.cwd();process.chdir(t);process.env.OLDPWD=r}catch(e){var o;try{n.statFollowLinks(t);o="not a directory: "+t}catch(e){o="no such file or directory: "+t}if(o)n.error(o)}return""}e.exports=_cd},4975:(e,t,r)=>{var s=r(3687);var n=r(5747);var o=r(5622);var i=function(e){return{OTHER_EXEC:e.EXEC,OTHER_WRITE:e.WRITE,OTHER_READ:e.READ,GROUP_EXEC:e.EXEC<<3,GROUP_WRITE:e.WRITE<<3,GROUP_READ:e.READ<<3,OWNER_EXEC:e.EXEC<<6,OWNER_WRITE:e.WRITE<<6,OWNER_READ:e.READ<<6,STICKY:parseInt("01000",8),SETGID:parseInt("02000",8),SETUID:parseInt("04000",8),TYPE_MASK:parseInt("0770000",8)}}({EXEC:1,WRITE:2,READ:4});s.register("chmod",_chmod,{});function _chmod(e,t,r){if(!r){if(e.length>0&&e.charAt(0)==="-"){[].unshift.call(arguments,"")}else{s.error("You must specify a file.")}}e=s.parseOptions(e,{R:"recursive",c:"changes",v:"verbose"});r=[].slice.call(arguments,2);var a;if(e.recursive){a=[];r.forEach(function addFile(e){var t=s.statNoFollowLinks(e);if(!t.isSymbolicLink()){a.push(e);if(t.isDirectory()){n.readdirSync(e).forEach(function(t){addFile(e+"/"+t)})}}})}else{a=r}a.forEach(function innerChmod(r){r=o.resolve(r);if(!n.existsSync(r)){s.error("File not found: "+r)}if(e.recursive&&s.statNoFollowLinks(r).isSymbolicLink()){return}var a=s.statFollowLinks(r);var c=a.isDirectory();var u=a.mode;var l=u&i.TYPE_MASK;var f=u;if(isNaN(parseInt(t,8))){t.split(",").forEach(function(t){var o=/([ugoa]*)([=\+-])([rwxXst]*)/i;var a=o.exec(t);if(a){var p=a[1];var d=a[2];var h=a[3];var g=p.indexOf("u")!==-1||p==="a"||p==="";var m=p.indexOf("g")!==-1||p==="a"||p==="";var y=p.indexOf("o")!==-1||p==="a"||p==="";var v=h.indexOf("r")!==-1;var b=h.indexOf("w")!==-1;var w=h.indexOf("x")!==-1;var E=h.indexOf("X")!==-1;var T=h.indexOf("t")!==-1;var _=h.indexOf("s")!==-1;if(E&&c){w=true}var O=0;if(g){O|=(v?i.OWNER_READ:0)+(b?i.OWNER_WRITE:0)+(w?i.OWNER_EXEC:0)+(_?i.SETUID:0)}if(m){O|=(v?i.GROUP_READ:0)+(b?i.GROUP_WRITE:0)+(w?i.GROUP_EXEC:0)+(_?i.SETGID:0)}if(y){O|=(v?i.OTHER_READ:0)+(b?i.OTHER_WRITE:0)+(w?i.OTHER_EXEC:0)}if(T){O|=i.STICKY}switch(d){case"+":f|=O;break;case"-":f&=~O;break;case"=":f=l+O;if(s.statFollowLinks(r).isDirectory()){f|=i.SETUID+i.SETGID&u}break;default:s.error("Could not recognize operator: `"+d+"`")}if(e.verbose){console.log(r+" -> "+f.toString(8))}if(u!==f){if(!e.verbose&&e.changes){console.log(r+" -> "+f.toString(8))}n.chmodSync(r,f);u=f}}else{s.error("Invalid symbolic mode change: "+t)}})}else{f=l+parseInt(t,8);if(s.statFollowLinks(r).isDirectory()){f|=i.SETUID+i.SETGID&u}n.chmodSync(r,f)}});return""}e.exports=_chmod},3687:(e,t,r)=>{"use strict";var s=r(2087);var n=r(5747);var o=r(1957);var i=r(3516);var a=Object.create(i);t.extend=Object.assign;var c=Boolean(process.versions.electron);var u={fatal:false,globOptions:{},maxdepth:255,noglob:false,silent:false,verbose:false,execPath:null,bufLength:64*1024};var l={reset:function(){Object.assign(this,u);if(!c){this.execPath=process.execPath}},resetForTesting:function(){this.reset();this.silent=true}};l.reset();t.config=l;var f={error:null,errorCode:0,currentCmd:"shell.js"};t.state=f;delete process.env.OLDPWD;function isObject(e){return typeof e==="object"&&e!==null}t.isObject=isObject;function log(){if(!l.silent){console.error.apply(console,arguments)}}t.log=log;function convertErrorOutput(e){if(typeof e!=="string"){throw new TypeError("input must be a string")}return e.replace(/\\/g,"/")}t.convertErrorOutput=convertErrorOutput;function error(e,t,r){if(typeof e!=="string")throw new Error("msg must be a string");var s={continue:false,code:1,prefix:f.currentCmd+": ",silent:false};if(typeof t==="number"&&isObject(r)){r.code=t}else if(isObject(t)){r=t}else if(typeof t==="number"){r={code:t}}else if(typeof t!=="number"){r={}}r=Object.assign({},s,r);if(!f.errorCode)f.errorCode=r.code;var n=convertErrorOutput(r.prefix+e);f.error=f.error?f.error+"\n":"";f.error+=n;if(l.fatal)throw new Error(n);if(e.length>0&&!r.silent)log(n);if(!r.continue){throw{msg:"earlyExit",retValue:new ShellString("",f.error,f.errorCode)}}}t.error=error;function ShellString(e,t,r){var s;if(e instanceof Array){s=e;s.stdout=e.join("\n");if(e.length>0)s.stdout+="\n"}else{s=new String(e);s.stdout=e}s.stderr=t;s.code=r;h.forEach(function(e){s[e]=a[e].bind(s)});return s}t.ShellString=ShellString;function parseOptions(e,t,r){if(typeof e!=="string"&&!isObject(e)){throw new Error("options must be strings or key-value pairs")}else if(!isObject(t)){throw new Error("parseOptions() internal error: map must be an object")}else if(r&&!isObject(r)){throw new Error("parseOptions() internal error: errorOptions must be object")}if(e==="--"){return{}}var s={};Object.keys(t).forEach(function(e){var r=t[e];if(r[0]!=="!"){s[r]=false}});if(e==="")return s;if(typeof e==="string"){if(e[0]!=="-"){throw new Error("Options string must start with a '-'")}var n=e.slice(1).split("");n.forEach(function(e){if(e in t){var n=t[e];if(n[0]==="!"){s[n.slice(1)]=false}else{s[n]=true}}else{error("option not recognized: "+e,r||{})}})}else{Object.keys(e).forEach(function(n){var o=n[1];if(o in t){var i=t[o];s[i]=e[n]}else{error("option not recognized: "+o,r||{})}})}return s}t.parseOptions=parseOptions;function expand(e){if(!Array.isArray(e)){throw new TypeError("must be an array")}var t=[];e.forEach(function(e){if(typeof e!=="string"){t.push(e)}else{var r;try{r=o.sync(e,l.globOptions);r=r.length>0?r:[e]}catch(t){r=[e]}t=t.concat(r)}});return t}t.expand=expand;var p=typeof Buffer.alloc==="function"?function(e){return Buffer.alloc(e||l.bufLength)}:function(e){return new Buffer(e||l.bufLength)};t.buffer=p;function unlinkSync(e){try{n.unlinkSync(e)}catch(t){if(t.code==="EPERM"){n.chmodSync(e,"0666");n.unlinkSync(e)}else{throw t}}}t.unlinkSync=unlinkSync;function statFollowLinks(){return n.statSync.apply(n,arguments)}t.statFollowLinks=statFollowLinks;function statNoFollowLinks(){return n.lstatSync.apply(n,arguments)}t.statNoFollowLinks=statNoFollowLinks;function randomFileName(){function randomHash(e){if(e===1){return parseInt(16*Math.random(),10).toString(16)}var t="";for(var r=0;r{var s=r(5747);var n=r(5622);var o=r(3687);o.register("cp",_cp,{cmdOptions:{f:"!no_force",n:"no_force",u:"update",R:"recursive",r:"recursive",L:"followsymlink",P:"noFollowsymlink"},wrapOutput:false});function copyFileSync(e,t,r){if(!s.existsSync(e)){o.error("copyFileSync: no such file or directory: "+e)}var n=process.platform==="win32";try{if(r.update&&o.statFollowLinks(e).mtime=o.config.maxdepth)return;r++;var i=process.platform==="win32";try{s.mkdirSync(t)}catch(e){if(e.code!=="EEXIST")throw e}var a=s.readdirSync(e);for(var c=0;c and/or ")}else{t=[].slice.call(arguments,1,arguments.length-1);r=arguments[arguments.length-1]}var i=s.existsSync(r);var a=i&&o.statFollowLinks(r);if((!i||!a.isDirectory())&&t.length>1){o.error("dest is not a directory (too many sources)")}if(i&&a.isFile()&&e.no_force){return new o.ShellString("","",0)}t.forEach(function(i,c){if(!s.existsSync(i)){if(i==="")i="''";o.error("no such file or directory: "+i,{continue:true});return}var u=o.statFollowLinks(i);if(!e.noFollowsymlink&&u.isDirectory()){if(!e.recursive){o.error("omitting directory '"+i+"'",{continue:true})}else{var l=a&&a.isDirectory()?n.join(r,n.basename(i)):r;try{o.statFollowLinks(n.dirname(r));cpdirSyncRecursive(i,l,0,{no_force:e.no_force,followsymlink:e.followsymlink})}catch(e){o.error("cannot create directory '"+r+"': No such file or directory")}}}else{var f=r;if(a&&a.isDirectory()){f=n.normalize(r+"/"+n.basename(i))}var p=s.existsSync(f);if(p&&checkRecentCreated(t,c)){if(!e.no_force){o.error("will not overwrite just-created '"+f+"' with '"+i+"'",{continue:true})}return}if(p&&e.no_force){return}if(n.relative(i,f)===""){o.error("'"+f+"' and '"+i+"' are the same file",{continue:true});return}copyFileSync(i,f,e)}});return new o.ShellString("",o.state.error,o.state.errorCode)}e.exports=_cp},1178:(e,t,r)=>{var s=r(3687);var n=r(2051);var o=r(5622);s.register("dirs",_dirs,{wrapOutput:false});s.register("pushd",_pushd,{wrapOutput:false});s.register("popd",_popd,{wrapOutput:false});var i=[];function _isStackIndex(e){return/^[\-+]\d+$/.test(e)}function _parseStackIndex(e){if(_isStackIndex(e)){if(Math.abs(e)1){r=r.splice(1,1).concat(r)}else{return s.error("no other directory")}}else if(_isStackIndex(t)){var a=_parseStackIndex(t);r=r.slice(a).concat(r.slice(0,a))}else{if(e["no-cd"]){r.splice(1,0,t)}else{r.unshift(t)}}if(e["no-cd"]){r=r.slice(1)}else{t=o.resolve(r.shift());n("",t)}i=r;return _dirs(e.quiet?"-q":"")}t.pushd=_pushd;function _popd(e,t){if(_isStackIndex(e)){t=e;e=""}e=s.parseOptions(e,{n:"no-cd",q:"quiet"});if(!i.length){return s.error("directory stack empty")}t=_parseStackIndex(t||"+0");if(e["no-cd"]||t>0||i.length+t===0){t=t>0?t-1:t;i.splice(t,1)}else{var r=o.resolve(i.shift());n("",r)}return _dirs(e.quiet?"-q":"")}t.popd=_popd;function _dirs(e,t){if(_isStackIndex(e)){t=e;e=""}e=s.parseOptions(e,{c:"clear",q:"quiet"});if(e.clear){i=[];return i}var r=_actualDirStack();if(t){t=_parseStackIndex(t);if(t<0){t=r.length+t}if(!e.quiet){s.log(r[t])}return r[t]}if(!e.quiet){s.log(r.join(" "))}return r}t.dirs=_dirs},243:(e,t,r)=>{var s=r(1669).format;var n=r(3687);n.register("echo",_echo,{allowGlobbing:false});function _echo(e){var t=[].slice.call(arguments,e?0:1);var r={};try{r=n.parseOptions(t[0],{e:"escapes",n:"no_newline"},{silent:true});if(t[0]){t.shift()}}catch(e){n.state.error=null}var o=s.apply(null,t);if(!r.no_newline){o+="\n"}process.stdout.write(o);return o}e.exports=_echo},232:(e,t,r)=>{var s=r(3687);function error(){return s.state.error}e.exports=error},9607:(e,t,r)=>{e=r.nmd(e);if(require.main!==e){throw new Error("This file should not be required")}var s=r(3129);var n=r(5747);var o=process.argv[2];var i=n.readFileSync(o,"utf8");var a=JSON.parse(i);var c=a.command;var u=a.execOptions;var l=a.pipe;var f=a.stdoutFile;var p=a.stderrFile;var d=s.exec(c,u,function(e){if(!e){process.exitCode=0}else if(e.code===undefined){process.exitCode=1}else{process.exitCode=e.code}});var h=n.createWriteStream(f);var g=n.createWriteStream(p);d.stdout.pipe(h);d.stderr.pipe(g);d.stdout.pipe(process.stdout);d.stderr.pipe(process.stderr);if(l){d.stdin.end(l)}},896:(e,t,r)=>{var s=r(3687);var n=r(6150).tempDir;var o=r(8553);var i=r(5622);var a=r(5747);var c=r(3129);var u=20*1024*1024;var l=1;s.register("exec",_exec,{unix:false,canReceivePipe:true,wrapOutput:false});function execSync(e,t,f){if(!s.config.execPath){s.error("Unable to find a path to the node binary. Please manually set config.execPath")}var p=n();var d=i.resolve(p+"/"+s.randomFileName());var h=i.resolve(p+"/"+s.randomFileName());var g=i.resolve(p+"/"+s.randomFileName());t=s.extend({silent:s.config.silent,cwd:o().toString(),env:process.env,maxBuffer:u,encoding:"utf8"},t);if(a.existsSync(d))s.unlinkSync(d);if(a.existsSync(h))s.unlinkSync(h);if(a.existsSync(g))s.unlinkSync(g);t.cwd=i.resolve(t.cwd);var m={command:e,execOptions:t,pipe:f,stdoutFile:g,stderrFile:h};a.writeFileSync(d,JSON.stringify(m),"utf8");var y=[r.ab+"exec-child.js",d];if(t.silent){t.stdio="ignore"}else{t.stdio=[0,1,2]}var v=0;try{delete t.shell;c.execFileSync(s.config.execPath,y,t)}catch(e){v=e.status||l}var b="";var w="";if(t.encoding==="buffer"){b=a.readFileSync(g);w=a.readFileSync(h)}else{b=a.readFileSync(g,t.encoding);w=a.readFileSync(h,t.encoding)}try{s.unlinkSync(d)}catch(e){}try{s.unlinkSync(h)}catch(e){}try{s.unlinkSync(g)}catch(e){}if(v!==0){s.error(w,v,{continue:true,silent:true})}var E=s.ShellString(b,w,v);return E}function execAsync(e,t,r,n){t=s.extend({silent:s.config.silent,cwd:o().toString(),env:process.env,maxBuffer:u,encoding:"utf8"},t);var i=c.exec(e,t,function(e,t,r){if(n){if(!e){n(0,t,r)}else if(e.code===undefined){n(1,t,r)}else{n(e.code,t,r)}}});if(r)i.stdin.end(r);if(!t.silent){i.stdout.pipe(process.stdout);i.stderr.pipe(process.stderr)}return i}function _exec(e,t,r){t=t||{};if(!e)s.error("must specify command");var n=s.readFromPipe();if(typeof t==="function"){r=t;t={async:true}}if(typeof t==="object"&&typeof r==="function"){t.async=true}t=s.extend({silent:s.config.silent,async:false},t);if(t.async){return execAsync(e,t,n,r)}else{return execSync(e,t,n)}}e.exports=_exec},7838:(e,t,r)=>{var s=r(5622);var n=r(3687);var o=r(5561);n.register("find",_find,{});function _find(e,t){if(!t){n.error("no path specified")}else if(typeof t==="string"){t=[].slice.call(arguments,1)}var r=[];function pushFile(e){if(process.platform==="win32"){e=e.replace(/\\/g,"/")}r.push(e)}t.forEach(function(e){var t;try{t=n.statFollowLinks(e)}catch(t){n.error("no such file or directory: "+e)}pushFile(e);if(t.isDirectory()){o({recursive:true,all:true},e).forEach(function(t){pushFile(s.join(e,t))})}});return r}e.exports=_find},7417:(e,t,r)=>{var s=r(3687);var n=r(5747);s.register("grep",_grep,{globStart:2,canReceivePipe:true,cmdOptions:{v:"inverse",l:"nameOnly",i:"ignoreCase"}});function _grep(e,t,r){var o=s.readFromPipe();if(!r&&!o)s.error("no paths given",2);r=[].slice.call(arguments,2);if(o){r.unshift("-")}var i=[];if(e.ignoreCase){t=new RegExp(t,"i")}r.forEach(function(r){if(!n.existsSync(r)&&r!=="-"){s.error("no such file or directory: "+r,2,{continue:true});return}var a=r==="-"?o:n.readFileSync(r,"utf8");if(e.nameOnly){if(a.match(t)){i.push(r)}}else{var c=a.split("\n");c.forEach(function(r){var s=r.match(t);if(e.inverse&&!s||!e.inverse&&s){i.push(r)}})}});return i.join("\n")+"\n"}e.exports=_grep},6613:(e,t,r)=>{var s=r(3687);var n=r(5747);s.register("head",_head,{canReceivePipe:true,cmdOptions:{n:"numLines"}});function readSomeLines(e,t){var r=s.buffer();var o=r.length;var i=o;var a=0;var c=n.openSync(e,"r");var u=0;var l="";while(i===o&&u{var s=r(5747);var n=r(5622);var o=r(3687);o.register("ln",_ln,{cmdOptions:{s:"symlink",f:"force"}});function _ln(e,t,r){if(!t||!r){o.error("Missing and/or ")}t=String(t);var i=n.normalize(t).replace(RegExp(n.sep+"$"),"");var a=n.resolve(t)===i;r=n.resolve(process.cwd(),String(r));if(s.existsSync(r)){if(!e.force){o.error("Destination file exists",{continue:true})}s.unlinkSync(r)}if(e.symlink){var c=process.platform==="win32";var u=c?"file":null;var l=a?i:n.resolve(process.cwd(),n.dirname(r),t);if(!s.existsSync(l)){o.error("Source file does not exist",{continue:true})}else if(c&&o.statFollowLinks(l).isDirectory()){u="junction"}try{s.symlinkSync(u==="junction"?l:t,r,u)}catch(e){o.error(e.message)}}else{if(!s.existsSync(t)){o.error("Source file does not exist",{continue:true})}try{s.linkSync(t,r)}catch(e){o.error(e.message)}}return""}e.exports=_ln},5561:(e,t,r)=>{var s=r(5622);var n=r(5747);var o=r(3687);var i=r(1957);var a=s.sep+"**";o.register("ls",_ls,{cmdOptions:{R:"recursive",A:"all",L:"link",a:"all_deprecated",d:"directory",l:"long"}});function _ls(e,t){if(e.all_deprecated){o.log("ls: Option -a is deprecated. Use -A instead");e.all=true}if(!t){t=["."]}else{t=[].slice.call(arguments,1)}var r=[];function pushFile(t,s,n){if(process.platform==="win32"){s=s.replace(/\\/g,"/")}if(e.long){n=n||(e.link?o.statFollowLinks(t):o.statNoFollowLinks(t));r.push(addLsAttributes(s,n))}else{r.push(s)}}t.forEach(function(t){var r;try{r=e.link?o.statFollowLinks(t):o.statNoFollowLinks(t);if(r.isSymbolicLink()){try{var c=o.statFollowLinks(t);if(c.isDirectory()){r=c}}catch(e){}}}catch(e){o.error("no such file or directory: "+t,2,{continue:true});return}if(r.isDirectory()&&!e.directory){if(e.recursive){i.sync(t+a,{dot:e.all,follow:e.link}).forEach(function(e){if(s.relative(t,e)){pushFile(e,s.relative(t,e))}})}else if(e.all){n.readdirSync(t).forEach(function(e){pushFile(s.join(t,e),e)})}else{n.readdirSync(t).forEach(function(e){if(e[0]!=="."){pushFile(s.join(t,e),e)}})}}else{pushFile(t,t,r)}});return r}function addLsAttributes(e,t){t.name=e;t.toString=function(){return[this.mode,this.nlink,this.uid,this.gid,this.size,this.mtime,this.name].join(" ")};return t}e.exports=_ls},2695:(e,t,r)=>{var s=r(3687);var n=r(5747);var o=r(5622);s.register("mkdir",_mkdir,{cmdOptions:{p:"fullpath"}});function mkdirSyncRecursive(e){var t=o.dirname(e);if(t===e){s.error("dirname() failed: ["+e+"]")}if(n.existsSync(t)){n.mkdirSync(e,parseInt("0777",8));return}mkdirSyncRecursive(t);n.mkdirSync(e,parseInt("0777",8))}function _mkdir(e,t){if(!t)s.error("no paths given");if(typeof t==="string"){t=[].slice.call(arguments,1)}t.forEach(function(t){try{var r=s.statNoFollowLinks(t);if(!e.fullpath){s.error("path already exists: "+t,{continue:true})}else if(r.isFile()){s.error("cannot create directory "+t+": File exists",{continue:true})}return}catch(e){}var i=o.dirname(t);if(!n.existsSync(i)&&!e.fullpath){s.error("no such file or directory: "+i,{continue:true});return}try{if(e.fullpath){mkdirSyncRecursive(o.resolve(t))}else{n.mkdirSync(t,parseInt("0777",8))}}catch(e){var a;if(e.code==="EACCES"){a="Permission denied"}else if(e.code==="ENOTDIR"||e.code==="ENOENT"){a="Not a directory"}else{throw e}s.error("cannot create directory "+t+": "+a,{continue:true})}});return""}e.exports=_mkdir},9849:(e,t,r)=>{var s=r(5747);var n=r(5622);var o=r(3687);var i=r(4932);var a=r(2830);o.register("mv",_mv,{cmdOptions:{f:"!no_force",n:"no_force"}});function checkRecentCreated(e,t){var r=e[t];return e.slice(0,t).some(function(e){return n.basename(e)===n.basename(r)})}function _mv(e,t,r){if(arguments.length<3){o.error("missing and/or ")}else if(arguments.length>3){t=[].slice.call(arguments,1,arguments.length-1);r=arguments[arguments.length-1]}else if(typeof t==="string"){t=[t]}else{o.error("invalid arguments")}var c=s.existsSync(r);var u=c&&o.statFollowLinks(r);if((!c||!u.isDirectory())&&t.length>1){o.error("dest is not a directory (too many sources)")}if(c&&u.isFile()&&e.no_force){o.error("dest file already exists: "+r)}t.forEach(function(c,u){if(!s.existsSync(c)){o.error("no such file or directory: "+c,{continue:true});return}var l=r;if(s.existsSync(r)&&o.statFollowLinks(r).isDirectory()){l=n.normalize(r+"/"+n.basename(c))}var f=s.existsSync(l);if(f&&checkRecentCreated(t,u)){if(!e.no_force){o.error("will not overwrite just-created '"+l+"' with '"+c+"'",{continue:true})}return}if(s.existsSync(l)&&e.no_force){o.error("dest file already exists: "+l,{continue:true});return}if(n.resolve(c)===n.dirname(n.resolve(l))){o.error("cannot move to self: "+c,{continue:true});return}try{s.renameSync(c,l)}catch(e){if(e.code==="EXDEV"){i("-r",c,l);a("-rf",c)}}});return""}e.exports=_mv},227:()=>{},4177:()=>{},8553:(e,t,r)=>{var s=r(5622);var n=r(3687);n.register("pwd",_pwd,{allowGlobbing:false});function _pwd(){var e=s.resolve(process.cwd());return e}e.exports=_pwd},2830:(e,t,r)=>{var s=r(3687);var n=r(5747);s.register("rm",_rm,{cmdOptions:{f:"force",r:"recursive",R:"recursive"}});function rmdirSyncRecursive(e,t,r){var o;o=n.readdirSync(e);for(var i=0;i1e3)throw e}else if(e.code==="ENOENT"){break}else{throw e}}}}catch(t){s.error("could not remove directory (code "+t.code+"): "+e,{continue:true})}return u}function isWriteable(e){var t=true;try{var r=n.openSync(e,"a");n.closeSync(r)}catch(e){t=false}return t}function handleFile(e,t){if(t.force||isWriteable(e)){s.unlinkSync(e)}else{s.error("permission denied: "+e,{continue:true})}}function handleDirectory(e,t){if(t.recursive){rmdirSyncRecursive(e,t.force)}else{s.error("path is a directory",{continue:true})}}function handleSymbolicLink(e,t){var r;try{r=s.statFollowLinks(e)}catch(t){s.unlinkSync(e);return}if(r.isFile()){s.unlinkSync(e)}else if(r.isDirectory()){if(e[e.length-1]==="/"){if(t.recursive){var n=true;rmdirSyncRecursive(e,t.force,n)}else{s.error("path is a directory",{continue:true})}}else{s.unlinkSync(e)}}}function handleFIFO(e){s.unlinkSync(e)}function _rm(e,t){if(!t)s.error("no paths given");t=[].slice.call(arguments,1);t.forEach(function(t){var r;try{var n=t[t.length-1]==="/"?t.slice(0,-1):t;r=s.statNoFollowLinks(n)}catch(r){if(!e.force){s.error("no such file or directory: "+t,{continue:true})}return}if(r.isFile()){handleFile(t,e)}else if(r.isDirectory()){handleDirectory(t,e)}else if(r.isSymbolicLink()){handleSymbolicLink(t,e)}else if(r.isFIFO()){handleFIFO(t)}});return""}e.exports=_rm},5899:(e,t,r)=>{var s=r(3687);var n=r(5747);s.register("sed",_sed,{globStart:3,canReceivePipe:true,cmdOptions:{i:"inplace"}});function _sed(e,t,r,o){var i=s.readFromPipe();if(typeof r!=="string"&&typeof r!=="function"){if(typeof r==="number"){r=r.toString()}else{s.error("invalid replacement string")}}if(typeof t==="string"){t=RegExp(t)}if(!o&&!i){s.error("no files given")}o=[].slice.call(arguments,3);if(i){o.unshift("-")}var a=[];o.forEach(function(o){if(!n.existsSync(o)&&o!=="-"){s.error("no such file or directory: "+o,2,{continue:true});return}var c=o==="-"?i:n.readFileSync(o,"utf8");var u=c.split("\n");var l=u.map(function(e){return e.replace(t,r)}).join("\n");a.push(l);if(e.inplace){n.writeFileSync(o,l,"utf8")}});return a.join("\n")}e.exports=_sed},1411:(e,t,r)=>{var s=r(3687);s.register("set",_set,{allowGlobbing:false,wrapOutput:false});function _set(e){if(!e){var t=[].slice.call(arguments,0);if(t.length<2)s.error("must provide an argument");e=t[1]}var r=e[0]==="+";if(r){e="-"+e.slice(1)}e=s.parseOptions(e,{e:"fatal",v:"verbose",f:"noglob"});if(r){Object.keys(e).forEach(function(t){e[t]=!e[t]})}Object.keys(e).forEach(function(t){if(r!==e[t]){s.config[t]=e[t]}});return}e.exports=_set},2116:(e,t,r)=>{var s=r(3687);var n=r(5747);s.register("sort",_sort,{canReceivePipe:true,cmdOptions:{r:"reverse",n:"numerical"}});function parseNumber(e){var t=e.match(/^\s*(\d*)\s*(.*)$/);return{num:Number(t[1]),value:t[2]}}function unixCmp(e,t){var r=e.toLowerCase();var s=t.toLowerCase();return r===s?-1*e.localeCompare(t):r.localeCompare(s)}function numericalCmp(e,t){var r=parseNumber(e);var s=parseNumber(t);if(r.hasOwnProperty("num")&&s.hasOwnProperty("num")){return r.num!==s.num?r.num-s.num:unixCmp(r.value,s.value)}else{return unixCmp(r.value,s.value)}}function _sort(e,t){var r=s.readFromPipe();if(!t&&!r)s.error("no files given");t=[].slice.call(arguments,1);if(r){t.unshift("-")}var o=t.reduce(function(e,t){if(t!=="-"){if(!n.existsSync(t)){s.error("no such file or directory: "+t,{continue:true});return e}else if(s.statFollowLinks(t).isDirectory()){s.error("read failed: "+t+": Is a directory",{continue:true});return e}}var o=t==="-"?r:n.readFileSync(t,"utf8");return e.concat(o.trimRight().split("\n"))},[]);var i=o.sort(e.numerical?numericalCmp:unixCmp);if(e.reverse){i=i.reverse()}return i.join("\n")+"\n"}e.exports=_sort},2284:(e,t,r)=>{var s=r(3687);var n=r(5747);s.register("tail",_tail,{canReceivePipe:true,cmdOptions:{n:"numLines"}});function _tail(e,t){var r=[];var o=s.readFromPipe();if(!t&&!o)s.error("no paths given");var i=1;if(e.numLines===true){i=2;e.numLines=Number(arguments[1])}else if(e.numLines===false){e.numLines=10}e.numLines=-1*Math.abs(e.numLines);t=[].slice.call(arguments,i);if(o){t.unshift("-")}var a=false;t.forEach(function(t){if(t!=="-"){if(!n.existsSync(t)){s.error("no such file or directory: "+t,{continue:true});return}else if(s.statFollowLinks(t).isDirectory()){s.error("error reading '"+t+"': Is a directory",{continue:true});return}}var i=t==="-"?o:n.readFileSync(t,"utf8");var c=i.split("\n");if(c[c.length-1]===""){c.pop();a=true}else{a=false}r=r.concat(c.slice(e.numLines))});if(a){r.push("")}return r.join("\n")}e.exports=_tail},6150:(e,t,r)=>{var s=r(3687);var n=r(2087);var o=r(5747);s.register("tempdir",_tempDir,{allowGlobbing:false,wrapOutput:false});function writeableDir(e){if(!e||!o.existsSync(e))return false;if(!s.statFollowLinks(e).isDirectory())return false;var t=e+"/"+s.randomFileName();try{o.writeFileSync(t," ");s.unlinkSync(t);return e}catch(e){return false}}var i;function _tempDir(){if(i)return i;i=writeableDir(n.tmpdir())||writeableDir(process.env.TMPDIR)||writeableDir(process.env.TEMP)||writeableDir(process.env.TMP)||writeableDir(process.env.Wimp$ScrapDir)||writeableDir("C:\\TEMP")||writeableDir("C:\\TMP")||writeableDir("\\TEMP")||writeableDir("\\TMP")||writeableDir("/tmp")||writeableDir("/var/tmp")||writeableDir("/usr/tmp")||writeableDir(".");return i}function isCached(){return i}function clearCache(){i=undefined}e.exports.tempDir=_tempDir;e.exports.isCached=isCached;e.exports.clearCache=clearCache},9723:(e,t,r)=>{var s=r(3687);var n=r(5747);s.register("test",_test,{cmdOptions:{b:"block",c:"character",d:"directory",e:"exists",f:"file",L:"link",p:"pipe",S:"socket"},wrapOutput:false,allowGlobbing:false});function _test(e,t){if(!t)s.error("no path given");var r=false;Object.keys(e).forEach(function(t){if(e[t]===true){r=true}});if(!r)s.error("could not interpret expression");if(e.link){try{return s.statNoFollowLinks(t).isSymbolicLink()}catch(e){return false}}if(!n.existsSync(t))return false;if(e.exists)return true;var o=s.statFollowLinks(t);if(e.block)return o.isBlockDevice();if(e.character)return o.isCharacterDevice();if(e.directory)return o.isDirectory();if(e.file)return o.isFile();if(e.pipe)return o.isFIFO();if(e.socket)return o.isSocket();return false}e.exports=_test},1961:(e,t,r)=>{var s=r(3687);var n=r(5747);var o=r(5622);s.register("to",_to,{pipeOnly:true,wrapOutput:false});function _to(e,t){if(!t)s.error("wrong arguments");if(!n.existsSync(o.dirname(t))){s.error("no such file or directory: "+o.dirname(t))}try{n.writeFileSync(t,this.stdout||this.toString(),"utf8");return this}catch(e){s.error("could not write to file (code "+e.code+"): "+t,{continue:true})}}e.exports=_to},3736:(e,t,r)=>{var s=r(3687);var n=r(5747);var o=r(5622);s.register("toEnd",_toEnd,{pipeOnly:true,wrapOutput:false});function _toEnd(e,t){if(!t)s.error("wrong arguments");if(!n.existsSync(o.dirname(t))){s.error("no such file or directory: "+o.dirname(t))}try{n.appendFileSync(t,this.stdout||this.toString(),"utf8");return this}catch(e){s.error("could not append to file (code "+e.code+"): "+t,{continue:true})}}e.exports=_toEnd},8358:(e,t,r)=>{var s=r(3687);var n=r(5747);s.register("touch",_touch,{cmdOptions:{a:"atime_only",c:"no_create",d:"date",m:"mtime_only",r:"reference"}});function _touch(e,t){if(!t){s.error("no files given")}else if(typeof t==="string"){t=[].slice.call(arguments,1)}else{s.error("file arg should be a string file path or an Array of string file paths")}t.forEach(function(t){touchFile(e,t)});return""}function touchFile(e,t){var r=tryStatFile(t);if(r&&r.isDirectory()){return}if(!r&&e.no_create){return}n.closeSync(n.openSync(t,"a"));var o=new Date;var i=e.date||o;var a=e.date||o;if(e.reference){var c=tryStatFile(e.reference);if(!c){s.error("failed to get attributess of "+e.reference)}i=c.mtime;a=c.atime}else if(e.date){i=e.date;a=e.date}if(e.atime_only&&e.mtime_only){}else if(e.atime_only){i=r.mtime}else if(e.mtime_only){a=r.atime}n.utimesSync(t,a,i)}e.exports=_touch;function tryStatFile(e){try{return s.statFollowLinks(e)}catch(e){return null}}},7286:(e,t,r)=>{var s=r(3687);var n=r(5747);function lpad(e,t){var r=""+t;if(r.length1:true}).map(function(t){return(e.count?lpad(7,t.count)+" ":"")+t.ln}).join("\n")+"\n";if(r){new s.ShellString(c).to(r);return""}else{return c}}e.exports=_uniq},4766:(e,t,r)=>{var s=r(3687);var n=r(5747);var o=r(5622);s.register("which",_which,{allowGlobbing:false,cmdOptions:{a:"all"}});var i=".com;.exe;.bat;.cmd;.vbs;.vbe;.js;.jse;.wsf;.wsh";var a=1;function isWindowsPlatform(){return process.platform==="win32"}function splitPath(e){return e?e.split(o.delimiter):[]}function isExecutable(e){try{n.accessSync(e,a)}catch(e){return false}return true}function checkPath(e){return n.existsSync(e)&&!s.statFollowLinks(e).isDirectory()&&(isWindowsPlatform()||isExecutable(e))}function _which(e,t){if(!t)s.error("must specify command");var r=isWindowsPlatform();var n=splitPath(process.env.PATH);var a=[];if(t.indexOf("/")===-1){var c=[""];if(r){var u=process.env.PATHEXT||i;c=splitPath(u.toUpperCase())}for(var l=0;l0&&!e.all)break;var f=o.resolve(n[l],t);if(r){f=f.toUpperCase()}var p=f.match(/\.[^<>:"/\|?*.]+$/);if(p&&c.indexOf(p[0])>=0){if(checkPath(f)){a.push(f);break}}else{for(var d=0;d0){return e.all?a:a[0]}return e.all?[]:null}e.exports=_which},4294:(e,t,r)=>{e.exports=r(4219)},4219:(e,t,r)=>{"use strict";var s=r(1631);var n=r(4016);var o=r(8605);var i=r(7211);var a=r(8614);var c=r(2357);var u=r(1669);t.httpOverHttp=httpOverHttp;t.httpsOverHttp=httpsOverHttp;t.httpOverHttps=httpOverHttps;t.httpsOverHttps=httpsOverHttps;function httpOverHttp(e){var t=new TunnelingAgent(e);t.request=o.request;return t}function httpsOverHttp(e){var t=new TunnelingAgent(e);t.request=o.request;t.createSocket=createSecureSocket;t.defaultPort=443;return t}function httpOverHttps(e){var t=new TunnelingAgent(e);t.request=i.request;return t}function httpsOverHttps(e){var t=new TunnelingAgent(e);t.request=i.request;t.createSocket=createSecureSocket;t.defaultPort=443;return t}function TunnelingAgent(e){var t=this;t.options=e||{};t.proxyOptions=t.options.proxy||{};t.maxSockets=t.options.maxSockets||o.Agent.defaultMaxSockets;t.requests=[];t.sockets=[];t.on("free",function onFree(e,r,s,n){var o=toOptions(r,s,n);for(var i=0,a=t.requests.length;i=this.maxSockets){n.requests.push(o);return}n.createSocket(o,function(t){t.on("free",onFree);t.on("close",onCloseOrRemove);t.on("agentRemove",onCloseOrRemove);e.onSocket(t);function onFree(){n.emit("free",t,o)}function onCloseOrRemove(e){n.removeSocket(t);t.removeListener("free",onFree);t.removeListener("close",onCloseOrRemove);t.removeListener("agentRemove",onCloseOrRemove)}})};TunnelingAgent.prototype.createSocket=function createSocket(e,t){var r=this;var s={};r.sockets.push(s);var n=mergeOptions({},r.proxyOptions,{method:"CONNECT",path:e.host+":"+e.port,agent:false,headers:{host:e.host+":"+e.port}});if(e.localAddress){n.localAddress=e.localAddress}if(n.proxyAuth){n.headers=n.headers||{};n.headers["Proxy-Authorization"]="Basic "+new Buffer(n.proxyAuth).toString("base64")}l("making CONNECT request");var o=r.request(n);o.useChunkedEncodingByDefault=false;o.once("response",onResponse);o.once("upgrade",onUpgrade);o.once("connect",onConnect);o.once("error",onError);o.end();function onResponse(e){e.upgrade=true}function onUpgrade(e,t,r){process.nextTick(function(){onConnect(e,t,r)})}function onConnect(n,i,a){o.removeAllListeners();i.removeAllListeners();if(n.statusCode!==200){l("tunneling socket could not be established, statusCode=%d",n.statusCode);i.destroy();var c=new Error("tunneling socket could not be established, "+"statusCode="+n.statusCode);c.code="ECONNRESET";e.request.emit("error",c);r.removeSocket(s);return}if(a.length>0){l("got illegal response body from proxy");i.destroy();var c=new Error("got illegal response body from proxy");c.code="ECONNRESET";e.request.emit("error",c);r.removeSocket(s);return}l("tunneling connection has established");r.sockets[r.sockets.indexOf(s)]=i;return t(i)}function onError(t){o.removeAllListeners();l("tunneling socket could not be established, cause=%s\n",t.message,t.stack);var n=new Error("tunneling socket could not be established, "+"cause="+t.message);n.code="ECONNRESET";e.request.emit("error",n);r.removeSocket(s)}};TunnelingAgent.prototype.removeSocket=function removeSocket(e){var t=this.sockets.indexOf(e);if(t===-1){return}this.sockets.splice(t,1);var r=this.requests.shift();if(r){this.createSocket(r,function(e){r.request.onSocket(e)})}};function createSecureSocket(e,t){var r=this;TunnelingAgent.prototype.createSocket.call(r,e,function(s){var o=e.request.getHeader("host");var i=mergeOptions({},r.options,{socket:s,servername:o?o.replace(/:.*$/,""):e.host});var a=n.connect(0,i);r.sockets[r.sockets.indexOf(s)]=a;t(a)})}function toOptions(e,t,r){if(typeof e==="string"){return{host:e,port:t,localAddress:r}}return e}function mergeOptions(e){for(var t=1,r=arguments.length;t{"use strict";Object.defineProperty(t,"__esModule",{value:true});function getUserAgent(){if(typeof navigator==="object"&&"userAgent"in navigator){return navigator.userAgent}if(typeof process==="object"&&"version"in process){return`Node.js/${process.version.substr(1)} (${process.platform}; ${process.arch})`}return""}t.getUserAgent=getUserAgent},2940:e=>{e.exports=wrappy;function wrappy(e,t){if(e&&t)return wrappy(e)(t);if(typeof e!=="function")throw new TypeError("need wrapper function");Object.keys(e).forEach(function(t){wrapper[t]=e[t]});return wrapper;function wrapper(){var t=new Array(arguments.length);for(var r=0;r{const t=[];for(const s of r){t.push(l.default.join(e,s))}return t})();const n=await u.create(s.join("\n"));const o=await n.glob();for await(const e of n.globGenerator()){a.info(`[INFO] delete ${e}`)}h.rm("-rf",o);return}t.deleteExcludedAssets=deleteExcludedAssets;async function copyAssets(e,t,r){a.info(`[INFO] prepare publishing assets`);if(!f.default.existsSync(t)){a.info(`[INFO] create ${t}`);await d.createDir(t)}const s=l.default.join(e,".git");if(f.default.existsSync(s)){a.info(`[INFO] delete ${s}`);h.rm("-rf",s)}a.info(`[INFO] copy ${e} to ${t}`);h.cp("-RfL",[`${e}/*`,`${e}/.*`],t);await deleteExcludedAssets(t,r);return}t.copyAssets=copyAssets;async function setRepo(e,t,r){const s=l.default.isAbsolute(e.PublishDir)?e.PublishDir:l.default.join(`${process.env.GITHUB_WORKSPACE}`,e.PublishDir);if(l.default.isAbsolute(e.DestinationDir)){throw new Error("destination_dir should be a relative path")}const n=(()=>{if(e.DestinationDir===""){return r}else{return l.default.join(r,e.DestinationDir)}})();a.info(`[INFO] ForceOrphan: ${e.ForceOrphan}`);if(e.ForceOrphan){await d.createDir(n);a.info(`[INFO] chdir ${r}`);process.chdir(r);await createBranchForce(e.PublishBranch);await copyAssets(s,n,e.ExcludeAssets);return}const o={exitcode:0,output:""};const i={listeners:{stdout:e=>{o.output+=e.toString()}}};try{o.exitcode=await c.exec("git",["clone","--depth=1","--single-branch","--branch",e.PublishBranch,t,r],i);if(o.exitcode===0){await d.createDir(n);if(e.KeepFiles){a.info("[INFO] Keep existing files")}else{a.info(`[INFO] clean up ${n}`);a.info(`[INFO] chdir ${n}`);process.chdir(n);await c.exec("git",["rm","-r","--ignore-unmatch","*"])}a.info(`[INFO] chdir ${r}`);process.chdir(r);await copyAssets(s,n,e.ExcludeAssets);return}else{throw new Error(`Failed to clone remote branch ${e.PublishBranch}`)}}catch(t){a.info(`[INFO] first deployment, create new branch ${e.PublishBranch}`);a.info(`[INFO] ${t.message}`);await d.createDir(n);a.info(`[INFO] chdir ${r}`);process.chdir(r);await createBranchForce(e.PublishBranch);await copyAssets(s,n,e.ExcludeAssets);return}}t.setRepo=setRepo;function getUserName(e){if(e){return e}else{return`${process.env.GITHUB_ACTOR}`}}t.getUserName=getUserName;function getUserEmail(e){if(e){return e}else{return`${process.env.GITHUB_ACTOR}@users.noreply.github.com`}}t.getUserEmail=getUserEmail;async function setCommitAuthor(e,t){if(e&&!t){throw new Error("user_email is undefined")}if(!e&&t){throw new Error("user_name is undefined")}await c.exec("git",["config","user.name",getUserName(e)]);await c.exec("git",["config","user.email",getUserEmail(t)])}t.setCommitAuthor=setCommitAuthor;function getCommitMessage(e,t,r,s,n){const o=(()=>{if(r){return`${s}@${n}`}else{return n}})();const i=(()=>{if(t){return t}else if(e){return`${e} ${o}`}else{return`deploy: ${o}`}})();return i}t.getCommitMessage=getCommitMessage;async function commit(e,t){try{if(e){await c.exec("git",["commit","--allow-empty","-m",`${t}`])}else{await c.exec("git",["commit","-m",`${t}`])}}catch(e){a.info("[INFO] skip commit");a.debug(`[INFO] skip commit ${e.message}`)}}t.commit=commit;async function push(e,t){if(t){await c.exec("git",["push","origin","--force",e])}else{await c.exec("git",["push","origin",e])}}t.push=push;async function pushTag(e,t){if(e===""){return}let r="";if(t){r=t}else{r=`Deployment ${e}`}await c.exec("git",["tag","-a",`${e}`,"-m",`${r}`]);await c.exec("git",["push","origin",`${e}`])}t.pushTag=pushTag},6144:function(e,t,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,t,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,s){if(s===undefined)s=r;e[s]=t[r]});var n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.prototype.hasOwnProperty.call(e,r))s(t,e,r);n(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});const i=o(r(2186));const a=o(r(399));(async()=>{try{await a.run()}catch(e){i.setFailed(`Action failed with "${e.message}"`)}})()},399:function(e,t,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,t,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,s){if(s===undefined)s=r;e[s]=t[r]});var n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.prototype.hasOwnProperty.call(e,r))s(t,e,r);n(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.run=void 0;const i=r(5438);const a=o(r(2186));const c=o(r(1514));const u=o(r(5438));const l=r(6450);const f=r(9516);const p=r(7213);const d=r(1314);async function run(){try{a.info("[INFO] Usage https://github.com/peaceiris/actions-gh-pages#readme");const e=l.getInputs();a.startGroup("Dump inputs");l.showInputs(e);a.endGroup();if(a.isDebug()){a.startGroup("Debug: dump context");console.log(i.context);a.endGroup()}const t=i.context.eventName;if(t==="pull_request"||t==="push"){const t=i.context.payload.repository.fork;const r=await d.skipOnFork(t,e.GithubToken,e.DeployKey,e.PersonalToken);if(r){a.warning("This action runs on a fork and not found auth token, Skip deployment");a.setOutput("skip","true");return}}a.startGroup("Setup auth token");const r=await f.setTokens(e);a.debug(`remoteURL: ${r}`);a.endGroup();a.startGroup("Prepare publishing assets");const s=new Date;const n=s.getTime();const o=await d.getWorkDirName(`${n}`);await p.setRepo(e,r,o);await d.addNoJekyll(o,e.DisableNoJekyll);await d.addCNAME(o,e.CNAME);a.endGroup();a.startGroup("Setup Git config");try{await c.exec("git",["remote","rm","origin"])}catch(e){a.info(`[INFO] ${e.message}`)}await c.exec("git",["remote","add","origin",r]);await c.exec("git",["add","--all"]);await p.setCommitAuthor(e.UserName,e.UserEmail);a.endGroup();a.startGroup("Create a commit");const h=`${process.env.GITHUB_SHA}`;const g=`${u.context.repo.owner}/${u.context.repo.repo}`;const m=p.getCommitMessage(e.CommitMessage,e.FullCommitMessage,e.ExternalRepository,g,h);await p.commit(e.AllowEmptyCommit,m);a.endGroup();a.startGroup("Push the commit or tag");await p.push(e.PublishBranch,e.ForceOrphan);await p.pushTag(e.TagName,e.TagMessage);a.endGroup();a.info("[INFO] Action successfully completed");return}catch(e){throw new Error(e.message)}}t.run=run},9516:function(e,t,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,t,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,s){if(s===undefined)s=r;e[s]=t[r]});var n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.prototype.hasOwnProperty.call(e,r))s(t,e,r);n(t,e);return t};var i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:true});t.setTokens=t.getPublishRepo=t.setPersonalToken=t.setGithubToken=t.setSSHKey=void 0;const a=o(r(2186));const c=o(r(1514));const u=o(r(5438));const l=o(r(7436));const f=i(r(5622));const p=i(r(5747));const d=r(3129).spawnSync;const h=r(3129).execFileSync;const g=r(1314);const m=r(7213);async function setSSHKey(e,t){a.info("[INFO] setup SSH deploy key");const r=await g.getHomeDir();const s=f.default.join(r,".ssh");await l.mkdirP(s);await c.exec("chmod",["700",s]);const n=f.default.join(s,"known_hosts");const o=`# ${m.getServerUrl().host}.com:22 SSH-2.0-babeld-1f0633a6\n${m.getServerUrl().host} ssh-rsa AAAAB3NzaC1yc2EAAAABIwAAAQEAq2A7hRGmdnm9tUDbO9IDSwBK6TbQa+PXYPCPy6rbTrTtw7PHkccKrpp0yVhp5HdEIcKr6pLlVDBfOLX9QUsyCOV0wzfjIJNlGEYsdlLJizHhbn2mUjvSAHQqZETYP81eFzLQNnPHt4EVVUh7VfDESU84KezmD5QlWpXLmvU31/yMf+Se8xhHTvKSCZIFImWwoG6mbUoWf9nzpIoaSjB+weqqUUmpaaasXVal72J+UX2B+2RPW3RcT0eOzQgqlJL3RKrTJvdsjE3JEAvGq3lGHSZXy28G3skua2SmVi/w4yCE6gbODqnTWlg7+wC604ydGXA8VJiS5ap43JXiUFFAaQ==\n`;p.default.writeFileSync(n,o+"\n");a.info(`[INFO] wrote ${n}`);await c.exec("chmod",["600",n]);const i=f.default.join(s,"github");p.default.writeFileSync(i,e.DeployKey+"\n");a.info(`[INFO] wrote ${i}`);await c.exec("chmod",["600",i]);const u=f.default.join(s,"config");const y=`Host ${m.getServerUrl().host}\n HostName ${m.getServerUrl().host}\n IdentityFile ~/.ssh/github\n User git\n`;p.default.writeFileSync(u,y+"\n");a.info(`[INFO] wrote ${u}`);await c.exec("chmod",["600",u]);if(process.platform==="win32"){a.warning(`Currently, the deploy_key option is not supported on the windows-latest.\nWatch https://github.com/peaceiris/actions-gh-pages/issues/87\n`);await d("Start-Process",["powershell.exe","-Verb","runas"]);await d("sh",["-c","'eval \"$(ssh-agent)\"'"],{shell:true});await c.exec("sc",["config","ssh-agent","start=auto"]);await c.exec("sc",["start","ssh-agent"])}await h("ssh-agent",["-a","/tmp/ssh-auth.sock"]);a.exportVariable("SSH_AUTH_SOCK","/tmp/ssh-auth.sock");await c.exec("ssh-add",[i]);return`git@${m.getServerUrl().host}:${t}.git`}t.setSSHKey=setSSHKey;function setGithubToken(e,t,r,s,n,o){a.info("[INFO] setup GITHUB_TOKEN");a.debug(`ref: ${n}`);a.debug(`eventName: ${o}`);let i=false;if(s){throw new Error(`The generated GITHUB_TOKEN (github_token) does not support to push to an external repository.\nUse deploy_key or personal_token.\n`)}if(o==="push"){i=n.match(new RegExp(`^refs/heads/${r}$`))!==null;if(i){throw new Error(`You deploy from ${r} to ${r}\nThis operation is prohibited to protect your contents\n`)}}return`https://x-access-token:${e}@${m.getServerUrl().host}/${t}.git`}t.setGithubToken=setGithubToken;function setPersonalToken(e,t){a.info("[INFO] setup personal access token");return`https://x-access-token:${e}@${m.getServerUrl().host}/${t}.git`}t.setPersonalToken=setPersonalToken;function getPublishRepo(e,t,r){if(e){return e}return`${t}/${r}`}t.getPublishRepo=getPublishRepo;async function setTokens(e){try{const t=getPublishRepo(e.ExternalRepository,u.context.repo.owner,u.context.repo.repo);if(e.DeployKey){return setSSHKey(e,t)}else if(e.PersonalToken){return setPersonalToken(e.PersonalToken,t)}else if(e.GithubToken){const r=u.context;const s=r.ref;const n=r.eventName;return setGithubToken(e.GithubToken,t,e.PublishBranch,e.ExternalRepository,s,n)}else{throw new Error("not found deploy key or tokens")}}catch(e){throw new Error(e.message)}}t.setTokens=setTokens},1314:function(e,t,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,t,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,s){if(s===undefined)s=r;e[s]=t[r]});var n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.prototype.hasOwnProperty.call(e,r))s(t,e,r);n(t,e);return t};var i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:true});t.skipOnFork=t.addCNAME=t.addNoJekyll=t.createDir=t.getWorkDirName=t.getHomeDir=void 0;const a=o(r(2186));const c=o(r(7436));const u=i(r(5622));const l=i(r(5747));async function getHomeDir(){let e="";if(process.platform==="win32"){e=process.env["USERPROFILE"]||"C:\\"}else{e=`${process.env.HOME}`}a.debug(`homeDir: ${e}`);return e}t.getHomeDir=getHomeDir;async function getWorkDirName(e){const t=await getHomeDir();const r=u.default.join(t,`actions_github_pages_${e}`);return r}t.getWorkDirName=getWorkDirName;async function createDir(e){await c.mkdirP(e);a.debug(`Created directory ${e}`);return}t.createDir=createDir;async function addNoJekyll(e,t){if(t){return}const r=u.default.join(e,".nojekyll");if(l.default.existsSync(r)){return}l.default.closeSync(l.default.openSync(r,"w"));a.info(`[INFO] Created ${r}`)}t.addNoJekyll=addNoJekyll;async function addCNAME(e,t){if(t===""){return}const r=u.default.join(e,"CNAME");if(l.default.existsSync(r)){a.info(`CNAME already exists, skip adding CNAME`);return}l.default.writeFileSync(r,t+"\n");a.info(`[INFO] Created ${r}`)}t.addCNAME=addCNAME;async function skipOnFork(e,t,r,s){if(e){if(t===""&&r===""&&s===""){return true}}return false}t.skipOnFork=skipOnFork},2877:module=>{module.exports=eval("require")("encoding")},2357:e=>{"use strict";e.exports=require("assert")},3129:e=>{"use strict";e.exports=require("child_process")},6417:e=>{"use strict";e.exports=require("crypto")},8614:e=>{"use strict";e.exports=require("events")},5747:e=>{"use strict";e.exports=require("fs")},8605:e=>{"use strict";e.exports=require("http")},7211:e=>{"use strict";e.exports=require("https")},1631:e=>{"use strict";e.exports=require("net")},2087:e=>{"use strict";e.exports=require("os")},5622:e=>{"use strict";e.exports=require("path")},2413:e=>{"use strict";e.exports=require("stream")},4304:e=>{"use strict";e.exports=require("string_decoder")},8213:e=>{"use strict";e.exports=require("timers")},4016:e=>{"use strict";e.exports=require("tls")},8835:e=>{"use strict";e.exports=require("url")},1669:e=>{"use strict";e.exports=require("util")},8761:e=>{"use strict";e.exports=require("zlib")}};var __webpack_module_cache__={};function __nccwpck_require__(e){if(__webpack_module_cache__[e]){return __webpack_module_cache__[e].exports}var t=__webpack_module_cache__[e]={id:e,loaded:false,exports:{}};var r=true;try{__webpack_modules__[e].call(t.exports,t,t.exports,__nccwpck_require__);r=false}finally{if(r)delete __webpack_module_cache__[e]}t.loaded=true;return t.exports}(()=>{__nccwpck_require__.nmd=(e=>{e.paths=[];if(!e.children)e.children=[];return e})})();__nccwpck_require__.ab=__dirname+"/";return __nccwpck_require__(6144)})(); \ No newline at end of file From 4509111cb46164498206268992ad6b0a2d816005 Mon Sep 17 00:00:00 2001 From: peaceiris <30958501+peaceiris@users.noreply.github.com> Date: Thu, 9 Sep 2021 23:59:12 +0900 Subject: [PATCH 7/7] delete pre-release --- lib/exec-child.js | 1 - lib/index.js | 1 - 2 files changed, 2 deletions(-) delete mode 100644 lib/exec-child.js delete mode 100644 lib/index.js diff --git a/lib/exec-child.js b/lib/exec-child.js deleted file mode 100644 index b8598bd92..000000000 --- a/lib/exec-child.js +++ /dev/null @@ -1 +0,0 @@ -module.exports=(()=>{var e={607:(e,r,t)=>{e=t.nmd(e);if(require.main!==e){throw new Error("This file should not be required")}var i=t(129);var s=t(747);var a=process.argv[2];var d=s.readFileSync(a,"utf8");var o=JSON.parse(d);var p=o.command;var _=o.execOptions;var c=o.pipe;var u=o.stdoutFile;var n=o.stderrFile;var l=i.exec(p,_,function(e){if(!e){process.exitCode=0}else if(e.code===undefined){process.exitCode=1}else{process.exitCode=e.code}});var v=s.createWriteStream(u);var f=s.createWriteStream(n);l.stdout.pipe(v);l.stderr.pipe(f);l.stdout.pipe(process.stdout);l.stderr.pipe(process.stderr);if(c){l.stdin.end(c)}},129:e=>{"use strict";e.exports=require("child_process")},747:e=>{"use strict";e.exports=require("fs")}};var r={};function __nccwpck_require__(t){if(r[t]){return r[t].exports}var i=r[t]={id:t,loaded:false,exports:{}};var s=true;try{e[t](i,i.exports,__nccwpck_require__);s=false}finally{if(s)delete r[t]}i.loaded=true;return i.exports}(()=>{__nccwpck_require__.nmd=(e=>{e.paths=[];if(!e.children)e.children=[];return e})})();__nccwpck_require__.ab=__dirname+"/";return __nccwpck_require__(607)})(); \ No newline at end of file diff --git a/lib/index.js b/lib/index.js deleted file mode 100644 index beb6c4b17..000000000 --- a/lib/index.js +++ /dev/null @@ -1 +0,0 @@ -module.exports=(()=>{var __webpack_modules__={7351:function(e,t,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,t,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,s){if(s===undefined)s=r;e[s]=t[r]});var n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))s(t,e,r);n(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.issue=t.issueCommand=void 0;const i=o(r(2087));const a=r(5278);function issueCommand(e,t,r){const s=new Command(e,t,r);process.stdout.write(s.toString()+i.EOL)}t.issueCommand=issueCommand;function issue(e,t=""){issueCommand(e,{},t)}t.issue=issue;const c="::";class Command{constructor(e,t,r){if(!e){e="missing.command"}this.command=e;this.properties=t;this.message=r}toString(){let e=c+this.command;if(this.properties&&Object.keys(this.properties).length>0){e+=" ";let t=true;for(const r in this.properties){if(this.properties.hasOwnProperty(r)){const s=this.properties[r];if(s){if(t){t=false}else{e+=","}e+=`${r}=${escapeProperty(s)}`}}}}e+=`${c}${escapeData(this.message)}`;return e}}function escapeData(e){return a.toCommandValue(e).replace(/%/g,"%25").replace(/\r/g,"%0D").replace(/\n/g,"%0A")}function escapeProperty(e){return a.toCommandValue(e).replace(/%/g,"%25").replace(/\r/g,"%0D").replace(/\n/g,"%0A").replace(/:/g,"%3A").replace(/,/g,"%2C")}},2186:function(e,t,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,t,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,s){if(s===undefined)s=r;e[s]=t[r]});var n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))s(t,e,r);n(t,e);return t};var i=this&&this.__awaiter||function(e,t,r,s){function adopt(e){return e instanceof r?e:new r(function(t){t(e)})}return new(r||(r=Promise))(function(r,n){function fulfilled(e){try{step(s.next(e))}catch(e){n(e)}}function rejected(e){try{step(s["throw"](e))}catch(e){n(e)}}function step(e){e.done?r(e.value):adopt(e.value).then(fulfilled,rejected)}step((s=s.apply(e,t||[])).next())})};Object.defineProperty(t,"__esModule",{value:true});t.getState=t.saveState=t.group=t.endGroup=t.startGroup=t.info=t.notice=t.warning=t.error=t.debug=t.isDebug=t.setFailed=t.setCommandEcho=t.setOutput=t.getBooleanInput=t.getMultilineInput=t.getInput=t.addPath=t.setSecret=t.exportVariable=t.ExitCode=void 0;const a=r(7351);const c=r(717);const u=r(5278);const l=o(r(2087));const f=o(r(5622));var p;(function(e){e[e["Success"]=0]="Success";e[e["Failure"]=1]="Failure"})(p=t.ExitCode||(t.ExitCode={}));function exportVariable(e,t){const r=u.toCommandValue(t);process.env[e]=r;const s=process.env["GITHUB_ENV"]||"";if(s){const t="_GitHubActionsFileCommandDelimeter_";const s=`${e}<<${t}${l.EOL}${r}${l.EOL}${t}`;c.issueCommand("ENV",s)}else{a.issueCommand("set-env",{name:e},r)}}t.exportVariable=exportVariable;function setSecret(e){a.issueCommand("add-mask",{},e)}t.setSecret=setSecret;function addPath(e){const t=process.env["GITHUB_PATH"]||"";if(t){c.issueCommand("PATH",e)}else{a.issueCommand("add-path",{},e)}process.env["PATH"]=`${e}${f.delimiter}${process.env["PATH"]}`}t.addPath=addPath;function getInput(e,t){const r=process.env[`INPUT_${e.replace(/ /g,"_").toUpperCase()}`]||"";if(t&&t.required&&!r){throw new Error(`Input required and not supplied: ${e}`)}if(t&&t.trimWhitespace===false){return r}return r.trim()}t.getInput=getInput;function getMultilineInput(e,t){const r=getInput(e,t).split("\n").filter(e=>e!=="");return r}t.getMultilineInput=getMultilineInput;function getBooleanInput(e,t){const r=["true","True","TRUE"];const s=["false","False","FALSE"];const n=getInput(e,t);if(r.includes(n))return true;if(s.includes(n))return false;throw new TypeError(`Input does not meet YAML 1.2 "Core Schema" specification: ${e}\n`+`Support boolean input list: \`true | True | TRUE | false | False | FALSE\``)}t.getBooleanInput=getBooleanInput;function setOutput(e,t){process.stdout.write(l.EOL);a.issueCommand("set-output",{name:e},t)}t.setOutput=setOutput;function setCommandEcho(e){a.issue("echo",e?"on":"off")}t.setCommandEcho=setCommandEcho;function setFailed(e){process.exitCode=p.Failure;error(e)}t.setFailed=setFailed;function isDebug(){return process.env["RUNNER_DEBUG"]==="1"}t.isDebug=isDebug;function debug(e){a.issueCommand("debug",{},e)}t.debug=debug;function error(e,t={}){a.issueCommand("error",u.toCommandProperties(t),e instanceof Error?e.toString():e)}t.error=error;function warning(e,t={}){a.issueCommand("warning",u.toCommandProperties(t),e instanceof Error?e.toString():e)}t.warning=warning;function notice(e,t={}){a.issueCommand("notice",u.toCommandProperties(t),e instanceof Error?e.toString():e)}t.notice=notice;function info(e){process.stdout.write(e+l.EOL)}t.info=info;function startGroup(e){a.issue("group",e)}t.startGroup=startGroup;function endGroup(){a.issue("endgroup")}t.endGroup=endGroup;function group(e,t){return i(this,void 0,void 0,function*(){startGroup(e);let r;try{r=yield t()}finally{endGroup()}return r})}t.group=group;function saveState(e,t){a.issueCommand("save-state",{name:e},t)}t.saveState=saveState;function getState(e){return process.env[`STATE_${e}`]||""}t.getState=getState},717:function(e,t,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,t,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,s){if(s===undefined)s=r;e[s]=t[r]});var n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))s(t,e,r);n(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.issueCommand=void 0;const i=o(r(5747));const a=o(r(2087));const c=r(5278);function issueCommand(e,t){const r=process.env[`GITHUB_${e}`];if(!r){throw new Error(`Unable to find environment variable for file command ${e}`)}if(!i.existsSync(r)){throw new Error(`Missing file at path: ${r}`)}i.appendFileSync(r,`${c.toCommandValue(t)}${a.EOL}`,{encoding:"utf8"})}t.issueCommand=issueCommand},5278:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.toCommandProperties=t.toCommandValue=void 0;function toCommandValue(e){if(e===null||e===undefined){return""}else if(typeof e==="string"||e instanceof String){return e}return JSON.stringify(e)}t.toCommandValue=toCommandValue;function toCommandProperties(e){if(!Object.keys(e).length){return{}}return{title:e.title,line:e.startLine,endLine:e.endLine,col:e.startColumn,endColumn:e.endColumn}}t.toCommandProperties=toCommandProperties},1514:function(e,t,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,t,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,s){if(s===undefined)s=r;e[s]=t[r]});var n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))s(t,e,r);n(t,e);return t};var i=this&&this.__awaiter||function(e,t,r,s){function adopt(e){return e instanceof r?e:new r(function(t){t(e)})}return new(r||(r=Promise))(function(r,n){function fulfilled(e){try{step(s.next(e))}catch(e){n(e)}}function rejected(e){try{step(s["throw"](e))}catch(e){n(e)}}function step(e){e.done?r(e.value):adopt(e.value).then(fulfilled,rejected)}step((s=s.apply(e,t||[])).next())})};Object.defineProperty(t,"__esModule",{value:true});t.getExecOutput=t.exec=void 0;const a=r(4304);const c=o(r(8159));function exec(e,t,r){return i(this,void 0,void 0,function*(){const s=c.argStringToArray(e);if(s.length===0){throw new Error(`Parameter 'commandLine' cannot be null or empty.`)}const n=s[0];t=s.slice(1).concat(t||[]);const o=new c.ToolRunner(n,t,r);return o.exec()})}t.exec=exec;function getExecOutput(e,t,r){var s,n;return i(this,void 0,void 0,function*(){let o="";let i="";const c=new a.StringDecoder("utf8");const u=new a.StringDecoder("utf8");const l=(s=r===null||r===void 0?void 0:r.listeners)===null||s===void 0?void 0:s.stdout;const f=(n=r===null||r===void 0?void 0:r.listeners)===null||n===void 0?void 0:n.stderr;const p=e=>{i+=u.write(e);if(f){f(e)}};const d=e=>{o+=c.write(e);if(l){l(e)}};const h=Object.assign(Object.assign({},r===null||r===void 0?void 0:r.listeners),{stdout:d,stderr:p});const g=yield exec(e,t,Object.assign(Object.assign({},r),{listeners:h}));o+=c.end();i+=u.end();return{exitCode:g,stdout:o,stderr:i}})}t.getExecOutput=getExecOutput},8159:function(e,t,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,t,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,s){if(s===undefined)s=r;e[s]=t[r]});var n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))s(t,e,r);n(t,e);return t};var i=this&&this.__awaiter||function(e,t,r,s){function adopt(e){return e instanceof r?e:new r(function(t){t(e)})}return new(r||(r=Promise))(function(r,n){function fulfilled(e){try{step(s.next(e))}catch(e){n(e)}}function rejected(e){try{step(s["throw"](e))}catch(e){n(e)}}function step(e){e.done?r(e.value):adopt(e.value).then(fulfilled,rejected)}step((s=s.apply(e,t||[])).next())})};Object.defineProperty(t,"__esModule",{value:true});t.argStringToArray=t.ToolRunner=void 0;const a=o(r(2087));const c=o(r(8614));const u=o(r(3129));const l=o(r(5622));const f=o(r(7436));const p=o(r(1962));const d=r(8213);const h=process.platform==="win32";class ToolRunner extends c.EventEmitter{constructor(e,t,r){super();if(!e){throw new Error("Parameter 'toolPath' cannot be null or empty.")}this.toolPath=e;this.args=t||[];this.options=r||{}}_debug(e){if(this.options.listeners&&this.options.listeners.debug){this.options.listeners.debug(e)}}_getCommandString(e,t){const r=this._getSpawnFileName();const s=this._getSpawnArgs(e);let n=t?"":"[command]";if(h){if(this._isCmdFile()){n+=r;for(const e of s){n+=` ${e}`}}else if(e.windowsVerbatimArguments){n+=`"${r}"`;for(const e of s){n+=` ${e}`}}else{n+=this._windowsQuoteCmdArg(r);for(const e of s){n+=` ${this._windowsQuoteCmdArg(e)}`}}}else{n+=r;for(const e of s){n+=` ${e}`}}return n}_processLineBuffer(e,t,r){try{let s=t+e.toString();let n=s.indexOf(a.EOL);while(n>-1){const e=s.substring(0,n);r(e);s=s.substring(n+a.EOL.length);n=s.indexOf(a.EOL)}return s}catch(e){this._debug(`error processing line. Failed with error ${e}`);return""}}_getSpawnFileName(){if(h){if(this._isCmdFile()){return process.env["COMSPEC"]||"cmd.exe"}}return this.toolPath}_getSpawnArgs(e){if(h){if(this._isCmdFile()){let t=`/D /S /C "${this._windowsQuoteCmdArg(this.toolPath)}`;for(const r of this.args){t+=" ";t+=e.windowsVerbatimArguments?r:this._windowsQuoteCmdArg(r)}t+='"';return[t]}}return this.args}_endsWith(e,t){return e.endsWith(t)}_isCmdFile(){const e=this.toolPath.toUpperCase();return this._endsWith(e,".CMD")||this._endsWith(e,".BAT")}_windowsQuoteCmdArg(e){if(!this._isCmdFile()){return this._uvQuoteCmdArg(e)}if(!e){return'""'}const t=[" ","\t","&","(",")","[","]","{","}","^","=",";","!","'","+",",","`","~","|","<",">",'"'];let r=false;for(const s of e){if(t.some(e=>e===s)){r=true;break}}if(!r){return e}let s='"';let n=true;for(let t=e.length;t>0;t--){s+=e[t-1];if(n&&e[t-1]==="\\"){s+="\\"}else if(e[t-1]==='"'){n=true;s+='"'}else{n=false}}s+='"';return s.split("").reverse().join("")}_uvQuoteCmdArg(e){if(!e){return'""'}if(!e.includes(" ")&&!e.includes("\t")&&!e.includes('"')){return e}if(!e.includes('"')&&!e.includes("\\")){return`"${e}"`}let t='"';let r=true;for(let s=e.length;s>0;s--){t+=e[s-1];if(r&&e[s-1]==="\\"){t+="\\"}else if(e[s-1]==='"'){r=true;t+="\\"}else{r=false}}t+='"';return t.split("").reverse().join("")}_cloneExecOptions(e){e=e||{};const t={cwd:e.cwd||process.cwd(),env:e.env||process.env,silent:e.silent||false,windowsVerbatimArguments:e.windowsVerbatimArguments||false,failOnStdErr:e.failOnStdErr||false,ignoreReturnCode:e.ignoreReturnCode||false,delay:e.delay||1e4};t.outStream=e.outStream||process.stdout;t.errStream=e.errStream||process.stderr;return t}_getSpawnOptions(e,t){e=e||{};const r={};r.cwd=e.cwd;r.env=e.env;r["windowsVerbatimArguments"]=e.windowsVerbatimArguments||this._isCmdFile();if(e.windowsVerbatimArguments){r.argv0=`"${t}"`}return r}exec(){return i(this,void 0,void 0,function*(){if(!p.isRooted(this.toolPath)&&(this.toolPath.includes("/")||h&&this.toolPath.includes("\\"))){this.toolPath=l.resolve(process.cwd(),this.options.cwd||process.cwd(),this.toolPath)}this.toolPath=yield f.which(this.toolPath,true);return new Promise((e,t)=>i(this,void 0,void 0,function*(){this._debug(`exec tool: ${this.toolPath}`);this._debug("arguments:");for(const e of this.args){this._debug(` ${e}`)}const r=this._cloneExecOptions(this.options);if(!r.silent&&r.outStream){r.outStream.write(this._getCommandString(r)+a.EOL)}const s=new ExecState(r,this.toolPath);s.on("debug",e=>{this._debug(e)});if(this.options.cwd&&!(yield p.exists(this.options.cwd))){return t(new Error(`The cwd: ${this.options.cwd} does not exist!`))}const n=this._getSpawnFileName();const o=u.spawn(n,this._getSpawnArgs(r),this._getSpawnOptions(this.options,n));let i="";if(o.stdout){o.stdout.on("data",e=>{if(this.options.listeners&&this.options.listeners.stdout){this.options.listeners.stdout(e)}if(!r.silent&&r.outStream){r.outStream.write(e)}i=this._processLineBuffer(e,i,e=>{if(this.options.listeners&&this.options.listeners.stdline){this.options.listeners.stdline(e)}})})}let c="";if(o.stderr){o.stderr.on("data",e=>{s.processStderr=true;if(this.options.listeners&&this.options.listeners.stderr){this.options.listeners.stderr(e)}if(!r.silent&&r.errStream&&r.outStream){const t=r.failOnStdErr?r.errStream:r.outStream;t.write(e)}c=this._processLineBuffer(e,c,e=>{if(this.options.listeners&&this.options.listeners.errline){this.options.listeners.errline(e)}})})}o.on("error",e=>{s.processError=e.message;s.processExited=true;s.processClosed=true;s.CheckComplete()});o.on("exit",e=>{s.processExitCode=e;s.processExited=true;this._debug(`Exit code ${e} received from tool '${this.toolPath}'`);s.CheckComplete()});o.on("close",e=>{s.processExitCode=e;s.processExited=true;s.processClosed=true;this._debug(`STDIO streams have closed for tool '${this.toolPath}'`);s.CheckComplete()});s.on("done",(r,s)=>{if(i.length>0){this.emit("stdline",i)}if(c.length>0){this.emit("errline",c)}o.removeAllListeners();if(r){t(r)}else{e(s)}});if(this.options.input){if(!o.stdin){throw new Error("child process missing stdin")}o.stdin.end(this.options.input)}}))})}}t.ToolRunner=ToolRunner;function argStringToArray(e){const t=[];let r=false;let s=false;let n="";function append(e){if(s&&e!=='"'){n+="\\"}n+=e;s=false}for(let o=0;o0){t.push(n);n=""}continue}append(i)}if(n.length>0){t.push(n.trim())}return t}t.argStringToArray=argStringToArray;class ExecState extends c.EventEmitter{constructor(e,t){super();this.processClosed=false;this.processError="";this.processExitCode=0;this.processExited=false;this.processStderr=false;this.delay=1e4;this.done=false;this.timeout=null;if(!t){throw new Error("toolPath must not be empty")}this.options=e;this.toolPath=t;if(e.delay){this.delay=e.delay}}CheckComplete(){if(this.done){return}if(this.processClosed){this._setResult()}else if(this.processExited){this.timeout=d.setTimeout(ExecState.HandleTimeout,this.delay,this)}}_debug(e){this.emit("debug",e)}_setResult(){let e;if(this.processExited){if(this.processError){e=new Error(`There was an error when attempting to execute the process '${this.toolPath}'. This may indicate the process failed to start. Error: ${this.processError}`)}else if(this.processExitCode!==0&&!this.options.ignoreReturnCode){e=new Error(`The process '${this.toolPath}' failed with exit code ${this.processExitCode}`)}else if(this.processStderr&&this.options.failOnStdErr){e=new Error(`The process '${this.toolPath}' failed because one or more lines were written to the STDERR stream`)}}if(this.timeout){clearTimeout(this.timeout);this.timeout=null}this.done=true;this.emit("done",e,this.processExitCode)}static HandleTimeout(e){if(e.done){return}if(!e.processClosed&&e.processExited){const t=`The STDIO streams did not close within ${e.delay/1e3} seconds of the exit event from process '${e.toolPath}'. This may indicate a child process inherited the STDIO streams and has not yet exited.`;e._debug(t)}e._setResult()}}},4087:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.Context=void 0;const s=r(5747);const n=r(2087);class Context{constructor(){var e,t,r;this.payload={};if(process.env.GITHUB_EVENT_PATH){if(s.existsSync(process.env.GITHUB_EVENT_PATH)){this.payload=JSON.parse(s.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${n.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=(t=process.env.GITHUB_SERVER_URL)!==null&&t!==void 0?t:`https://github.com`;this.graphqlUrl=(r=process.env.GITHUB_GRAPHQL_URL)!==null&&r!==void 0?r:`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,t]=process.env.GITHUB_REPOSITORY.split("/");return{owner:e,repo:t}}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'")}}t.Context=Context},5438:function(e,t,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,t,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,s){if(s===undefined)s=r;e[s]=t[r]});var n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))s(t,e,r);n(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.getOctokit=t.context=void 0;const i=o(r(4087));const a=r(3030);t.context=new i.Context;function getOctokit(e,t){return new a.GitHub(a.getOctokitOptions(e,t))}t.getOctokit=getOctokit},7914:function(e,t,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,t,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,s){if(s===undefined)s=r;e[s]=t[r]});var n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))s(t,e,r);n(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.getApiBaseUrl=t.getProxyAgent=t.getAuthString=void 0;const i=o(r(9925));function getAuthString(e,t){if(!e&&!t.auth){throw new Error("Parameter token or opts.auth is required")}else if(e&&t.auth){throw new Error("Parameters token and opts.auth may not both be specified")}return typeof t.auth==="string"?t.auth:`token ${e}`}t.getAuthString=getAuthString;function getProxyAgent(e){const t=new i.HttpClient;return t.getAgent(e)}t.getProxyAgent=getProxyAgent;function getApiBaseUrl(){return process.env["GITHUB_API_URL"]||"https://api.github.com"}t.getApiBaseUrl=getApiBaseUrl},3030:function(e,t,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,t,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,s){if(s===undefined)s=r;e[s]=t[r]});var n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))s(t,e,r);n(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.getOctokitOptions=t.GitHub=t.context=void 0;const i=o(r(4087));const a=o(r(7914));const c=r(6762);const u=r(3044);const l=r(4193);t.context=new i.Context;const f=a.getApiBaseUrl();const p={baseUrl:f,request:{agent:a.getProxyAgent(f)}};t.GitHub=c.Octokit.plugin(u.restEndpointMethods,l.paginateRest).defaults(p);function getOctokitOptions(e,t){const r=Object.assign({},t||{});const s=a.getAuthString(e,r);if(s){r.auth=s}return r}t.getOctokitOptions=getOctokitOptions},8090:function(e,t,r){"use strict";var s=this&&this.__awaiter||function(e,t,r,s){function adopt(e){return e instanceof r?e:new r(function(t){t(e)})}return new(r||(r=Promise))(function(r,n){function fulfilled(e){try{step(s.next(e))}catch(e){n(e)}}function rejected(e){try{step(s["throw"](e))}catch(e){n(e)}}function step(e){e.done?r(e.value):adopt(e.value).then(fulfilled,rejected)}step((s=s.apply(e,t||[])).next())})};Object.defineProperty(t,"__esModule",{value:true});t.hashFiles=t.create=void 0;const n=r(8298);const o=r(2448);function create(e,t){return s(this,void 0,void 0,function*(){return yield n.DefaultGlobber.create(e,t)})}t.create=create;function hashFiles(e,t){return s(this,void 0,void 0,function*(){let r=true;if(t&&typeof t.followSymbolicLinks==="boolean"){r=t.followSymbolicLinks}const s=yield create(e,{followSymbolicLinks:r});return o.hashFiles(s)})}t.hashFiles=hashFiles},1026:function(e,t,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,t,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,s){if(s===undefined)s=r;e[s]=t[r]});var n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))s(t,e,r);n(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.getOptions=void 0;const i=o(r(2186));function getOptions(e){const t={followSymbolicLinks:true,implicitDescendants:true,matchDirectories:true,omitBrokenSymbolicLinks:true};if(e){if(typeof e.followSymbolicLinks==="boolean"){t.followSymbolicLinks=e.followSymbolicLinks;i.debug(`followSymbolicLinks '${t.followSymbolicLinks}'`)}if(typeof e.implicitDescendants==="boolean"){t.implicitDescendants=e.implicitDescendants;i.debug(`implicitDescendants '${t.implicitDescendants}'`)}if(typeof e.matchDirectories==="boolean"){t.matchDirectories=e.matchDirectories;i.debug(`matchDirectories '${t.matchDirectories}'`)}if(typeof e.omitBrokenSymbolicLinks==="boolean"){t.omitBrokenSymbolicLinks=e.omitBrokenSymbolicLinks;i.debug(`omitBrokenSymbolicLinks '${t.omitBrokenSymbolicLinks}'`)}}return t}t.getOptions=getOptions},8298:function(e,t,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,t,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,s){if(s===undefined)s=r;e[s]=t[r]});var n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))s(t,e,r);n(t,e);return t};var i=this&&this.__awaiter||function(e,t,r,s){function adopt(e){return e instanceof r?e:new r(function(t){t(e)})}return new(r||(r=Promise))(function(r,n){function fulfilled(e){try{step(s.next(e))}catch(e){n(e)}}function rejected(e){try{step(s["throw"](e))}catch(e){n(e)}}function step(e){e.done?r(e.value):adopt(e.value).then(fulfilled,rejected)}step((s=s.apply(e,t||[])).next())})};var a=this&&this.__asyncValues||function(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t=e[Symbol.asyncIterator],r;return t?t.call(e):(e=typeof __values==="function"?__values(e):e[Symbol.iterator](),r={},verb("next"),verb("throw"),verb("return"),r[Symbol.asyncIterator]=function(){return this},r);function verb(t){r[t]=e[t]&&function(r){return new Promise(function(s,n){r=e[t](r),settle(s,n,r.done,r.value)})}}function settle(e,t,r,s){Promise.resolve(s).then(function(t){e({value:t,done:r})},t)}};var c=this&&this.__await||function(e){return this instanceof c?(this.v=e,this):new c(e)};var u=this&&this.__asyncGenerator||function(e,t,r){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var s=r.apply(e,t||[]),n,o=[];return n={},verb("next"),verb("throw"),verb("return"),n[Symbol.asyncIterator]=function(){return this},n;function verb(e){if(s[e])n[e]=function(t){return new Promise(function(r,s){o.push([e,t,r,s])>1||resume(e,t)})}}function resume(e,t){try{step(s[e](t))}catch(e){settle(o[0][3],e)}}function step(e){e.value instanceof c?Promise.resolve(e.value.v).then(fulfill,reject):settle(o[0][2],e)}function fulfill(e){resume("next",e)}function reject(e){resume("throw",e)}function settle(e,t){if(e(t),o.shift(),o.length)resume(o[0][0],o[0][1])}};Object.defineProperty(t,"__esModule",{value:true});t.DefaultGlobber=void 0;const l=o(r(2186));const f=o(r(5747));const p=o(r(1026));const d=o(r(5622));const h=o(r(9005));const g=r(1063);const m=r(4536);const y=r(9117);const v=process.platform==="win32";class DefaultGlobber{constructor(e){this.patterns=[];this.searchPaths=[];this.options=p.getOptions(e)}getSearchPaths(){return this.searchPaths.slice()}glob(){var e,t;return i(this,void 0,void 0,function*(){const r=[];try{for(var s=a(this.globGenerator()),n;n=yield s.next(),!n.done;){const e=n.value;r.push(e)}}catch(t){e={error:t}}finally{try{if(n&&!n.done&&(t=s.return))yield t.call(s)}finally{if(e)throw e.error}}return r})}globGenerator(){return u(this,arguments,function*globGenerator_1(){const e=p.getOptions(this.options);const t=[];for(const r of this.patterns){t.push(r);if(e.implicitDescendants&&(r.trailingSeparator||r.segments[r.segments.length-1]!=="**")){t.push(new m.Pattern(r.negate,true,r.segments.concat("**")))}}const r=[];for(const e of h.getSearchPaths(t)){l.debug(`Search path '${e}'`);try{yield c(f.promises.lstat(e))}catch(e){if(e.code==="ENOENT"){continue}throw e}r.unshift(new y.SearchState(e,1))}const s=[];while(r.length){const n=r.pop();const o=h.match(t,n.path);const i=!!o||h.partialMatch(t,n.path);if(!o&&!i){continue}const a=yield c(DefaultGlobber.stat(n,e,s));if(!a){continue}if(a.isDirectory()){if(o&g.MatchKind.Directory&&e.matchDirectories){yield yield c(n.path)}else if(!i){continue}const t=n.level+1;const s=(yield c(f.promises.readdir(n.path))).map(e=>new y.SearchState(d.join(n.path,e),t));r.push(...s.reverse())}else if(o&g.MatchKind.File){yield yield c(n.path)}}})}static create(e,t){return i(this,void 0,void 0,function*(){const r=new DefaultGlobber(t);if(v){e=e.replace(/\r\n/g,"\n");e=e.replace(/\r/g,"\n")}const s=e.split("\n").map(e=>e.trim());for(const e of s){if(!e||e.startsWith("#")){continue}else{r.patterns.push(new m.Pattern(e))}}r.searchPaths.push(...h.getSearchPaths(r.patterns));return r})}static stat(e,t,r){return i(this,void 0,void 0,function*(){let s;if(t.followSymbolicLinks){try{s=yield f.promises.stat(e.path)}catch(r){if(r.code==="ENOENT"){if(t.omitBrokenSymbolicLinks){l.debug(`Broken symlink '${e.path}'`);return undefined}throw new Error(`No information found for the path '${e.path}'. This may indicate a broken symbolic link.`)}throw r}}else{s=yield f.promises.lstat(e.path)}if(s.isDirectory()&&t.followSymbolicLinks){const t=yield f.promises.realpath(e.path);while(r.length>=e.level){r.pop()}if(r.some(e=>e===t)){l.debug(`Symlink cycle detected for path '${e.path}' and realpath '${t}'`);return undefined}r.push(t)}return s})}}t.DefaultGlobber=DefaultGlobber},2448:function(e,t,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,t,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,s){if(s===undefined)s=r;e[s]=t[r]});var n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))s(t,e,r);n(t,e);return t};var i=this&&this.__awaiter||function(e,t,r,s){function adopt(e){return e instanceof r?e:new r(function(t){t(e)})}return new(r||(r=Promise))(function(r,n){function fulfilled(e){try{step(s.next(e))}catch(e){n(e)}}function rejected(e){try{step(s["throw"](e))}catch(e){n(e)}}function step(e){e.done?r(e.value):adopt(e.value).then(fulfilled,rejected)}step((s=s.apply(e,t||[])).next())})};var a=this&&this.__asyncValues||function(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t=e[Symbol.asyncIterator],r;return t?t.call(e):(e=typeof __values==="function"?__values(e):e[Symbol.iterator](),r={},verb("next"),verb("throw"),verb("return"),r[Symbol.asyncIterator]=function(){return this},r);function verb(t){r[t]=e[t]&&function(r){return new Promise(function(s,n){r=e[t](r),settle(s,n,r.done,r.value)})}}function settle(e,t,r,s){Promise.resolve(s).then(function(t){e({value:t,done:r})},t)}};Object.defineProperty(t,"__esModule",{value:true});t.hashFiles=void 0;const c=o(r(6417));const u=o(r(2186));const l=o(r(5747));const f=o(r(2413));const p=o(r(1669));const d=o(r(5622));function hashFiles(e){var t,r;var s;return i(this,void 0,void 0,function*(){let n=false;const o=(s=process.env["GITHUB_WORKSPACE"])!==null&&s!==void 0?s:process.cwd();const i=c.createHash("sha256");let h=0;try{for(var g=a(e.globGenerator()),m;m=yield g.next(),!m.done;){const e=m.value;u.debug(e);if(!e.startsWith(`${o}${d.sep}`)){u.debug(`Ignore '${e}' since it is not under GITHUB_WORKSPACE.`);continue}if(l.statSync(e).isDirectory()){u.debug(`Skip directory '${e}'.`);continue}const t=c.createHash("sha256");const r=p.promisify(f.pipeline);yield r(l.createReadStream(e),t);i.write(t.digest());h++;if(!n){n=true}}}catch(e){t={error:e}}finally{try{if(m&&!m.done&&(r=g.return))yield r.call(g)}finally{if(t)throw t.error}}i.end();if(n){u.debug(`Found ${h} files to hash.`);return i.digest("hex")}else{u.debug(`No matches found for glob`);return""}})}t.hashFiles=hashFiles},1063:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.MatchKind=void 0;var r;(function(e){e[e["None"]=0]="None";e[e["Directory"]=1]="Directory";e[e["File"]=2]="File";e[e["All"]=3]="All"})(r=t.MatchKind||(t.MatchKind={}))},1849:function(e,t,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,t,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,s){if(s===undefined)s=r;e[s]=t[r]});var n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))s(t,e,r);n(t,e);return t};var i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:true});t.safeTrimTrailingSeparator=t.normalizeSeparators=t.hasRoot=t.hasAbsoluteRoot=t.ensureAbsoluteRoot=t.dirname=void 0;const a=o(r(5622));const c=i(r(2357));const u=process.platform==="win32";function dirname(e){e=safeTrimTrailingSeparator(e);if(u&&/^\\\\[^\\]+(\\[^\\]+)?$/.test(e)){return e}let t=a.dirname(e);if(u&&/^\\\\[^\\]+\\[^\\]+\\$/.test(t)){t=safeTrimTrailingSeparator(t)}return t}t.dirname=dirname;function ensureAbsoluteRoot(e,t){c.default(e,`ensureAbsoluteRoot parameter 'root' must not be empty`);c.default(t,`ensureAbsoluteRoot parameter 'itemPath' must not be empty`);if(hasAbsoluteRoot(t)){return t}if(u){if(t.match(/^[A-Z]:[^\\/]|^[A-Z]:$/i)){let e=process.cwd();c.default(e.match(/^[A-Z]:\\/i),`Expected current directory to start with an absolute drive root. Actual '${e}'`);if(t[0].toUpperCase()===e[0].toUpperCase()){if(t.length===2){return`${t[0]}:\\${e.substr(3)}`}else{if(!e.endsWith("\\")){e+="\\"}return`${t[0]}:\\${e.substr(3)}${t.substr(2)}`}}else{return`${t[0]}:\\${t.substr(2)}`}}else if(normalizeSeparators(t).match(/^\\$|^\\[^\\]/)){const e=process.cwd();c.default(e.match(/^[A-Z]:\\/i),`Expected current directory to start with an absolute drive root. Actual '${e}'`);return`${e[0]}:\\${t.substr(1)}`}}c.default(hasAbsoluteRoot(e),`ensureAbsoluteRoot parameter 'root' must have an absolute root`);if(e.endsWith("/")||u&&e.endsWith("\\")){}else{e+=a.sep}return e+t}t.ensureAbsoluteRoot=ensureAbsoluteRoot;function hasAbsoluteRoot(e){c.default(e,`hasAbsoluteRoot parameter 'itemPath' must not be empty`);e=normalizeSeparators(e);if(u){return e.startsWith("\\\\")||/^[A-Z]:\\/i.test(e)}return e.startsWith("/")}t.hasAbsoluteRoot=hasAbsoluteRoot;function hasRoot(e){c.default(e,`isRooted parameter 'itemPath' must not be empty`);e=normalizeSeparators(e);if(u){return e.startsWith("\\")||/^[A-Z]:/i.test(e)}return e.startsWith("/")}t.hasRoot=hasRoot;function normalizeSeparators(e){e=e||"";if(u){e=e.replace(/\//g,"\\");const t=/^\\\\+[^\\]/.test(e);return(t?"\\":"")+e.replace(/\\\\+/g,"\\")}return e.replace(/\/\/+/g,"/")}t.normalizeSeparators=normalizeSeparators;function safeTrimTrailingSeparator(e){if(!e){return""}e=normalizeSeparators(e);if(!e.endsWith(a.sep)){return e}if(e===a.sep){return e}if(u&&/^[A-Z]:\\$/i.test(e)){return e}return e.substr(0,e.length-1)}t.safeTrimTrailingSeparator=safeTrimTrailingSeparator},6836:function(e,t,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,t,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,s){if(s===undefined)s=r;e[s]=t[r]});var n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))s(t,e,r);n(t,e);return t};var i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:true});t.Path=void 0;const a=o(r(5622));const c=o(r(1849));const u=i(r(2357));const l=process.platform==="win32";class Path{constructor(e){this.segments=[];if(typeof e==="string"){u.default(e,`Parameter 'itemPath' must not be empty`);e=c.safeTrimTrailingSeparator(e);if(!c.hasRoot(e)){this.segments=e.split(a.sep)}else{let t=e;let r=c.dirname(t);while(r!==t){const e=a.basename(t);this.segments.unshift(e);t=r;r=c.dirname(t)}this.segments.unshift(t)}}else{u.default(e.length>0,`Parameter 'itemPath' must not be an empty array`);for(let t=0;t!e.negate);const t={};for(const r of e){const e=c?r.searchPath.toUpperCase():r.searchPath;t[e]="candidate"}const r=[];for(const s of e){const e=c?s.searchPath.toUpperCase():s.searchPath;if(t[e]==="included"){continue}let n=false;let o=e;let a=i.dirname(o);while(a!==o){if(t[a]){n=true;break}o=a;a=i.dirname(o)}if(!n){r.push(s.searchPath);t[e]="included"}}return r}t.getSearchPaths=getSearchPaths;function match(e,t){let r=a.MatchKind.None;for(const s of e){if(s.negate){r&=~s.match(t)}else{r|=s.match(t)}}return r}t.match=match;function partialMatch(e,t){return e.some(e=>!e.negate&&e.partialMatch(t))}t.partialMatch=partialMatch},4536:function(e,t,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,t,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,s){if(s===undefined)s=r;e[s]=t[r]});var n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))s(t,e,r);n(t,e);return t};var i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:true});t.Pattern=void 0;const a=o(r(2087));const c=o(r(5622));const u=o(r(1849));const l=i(r(2357));const f=r(3973);const p=r(1063);const d=r(6836);const h=process.platform==="win32";class Pattern{constructor(e,t=false,r,s){this.negate=false;let n;if(typeof e==="string"){n=e.trim()}else{r=r||[];l.default(r.length,`Parameter 'segments' must not empty`);const t=Pattern.getLiteral(r[0]);l.default(t&&u.hasAbsoluteRoot(t),`Parameter 'segments' first element must be a root path`);n=new d.Path(r).toString().trim();if(e){n=`!${n}`}}while(n.startsWith("!")){this.negate=!this.negate;n=n.substr(1).trim()}n=Pattern.fixupPattern(n,s);this.segments=new d.Path(n).segments;this.trailingSeparator=u.normalizeSeparators(n).endsWith(c.sep);n=u.safeTrimTrailingSeparator(n);let o=false;const i=this.segments.map(e=>Pattern.getLiteral(e)).filter(e=>!o&&!(o=e===""));this.searchPath=new d.Path(i).toString();this.rootRegExp=new RegExp(Pattern.regExpEscape(i[0]),h?"i":"");this.isImplicitPattern=t;const a={dot:true,nobrace:true,nocase:h,nocomment:true,noext:true,nonegate:true};n=h?n.replace(/\\/g,"/"):n;this.minimatch=new f.Minimatch(n,a)}match(e){if(this.segments[this.segments.length-1]==="**"){e=u.normalizeSeparators(e);if(!e.endsWith(c.sep)&&this.isImplicitPattern===false){e=`${e}${c.sep}`}}else{e=u.safeTrimTrailingSeparator(e)}if(this.minimatch.match(e)){return this.trailingSeparator?p.MatchKind.Directory:p.MatchKind.All}return p.MatchKind.None}partialMatch(e){e=u.safeTrimTrailingSeparator(e);if(u.dirname(e)===e){return this.rootRegExp.test(e)}return this.minimatch.matchOne(e.split(h?/\\+/:/\/+/),this.minimatch.set[0],true)}static globEscape(e){return(h?e:e.replace(/\\/g,"\\\\")).replace(/(\[)(?=[^/]+\])/g,"[[]").replace(/\?/g,"[?]").replace(/\*/g,"[*]")}static fixupPattern(e,t){l.default(e,"pattern cannot be empty");const r=new d.Path(e).segments.map(e=>Pattern.getLiteral(e));l.default(r.every((e,t)=>(e!=="."||t===0)&&e!==".."),`Invalid pattern '${e}'. Relative pathing '.' and '..' is not allowed.`);l.default(!u.hasRoot(e)||r[0],`Invalid pattern '${e}'. Root segment must not contain globs.`);e=u.normalizeSeparators(e);if(e==="."||e.startsWith(`.${c.sep}`)){e=Pattern.globEscape(process.cwd())+e.substr(1)}else if(e==="~"||e.startsWith(`~${c.sep}`)){t=t||a.homedir();l.default(t,"Unable to determine HOME directory");l.default(u.hasAbsoluteRoot(t),`Expected HOME directory to be a rooted path. Actual '${t}'`);e=Pattern.globEscape(t)+e.substr(1)}else if(h&&(e.match(/^[A-Z]:$/i)||e.match(/^[A-Z]:[^\\]/i))){let t=u.ensureAbsoluteRoot("C:\\dummy-root",e.substr(0,2));if(e.length>2&&!t.endsWith("\\")){t+="\\"}e=Pattern.globEscape(t)+e.substr(2)}else if(h&&(e==="\\"||e.match(/^\\[^\\]/))){let t=u.ensureAbsoluteRoot("C:\\dummy-root","\\");if(!t.endsWith("\\")){t+="\\"}e=Pattern.globEscape(t)+e.substr(1)}else{e=u.ensureAbsoluteRoot(Pattern.globEscape(process.cwd()),e)}return u.normalizeSeparators(e)}static getLiteral(e){let t="";for(let r=0;r=0){if(s.length>1){return""}if(s){t+=s;r=n;continue}}}t+=s}return t}static regExpEscape(e){return e.replace(/[[\\^$.|?*+()]/g,"\\$&")}}t.Pattern=Pattern},9117:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.SearchState=void 0;class SearchState{constructor(e,t){this.path=e;this.level=t}}t.SearchState=SearchState},9925:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const s=r(8605);const n=r(7211);const o=r(6443);let i;var a;(function(e){e[e["OK"]=200]="OK";e[e["MultipleChoices"]=300]="MultipleChoices";e[e["MovedPermanently"]=301]="MovedPermanently";e[e["ResourceMoved"]=302]="ResourceMoved";e[e["SeeOther"]=303]="SeeOther";e[e["NotModified"]=304]="NotModified";e[e["UseProxy"]=305]="UseProxy";e[e["SwitchProxy"]=306]="SwitchProxy";e[e["TemporaryRedirect"]=307]="TemporaryRedirect";e[e["PermanentRedirect"]=308]="PermanentRedirect";e[e["BadRequest"]=400]="BadRequest";e[e["Unauthorized"]=401]="Unauthorized";e[e["PaymentRequired"]=402]="PaymentRequired";e[e["Forbidden"]=403]="Forbidden";e[e["NotFound"]=404]="NotFound";e[e["MethodNotAllowed"]=405]="MethodNotAllowed";e[e["NotAcceptable"]=406]="NotAcceptable";e[e["ProxyAuthenticationRequired"]=407]="ProxyAuthenticationRequired";e[e["RequestTimeout"]=408]="RequestTimeout";e[e["Conflict"]=409]="Conflict";e[e["Gone"]=410]="Gone";e[e["TooManyRequests"]=429]="TooManyRequests";e[e["InternalServerError"]=500]="InternalServerError";e[e["NotImplemented"]=501]="NotImplemented";e[e["BadGateway"]=502]="BadGateway";e[e["ServiceUnavailable"]=503]="ServiceUnavailable";e[e["GatewayTimeout"]=504]="GatewayTimeout"})(a=t.HttpCodes||(t.HttpCodes={}));var c;(function(e){e["Accept"]="accept";e["ContentType"]="content-type"})(c=t.Headers||(t.Headers={}));var u;(function(e){e["ApplicationJson"]="application/json"})(u=t.MediaTypes||(t.MediaTypes={}));function getProxyUrl(e){let t=o.getProxyUrl(new URL(e));return t?t.href:""}t.getProxyUrl=getProxyUrl;const l=[a.MovedPermanently,a.ResourceMoved,a.SeeOther,a.TemporaryRedirect,a.PermanentRedirect];const f=[a.BadGateway,a.ServiceUnavailable,a.GatewayTimeout];const p=["OPTIONS","GET","DELETE","HEAD"];const d=10;const h=5;class HttpClientError extends Error{constructor(e,t){super(e);this.name="HttpClientError";this.statusCode=t;Object.setPrototypeOf(this,HttpClientError.prototype)}}t.HttpClientError=HttpClientError;class HttpClientResponse{constructor(e){this.message=e}readBody(){return new Promise(async(e,t)=>{let r=Buffer.alloc(0);this.message.on("data",e=>{r=Buffer.concat([r,e])});this.message.on("end",()=>{e(r.toString())})})}}t.HttpClientResponse=HttpClientResponse;function isHttps(e){let t=new URL(e);return t.protocol==="https:"}t.isHttps=isHttps;class HttpClient{constructor(e,t,r){this._ignoreSslError=false;this._allowRedirects=true;this._allowRedirectDowngrade=false;this._maxRedirects=50;this._allowRetries=false;this._maxRetries=1;this._keepAlive=false;this._disposed=false;this.userAgent=e;this.handlers=t||[];this.requestOptions=r;if(r){if(r.ignoreSslError!=null){this._ignoreSslError=r.ignoreSslError}this._socketTimeout=r.socketTimeout;if(r.allowRedirects!=null){this._allowRedirects=r.allowRedirects}if(r.allowRedirectDowngrade!=null){this._allowRedirectDowngrade=r.allowRedirectDowngrade}if(r.maxRedirects!=null){this._maxRedirects=Math.max(r.maxRedirects,0)}if(r.keepAlive!=null){this._keepAlive=r.keepAlive}if(r.allowRetries!=null){this._allowRetries=r.allowRetries}if(r.maxRetries!=null){this._maxRetries=r.maxRetries}}}options(e,t){return this.request("OPTIONS",e,null,t||{})}get(e,t){return this.request("GET",e,null,t||{})}del(e,t){return this.request("DELETE",e,null,t||{})}post(e,t,r){return this.request("POST",e,t,r||{})}patch(e,t,r){return this.request("PATCH",e,t,r||{})}put(e,t,r){return this.request("PUT",e,t,r||{})}head(e,t){return this.request("HEAD",e,null,t||{})}sendStream(e,t,r,s){return this.request(e,t,r,s)}async getJson(e,t={}){t[c.Accept]=this._getExistingOrDefaultHeader(t,c.Accept,u.ApplicationJson);let r=await this.get(e,t);return this._processResponse(r,this.requestOptions)}async postJson(e,t,r={}){let s=JSON.stringify(t,null,2);r[c.Accept]=this._getExistingOrDefaultHeader(r,c.Accept,u.ApplicationJson);r[c.ContentType]=this._getExistingOrDefaultHeader(r,c.ContentType,u.ApplicationJson);let n=await this.post(e,s,r);return this._processResponse(n,this.requestOptions)}async putJson(e,t,r={}){let s=JSON.stringify(t,null,2);r[c.Accept]=this._getExistingOrDefaultHeader(r,c.Accept,u.ApplicationJson);r[c.ContentType]=this._getExistingOrDefaultHeader(r,c.ContentType,u.ApplicationJson);let n=await this.put(e,s,r);return this._processResponse(n,this.requestOptions)}async patchJson(e,t,r={}){let s=JSON.stringify(t,null,2);r[c.Accept]=this._getExistingOrDefaultHeader(r,c.Accept,u.ApplicationJson);r[c.ContentType]=this._getExistingOrDefaultHeader(r,c.ContentType,u.ApplicationJson);let n=await this.patch(e,s,r);return this._processResponse(n,this.requestOptions)}async request(e,t,r,s){if(this._disposed){throw new Error("Client has already been disposed.")}let n=new URL(t);let o=this._prepareRequest(e,n,s);let i=this._allowRetries&&p.indexOf(e)!=-1?this._maxRetries+1:1;let c=0;let u;while(c0){const i=u.message.headers["location"];if(!i){break}let a=new URL(i);if(n.protocol=="https:"&&n.protocol!=a.protocol&&!this._allowRedirectDowngrade){throw new Error("Redirect from HTTPS to HTTP protocol. This downgrade is not allowed for security reasons. If you want to allow this behavior, set the allowRedirectDowngrade option to true.")}await u.readBody();if(a.hostname!==n.hostname){for(let e in s){if(e.toLowerCase()==="authorization"){delete s[e]}}}o=this._prepareRequest(e,a,s);u=await this.requestRaw(o,r);t--}if(f.indexOf(u.message.statusCode)==-1){return u}c+=1;if(c{let n=function(e,t){if(e){s(e)}r(t)};this.requestRawWithCallback(e,t,n)})}requestRawWithCallback(e,t,r){let s;if(typeof t==="string"){e.options.headers["Content-Length"]=Buffer.byteLength(t,"utf8")}let n=false;let o=(e,t)=>{if(!n){n=true;r(e,t)}};let i=e.httpModule.request(e.options,e=>{let t=new HttpClientResponse(e);o(null,t)});i.on("socket",e=>{s=e});i.setTimeout(this._socketTimeout||3*6e4,()=>{if(s){s.end()}o(new Error("Request timeout: "+e.options.path),null)});i.on("error",function(e){o(e,null)});if(t&&typeof t==="string"){i.write(t,"utf8")}if(t&&typeof t!=="string"){t.on("close",function(){i.end()});t.pipe(i)}else{i.end()}}getAgent(e){let t=new URL(e);return this._getAgent(t)}_prepareRequest(e,t,r){const o={};o.parsedUrl=t;const i=o.parsedUrl.protocol==="https:";o.httpModule=i?n:s;const a=i?443:80;o.options={};o.options.host=o.parsedUrl.hostname;o.options.port=o.parsedUrl.port?parseInt(o.parsedUrl.port):a;o.options.path=(o.parsedUrl.pathname||"")+(o.parsedUrl.search||"");o.options.method=e;o.options.headers=this._mergeHeaders(r);if(this.userAgent!=null){o.options.headers["user-agent"]=this.userAgent}o.options.agent=this._getAgent(o.parsedUrl);if(this.handlers){this.handlers.forEach(e=>{e.prepareRequest(o.options)})}return o}_mergeHeaders(e){const t=e=>Object.keys(e).reduce((t,r)=>(t[r.toLowerCase()]=e[r],t),{});if(this.requestOptions&&this.requestOptions.headers){return Object.assign({},t(this.requestOptions.headers),t(e))}return t(e||{})}_getExistingOrDefaultHeader(e,t,r){const s=e=>Object.keys(e).reduce((t,r)=>(t[r.toLowerCase()]=e[r],t),{});let n;if(this.requestOptions&&this.requestOptions.headers){n=s(this.requestOptions.headers)[t]}return e[t]||n||r}_getAgent(e){let t;let a=o.getProxyUrl(e);let c=a&&a.hostname;if(this._keepAlive&&c){t=this._proxyAgent}if(this._keepAlive&&!c){t=this._agent}if(!!t){return t}const u=e.protocol==="https:";let l=100;if(!!this.requestOptions){l=this.requestOptions.maxSockets||s.globalAgent.maxSockets}if(c){if(!i){i=r(4294)}const e={maxSockets:l,keepAlive:this._keepAlive,proxy:{...(a.username||a.password)&&{proxyAuth:`${a.username}:${a.password}`},host:a.hostname,port:a.port}};let s;const n=a.protocol==="https:";if(u){s=n?i.httpsOverHttps:i.httpsOverHttp}else{s=n?i.httpOverHttps:i.httpOverHttp}t=s(e);this._proxyAgent=t}if(this._keepAlive&&!t){const e={keepAlive:this._keepAlive,maxSockets:l};t=u?new n.Agent(e):new s.Agent(e);this._agent=t}if(!t){t=u?n.globalAgent:s.globalAgent}if(u&&this._ignoreSslError){t.options=Object.assign(t.options||{},{rejectUnauthorized:false})}return t}_performExponentialBackoff(e){e=Math.min(d,e);const t=h*Math.pow(2,e);return new Promise(e=>setTimeout(()=>e(),t))}static dateTimeDeserializer(e,t){if(typeof t==="string"){let e=new Date(t);if(!isNaN(e.valueOf())){return e}}return t}async _processResponse(e,t){return new Promise(async(r,s)=>{const n=e.message.statusCode;const o={statusCode:n,result:null,headers:{}};if(n==a.NotFound){r(o)}let i;let c;try{c=await e.readBody();if(c&&c.length>0){if(t&&t.deserializeDates){i=JSON.parse(c,HttpClient.dateTimeDeserializer)}else{i=JSON.parse(c)}o.result=i}o.headers=e.message.headers}catch(e){}if(n>299){let e;if(i&&i.message){e=i.message}else if(c&&c.length>0){e=c}else{e="Failed request: ("+n+")"}let t=new HttpClientError(e,n);t.result=o.result;s(t)}else{r(o)}})}}t.HttpClient=HttpClient},6443:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});function getProxyUrl(e){let t=e.protocol==="https:";let r;if(checkBypass(e)){return r}let s;if(t){s=process.env["https_proxy"]||process.env["HTTPS_PROXY"]}else{s=process.env["http_proxy"]||process.env["HTTP_PROXY"]}if(s){r=new URL(s)}return r}t.getProxyUrl=getProxyUrl;function checkBypass(e){if(!e.hostname){return false}let t=process.env["no_proxy"]||process.env["NO_PROXY"]||"";if(!t){return false}let r;if(e.port){r=Number(e.port)}else if(e.protocol==="http:"){r=80}else if(e.protocol==="https:"){r=443}let s=[e.hostname.toUpperCase()];if(typeof r==="number"){s.push(`${s[0]}:${r}`)}for(let e of t.split(",").map(e=>e.trim().toUpperCase()).filter(e=>e)){if(s.some(t=>t===e)){return true}}return false}t.checkBypass=checkBypass},1962:function(e,t,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,t,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,s){if(s===undefined)s=r;e[s]=t[r]});var n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))s(t,e,r);n(t,e);return t};var i=this&&this.__awaiter||function(e,t,r,s){function adopt(e){return e instanceof r?e:new r(function(t){t(e)})}return new(r||(r=Promise))(function(r,n){function fulfilled(e){try{step(s.next(e))}catch(e){n(e)}}function rejected(e){try{step(s["throw"](e))}catch(e){n(e)}}function step(e){e.done?r(e.value):adopt(e.value).then(fulfilled,rejected)}step((s=s.apply(e,t||[])).next())})};var a;Object.defineProperty(t,"__esModule",{value:true});t.getCmdPath=t.tryGetExecutablePath=t.isRooted=t.isDirectory=t.exists=t.IS_WINDOWS=t.unlink=t.symlink=t.stat=t.rmdir=t.rename=t.readlink=t.readdir=t.mkdir=t.lstat=t.copyFile=t.chmod=void 0;const c=o(r(5747));const u=o(r(5622));a=c.promises,t.chmod=a.chmod,t.copyFile=a.copyFile,t.lstat=a.lstat,t.mkdir=a.mkdir,t.readdir=a.readdir,t.readlink=a.readlink,t.rename=a.rename,t.rmdir=a.rmdir,t.stat=a.stat,t.symlink=a.symlink,t.unlink=a.unlink;t.IS_WINDOWS=process.platform==="win32";function exists(e){return i(this,void 0,void 0,function*(){try{yield t.stat(e)}catch(e){if(e.code==="ENOENT"){return false}throw e}return true})}t.exists=exists;function isDirectory(e,r=false){return i(this,void 0,void 0,function*(){const s=r?yield t.stat(e):yield t.lstat(e);return s.isDirectory()})}t.isDirectory=isDirectory;function isRooted(e){e=normalizeSeparators(e);if(!e){throw new Error('isRooted() parameter "p" cannot be empty')}if(t.IS_WINDOWS){return e.startsWith("\\")||/^[A-Z]:/i.test(e)}return e.startsWith("/")}t.isRooted=isRooted;function tryGetExecutablePath(e,r){return i(this,void 0,void 0,function*(){let s=undefined;try{s=yield t.stat(e)}catch(t){if(t.code!=="ENOENT"){console.log(`Unexpected error attempting to determine if executable file exists '${e}': ${t}`)}}if(s&&s.isFile()){if(t.IS_WINDOWS){const t=u.extname(e).toUpperCase();if(r.some(e=>e.toUpperCase()===t)){return e}}else{if(isUnixExecutable(s)){return e}}}const n=e;for(const o of r){e=n+o;s=undefined;try{s=yield t.stat(e)}catch(t){if(t.code!=="ENOENT"){console.log(`Unexpected error attempting to determine if executable file exists '${e}': ${t}`)}}if(s&&s.isFile()){if(t.IS_WINDOWS){try{const r=u.dirname(e);const s=u.basename(e).toUpperCase();for(const n of yield t.readdir(r)){if(s===n.toUpperCase()){e=u.join(r,n);break}}}catch(t){console.log(`Unexpected error attempting to determine the actual case of the file '${e}': ${t}`)}return e}else{if(isUnixExecutable(s)){return e}}}}return""})}t.tryGetExecutablePath=tryGetExecutablePath;function normalizeSeparators(e){e=e||"";if(t.IS_WINDOWS){e=e.replace(/\//g,"\\");return e.replace(/\\\\+/g,"\\")}return e.replace(/\/\/+/g,"/")}function isUnixExecutable(e){return(e.mode&1)>0||(e.mode&8)>0&&e.gid===process.getgid()||(e.mode&64)>0&&e.uid===process.getuid()}function getCmdPath(){var e;return(e=process.env["COMSPEC"])!==null&&e!==void 0?e:`cmd.exe`}t.getCmdPath=getCmdPath},7436:function(e,t,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,t,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,s){if(s===undefined)s=r;e[s]=t[r]});var n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))s(t,e,r);n(t,e);return t};var i=this&&this.__awaiter||function(e,t,r,s){function adopt(e){return e instanceof r?e:new r(function(t){t(e)})}return new(r||(r=Promise))(function(r,n){function fulfilled(e){try{step(s.next(e))}catch(e){n(e)}}function rejected(e){try{step(s["throw"](e))}catch(e){n(e)}}function step(e){e.done?r(e.value):adopt(e.value).then(fulfilled,rejected)}step((s=s.apply(e,t||[])).next())})};Object.defineProperty(t,"__esModule",{value:true});t.findInPath=t.which=t.mkdirP=t.rmRF=t.mv=t.cp=void 0;const a=r(2357);const c=o(r(3129));const u=o(r(5622));const l=r(1669);const f=o(r(1962));const p=l.promisify(c.exec);const d=l.promisify(c.execFile);function cp(e,t,r={}){return i(this,void 0,void 0,function*(){const{force:s,recursive:n,copySourceDirectory:o}=readCopyOptions(r);const i=(yield f.exists(t))?yield f.stat(t):null;if(i&&i.isFile()&&!s){return}const a=i&&i.isDirectory()&&o?u.join(t,u.basename(e)):t;if(!(yield f.exists(e))){throw new Error(`no such file or directory: ${e}`)}const c=yield f.stat(e);if(c.isDirectory()){if(!n){throw new Error(`Failed to copy. ${e} is a directory, but tried to copy without recursive flag.`)}else{yield cpDirRecursive(e,a,0,s)}}else{if(u.relative(e,a)===""){throw new Error(`'${a}' and '${e}' are the same file`)}yield copyFile(e,a,s)}})}t.cp=cp;function mv(e,t,r={}){return i(this,void 0,void 0,function*(){if(yield f.exists(t)){let s=true;if(yield f.isDirectory(t)){t=u.join(t,u.basename(e));s=yield f.exists(t)}if(s){if(r.force==null||r.force){yield rmRF(t)}else{throw new Error("Destination already exists")}}}yield mkdirP(u.dirname(t));yield f.rename(e,t)})}t.mv=mv;function rmRF(e){return i(this,void 0,void 0,function*(){if(f.IS_WINDOWS){if(/[*"<>|]/.test(e)){throw new Error('File path must not contain `*`, `"`, `<`, `>` or `|` on Windows')}try{const t=f.getCmdPath();if(yield f.isDirectory(e,true)){yield p(`${t} /s /c "rd /s /q "%inputPath%""`,{env:{inputPath:e}})}else{yield p(`${t} /s /c "del /f /a "%inputPath%""`,{env:{inputPath:e}})}}catch(e){if(e.code!=="ENOENT")throw e}try{yield f.unlink(e)}catch(e){if(e.code!=="ENOENT")throw e}}else{let t=false;try{t=yield f.isDirectory(e)}catch(e){if(e.code!=="ENOENT")throw e;return}if(t){yield d(`rm`,[`-rf`,`${e}`])}else{yield f.unlink(e)}}})}t.rmRF=rmRF;function mkdirP(e){return i(this,void 0,void 0,function*(){a.ok(e,"a path argument must be provided");yield f.mkdir(e,{recursive:true})})}t.mkdirP=mkdirP;function which(e,t){return i(this,void 0,void 0,function*(){if(!e){throw new Error("parameter 'tool' is required")}if(t){const t=yield which(e,false);if(!t){if(f.IS_WINDOWS){throw new Error(`Unable to locate executable file: ${e}. Please verify either the file path exists or the file can be found within a directory specified by the PATH environment variable. Also verify the file has a valid extension for an executable file.`)}else{throw new Error(`Unable to locate executable file: ${e}. Please verify either the file path exists or the file can be found within a directory specified by the PATH environment variable. Also check the file mode to verify the file is executable.`)}}return t}const r=yield findInPath(e);if(r&&r.length>0){return r[0]}return""})}t.which=which;function findInPath(e){return i(this,void 0,void 0,function*(){if(!e){throw new Error("parameter 'tool' is required")}const t=[];if(f.IS_WINDOWS&&process.env["PATHEXT"]){for(const e of process.env["PATHEXT"].split(u.delimiter)){if(e){t.push(e)}}}if(f.isRooted(e)){const r=yield f.tryGetExecutablePath(e,t);if(r){return[r]}return[]}if(e.includes(u.sep)){return[]}const r=[];if(process.env.PATH){for(const e of process.env.PATH.split(u.delimiter)){if(e){r.push(e)}}}const s=[];for(const n of r){const r=yield f.tryGetExecutablePath(u.join(n,e),t);if(r){s.push(r)}}return s})}t.findInPath=findInPath;function readCopyOptions(e){const t=e.force==null?true:e.force;const r=Boolean(e.recursive);const s=e.copySourceDirectory==null?true:Boolean(e.copySourceDirectory);return{force:t,recursive:r,copySourceDirectory:s}}function cpDirRecursive(e,t,r,s){return i(this,void 0,void 0,function*(){if(r>=255)return;r++;yield mkdirP(t);const n=yield f.readdir(e);for(const o of n){const n=`${e}/${o}`;const i=`${t}/${o}`;const a=yield f.lstat(n);if(a.isDirectory()){yield cpDirRecursive(n,i,r,s)}else{yield copyFile(n,i,s)}}yield f.chmod(t,(yield f.stat(e)).mode)})}function copyFile(e,t,r){return i(this,void 0,void 0,function*(){if((yield f.lstat(e)).isSymbolicLink()){try{yield f.lstat(t);yield f.unlink(t)}catch(e){if(e.code==="EPERM"){yield f.chmod(t,"0666");yield f.unlink(t)}}const r=yield f.readlink(e);yield f.symlink(r,t,f.IS_WINDOWS?"junction":null)}else if(!(yield f.exists(t))||r){yield f.copyFile(e,t)}})}},334:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});async function auth(e){const t=e.split(/\./).length===3?"app":/^v\d+\./.test(e)?"installation":"oauth";return{type:"token",token:e,tokenType:t}}function withAuthorizationPrefix(e){if(e.split(/\./).length===3){return`bearer ${e}`}return`token ${e}`}async function hook(e,t,r,s){const n=t.endpoint.merge(r,s);n.headers.authorization=withAuthorizationPrefix(e);return t(n)}const r=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)})};t.createTokenAuth=r},6762:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var s=r(5030);var n=r(3682);var o=r(6234);var i=r(8467);var a=r(334);function _objectWithoutPropertiesLoose(e,t){if(e==null)return{};var r={};var s=Object.keys(e);var n,o;for(o=0;o=0)continue;r[n]=e[n]}return r}function _objectWithoutProperties(e,t){if(e==null)return{};var r=_objectWithoutPropertiesLoose(e,t);var s,n;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(n=0;n=0)continue;if(!Object.prototype.propertyIsEnumerable.call(e,s))continue;r[s]=e[s]}}return r}const c="3.5.1";const u=["authStrategy"];class Octokit{constructor(e={}){const t=new n.Collection;const r={baseUrl:o.request.endpoint.DEFAULTS.baseUrl,headers:{},request:Object.assign({},e.request,{hook:t.bind(null,"request")}),mediaType:{previews:[],format:""}};r.headers["user-agent"]=[e.userAgent,`octokit-core.js/${c} ${s.getUserAgent()}`].filter(Boolean).join(" ");if(e.baseUrl){r.baseUrl=e.baseUrl}if(e.previews){r.mediaType.previews=e.previews}if(e.timeZone){r.headers["time-zone"]=e.timeZone}this.request=o.request.defaults(r);this.graphql=i.withCustomRequest(this.request).defaults(r);this.log=Object.assign({debug:()=>{},info:()=>{},warn:console.warn.bind(console),error:console.error.bind(console)},e.log);this.hook=t;if(!e.authStrategy){if(!e.auth){this.auth=(async()=>({type:"unauthenticated"}))}else{const r=a.createTokenAuth(e.auth);t.wrap("request",r.hook);this.auth=r}}else{const{authStrategy:r}=e,s=_objectWithoutProperties(e,u);const n=r(Object.assign({request:this.request,log:this.log,octokit:this,octokitOptions:s},e.auth));t.wrap("request",n.hook);this.auth=n}const l=this.constructor;l.plugins.forEach(t=>{Object.assign(this,t(this,e))})}static defaults(e){const t=class extends(this){constructor(...t){const r=t[0]||{};if(typeof e==="function"){super(e(r));return}super(Object.assign({},e,r,r.userAgent&&e.userAgent?{userAgent:`${r.userAgent} ${e.userAgent}`}:null))}};return t}static plugin(...e){var t;const r=this.plugins;const s=(t=class extends(this){},t.plugins=r.concat(e.filter(e=>!r.includes(e))),t);return s}}Octokit.VERSION=c;Octokit.plugins=[];t.Octokit=Octokit},9440:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var s=r(3287);var n=r(5030);function lowercaseKeys(e){if(!e){return{}}return Object.keys(e).reduce((t,r)=>{t[r.toLowerCase()]=e[r];return t},{})}function mergeDeep(e,t){const r=Object.assign({},e);Object.keys(t).forEach(n=>{if(s.isPlainObject(t[n])){if(!(n in e))Object.assign(r,{[n]:t[n]});else r[n]=mergeDeep(e[n],t[n])}else{Object.assign(r,{[n]:t[n]})}});return r}function removeUndefinedProperties(e){for(const t in e){if(e[t]===undefined){delete e[t]}}return e}function merge(e,t,r){if(typeof t==="string"){let[e,s]=t.split(" ");r=Object.assign(s?{method:e,url:s}:{url:e},r)}else{r=Object.assign({},t)}r.headers=lowercaseKeys(r.headers);removeUndefinedProperties(r);removeUndefinedProperties(r.headers);const s=mergeDeep(e||{},r);if(e&&e.mediaType.previews.length){s.mediaType.previews=e.mediaType.previews.filter(e=>!s.mediaType.previews.includes(e)).concat(s.mediaType.previews)}s.mediaType.previews=s.mediaType.previews.map(e=>e.replace(/-preview/,""));return s}function addQueryParameters(e,t){const r=/\?/.test(e)?"&":"?";const s=Object.keys(t);if(s.length===0){return e}return e+r+s.map(e=>{if(e==="q"){return"q="+t.q.split("+").map(encodeURIComponent).join("+")}return`${e}=${encodeURIComponent(t[e])}`}).join("&")}const o=/\{[^}]+\}/g;function removeNonChars(e){return e.replace(/^\W+|\W+$/g,"").split(/,/)}function extractUrlVariableNames(e){const t=e.match(o);if(!t){return[]}return t.map(removeNonChars).reduce((e,t)=>e.concat(t),[])}function omit(e,t){return Object.keys(e).filter(e=>!t.includes(e)).reduce((t,r)=>{t[r]=e[r];return t},{})}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,t,r){t=e==="+"||e==="#"?encodeReserved(t):encodeUnreserved(t);if(r){return encodeUnreserved(r)+"="+t}else{return t}}function isDefined(e){return e!==undefined&&e!==null}function isKeyOperator(e){return e===";"||e==="&"||e==="?"}function getValues(e,t,r,s){var n=e[r],o=[];if(isDefined(n)&&n!==""){if(typeof n==="string"||typeof n==="number"||typeof n==="boolean"){n=n.toString();if(s&&s!=="*"){n=n.substring(0,parseInt(s,10))}o.push(encodeValue(t,n,isKeyOperator(t)?r:""))}else{if(s==="*"){if(Array.isArray(n)){n.filter(isDefined).forEach(function(e){o.push(encodeValue(t,e,isKeyOperator(t)?r:""))})}else{Object.keys(n).forEach(function(e){if(isDefined(n[e])){o.push(encodeValue(t,n[e],e))}})}}else{const e=[];if(Array.isArray(n)){n.filter(isDefined).forEach(function(r){e.push(encodeValue(t,r))})}else{Object.keys(n).forEach(function(r){if(isDefined(n[r])){e.push(encodeUnreserved(r));e.push(encodeValue(t,n[r].toString()))}})}if(isKeyOperator(t)){o.push(encodeUnreserved(r)+"="+e.join(","))}else if(e.length!==0){o.push(e.join(","))}}}}else{if(t===";"){if(isDefined(n)){o.push(encodeUnreserved(r))}}else if(n===""&&(t==="&"||t==="?")){o.push(encodeUnreserved(r)+"=")}else if(n===""){o.push("")}}return o}function parseUrl(e){return{expand:expand.bind(null,e)}}function expand(e,t){var r=["+","#",".","/",";","?","&"];return e.replace(/\{([^\{\}]+)\}|([^\{\}]+)/g,function(e,s,n){if(s){let e="";const n=[];if(r.indexOf(s.charAt(0))!==-1){e=s.charAt(0);s=s.substr(1)}s.split(/,/g).forEach(function(r){var s=/([^:\*]*)(?::(\d+)|(\*))?/.exec(r);n.push(getValues(t,e,s[1],s[2]||s[3]))});if(e&&e!=="+"){var o=",";if(e==="?"){o="&"}else if(e!=="#"){o=e}return(n.length!==0?e:"")+n.join(o)}else{return n.join(",")}}else{return encodeReserved(n)}})}function parse(e){let t=e.method.toUpperCase();let r=(e.url||"/").replace(/:([a-z]\w+)/g,"{$1}");let s=Object.assign({},e.headers);let n;let o=omit(e,["method","baseUrl","url","headers","request","mediaType"]);const i=extractUrlVariableNames(r);r=parseUrl(r).expand(o);if(!/^http/.test(r)){r=e.baseUrl+r}const a=Object.keys(e).filter(e=>i.includes(e)).concat("baseUrl");const c=omit(o,a);const u=/application\/octet-stream/i.test(s.accept);if(!u){if(e.mediaType.format){s.accept=s.accept.split(/,/).map(t=>t.replace(/application\/vnd(\.\w+)(\.v3)?(\.\w+)?(\+json)?$/,`application/vnd$1$2.${e.mediaType.format}`)).join(",")}if(e.mediaType.previews.length){const t=s.accept.match(/[\w-]+(?=-preview)/g)||[];s.accept=t.concat(e.mediaType.previews).map(t=>{const r=e.mediaType.format?`.${e.mediaType.format}`:"+json";return`application/vnd.github.${t}-preview${r}`}).join(",")}}if(["GET","HEAD"].includes(t)){r=addQueryParameters(r,c)}else{if("data"in c){n=c.data}else{if(Object.keys(c).length){n=c}else{s["content-length"]=0}}}if(!s["content-type"]&&typeof n!=="undefined"){s["content-type"]="application/json; charset=utf-8"}if(["PATCH","PUT"].includes(t)&&typeof n==="undefined"){n=""}return Object.assign({method:t,url:r,headers:s},typeof n!=="undefined"?{body:n}:null,e.request?{request:e.request}:null)}function endpointWithDefaults(e,t,r){return parse(merge(e,t,r))}function withDefaults(e,t){const r=merge(e,t);const s=endpointWithDefaults.bind(null,r);return Object.assign(s,{DEFAULTS:r,defaults:withDefaults.bind(null,r),merge:merge.bind(null,r),parse:parse})}const i="6.0.12";const a=`octokit-endpoint.js/${i} ${n.getUserAgent()}`;const c={method:"GET",baseUrl:"https://api.github.com",headers:{accept:"application/vnd.github.v3+json","user-agent":a},mediaType:{format:"",previews:[]}};const u=withDefaults(null,c);t.endpoint=u},8467:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var s=r(6234);var n=r(5030);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,t,r){super(_buildMessageForResponseErrors(r));this.request=e;this.headers=t;this.response=r;this.name="GraphqlResponseError";this.errors=r.errors;this.data=r.data;if(Error.captureStackTrace){Error.captureStackTrace(this,this.constructor)}}}const i=["method","baseUrl","url","headers","request","query","mediaType"];const a=["query","method","url"];const c=/\/api\/v3\/?$/;function graphql(e,t,r){if(r){if(typeof t==="string"&&"query"in r){return Promise.reject(new Error(`[@octokit/graphql] "query" cannot be used as variable name`))}for(const e in r){if(!a.includes(e))continue;return Promise.reject(new Error(`[@octokit/graphql] "${e}" cannot be used as variable name`))}}const s=typeof t==="string"?Object.assign({query:t},r):t;const n=Object.keys(s).reduce((e,t)=>{if(i.includes(t)){e[t]=s[t];return e}if(!e.variables){e.variables={}}e.variables[t]=s[t];return e},{});const o=s.baseUrl||e.endpoint.DEFAULTS.baseUrl;if(c.test(o)){n.url=o.replace(c,"/api/graphql")}return e(n).then(e=>{if(e.data.errors){const t={};for(const r of Object.keys(e.headers)){t[r]=e.headers[r]}throw new GraphqlResponseError(n,t,e.data)}return e.data.data})}function withDefaults(e,t){const r=e.defaults(t);const n=(e,t)=>{return graphql(r,e,t)};return Object.assign(n,{defaults:withDefaults.bind(null,r),endpoint:s.request.endpoint})}const u=withDefaults(s.request,{headers:{"user-agent":`octokit-graphql.js/${o} ${n.getUserAgent()}`},method:"POST",url:"/graphql"});function withCustomRequest(e){return withDefaults(e,{method:"POST",url:"/graphql"})}t.GraphqlResponseError=GraphqlResponseError;t.graphql=u;t.withCustomRequest=withCustomRequest},4193:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const r="2.16.0";function ownKeys(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(e);if(t){s=s.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})}r.push.apply(r,s)}return r}function _objectSpread2(e){for(var t=1;t({async next(){if(!a)return{done:true};try{const e=await n({method:o,url:a,headers:i});const t=normalizePaginatedListResponse(e);a=((t.headers.link||"").match(/<([^>]+)>;\s*rel="next"/)||[])[1];return{value:t}}catch(e){if(e.status!==409)throw e;a="";return{value:{status:200,headers:{},data:[]}}}}})}}function paginate(e,t,r,s){if(typeof r==="function"){s=r;r=undefined}return gather(e,[],iterator(e,t,r)[Symbol.asyncIterator](),s)}function gather(e,t,r,s){return r.next().then(n=>{if(n.done){return t}let o=false;function done(){o=true}t=t.concat(s?s(n.value,done):n.value.data);if(o){return t}return gather(e,t,r,s)})}const s=Object.assign(paginate,{iterator:iterator});const n=["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}/actions/runners/downloads","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 /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/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/runners/downloads","GET /orgs/{org}/actions/secrets","GET /orgs/{org}/actions/secrets/{secret_name}/repositories","GET /orgs/{org}/blocks","GET /orgs/{org}/credential-authorizations","GET /orgs/{org}/events","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}/projects","GET /orgs/{org}/public_members","GET /orgs/{org}/repos","GET /orgs/{org}/secret-scanning/alerts","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}/team-sync/group-mappings","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/runners","GET /repos/{owner}/{repo}/actions/runners/downloads","GET /repos/{owner}/{repo}/actions/runs","GET /repos/{owner}/{repo}/actions/runs/{run_id}/artifacts","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}/autolinks","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}/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}/branches-where-head","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}/statuses","GET /repos/{owner}/{repo}/contributors","GET /repos/{owner}/{repo}/deployments","GET /repos/{owner}/{repo}/deployments/{deployment_id}/statuses","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}/secret-scanning/alerts","GET /repos/{owner}/{repo}/stargazers","GET /repos/{owner}/{repo}/subscribers","GET /repos/{owner}/{repo}/tags","GET /repos/{owner}/{repo}/teams","GET /repositories","GET /repositories/{repository_id}/environments/{environment_name}/secrets","GET /scim/v2/enterprises/{enterprise}/Groups","GET /scim/v2/enterprises/{enterprise}/Users","GET /scim/v2/organizations/{org}/Users","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}/team-sync/group-mappings","GET /teams/{team_id}/teams","GET /user/blocks","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/public_emails","GET /user/repos","GET /user/repository_invitations","GET /user/starred","GET /user/subscriptions","GET /user/teams","GET /user/{username}/packages","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}/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 n.includes(e)}else{return false}}function paginateRest(e){return{paginate:Object.assign(paginate.bind(null,e),{iterator:iterator.bind(null,e)})}}paginateRest.VERSION=r;t.composePaginateRest=s;t.isPaginatingEndpoint=isPaginatingEndpoint;t.paginateRest=paginateRest;t.paginatingEndpoints=n},3044:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});function ownKeys(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(e);if(t){s=s.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})}r.push.apply(r,s)}return r}function _objectSpread2(e){for(var t=1;t{"use strict";Object.defineProperty(t,"__esModule",{value:true});function _interopDefault(e){return e&&typeof e==="object"&&"default"in e?e["default"]:e}var s=r(8932);var n=_interopDefault(r(1223));const o=n(e=>console.warn(e));const i=n(e=>console.warn(e));class RequestError extends Error{constructor(e,t,r){super(e);if(Error.captureStackTrace){Error.captureStackTrace(this,this.constructor)}this.name="HttpError";this.status=t;let n;if("headers"in r&&typeof r.headers!=="undefined"){n=r.headers}if("response"in r){this.response=r.response;n=r.response.headers}const a=Object.assign({},r.request);if(r.request.headers.authorization){a.headers=Object.assign({},r.request.headers,{authorization:r.request.headers.authorization.replace(/ .*$/," [REDACTED]")})}a.url=a.url.replace(/\bclient_secret=\w+/g,"client_secret=[REDACTED]").replace(/\baccess_token=\w+/g,"access_token=[REDACTED]");this.request=a;Object.defineProperty(this,"code",{get(){o(new s.Deprecation("[@octokit/request-error] `error.code` is deprecated, use `error.status`."));return t}});Object.defineProperty(this,"headers",{get(){i(new s.Deprecation("[@octokit/request-error] `error.headers` is deprecated, use `error.response.headers`."));return n||{}}})}}t.RequestError=RequestError},6234:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});function _interopDefault(e){return e&&typeof e==="object"&&"default"in e?e["default"]:e}var s=r(9440);var n=r(5030);var o=r(3287);var i=_interopDefault(r(467));var a=r(537);const c="5.6.1";function getBufferResponse(e){return e.arrayBuffer()}function fetchWrapper(e){const t=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 r={};let s;let n;const c=e.request&&e.request.fetch||i;return c(e.url,Object.assign({method:e.method,body:e.body,headers:e.headers,redirect:e.redirect},e.request)).then(async o=>{n=o.url;s=o.status;for(const e of o.headers){r[e[0]]=e[1]}if("deprecation"in r){const s=r.link&&r.link.match(/<([^>]+)>; rel="deprecation"/);const n=s&&s.pop();t.warn(`[@octokit/request] "${e.method} ${e.url}" is deprecated. It is scheduled to be removed on ${r.sunset}${n?`. See ${n}`:""}`)}if(s===204||s===205){return}if(e.method==="HEAD"){if(s<400){return}throw new a.RequestError(o.statusText,s,{response:{url:n,status:s,headers:r,data:undefined},request:e})}if(s===304){throw new a.RequestError("Not modified",s,{response:{url:n,status:s,headers:r,data:await getResponseData(o)},request:e})}if(s>=400){const t=await getResponseData(o);const i=new a.RequestError(toErrorMessage(t),s,{response:{url:n,status:s,headers:r,data:t},request:e});throw i}return getResponseData(o)}).then(e=>{return{status:s,url:n,headers:r,data:e}}).catch(t=>{if(t instanceof a.RequestError)throw t;throw new a.RequestError(t.message,500,{request:e})})}async function getResponseData(e){const t=e.headers.get("content-type");if(/application\/json/.test(t)){return e.json()}if(!t||/^text\/|charset=utf-8$/.test(t)){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,t){const r=e.defaults(t);const s=function(e,t){const s=r.merge(e,t);if(!s.request||!s.request.hook){return fetchWrapper(r.parse(s))}const n=(e,t)=>{return fetchWrapper(r.parse(r.merge(e,t)))};Object.assign(n,{endpoint:r,defaults:withDefaults.bind(null,r)});return s.request.hook(n,s)};return Object.assign(s,{endpoint:r,defaults:withDefaults.bind(null,r)})}const u=withDefaults(s.endpoint,{headers:{"user-agent":`octokit-request.js/${c} ${n.getUserAgent()}`}});t.request=u},9417:e=>{"use strict";e.exports=balanced;function balanced(e,t,r){if(e instanceof RegExp)e=maybeMatch(e,r);if(t instanceof RegExp)t=maybeMatch(t,r);var s=range(e,t,r);return s&&{start:s[0],end:s[1],pre:r.slice(0,s[0]),body:r.slice(s[0]+e.length,s[1]),post:r.slice(s[1]+t.length)}}function maybeMatch(e,t){var r=t.match(e);return r?r[0]:null}balanced.range=range;function range(e,t,r){var s,n,o,i,a;var c=r.indexOf(e);var u=r.indexOf(t,c+1);var l=c;if(c>=0&&u>0){s=[];o=r.length;while(l>=0&&!a){if(l==c){s.push(l);c=r.indexOf(e,l+1)}else if(s.length==1){a=[s.pop(),u]}else{n=s.pop();if(n=0?c:u}if(s.length){a=[o,i]}}return a}},3682:(e,t,r)=>{var s=r(4670);var n=r(5549);var o=r(6819);var i=Function.bind;var a=i.bind(i);function bindApi(e,t,r){var s=a(o,null).apply(null,r?[t,r]:[t]);e.api={remove:s};e.remove=s;["before","error","after","wrap"].forEach(function(s){var o=r?[t,s,r]:[t,s];e[s]=e.api[s]=a(n,null).apply(null,o)})}function HookSingular(){var e="h";var t={registry:{}};var r=s.bind(null,t,e);bindApi(r,t,e);return r}function HookCollection(){var e={registry:{}};var t=s.bind(null,e);bindApi(t,e);return t}var c=false;function Hook(){if(!c){console.warn('[before-after-hook]: "Hook()" repurposing warning, use "Hook.Collection()". Read more: https://git.io/upgrade-before-after-hook-to-1.4');c=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},5549:e=>{e.exports=addHook;function addHook(e,t,r,s){var n=s;if(!e.registry[r]){e.registry[r]=[]}if(t==="before"){s=function(e,t){return Promise.resolve().then(n.bind(null,t)).then(e.bind(null,t))}}if(t==="after"){s=function(e,t){var r;return Promise.resolve().then(e.bind(null,t)).then(function(e){r=e;return n(r,t)}).then(function(){return r})}}if(t==="error"){s=function(e,t){return Promise.resolve().then(e.bind(null,t)).catch(function(e){return n(e,t)})}}e.registry[r].push({hook:s,orig:n})}},4670:e=>{e.exports=register;function register(e,t,r,s){if(typeof r!=="function"){throw new Error("method for before hook must be a function")}if(!s){s={}}if(Array.isArray(t)){return t.reverse().reduce(function(t,r){return register.bind(null,e,r,t,s)},r)()}return Promise.resolve().then(function(){if(!e.registry[t]){return r(s)}return e.registry[t].reduce(function(e,t){return t.hook.bind(null,e,s)},r)()})}},6819:e=>{e.exports=removeHook;function removeHook(e,t,r){if(!e.registry[t]){return}var s=e.registry[t].map(function(e){return e.orig}).indexOf(r);if(s===-1){return}e.registry[t].splice(s,1)}},3717:(e,t,r)=>{var s=r(6891);var n=r(9417);e.exports=expandTop;var o="\0SLASH"+Math.random()+"\0";var i="\0OPEN"+Math.random()+"\0";var a="\0CLOSE"+Math.random()+"\0";var c="\0COMMA"+Math.random()+"\0";var u="\0PERIOD"+Math.random()+"\0";function numeric(e){return parseInt(e,10)==e?parseInt(e,10):e.charCodeAt(0)}function escapeBraces(e){return e.split("\\\\").join(o).split("\\{").join(i).split("\\}").join(a).split("\\,").join(c).split("\\.").join(u)}function unescapeBraces(e){return e.split(o).join("\\").split(i).join("{").split(a).join("}").split(c).join(",").split(u).join(".")}function parseCommaParts(e){if(!e)return[""];var t=[];var r=n("{","}",e);if(!r)return e.split(",");var s=r.pre;var o=r.body;var i=r.post;var a=s.split(",");a[a.length-1]+="{"+o+"}";var c=parseCommaParts(i);if(i.length){a[a.length-1]+=c.shift();a.push.apply(a,c)}t.push.apply(t,a);return t}function expandTop(e){if(!e)return[];if(e.substr(0,2)==="{}"){e="\\{\\}"+e.substr(2)}return expand(escapeBraces(e),true).map(unescapeBraces)}function identity(e){return e}function embrace(e){return"{"+e+"}"}function isPadded(e){return/^-?0\d/.test(e)}function lte(e,t){return e<=t}function gte(e,t){return e>=t}function expand(e,t){var r=[];var o=n("{","}",e);if(!o||/\$$/.test(o.pre))return[e];var i=/^-?\d+\.\.-?\d+(?:\.\.-?\d+)?$/.test(o.body);var c=/^[a-zA-Z]\.\.[a-zA-Z](?:\.\.-?\d+)?$/.test(o.body);var u=i||c;var l=o.body.indexOf(",")>=0;if(!u&&!l){if(o.post.match(/,.*\}/)){e=o.pre+"{"+o.body+a+o.post;return expand(e)}return[e]}var f;if(u){f=o.body.split(/\.\./)}else{f=parseCommaParts(o.body);if(f.length===1){f=expand(f[0],false).map(embrace);if(f.length===1){var p=o.post.length?expand(o.post,false):[""];return p.map(function(e){return o.pre+f[0]+e})}}}var d=o.pre;var p=o.post.length?expand(o.post,false):[""];var h;if(u){var g=numeric(f[0]);var m=numeric(f[1]);var y=Math.max(f[0].length,f[1].length);var v=f.length==3?Math.abs(numeric(f[2])):1;var b=lte;var w=m0){var S=new Array(O+1).join("0");if(T<0)_="-"+S+_.slice(1);else _=S+_}}}h.push(_)}}else{h=s(f,function(e){return expand(e,false)})}for(var G=0;G{e.exports=function(e,r){var s=[];for(var n=0;n{"use strict";Object.defineProperty(t,"__esModule",{value:true});class Deprecation extends Error{constructor(e){super(e);if(Error.captureStackTrace){Error.captureStackTrace(this,this.constructor)}this.name="Deprecation"}}t.Deprecation=Deprecation},6863:(e,t,r)=>{e.exports=realpath;realpath.realpath=realpath;realpath.sync=realpathSync;realpath.realpathSync=realpathSync;realpath.monkeypatch=monkeypatch;realpath.unmonkeypatch=unmonkeypatch;var s=r(5747);var n=s.realpath;var o=s.realpathSync;var i=process.version;var a=/^v[0-5]\./.test(i);var c=r(1734);function newError(e){return e&&e.syscall==="realpath"&&(e.code==="ELOOP"||e.code==="ENOMEM"||e.code==="ENAMETOOLONG")}function realpath(e,t,r){if(a){return n(e,t,r)}if(typeof t==="function"){r=t;t=null}n(e,t,function(s,n){if(newError(s)){c.realpath(e,t,r)}else{r(s,n)}})}function realpathSync(e,t){if(a){return o(e,t)}try{return o(e,t)}catch(r){if(newError(r)){return c.realpathSync(e,t)}else{throw r}}}function monkeypatch(){s.realpath=realpath;s.realpathSync=realpathSync}function unmonkeypatch(){s.realpath=n;s.realpathSync=o}},1734:(e,t,r)=>{var s=r(5622);var n=process.platform==="win32";var o=r(5747);var i=process.env.NODE_DEBUG&&/fs/.test(process.env.NODE_DEBUG);function rethrow(){var e;if(i){var t=new Error;e=debugCallback}else e=missingCallback;return e;function debugCallback(e){if(e){t.message=e.message;e=t;missingCallback(e)}}function missingCallback(e){if(e){if(process.throwDeprecation)throw e;else if(!process.noDeprecation){var t="fs: missing callback "+(e.stack||e.message);if(process.traceDeprecation)console.trace(t);else console.error(t)}}}}function maybeCallback(e){return typeof e==="function"?e:rethrow()}var a=s.normalize;if(n){var c=/(.*?)(?:[\/\\]+|$)/g}else{var c=/(.*?)(?:[\/]+|$)/g}if(n){var u=/^(?:[a-zA-Z]:|[\\\/]{2}[^\\\/]+[\\\/][^\\\/]+)?[\\\/]*/}else{var u=/^[\/]*/}t.realpathSync=function realpathSync(e,t){e=s.resolve(e);if(t&&Object.prototype.hasOwnProperty.call(t,e)){return t[e]}var r=e,i={},a={};var l;var f;var p;var d;start();function start(){var t=u.exec(e);l=t[0].length;f=t[0];p=t[0];d="";if(n&&!a[p]){o.lstatSync(p);a[p]=true}}while(l=e.length){if(t)t[i]=e;return r(null,e)}c.lastIndex=f;var s=c.exec(e);h=p;p+=s[0];d=h+s[1];f=c.lastIndex;if(l[d]||t&&t[d]===d){return process.nextTick(LOOP)}if(t&&Object.prototype.hasOwnProperty.call(t,d)){return gotResolvedLink(t[d])}return o.lstat(d,gotStat)}function gotStat(e,s){if(e)return r(e);if(!s.isSymbolicLink()){l[d]=true;if(t)t[d]=d;return process.nextTick(LOOP)}if(!n){var i=s.dev.toString(32)+":"+s.ino.toString(32);if(a.hasOwnProperty(i)){return gotTarget(null,a[i],d)}}o.stat(d,function(e){if(e)return r(e);o.readlink(d,function(e,t){if(!n)a[i]=t;gotTarget(e,t)})})}function gotTarget(e,n,o){if(e)return r(e);var i=s.resolve(h,n);if(t)t[o]=i;gotResolvedLink(i)}function gotResolvedLink(t){e=s.resolve(t,e.slice(f));start()}}},7625:(e,t,r)=>{t.alphasort=alphasort;t.alphasorti=alphasorti;t.setopts=setopts;t.ownProp=ownProp;t.makeAbs=makeAbs;t.finish=finish;t.mark=mark;t.isIgnored=isIgnored;t.childrenIgnored=childrenIgnored;function ownProp(e,t){return Object.prototype.hasOwnProperty.call(e,t)}var s=r(5622);var n=r(3973);var o=r(8714);var i=n.Minimatch;function alphasorti(e,t){return e.toLowerCase().localeCompare(t.toLowerCase())}function alphasort(e,t){return e.localeCompare(t)}function setupIgnores(e,t){e.ignore=t.ignore||[];if(!Array.isArray(e.ignore))e.ignore=[e.ignore];if(e.ignore.length){e.ignore=e.ignore.map(ignoreMap)}}function ignoreMap(e){var t=null;if(e.slice(-3)==="/**"){var r=e.replace(/(\/\*\*)+$/,"");t=new i(r,{dot:true})}return{matcher:new i(e,{dot:true}),gmatcher:t}}function setopts(e,t,r){if(!r)r={};if(r.matchBase&&-1===t.indexOf("/")){if(r.noglobstar){throw new Error("base matching requires globstar")}t="**/"+t}e.silent=!!r.silent;e.pattern=t;e.strict=r.strict!==false;e.realpath=!!r.realpath;e.realpathCache=r.realpathCache||Object.create(null);e.follow=!!r.follow;e.dot=!!r.dot;e.mark=!!r.mark;e.nodir=!!r.nodir;if(e.nodir)e.mark=true;e.sync=!!r.sync;e.nounique=!!r.nounique;e.nonull=!!r.nonull;e.nosort=!!r.nosort;e.nocase=!!r.nocase;e.stat=!!r.stat;e.noprocess=!!r.noprocess;e.absolute=!!r.absolute;e.maxLength=r.maxLength||Infinity;e.cache=r.cache||Object.create(null);e.statCache=r.statCache||Object.create(null);e.symlinks=r.symlinks||Object.create(null);setupIgnores(e,r);e.changedCwd=false;var n=process.cwd();if(!ownProp(r,"cwd"))e.cwd=n;else{e.cwd=s.resolve(r.cwd);e.changedCwd=e.cwd!==n}e.root=r.root||s.resolve(e.cwd,"/");e.root=s.resolve(e.root);if(process.platform==="win32")e.root=e.root.replace(/\\/g,"/");e.cwdAbs=o(e.cwd)?e.cwd:makeAbs(e,e.cwd);if(process.platform==="win32")e.cwdAbs=e.cwdAbs.replace(/\\/g,"/");e.nomount=!!r.nomount;r.nonegate=true;r.nocomment=true;e.minimatch=new i(t,r);e.options=e.minimatch.options}function finish(e){var t=e.nounique;var r=t?[]:Object.create(null);for(var s=0,n=e.matches.length;s{e.exports=glob;var s=r(5747);var n=r(6863);var o=r(3973);var i=o.Minimatch;var a=r(4124);var c=r(8614).EventEmitter;var u=r(5622);var l=r(2357);var f=r(8714);var p=r(9010);var d=r(7625);var h=d.alphasort;var g=d.alphasorti;var m=d.setopts;var y=d.ownProp;var v=r(2492);var b=r(1669);var w=d.childrenIgnored;var E=d.isIgnored;var T=r(1223);function glob(e,t,r){if(typeof t==="function")r=t,t={};if(!t)t={};if(t.sync){if(r)throw new TypeError("callback provided to sync glob");return p(e,t)}return new Glob(e,t,r)}glob.sync=p;var _=glob.GlobSync=p.GlobSync;glob.glob=glob;function extend(e,t){if(t===null||typeof t!=="object"){return e}var r=Object.keys(t);var s=r.length;while(s--){e[r[s]]=t[r[s]]}return e}glob.hasMagic=function(e,t){var r=extend({},t);r.noprocess=true;var s=new Glob(e,r);var n=s.minimatch.set;if(!e)return false;if(n.length>1)return true;for(var o=0;othis.maxLength)return t();if(!this.stat&&y(this.cache,r)){var o=this.cache[r];if(Array.isArray(o))o="DIR";if(!n||o==="DIR")return t(null,o);if(n&&o==="FILE")return t()}var i;var a=this.statCache[r];if(a!==undefined){if(a===false)return t(null,a);else{var c=a.isDirectory()?"DIR":"FILE";if(n&&c==="FILE")return t();else return t(null,c,a)}}var u=this;var l=v("stat\0"+r,lstatcb_);if(l)s.lstat(r,l);function lstatcb_(n,o){if(o&&o.isSymbolicLink()){return s.stat(r,function(s,n){if(s)u._stat2(e,r,null,o,t);else u._stat2(e,r,s,n,t)})}else{u._stat2(e,r,n,o,t)}}};Glob.prototype._stat2=function(e,t,r,s,n){if(r&&(r.code==="ENOENT"||r.code==="ENOTDIR")){this.statCache[t]=false;return n()}var o=e.slice(-1)==="/";this.statCache[t]=s;if(t.slice(-1)==="/"&&s&&!s.isDirectory())return n(null,false,s);var i=true;if(s)i=s.isDirectory()?"DIR":"FILE";this.cache[t]=this.cache[t]||i;if(o&&i==="FILE")return n();return n(null,i,s)}},9010:(e,t,r)=>{e.exports=globSync;globSync.GlobSync=GlobSync;var s=r(5747);var n=r(6863);var o=r(3973);var i=o.Minimatch;var a=r(1957).Glob;var c=r(1669);var u=r(5622);var l=r(2357);var f=r(8714);var p=r(7625);var d=p.alphasort;var h=p.alphasorti;var g=p.setopts;var m=p.ownProp;var y=p.childrenIgnored;var v=p.isIgnored;function globSync(e,t){if(typeof t==="function"||arguments.length===3)throw new TypeError("callback provided to sync glob\n"+"See: https://github.com/isaacs/node-glob/issues/167");return new GlobSync(e,t).found}function GlobSync(e,t){if(!e)throw new Error("must provide pattern");if(typeof t==="function"||arguments.length===3)throw new TypeError("callback provided to sync glob\n"+"See: https://github.com/isaacs/node-glob/issues/167");if(!(this instanceof GlobSync))return new GlobSync(e,t);g(this,e,t);if(this.noprocess)return this;var r=this.minimatch.set.length;this.matches=new Array(r);for(var s=0;sthis.maxLength)return false;if(!this.stat&&m(this.cache,t)){var n=this.cache[t];if(Array.isArray(n))n="DIR";if(!r||n==="DIR")return n;if(r&&n==="FILE")return false}var o;var i=this.statCache[t];if(!i){var a;try{a=s.lstatSync(t)}catch(e){if(e&&(e.code==="ENOENT"||e.code==="ENOTDIR")){this.statCache[t]=false;return false}}if(a&&a.isSymbolicLink()){try{i=s.statSync(t)}catch(e){i=a}}else{i=a}}this.statCache[t]=i;var n=true;if(i)n=i.isDirectory()?"DIR":"FILE";this.cache[t]=this.cache[t]||n;if(r&&n==="FILE")return false;return n};GlobSync.prototype._mark=function(e){return p.mark(this,e)};GlobSync.prototype._makeAbs=function(e){return p.makeAbs(this,e)}},2492:(e,t,r)=>{var s=r(2940);var n=Object.create(null);var o=r(1223);e.exports=s(inflight);function inflight(e,t){if(n[e]){n[e].push(t);return null}else{n[e]=[t];return makeres(e)}}function makeres(e){return o(function RES(){var t=n[e];var r=t.length;var s=slice(arguments);try{for(var o=0;or){t.splice(0,r);process.nextTick(function(){RES.apply(null,s)})}else{delete n[e]}}})}function slice(e){var t=e.length;var r=[];for(var s=0;s{try{var s=r(1669);if(typeof s.inherits!=="function")throw"";e.exports=s.inherits}catch(t){e.exports=r(8544)}},8544:e=>{if(typeof Object.create==="function"){e.exports=function inherits(e,t){if(t){e.super_=t;e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:false,writable:true,configurable:true}})}}}else{e.exports=function inherits(e,t){if(t){e.super_=t;var r=function(){};r.prototype=t.prototype;e.prototype=new r;e.prototype.constructor=e}}}},3287:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});function isObject(e){return Object.prototype.toString.call(e)==="[object Object]"}function isPlainObject(e){var t,r;if(isObject(e)===false)return false;t=e.constructor;if(t===undefined)return true;r=t.prototype;if(isObject(r)===false)return false;if(r.hasOwnProperty("isPrototypeOf")===false){return false}return true}t.isPlainObject=isPlainObject},3973:(e,t,r)=>{e.exports=minimatch;minimatch.Minimatch=Minimatch;var s={sep:"/"};try{s=r(5622)}catch(e){}var n=minimatch.GLOBSTAR=Minimatch.GLOBSTAR={};var o=r(3717);var i={"!":{open:"(?:(?!(?:",close:"))[^/]*?)"},"?":{open:"(?:",close:")?"},"+":{open:"(?:",close:")+"},"*":{open:"(?:",close:")*"},"@":{open:"(?:",close:")"}};var a="[^/]";var c=a+"*?";var u="(?:(?!(?:\\/|^)(?:\\.{1,2})($|\\/)).)*?";var l="(?:(?!(?:\\/|^)\\.).)*?";var f=charSet("().*{}+?[]^$\\!");function charSet(e){return e.split("").reduce(function(e,t){e[t]=true;return e},{})}var p=/\/+/;minimatch.filter=filter;function filter(e,t){t=t||{};return function(r,s,n){return minimatch(r,e,t)}}function ext(e,t){e=e||{};t=t||{};var r={};Object.keys(t).forEach(function(e){r[e]=t[e]});Object.keys(e).forEach(function(t){r[t]=e[t]});return r}minimatch.defaults=function(e){if(!e||!Object.keys(e).length)return minimatch;var t=minimatch;var r=function minimatch(r,s,n){return t.minimatch(r,s,ext(e,n))};r.Minimatch=function Minimatch(r,s){return new t.Minimatch(r,ext(e,s))};return r};Minimatch.defaults=function(e){if(!e||!Object.keys(e).length)return Minimatch;return minimatch.defaults(e).Minimatch};function minimatch(e,t,r){if(typeof t!=="string"){throw new TypeError("glob pattern string required")}if(!r)r={};if(!r.nocomment&&t.charAt(0)==="#"){return false}if(t.trim()==="")return e==="";return new Minimatch(t,r).match(e)}function Minimatch(e,t){if(!(this instanceof Minimatch)){return new Minimatch(e,t)}if(typeof e!=="string"){throw new TypeError("glob pattern string required")}if(!t)t={};e=e.trim();if(s.sep!=="/"){e=e.split(s.sep).join("/")}this.options=t;this.set=[];this.pattern=e;this.regexp=null;this.negate=false;this.comment=false;this.empty=false;this.make()}Minimatch.prototype.debug=function(){};Minimatch.prototype.make=make;function make(){if(this._made)return;var e=this.pattern;var t=this.options;if(!t.nocomment&&e.charAt(0)==="#"){this.comment=true;return}if(!e){this.empty=true;return}this.parseNegate();var r=this.globSet=this.braceExpand();if(t.debug)this.debug=console.error;this.debug(this.pattern,r);r=this.globParts=r.map(function(e){return e.split(p)});this.debug(this.pattern,r);r=r.map(function(e,t,r){return e.map(this.parse,this)},this);this.debug(this.pattern,r);r=r.filter(function(e){return e.indexOf(false)===-1});this.debug(this.pattern,r);this.set=r}Minimatch.prototype.parseNegate=parseNegate;function parseNegate(){var e=this.pattern;var t=false;var r=this.options;var s=0;if(r.nonegate)return;for(var n=0,o=e.length;n1024*64){throw new TypeError("pattern is too long")}var r=this.options;if(!r.noglobstar&&e==="**")return n;if(e==="")return"";var s="";var o=!!r.nocase;var u=false;var l=[];var p=[];var h;var g=false;var m=-1;var y=-1;var v=e.charAt(0)==="."?"":r.dot?"(?!(?:^|\\/)\\.{1,2}(?:$|\\/))":"(?!\\.)";var b=this;function clearStateChar(){if(h){switch(h){case"*":s+=c;o=true;break;case"?":s+=a;o=true;break;default:s+="\\"+h;break}b.debug("clearStateChar %j %j",h,s);h=false}}for(var w=0,E=e.length,T;w-1;C--){var j=p[C];var P=s.slice(0,j.reStart);var D=s.slice(j.reStart,j.reEnd-8);var F=s.slice(j.reEnd-8,j.reEnd);var R=s.slice(j.reEnd);F+=R;var x=P.split("(").length-1;var I=R;for(w=0;w=0;i--){o=e[i];if(o)break}for(i=0;i>> no match, partial?",e,f,t,p);if(f===a)return true}return false}var h;if(typeof u==="string"){if(s.nocase){h=l.toLowerCase()===u.toLowerCase()}else{h=l===u}this.debug("string match",u,l,h)}else{h=l.match(u);this.debug("pattern match",u,l,h)}if(!h)return false}if(o===a&&i===c){return true}else if(o===a){return r}else if(i===c){var g=o===a-1&&e[o]==="";return g}throw new Error("wtf?")};function globUnescape(e){return e.replace(/\\(.)/g,"$1")}function regExpEscape(e){return e.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&")}},467:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});function _interopDefault(e){return e&&typeof e==="object"&&"default"in e?e["default"]:e}var s=_interopDefault(r(2413));var n=_interopDefault(r(8605));var o=_interopDefault(r(8835));var i=_interopDefault(r(7211));var a=_interopDefault(r(8761));const c=s.Readable;const u=Symbol("buffer");const l=Symbol("type");class Blob{constructor(){this[l]="";const e=arguments[0];const t=arguments[1];const r=[];let s=0;if(e){const t=e;const n=Number(t.length);for(let e=0;e1&&arguments[1]!==undefined?arguments[1]:{},n=r.size;let o=n===undefined?0:n;var i=r.timeout;let a=i===undefined?0:i;if(e==null){e=null}else if(isURLSearchParams(e)){e=Buffer.from(e.toString())}else if(isBlob(e)) ;else if(Buffer.isBuffer(e)) ;else if(Object.prototype.toString.call(e)==="[object ArrayBuffer]"){e=Buffer.from(e)}else if(ArrayBuffer.isView(e)){e=Buffer.from(e.buffer,e.byteOffset,e.byteLength)}else if(e instanceof s) ;else{e=Buffer.from(String(e))}this[p]={body:e,disturbed:false,error:null};this.size=o;this.timeout=a;if(e instanceof s){e.on("error",function(e){const r=e.name==="AbortError"?e:new FetchError(`Invalid response body while trying to fetch ${t.url}: ${e.message}`,"system",e);t[p].error=r})}}Body.prototype={get body(){return this[p].body},get bodyUsed(){return this[p].disturbed},arrayBuffer(){return consumeBody.call(this).then(function(e){return e.buffer.slice(e.byteOffset,e.byteOffset+e.byteLength)})},blob(){let e=this.headers&&this.headers.get("content-type")||"";return consumeBody.call(this).then(function(t){return Object.assign(new Blob([],{type:e.toLowerCase()}),{[u]:t})})},json(){var e=this;return consumeBody.call(this).then(function(t){try{return JSON.parse(t.toString())}catch(t){return Body.Promise.reject(new FetchError(`invalid json response body at ${e.url} reason: ${t.message}`,"invalid-json"))}})},text(){return consumeBody.call(this).then(function(e){return e.toString()})},buffer(){return consumeBody.call(this)},textConverted(){var e=this;return consumeBody.call(this).then(function(t){return convertBody(t,e.headers)})}};Object.defineProperties(Body.prototype,{body:{enumerable:true},bodyUsed:{enumerable:true},arrayBuffer:{enumerable:true},blob:{enumerable:true},json:{enumerable:true},text:{enumerable:true}});Body.mixIn=function(e){for(const t of Object.getOwnPropertyNames(Body.prototype)){if(!(t in e)){const r=Object.getOwnPropertyDescriptor(Body.prototype,t);Object.defineProperty(e,t,r)}}};function consumeBody(){var e=this;if(this[p].disturbed){return Body.Promise.reject(new TypeError(`body used already for: ${this.url}`))}this[p].disturbed=true;if(this[p].error){return Body.Promise.reject(this[p].error)}let t=this.body;if(t===null){return Body.Promise.resolve(Buffer.alloc(0))}if(isBlob(t)){t=t.stream()}if(Buffer.isBuffer(t)){return Body.Promise.resolve(t)}if(!(t instanceof s)){return Body.Promise.resolve(Buffer.alloc(0))}let r=[];let n=0;let o=false;return new Body.Promise(function(s,i){let a;if(e.timeout){a=setTimeout(function(){o=true;i(new FetchError(`Response timeout while trying to fetch ${e.url} (over ${e.timeout}ms)`,"body-timeout"))},e.timeout)}t.on("error",function(t){if(t.name==="AbortError"){o=true;i(t)}else{i(new FetchError(`Invalid response body while trying to fetch ${e.url}: ${t.message}`,"system",t))}});t.on("data",function(t){if(o||t===null){return}if(e.size&&n+t.length>e.size){o=true;i(new FetchError(`content size at ${e.url} over limit: ${e.size}`,"max-size"));return}n+=t.length;r.push(t)});t.on("end",function(){if(o){return}clearTimeout(a);try{s(Buffer.concat(r,n))}catch(t){i(new FetchError(`Could not create Buffer from response body for ${e.url}: ${t.message}`,"system",t))}})})}function convertBody(e,t){if(typeof f!=="function"){throw new Error("The package `encoding` must be installed to use the textConverted() function")}const r=t.get("content-type");let s="utf-8";let n,o;if(r){n=/charset=([^;]*)/i.exec(r)}o=e.slice(0,1024).toString();if(!n&&o){n=/0&&arguments[0]!==undefined?arguments[0]:undefined;this[m]=Object.create(null);if(e instanceof Headers){const t=e.raw();const r=Object.keys(t);for(const e of r){for(const r of t[e]){this.append(e,r)}}return}if(e==null) ;else if(typeof e==="object"){const t=e[Symbol.iterator];if(t!=null){if(typeof t!=="function"){throw new TypeError("Header pairs must be iterable")}const r=[];for(const t of e){if(typeof t!=="object"||typeof t[Symbol.iterator]!=="function"){throw new TypeError("Each header pair must be iterable")}r.push(Array.from(t))}for(const e of r){if(e.length!==2){throw new TypeError("Each header pair must be a name/value tuple")}this.append(e[0],e[1])}}else{for(const t of Object.keys(e)){const r=e[t];this.append(t,r)}}}else{throw new TypeError("Provided initializer must be an object")}}get(e){e=`${e}`;validateName(e);const t=find(this[m],e);if(t===undefined){return null}return this[m][t].join(", ")}forEach(e){let t=arguments.length>1&&arguments[1]!==undefined?arguments[1]:undefined;let r=getHeaders(this);let s=0;while(s1&&arguments[1]!==undefined?arguments[1]:"key+value";const r=Object.keys(e[m]).sort();return r.map(t==="key"?function(e){return e.toLowerCase()}:t==="value"?function(t){return e[m][t].join(", ")}:function(t){return[t.toLowerCase(),e[m][t].join(", ")]})}const y=Symbol("internal");function createHeadersIterator(e,t){const r=Object.create(v);r[y]={target:e,kind:t,index:0};return r}const v=Object.setPrototypeOf({next(){if(!this||Object.getPrototypeOf(this)!==v){throw new TypeError("Value of `this` is not a HeadersIterator")}var e=this[y];const t=e.target,r=e.kind,s=e.index;const n=getHeaders(t,r);const o=n.length;if(s>=o){return{value:undefined,done:true}}this[y].index=s+1;return{value:n[s],done:false}}},Object.getPrototypeOf(Object.getPrototypeOf([][Symbol.iterator]())));Object.defineProperty(v,Symbol.toStringTag,{value:"HeadersIterator",writable:false,enumerable:false,configurable:true});function exportNodeCompatibleHeaders(e){const t=Object.assign({__proto__:null},e[m]);const r=find(e[m],"Host");if(r!==undefined){t[r]=t[r][0]}return t}function createHeadersLenient(e){const t=new Headers;for(const r of Object.keys(e)){if(h.test(r)){continue}if(Array.isArray(e[r])){for(const s of e[r]){if(g.test(s)){continue}if(t[m][r]===undefined){t[m][r]=[s]}else{t[m][r].push(s)}}}else if(!g.test(e[r])){t[m][r]=[e[r]]}}return t}const b=Symbol("Response internals");const w=n.STATUS_CODES;class Response{constructor(){let e=arguments.length>0&&arguments[0]!==undefined?arguments[0]:null;let t=arguments.length>1&&arguments[1]!==undefined?arguments[1]:{};Body.call(this,e,t);const r=t.status||200;const s=new Headers(t.headers);if(e!=null&&!s.has("Content-Type")){const t=extractContentType(e);if(t){s.append("Content-Type",t)}}this[b]={url:t.url,status:r,statusText:t.statusText||w[r],headers:s,counter:t.counter}}get url(){return this[b].url||""}get status(){return this[b].status}get ok(){return this[b].status>=200&&this[b].status<300}get redirected(){return this[b].counter>0}get statusText(){return this[b].statusText}get headers(){return this[b].headers}clone(){return new Response(clone(this),{url:this.url,status:this.status,statusText:this.statusText,headers:this.headers,ok:this.ok,redirected:this.redirected})}}Body.mixIn(Response.prototype);Object.defineProperties(Response.prototype,{url:{enumerable:true},status:{enumerable:true},ok:{enumerable:true},redirected:{enumerable:true},statusText:{enumerable:true},headers:{enumerable:true},clone:{enumerable:true}});Object.defineProperty(Response.prototype,Symbol.toStringTag,{value:"Response",writable:false,enumerable:false,configurable:true});const E=Symbol("Request internals");const T=o.parse;const _=o.format;const O="destroy"in s.Readable.prototype;function isRequest(e){return typeof e==="object"&&typeof e[E]==="object"}function isAbortSignal(e){const t=e&&typeof e==="object"&&Object.getPrototypeOf(e);return!!(t&&t.constructor.name==="AbortSignal")}class Request{constructor(e){let t=arguments.length>1&&arguments[1]!==undefined?arguments[1]:{};let r;if(!isRequest(e)){if(e&&e.href){r=T(e.href)}else{r=T(`${e}`)}e={}}else{r=T(e.url)}let s=t.method||e.method||"GET";s=s.toUpperCase();if((t.body!=null||isRequest(e)&&e.body!==null)&&(s==="GET"||s==="HEAD")){throw new TypeError("Request with GET/HEAD method cannot have body")}let n=t.body!=null?t.body:isRequest(e)&&e.body!==null?clone(e):null;Body.call(this,n,{timeout:t.timeout||e.timeout||0,size:t.size||e.size||0});const o=new Headers(t.headers||e.headers||{});if(n!=null&&!o.has("Content-Type")){const e=extractContentType(n);if(e){o.append("Content-Type",e)}}let i=isRequest(e)?e.signal:null;if("signal"in t)i=t.signal;if(i!=null&&!isAbortSignal(i)){throw new TypeError("Expected signal to be an instanceof AbortSignal")}this[E]={method:s,redirect:t.redirect||e.redirect||"follow",headers:o,parsedURL:r,signal:i};this.follow=t.follow!==undefined?t.follow:e.follow!==undefined?e.follow:20;this.compress=t.compress!==undefined?t.compress:e.compress!==undefined?e.compress:true;this.counter=t.counter||e.counter||0;this.agent=t.agent||e.agent}get method(){return this[E].method}get url(){return _(this[E].parsedURL)}get headers(){return this[E].headers}get redirect(){return this[E].redirect}get signal(){return this[E].signal}clone(){return new Request(this)}}Body.mixIn(Request.prototype);Object.defineProperty(Request.prototype,Symbol.toStringTag,{value:"Request",writable:false,enumerable:false,configurable:true});Object.defineProperties(Request.prototype,{method:{enumerable:true},url:{enumerable:true},headers:{enumerable:true},redirect:{enumerable:true},clone:{enumerable:true},signal:{enumerable:true}});function getNodeRequestOptions(e){const t=e[E].parsedURL;const r=new Headers(e[E].headers);if(!r.has("Accept")){r.set("Accept","*/*")}if(!t.protocol||!t.hostname){throw new TypeError("Only absolute URLs are supported")}if(!/^https?:$/.test(t.protocol)){throw new TypeError("Only HTTP(S) protocols are supported")}if(e.signal&&e.body instanceof s.Readable&&!O){throw new Error("Cancellation of streamed requests with AbortSignal is not supported in node < 8")}let n=null;if(e.body==null&&/^(POST|PUT)$/i.test(e.method)){n="0"}if(e.body!=null){const t=getTotalBytes(e);if(typeof t==="number"){n=String(t)}}if(n){r.set("Content-Length",n)}if(!r.has("User-Agent")){r.set("User-Agent","node-fetch/1.0 (+https://github.com/bitinn/node-fetch)")}if(e.compress&&!r.has("Accept-Encoding")){r.set("Accept-Encoding","gzip,deflate")}let o=e.agent;if(typeof o==="function"){o=o(t)}if(!r.has("Connection")&&!o){r.set("Connection","close")}return Object.assign({},t,{method:e.method,headers:exportNodeCompatibleHeaders(r),agent:o})}function AbortError(e){Error.call(this,e);this.type="aborted";this.message=e;Error.captureStackTrace(this,this.constructor)}AbortError.prototype=Object.create(Error.prototype);AbortError.prototype.constructor=AbortError;AbortError.prototype.name="AbortError";const S=s.PassThrough;const G=o.resolve;function fetch(e,t){if(!fetch.Promise){throw new Error("native promise missing, set fetch.Promise to your favorite alternative")}Body.Promise=fetch.Promise;return new fetch.Promise(function(r,o){const c=new Request(e,t);const u=getNodeRequestOptions(c);const l=(u.protocol==="https:"?i:n).request;const f=c.signal;let p=null;const d=function abort(){let e=new AbortError("The user aborted a request.");o(e);if(c.body&&c.body instanceof s.Readable){c.body.destroy(e)}if(!p||!p.body)return;p.body.emit("error",e)};if(f&&f.aborted){d();return}const h=function abortAndFinalize(){d();finalize()};const g=l(u);let m;if(f){f.addEventListener("abort",h)}function finalize(){g.abort();if(f)f.removeEventListener("abort",h);clearTimeout(m)}if(c.timeout){g.once("socket",function(e){m=setTimeout(function(){o(new FetchError(`network timeout at: ${c.url}`,"request-timeout"));finalize()},c.timeout)})}g.on("error",function(e){o(new FetchError(`request to ${c.url} failed, reason: ${e.message}`,"system",e));finalize()});g.on("response",function(e){clearTimeout(m);const t=createHeadersLenient(e.headers);if(fetch.isRedirect(e.statusCode)){const s=t.get("Location");const n=s===null?null:G(c.url,s);switch(c.redirect){case"error":o(new FetchError(`uri requested responds with a redirect, redirect mode is set to error: ${c.url}`,"no-redirect"));finalize();return;case"manual":if(n!==null){try{t.set("Location",n)}catch(e){o(e)}}break;case"follow":if(n===null){break}if(c.counter>=c.follow){o(new FetchError(`maximum redirect reached at: ${c.url}`,"max-redirect"));finalize();return}const s={headers:new Headers(c.headers),follow:c.follow,counter:c.counter+1,agent:c.agent,compress:c.compress,method:c.method,body:c.body,signal:c.signal,timeout:c.timeout,size:c.size};if(e.statusCode!==303&&c.body&&getTotalBytes(c)===null){o(new FetchError("Cannot follow redirect with body being a readable stream","unsupported-redirect"));finalize();return}if(e.statusCode===303||(e.statusCode===301||e.statusCode===302)&&c.method==="POST"){s.method="GET";s.body=undefined;s.headers.delete("content-length")}r(fetch(new Request(n,s)));finalize();return}}e.once("end",function(){if(f)f.removeEventListener("abort",h)});let s=e.pipe(new S);const n={url:c.url,status:e.statusCode,statusText:e.statusMessage,headers:t,size:c.size,timeout:c.timeout,counter:c.counter};const i=t.get("Content-Encoding");if(!c.compress||c.method==="HEAD"||i===null||e.statusCode===204||e.statusCode===304){p=new Response(s,n);r(p);return}const u={flush:a.Z_SYNC_FLUSH,finishFlush:a.Z_SYNC_FLUSH};if(i=="gzip"||i=="x-gzip"){s=s.pipe(a.createGunzip(u));p=new Response(s,n);r(p);return}if(i=="deflate"||i=="x-deflate"){const t=e.pipe(new S);t.once("data",function(e){if((e[0]&15)===8){s=s.pipe(a.createInflate())}else{s=s.pipe(a.createInflateRaw())}p=new Response(s,n);r(p)});return}if(i=="br"&&typeof a.createBrotliDecompress==="function"){s=s.pipe(a.createBrotliDecompress());p=new Response(s,n);r(p);return}p=new Response(s,n);r(p)});writeToStream(g,c)})}fetch.isRedirect=function(e){return e===301||e===302||e===303||e===307||e===308};fetch.Promise=global.Promise;e.exports=t=fetch;Object.defineProperty(t,"__esModule",{value:true});t.default=t;t.Headers=Headers;t.Request=Request;t.Response=Response;t.FetchError=FetchError},1223:(e,t,r)=>{var s=r(2940);e.exports=s(once);e.exports.strict=s(onceStrict);once.proto=once(function(){Object.defineProperty(Function.prototype,"once",{value:function(){return once(this)},configurable:true});Object.defineProperty(Function.prototype,"onceStrict",{value:function(){return onceStrict(this)},configurable:true})});function once(e){var t=function(){if(t.called)return t.value;t.called=true;return t.value=e.apply(this,arguments)};t.called=false;return t}function onceStrict(e){var t=function(){if(t.called)throw new Error(t.onceError);t.called=true;return t.value=e.apply(this,arguments)};var r=e.name||"Function wrapped with `once`";t.onceError=r+" shouldn't be called more than once";t.called=false;return t}},8714:e=>{"use strict";function posix(e){return e.charAt(0)==="/"}function win32(e){var t=/^([a-zA-Z]:|[\\\/]{2}[^\\\/]+[\\\/]+[^\\\/]+)?([\\\/])?([\s\S]*?)$/;var r=t.exec(e);var s=r[1]||"";var n=Boolean(s&&s.charAt(1)!==":");return Boolean(r[2]||n)}e.exports=process.platform==="win32"?win32:posix;e.exports.posix=posix;e.exports.win32=win32},5123:e=>{e.exports=["cat","cd","chmod","cp","dirs","echo","exec","find","grep","head","ln","ls","mkdir","mv","pwd","rm","sed","set","sort","tail","tempdir","test","to","toEnd","touch","uniq","which"]},3516:(e,t,r)=>{function __ncc_wildcard$0(e){if(e==="cat.js"||e==="cat")return r(271);else if(e==="cd.js"||e==="cd")return r(2051);else if(e==="chmod.js"||e==="chmod")return r(4975);else if(e==="common.js"||e==="common")return r(3687);else if(e==="cp.js"||e==="cp")return r(4932);else if(e==="dirs.js"||e==="dirs")return r(1178);else if(e==="echo.js"||e==="echo")return r(243);else if(e==="error.js"||e==="error")return r(232);else if(e==="exec-child.js"||e==="exec-child")return r(9607);else if(e==="exec.js"||e==="exec")return r(896);else if(e==="find.js"||e==="find")return r(7838);else if(e==="grep.js"||e==="grep")return r(7417);else if(e==="head.js"||e==="head")return r(6613);else if(e==="ln.js"||e==="ln")return r(5787);else if(e==="ls.js"||e==="ls")return r(5561);else if(e==="mkdir.js"||e==="mkdir")return r(2695);else if(e==="mv.js"||e==="mv")return r(9849);else if(e==="popd.js"||e==="popd")return r(227);else if(e==="pushd.js"||e==="pushd")return r(4177);else if(e==="pwd.js"||e==="pwd")return r(8553);else if(e==="rm.js"||e==="rm")return r(2830);else if(e==="sed.js"||e==="sed")return r(5899);else if(e==="set.js"||e==="set")return r(1411);else if(e==="sort.js"||e==="sort")return r(2116);else if(e==="tail.js"||e==="tail")return r(2284);else if(e==="tempdir.js"||e==="tempdir")return r(6150);else if(e==="test.js"||e==="test")return r(9723);else if(e==="to.js"||e==="to")return r(1961);else if(e==="toEnd.js"||e==="toEnd")return r(3736);else if(e==="touch.js"||e==="touch")return r(8358);else if(e==="uniq.js"||e==="uniq")return r(7286);else if(e==="which.js"||e==="which")return r(4766)}var s=r(3687);r(5123).forEach(function(e){__ncc_wildcard$0(e)});t.exit=process.exit;t.error=r(232);t.ShellString=s.ShellString;t.env=process.env;t.config=s.config},271:(e,t,r)=>{var s=r(3687);var n=r(5747);s.register("cat",_cat,{canReceivePipe:true,cmdOptions:{n:"number"}});function _cat(e,t){var r=s.readFromPipe();if(!t&&!r)s.error("no paths given");t=[].slice.call(arguments,1);t.forEach(function(e){if(!n.existsSync(e)){s.error("no such file or directory: "+e)}else if(s.statFollowLinks(e).isDirectory()){s.error(e+": Is a directory")}r+=n.readFileSync(e,"utf8")});if(e.number){r=addNumbers(r)}return r}e.exports=_cat;function addNumbers(e){var t=e.split("\n");var r=t.pop();t=t.map(function(e,t){return numberedLine(t+1,e)});if(r.length){r=numberedLine(t.length+1,r)}t.push(r);return t.join("\n")}function numberedLine(e,t){var r=(" "+e).slice(-6)+"\t";return r+t}},2051:(e,t,r)=>{var s=r(2087);var n=r(3687);n.register("cd",_cd,{});function _cd(e,t){if(!t)t=s.homedir();if(t==="-"){if(!process.env.OLDPWD){n.error("could not find previous directory")}else{t=process.env.OLDPWD}}try{var r=process.cwd();process.chdir(t);process.env.OLDPWD=r}catch(e){var o;try{n.statFollowLinks(t);o="not a directory: "+t}catch(e){o="no such file or directory: "+t}if(o)n.error(o)}return""}e.exports=_cd},4975:(e,t,r)=>{var s=r(3687);var n=r(5747);var o=r(5622);var i=function(e){return{OTHER_EXEC:e.EXEC,OTHER_WRITE:e.WRITE,OTHER_READ:e.READ,GROUP_EXEC:e.EXEC<<3,GROUP_WRITE:e.WRITE<<3,GROUP_READ:e.READ<<3,OWNER_EXEC:e.EXEC<<6,OWNER_WRITE:e.WRITE<<6,OWNER_READ:e.READ<<6,STICKY:parseInt("01000",8),SETGID:parseInt("02000",8),SETUID:parseInt("04000",8),TYPE_MASK:parseInt("0770000",8)}}({EXEC:1,WRITE:2,READ:4});s.register("chmod",_chmod,{});function _chmod(e,t,r){if(!r){if(e.length>0&&e.charAt(0)==="-"){[].unshift.call(arguments,"")}else{s.error("You must specify a file.")}}e=s.parseOptions(e,{R:"recursive",c:"changes",v:"verbose"});r=[].slice.call(arguments,2);var a;if(e.recursive){a=[];r.forEach(function addFile(e){var t=s.statNoFollowLinks(e);if(!t.isSymbolicLink()){a.push(e);if(t.isDirectory()){n.readdirSync(e).forEach(function(t){addFile(e+"/"+t)})}}})}else{a=r}a.forEach(function innerChmod(r){r=o.resolve(r);if(!n.existsSync(r)){s.error("File not found: "+r)}if(e.recursive&&s.statNoFollowLinks(r).isSymbolicLink()){return}var a=s.statFollowLinks(r);var c=a.isDirectory();var u=a.mode;var l=u&i.TYPE_MASK;var f=u;if(isNaN(parseInt(t,8))){t.split(",").forEach(function(t){var o=/([ugoa]*)([=\+-])([rwxXst]*)/i;var a=o.exec(t);if(a){var p=a[1];var d=a[2];var h=a[3];var g=p.indexOf("u")!==-1||p==="a"||p==="";var m=p.indexOf("g")!==-1||p==="a"||p==="";var y=p.indexOf("o")!==-1||p==="a"||p==="";var v=h.indexOf("r")!==-1;var b=h.indexOf("w")!==-1;var w=h.indexOf("x")!==-1;var E=h.indexOf("X")!==-1;var T=h.indexOf("t")!==-1;var _=h.indexOf("s")!==-1;if(E&&c){w=true}var O=0;if(g){O|=(v?i.OWNER_READ:0)+(b?i.OWNER_WRITE:0)+(w?i.OWNER_EXEC:0)+(_?i.SETUID:0)}if(m){O|=(v?i.GROUP_READ:0)+(b?i.GROUP_WRITE:0)+(w?i.GROUP_EXEC:0)+(_?i.SETGID:0)}if(y){O|=(v?i.OTHER_READ:0)+(b?i.OTHER_WRITE:0)+(w?i.OTHER_EXEC:0)}if(T){O|=i.STICKY}switch(d){case"+":f|=O;break;case"-":f&=~O;break;case"=":f=l+O;if(s.statFollowLinks(r).isDirectory()){f|=i.SETUID+i.SETGID&u}break;default:s.error("Could not recognize operator: `"+d+"`")}if(e.verbose){console.log(r+" -> "+f.toString(8))}if(u!==f){if(!e.verbose&&e.changes){console.log(r+" -> "+f.toString(8))}n.chmodSync(r,f);u=f}}else{s.error("Invalid symbolic mode change: "+t)}})}else{f=l+parseInt(t,8);if(s.statFollowLinks(r).isDirectory()){f|=i.SETUID+i.SETGID&u}n.chmodSync(r,f)}});return""}e.exports=_chmod},3687:(e,t,r)=>{"use strict";var s=r(2087);var n=r(5747);var o=r(1957);var i=r(3516);var a=Object.create(i);t.extend=Object.assign;var c=Boolean(process.versions.electron);var u={fatal:false,globOptions:{},maxdepth:255,noglob:false,silent:false,verbose:false,execPath:null,bufLength:64*1024};var l={reset:function(){Object.assign(this,u);if(!c){this.execPath=process.execPath}},resetForTesting:function(){this.reset();this.silent=true}};l.reset();t.config=l;var f={error:null,errorCode:0,currentCmd:"shell.js"};t.state=f;delete process.env.OLDPWD;function isObject(e){return typeof e==="object"&&e!==null}t.isObject=isObject;function log(){if(!l.silent){console.error.apply(console,arguments)}}t.log=log;function convertErrorOutput(e){if(typeof e!=="string"){throw new TypeError("input must be a string")}return e.replace(/\\/g,"/")}t.convertErrorOutput=convertErrorOutput;function error(e,t,r){if(typeof e!=="string")throw new Error("msg must be a string");var s={continue:false,code:1,prefix:f.currentCmd+": ",silent:false};if(typeof t==="number"&&isObject(r)){r.code=t}else if(isObject(t)){r=t}else if(typeof t==="number"){r={code:t}}else if(typeof t!=="number"){r={}}r=Object.assign({},s,r);if(!f.errorCode)f.errorCode=r.code;var n=convertErrorOutput(r.prefix+e);f.error=f.error?f.error+"\n":"";f.error+=n;if(l.fatal)throw new Error(n);if(e.length>0&&!r.silent)log(n);if(!r.continue){throw{msg:"earlyExit",retValue:new ShellString("",f.error,f.errorCode)}}}t.error=error;function ShellString(e,t,r){var s;if(e instanceof Array){s=e;s.stdout=e.join("\n");if(e.length>0)s.stdout+="\n"}else{s=new String(e);s.stdout=e}s.stderr=t;s.code=r;h.forEach(function(e){s[e]=a[e].bind(s)});return s}t.ShellString=ShellString;function parseOptions(e,t,r){if(typeof e!=="string"&&!isObject(e)){throw new Error("options must be strings or key-value pairs")}else if(!isObject(t)){throw new Error("parseOptions() internal error: map must be an object")}else if(r&&!isObject(r)){throw new Error("parseOptions() internal error: errorOptions must be object")}if(e==="--"){return{}}var s={};Object.keys(t).forEach(function(e){var r=t[e];if(r[0]!=="!"){s[r]=false}});if(e==="")return s;if(typeof e==="string"){if(e[0]!=="-"){throw new Error("Options string must start with a '-'")}var n=e.slice(1).split("");n.forEach(function(e){if(e in t){var n=t[e];if(n[0]==="!"){s[n.slice(1)]=false}else{s[n]=true}}else{error("option not recognized: "+e,r||{})}})}else{Object.keys(e).forEach(function(n){var o=n[1];if(o in t){var i=t[o];s[i]=e[n]}else{error("option not recognized: "+o,r||{})}})}return s}t.parseOptions=parseOptions;function expand(e){if(!Array.isArray(e)){throw new TypeError("must be an array")}var t=[];e.forEach(function(e){if(typeof e!=="string"){t.push(e)}else{var r;try{r=o.sync(e,l.globOptions);r=r.length>0?r:[e]}catch(t){r=[e]}t=t.concat(r)}});return t}t.expand=expand;var p=typeof Buffer.alloc==="function"?function(e){return Buffer.alloc(e||l.bufLength)}:function(e){return new Buffer(e||l.bufLength)};t.buffer=p;function unlinkSync(e){try{n.unlinkSync(e)}catch(t){if(t.code==="EPERM"){n.chmodSync(e,"0666");n.unlinkSync(e)}else{throw t}}}t.unlinkSync=unlinkSync;function statFollowLinks(){return n.statSync.apply(n,arguments)}t.statFollowLinks=statFollowLinks;function statNoFollowLinks(){return n.lstatSync.apply(n,arguments)}t.statNoFollowLinks=statNoFollowLinks;function randomFileName(){function randomHash(e){if(e===1){return parseInt(16*Math.random(),10).toString(16)}var t="";for(var r=0;r{var s=r(5747);var n=r(5622);var o=r(3687);o.register("cp",_cp,{cmdOptions:{f:"!no_force",n:"no_force",u:"update",R:"recursive",r:"recursive",L:"followsymlink",P:"noFollowsymlink"},wrapOutput:false});function copyFileSync(e,t,r){if(!s.existsSync(e)){o.error("copyFileSync: no such file or directory: "+e)}var n=process.platform==="win32";try{if(r.update&&o.statFollowLinks(e).mtime=o.config.maxdepth)return;r++;var i=process.platform==="win32";try{s.mkdirSync(t)}catch(e){if(e.code!=="EEXIST")throw e}var a=s.readdirSync(e);for(var c=0;c and/or ")}else{t=[].slice.call(arguments,1,arguments.length-1);r=arguments[arguments.length-1]}var i=s.existsSync(r);var a=i&&o.statFollowLinks(r);if((!i||!a.isDirectory())&&t.length>1){o.error("dest is not a directory (too many sources)")}if(i&&a.isFile()&&e.no_force){return new o.ShellString("","",0)}t.forEach(function(i,c){if(!s.existsSync(i)){if(i==="")i="''";o.error("no such file or directory: "+i,{continue:true});return}var u=o.statFollowLinks(i);if(!e.noFollowsymlink&&u.isDirectory()){if(!e.recursive){o.error("omitting directory '"+i+"'",{continue:true})}else{var l=a&&a.isDirectory()?n.join(r,n.basename(i)):r;try{o.statFollowLinks(n.dirname(r));cpdirSyncRecursive(i,l,0,{no_force:e.no_force,followsymlink:e.followsymlink})}catch(e){o.error("cannot create directory '"+r+"': No such file or directory")}}}else{var f=r;if(a&&a.isDirectory()){f=n.normalize(r+"/"+n.basename(i))}var p=s.existsSync(f);if(p&&checkRecentCreated(t,c)){if(!e.no_force){o.error("will not overwrite just-created '"+f+"' with '"+i+"'",{continue:true})}return}if(p&&e.no_force){return}if(n.relative(i,f)===""){o.error("'"+f+"' and '"+i+"' are the same file",{continue:true});return}copyFileSync(i,f,e)}});return new o.ShellString("",o.state.error,o.state.errorCode)}e.exports=_cp},1178:(e,t,r)=>{var s=r(3687);var n=r(2051);var o=r(5622);s.register("dirs",_dirs,{wrapOutput:false});s.register("pushd",_pushd,{wrapOutput:false});s.register("popd",_popd,{wrapOutput:false});var i=[];function _isStackIndex(e){return/^[\-+]\d+$/.test(e)}function _parseStackIndex(e){if(_isStackIndex(e)){if(Math.abs(e)1){r=r.splice(1,1).concat(r)}else{return s.error("no other directory")}}else if(_isStackIndex(t)){var a=_parseStackIndex(t);r=r.slice(a).concat(r.slice(0,a))}else{if(e["no-cd"]){r.splice(1,0,t)}else{r.unshift(t)}}if(e["no-cd"]){r=r.slice(1)}else{t=o.resolve(r.shift());n("",t)}i=r;return _dirs(e.quiet?"-q":"")}t.pushd=_pushd;function _popd(e,t){if(_isStackIndex(e)){t=e;e=""}e=s.parseOptions(e,{n:"no-cd",q:"quiet"});if(!i.length){return s.error("directory stack empty")}t=_parseStackIndex(t||"+0");if(e["no-cd"]||t>0||i.length+t===0){t=t>0?t-1:t;i.splice(t,1)}else{var r=o.resolve(i.shift());n("",r)}return _dirs(e.quiet?"-q":"")}t.popd=_popd;function _dirs(e,t){if(_isStackIndex(e)){t=e;e=""}e=s.parseOptions(e,{c:"clear",q:"quiet"});if(e.clear){i=[];return i}var r=_actualDirStack();if(t){t=_parseStackIndex(t);if(t<0){t=r.length+t}if(!e.quiet){s.log(r[t])}return r[t]}if(!e.quiet){s.log(r.join(" "))}return r}t.dirs=_dirs},243:(e,t,r)=>{var s=r(1669).format;var n=r(3687);n.register("echo",_echo,{allowGlobbing:false});function _echo(e){var t=[].slice.call(arguments,e?0:1);var r={};try{r=n.parseOptions(t[0],{e:"escapes",n:"no_newline"},{silent:true});if(t[0]){t.shift()}}catch(e){n.state.error=null}var o=s.apply(null,t);if(!r.no_newline){o+="\n"}process.stdout.write(o);return o}e.exports=_echo},232:(e,t,r)=>{var s=r(3687);function error(){return s.state.error}e.exports=error},9607:(e,t,r)=>{e=r.nmd(e);if(require.main!==e){throw new Error("This file should not be required")}var s=r(3129);var n=r(5747);var o=process.argv[2];var i=n.readFileSync(o,"utf8");var a=JSON.parse(i);var c=a.command;var u=a.execOptions;var l=a.pipe;var f=a.stdoutFile;var p=a.stderrFile;var d=s.exec(c,u,function(e){if(!e){process.exitCode=0}else if(e.code===undefined){process.exitCode=1}else{process.exitCode=e.code}});var h=n.createWriteStream(f);var g=n.createWriteStream(p);d.stdout.pipe(h);d.stderr.pipe(g);d.stdout.pipe(process.stdout);d.stderr.pipe(process.stderr);if(l){d.stdin.end(l)}},896:(e,t,r)=>{var s=r(3687);var n=r(6150).tempDir;var o=r(8553);var i=r(5622);var a=r(5747);var c=r(3129);var u=20*1024*1024;var l=1;s.register("exec",_exec,{unix:false,canReceivePipe:true,wrapOutput:false});function execSync(e,t,f){if(!s.config.execPath){s.error("Unable to find a path to the node binary. Please manually set config.execPath")}var p=n();var d=i.resolve(p+"/"+s.randomFileName());var h=i.resolve(p+"/"+s.randomFileName());var g=i.resolve(p+"/"+s.randomFileName());t=s.extend({silent:s.config.silent,cwd:o().toString(),env:process.env,maxBuffer:u,encoding:"utf8"},t);if(a.existsSync(d))s.unlinkSync(d);if(a.existsSync(h))s.unlinkSync(h);if(a.existsSync(g))s.unlinkSync(g);t.cwd=i.resolve(t.cwd);var m={command:e,execOptions:t,pipe:f,stdoutFile:g,stderrFile:h};a.writeFileSync(d,JSON.stringify(m),"utf8");var y=[r.ab+"exec-child.js",d];if(t.silent){t.stdio="ignore"}else{t.stdio=[0,1,2]}var v=0;try{delete t.shell;c.execFileSync(s.config.execPath,y,t)}catch(e){v=e.status||l}var b="";var w="";if(t.encoding==="buffer"){b=a.readFileSync(g);w=a.readFileSync(h)}else{b=a.readFileSync(g,t.encoding);w=a.readFileSync(h,t.encoding)}try{s.unlinkSync(d)}catch(e){}try{s.unlinkSync(h)}catch(e){}try{s.unlinkSync(g)}catch(e){}if(v!==0){s.error(w,v,{continue:true,silent:true})}var E=s.ShellString(b,w,v);return E}function execAsync(e,t,r,n){t=s.extend({silent:s.config.silent,cwd:o().toString(),env:process.env,maxBuffer:u,encoding:"utf8"},t);var i=c.exec(e,t,function(e,t,r){if(n){if(!e){n(0,t,r)}else if(e.code===undefined){n(1,t,r)}else{n(e.code,t,r)}}});if(r)i.stdin.end(r);if(!t.silent){i.stdout.pipe(process.stdout);i.stderr.pipe(process.stderr)}return i}function _exec(e,t,r){t=t||{};if(!e)s.error("must specify command");var n=s.readFromPipe();if(typeof t==="function"){r=t;t={async:true}}if(typeof t==="object"&&typeof r==="function"){t.async=true}t=s.extend({silent:s.config.silent,async:false},t);if(t.async){return execAsync(e,t,n,r)}else{return execSync(e,t,n)}}e.exports=_exec},7838:(e,t,r)=>{var s=r(5622);var n=r(3687);var o=r(5561);n.register("find",_find,{});function _find(e,t){if(!t){n.error("no path specified")}else if(typeof t==="string"){t=[].slice.call(arguments,1)}var r=[];function pushFile(e){if(process.platform==="win32"){e=e.replace(/\\/g,"/")}r.push(e)}t.forEach(function(e){var t;try{t=n.statFollowLinks(e)}catch(t){n.error("no such file or directory: "+e)}pushFile(e);if(t.isDirectory()){o({recursive:true,all:true},e).forEach(function(t){pushFile(s.join(e,t))})}});return r}e.exports=_find},7417:(e,t,r)=>{var s=r(3687);var n=r(5747);s.register("grep",_grep,{globStart:2,canReceivePipe:true,cmdOptions:{v:"inverse",l:"nameOnly",i:"ignoreCase"}});function _grep(e,t,r){var o=s.readFromPipe();if(!r&&!o)s.error("no paths given",2);r=[].slice.call(arguments,2);if(o){r.unshift("-")}var i=[];if(e.ignoreCase){t=new RegExp(t,"i")}r.forEach(function(r){if(!n.existsSync(r)&&r!=="-"){s.error("no such file or directory: "+r,2,{continue:true});return}var a=r==="-"?o:n.readFileSync(r,"utf8");if(e.nameOnly){if(a.match(t)){i.push(r)}}else{var c=a.split("\n");c.forEach(function(r){var s=r.match(t);if(e.inverse&&!s||!e.inverse&&s){i.push(r)}})}});return i.join("\n")+"\n"}e.exports=_grep},6613:(e,t,r)=>{var s=r(3687);var n=r(5747);s.register("head",_head,{canReceivePipe:true,cmdOptions:{n:"numLines"}});function readSomeLines(e,t){var r=s.buffer();var o=r.length;var i=o;var a=0;var c=n.openSync(e,"r");var u=0;var l="";while(i===o&&u{var s=r(5747);var n=r(5622);var o=r(3687);o.register("ln",_ln,{cmdOptions:{s:"symlink",f:"force"}});function _ln(e,t,r){if(!t||!r){o.error("Missing and/or ")}t=String(t);var i=n.normalize(t).replace(RegExp(n.sep+"$"),"");var a=n.resolve(t)===i;r=n.resolve(process.cwd(),String(r));if(s.existsSync(r)){if(!e.force){o.error("Destination file exists",{continue:true})}s.unlinkSync(r)}if(e.symlink){var c=process.platform==="win32";var u=c?"file":null;var l=a?i:n.resolve(process.cwd(),n.dirname(r),t);if(!s.existsSync(l)){o.error("Source file does not exist",{continue:true})}else if(c&&o.statFollowLinks(l).isDirectory()){u="junction"}try{s.symlinkSync(u==="junction"?l:t,r,u)}catch(e){o.error(e.message)}}else{if(!s.existsSync(t)){o.error("Source file does not exist",{continue:true})}try{s.linkSync(t,r)}catch(e){o.error(e.message)}}return""}e.exports=_ln},5561:(e,t,r)=>{var s=r(5622);var n=r(5747);var o=r(3687);var i=r(1957);var a=s.sep+"**";o.register("ls",_ls,{cmdOptions:{R:"recursive",A:"all",L:"link",a:"all_deprecated",d:"directory",l:"long"}});function _ls(e,t){if(e.all_deprecated){o.log("ls: Option -a is deprecated. Use -A instead");e.all=true}if(!t){t=["."]}else{t=[].slice.call(arguments,1)}var r=[];function pushFile(t,s,n){if(process.platform==="win32"){s=s.replace(/\\/g,"/")}if(e.long){n=n||(e.link?o.statFollowLinks(t):o.statNoFollowLinks(t));r.push(addLsAttributes(s,n))}else{r.push(s)}}t.forEach(function(t){var r;try{r=e.link?o.statFollowLinks(t):o.statNoFollowLinks(t);if(r.isSymbolicLink()){try{var c=o.statFollowLinks(t);if(c.isDirectory()){r=c}}catch(e){}}}catch(e){o.error("no such file or directory: "+t,2,{continue:true});return}if(r.isDirectory()&&!e.directory){if(e.recursive){i.sync(t+a,{dot:e.all,follow:e.link}).forEach(function(e){if(s.relative(t,e)){pushFile(e,s.relative(t,e))}})}else if(e.all){n.readdirSync(t).forEach(function(e){pushFile(s.join(t,e),e)})}else{n.readdirSync(t).forEach(function(e){if(e[0]!=="."){pushFile(s.join(t,e),e)}})}}else{pushFile(t,t,r)}});return r}function addLsAttributes(e,t){t.name=e;t.toString=function(){return[this.mode,this.nlink,this.uid,this.gid,this.size,this.mtime,this.name].join(" ")};return t}e.exports=_ls},2695:(e,t,r)=>{var s=r(3687);var n=r(5747);var o=r(5622);s.register("mkdir",_mkdir,{cmdOptions:{p:"fullpath"}});function mkdirSyncRecursive(e){var t=o.dirname(e);if(t===e){s.error("dirname() failed: ["+e+"]")}if(n.existsSync(t)){n.mkdirSync(e,parseInt("0777",8));return}mkdirSyncRecursive(t);n.mkdirSync(e,parseInt("0777",8))}function _mkdir(e,t){if(!t)s.error("no paths given");if(typeof t==="string"){t=[].slice.call(arguments,1)}t.forEach(function(t){try{var r=s.statNoFollowLinks(t);if(!e.fullpath){s.error("path already exists: "+t,{continue:true})}else if(r.isFile()){s.error("cannot create directory "+t+": File exists",{continue:true})}return}catch(e){}var i=o.dirname(t);if(!n.existsSync(i)&&!e.fullpath){s.error("no such file or directory: "+i,{continue:true});return}try{if(e.fullpath){mkdirSyncRecursive(o.resolve(t))}else{n.mkdirSync(t,parseInt("0777",8))}}catch(e){var a;if(e.code==="EACCES"){a="Permission denied"}else if(e.code==="ENOTDIR"||e.code==="ENOENT"){a="Not a directory"}else{throw e}s.error("cannot create directory "+t+": "+a,{continue:true})}});return""}e.exports=_mkdir},9849:(e,t,r)=>{var s=r(5747);var n=r(5622);var o=r(3687);var i=r(4932);var a=r(2830);o.register("mv",_mv,{cmdOptions:{f:"!no_force",n:"no_force"}});function checkRecentCreated(e,t){var r=e[t];return e.slice(0,t).some(function(e){return n.basename(e)===n.basename(r)})}function _mv(e,t,r){if(arguments.length<3){o.error("missing and/or ")}else if(arguments.length>3){t=[].slice.call(arguments,1,arguments.length-1);r=arguments[arguments.length-1]}else if(typeof t==="string"){t=[t]}else{o.error("invalid arguments")}var c=s.existsSync(r);var u=c&&o.statFollowLinks(r);if((!c||!u.isDirectory())&&t.length>1){o.error("dest is not a directory (too many sources)")}if(c&&u.isFile()&&e.no_force){o.error("dest file already exists: "+r)}t.forEach(function(c,u){if(!s.existsSync(c)){o.error("no such file or directory: "+c,{continue:true});return}var l=r;if(s.existsSync(r)&&o.statFollowLinks(r).isDirectory()){l=n.normalize(r+"/"+n.basename(c))}var f=s.existsSync(l);if(f&&checkRecentCreated(t,u)){if(!e.no_force){o.error("will not overwrite just-created '"+l+"' with '"+c+"'",{continue:true})}return}if(s.existsSync(l)&&e.no_force){o.error("dest file already exists: "+l,{continue:true});return}if(n.resolve(c)===n.dirname(n.resolve(l))){o.error("cannot move to self: "+c,{continue:true});return}try{s.renameSync(c,l)}catch(e){if(e.code==="EXDEV"){i("-r",c,l);a("-rf",c)}}});return""}e.exports=_mv},227:()=>{},4177:()=>{},8553:(e,t,r)=>{var s=r(5622);var n=r(3687);n.register("pwd",_pwd,{allowGlobbing:false});function _pwd(){var e=s.resolve(process.cwd());return e}e.exports=_pwd},2830:(e,t,r)=>{var s=r(3687);var n=r(5747);s.register("rm",_rm,{cmdOptions:{f:"force",r:"recursive",R:"recursive"}});function rmdirSyncRecursive(e,t,r){var o;o=n.readdirSync(e);for(var i=0;i1e3)throw e}else if(e.code==="ENOENT"){break}else{throw e}}}}catch(t){s.error("could not remove directory (code "+t.code+"): "+e,{continue:true})}return u}function isWriteable(e){var t=true;try{var r=n.openSync(e,"a");n.closeSync(r)}catch(e){t=false}return t}function handleFile(e,t){if(t.force||isWriteable(e)){s.unlinkSync(e)}else{s.error("permission denied: "+e,{continue:true})}}function handleDirectory(e,t){if(t.recursive){rmdirSyncRecursive(e,t.force)}else{s.error("path is a directory",{continue:true})}}function handleSymbolicLink(e,t){var r;try{r=s.statFollowLinks(e)}catch(t){s.unlinkSync(e);return}if(r.isFile()){s.unlinkSync(e)}else if(r.isDirectory()){if(e[e.length-1]==="/"){if(t.recursive){var n=true;rmdirSyncRecursive(e,t.force,n)}else{s.error("path is a directory",{continue:true})}}else{s.unlinkSync(e)}}}function handleFIFO(e){s.unlinkSync(e)}function _rm(e,t){if(!t)s.error("no paths given");t=[].slice.call(arguments,1);t.forEach(function(t){var r;try{var n=t[t.length-1]==="/"?t.slice(0,-1):t;r=s.statNoFollowLinks(n)}catch(r){if(!e.force){s.error("no such file or directory: "+t,{continue:true})}return}if(r.isFile()){handleFile(t,e)}else if(r.isDirectory()){handleDirectory(t,e)}else if(r.isSymbolicLink()){handleSymbolicLink(t,e)}else if(r.isFIFO()){handleFIFO(t)}});return""}e.exports=_rm},5899:(e,t,r)=>{var s=r(3687);var n=r(5747);s.register("sed",_sed,{globStart:3,canReceivePipe:true,cmdOptions:{i:"inplace"}});function _sed(e,t,r,o){var i=s.readFromPipe();if(typeof r!=="string"&&typeof r!=="function"){if(typeof r==="number"){r=r.toString()}else{s.error("invalid replacement string")}}if(typeof t==="string"){t=RegExp(t)}if(!o&&!i){s.error("no files given")}o=[].slice.call(arguments,3);if(i){o.unshift("-")}var a=[];o.forEach(function(o){if(!n.existsSync(o)&&o!=="-"){s.error("no such file or directory: "+o,2,{continue:true});return}var c=o==="-"?i:n.readFileSync(o,"utf8");var u=c.split("\n");var l=u.map(function(e){return e.replace(t,r)}).join("\n");a.push(l);if(e.inplace){n.writeFileSync(o,l,"utf8")}});return a.join("\n")}e.exports=_sed},1411:(e,t,r)=>{var s=r(3687);s.register("set",_set,{allowGlobbing:false,wrapOutput:false});function _set(e){if(!e){var t=[].slice.call(arguments,0);if(t.length<2)s.error("must provide an argument");e=t[1]}var r=e[0]==="+";if(r){e="-"+e.slice(1)}e=s.parseOptions(e,{e:"fatal",v:"verbose",f:"noglob"});if(r){Object.keys(e).forEach(function(t){e[t]=!e[t]})}Object.keys(e).forEach(function(t){if(r!==e[t]){s.config[t]=e[t]}});return}e.exports=_set},2116:(e,t,r)=>{var s=r(3687);var n=r(5747);s.register("sort",_sort,{canReceivePipe:true,cmdOptions:{r:"reverse",n:"numerical"}});function parseNumber(e){var t=e.match(/^\s*(\d*)\s*(.*)$/);return{num:Number(t[1]),value:t[2]}}function unixCmp(e,t){var r=e.toLowerCase();var s=t.toLowerCase();return r===s?-1*e.localeCompare(t):r.localeCompare(s)}function numericalCmp(e,t){var r=parseNumber(e);var s=parseNumber(t);if(r.hasOwnProperty("num")&&s.hasOwnProperty("num")){return r.num!==s.num?r.num-s.num:unixCmp(r.value,s.value)}else{return unixCmp(r.value,s.value)}}function _sort(e,t){var r=s.readFromPipe();if(!t&&!r)s.error("no files given");t=[].slice.call(arguments,1);if(r){t.unshift("-")}var o=t.reduce(function(e,t){if(t!=="-"){if(!n.existsSync(t)){s.error("no such file or directory: "+t,{continue:true});return e}else if(s.statFollowLinks(t).isDirectory()){s.error("read failed: "+t+": Is a directory",{continue:true});return e}}var o=t==="-"?r:n.readFileSync(t,"utf8");return e.concat(o.trimRight().split("\n"))},[]);var i=o.sort(e.numerical?numericalCmp:unixCmp);if(e.reverse){i=i.reverse()}return i.join("\n")+"\n"}e.exports=_sort},2284:(e,t,r)=>{var s=r(3687);var n=r(5747);s.register("tail",_tail,{canReceivePipe:true,cmdOptions:{n:"numLines"}});function _tail(e,t){var r=[];var o=s.readFromPipe();if(!t&&!o)s.error("no paths given");var i=1;if(e.numLines===true){i=2;e.numLines=Number(arguments[1])}else if(e.numLines===false){e.numLines=10}e.numLines=-1*Math.abs(e.numLines);t=[].slice.call(arguments,i);if(o){t.unshift("-")}var a=false;t.forEach(function(t){if(t!=="-"){if(!n.existsSync(t)){s.error("no such file or directory: "+t,{continue:true});return}else if(s.statFollowLinks(t).isDirectory()){s.error("error reading '"+t+"': Is a directory",{continue:true});return}}var i=t==="-"?o:n.readFileSync(t,"utf8");var c=i.split("\n");if(c[c.length-1]===""){c.pop();a=true}else{a=false}r=r.concat(c.slice(e.numLines))});if(a){r.push("")}return r.join("\n")}e.exports=_tail},6150:(e,t,r)=>{var s=r(3687);var n=r(2087);var o=r(5747);s.register("tempdir",_tempDir,{allowGlobbing:false,wrapOutput:false});function writeableDir(e){if(!e||!o.existsSync(e))return false;if(!s.statFollowLinks(e).isDirectory())return false;var t=e+"/"+s.randomFileName();try{o.writeFileSync(t," ");s.unlinkSync(t);return e}catch(e){return false}}var i;function _tempDir(){if(i)return i;i=writeableDir(n.tmpdir())||writeableDir(process.env.TMPDIR)||writeableDir(process.env.TEMP)||writeableDir(process.env.TMP)||writeableDir(process.env.Wimp$ScrapDir)||writeableDir("C:\\TEMP")||writeableDir("C:\\TMP")||writeableDir("\\TEMP")||writeableDir("\\TMP")||writeableDir("/tmp")||writeableDir("/var/tmp")||writeableDir("/usr/tmp")||writeableDir(".");return i}function isCached(){return i}function clearCache(){i=undefined}e.exports.tempDir=_tempDir;e.exports.isCached=isCached;e.exports.clearCache=clearCache},9723:(e,t,r)=>{var s=r(3687);var n=r(5747);s.register("test",_test,{cmdOptions:{b:"block",c:"character",d:"directory",e:"exists",f:"file",L:"link",p:"pipe",S:"socket"},wrapOutput:false,allowGlobbing:false});function _test(e,t){if(!t)s.error("no path given");var r=false;Object.keys(e).forEach(function(t){if(e[t]===true){r=true}});if(!r)s.error("could not interpret expression");if(e.link){try{return s.statNoFollowLinks(t).isSymbolicLink()}catch(e){return false}}if(!n.existsSync(t))return false;if(e.exists)return true;var o=s.statFollowLinks(t);if(e.block)return o.isBlockDevice();if(e.character)return o.isCharacterDevice();if(e.directory)return o.isDirectory();if(e.file)return o.isFile();if(e.pipe)return o.isFIFO();if(e.socket)return o.isSocket();return false}e.exports=_test},1961:(e,t,r)=>{var s=r(3687);var n=r(5747);var o=r(5622);s.register("to",_to,{pipeOnly:true,wrapOutput:false});function _to(e,t){if(!t)s.error("wrong arguments");if(!n.existsSync(o.dirname(t))){s.error("no such file or directory: "+o.dirname(t))}try{n.writeFileSync(t,this.stdout||this.toString(),"utf8");return this}catch(e){s.error("could not write to file (code "+e.code+"): "+t,{continue:true})}}e.exports=_to},3736:(e,t,r)=>{var s=r(3687);var n=r(5747);var o=r(5622);s.register("toEnd",_toEnd,{pipeOnly:true,wrapOutput:false});function _toEnd(e,t){if(!t)s.error("wrong arguments");if(!n.existsSync(o.dirname(t))){s.error("no such file or directory: "+o.dirname(t))}try{n.appendFileSync(t,this.stdout||this.toString(),"utf8");return this}catch(e){s.error("could not append to file (code "+e.code+"): "+t,{continue:true})}}e.exports=_toEnd},8358:(e,t,r)=>{var s=r(3687);var n=r(5747);s.register("touch",_touch,{cmdOptions:{a:"atime_only",c:"no_create",d:"date",m:"mtime_only",r:"reference"}});function _touch(e,t){if(!t){s.error("no files given")}else if(typeof t==="string"){t=[].slice.call(arguments,1)}else{s.error("file arg should be a string file path or an Array of string file paths")}t.forEach(function(t){touchFile(e,t)});return""}function touchFile(e,t){var r=tryStatFile(t);if(r&&r.isDirectory()){return}if(!r&&e.no_create){return}n.closeSync(n.openSync(t,"a"));var o=new Date;var i=e.date||o;var a=e.date||o;if(e.reference){var c=tryStatFile(e.reference);if(!c){s.error("failed to get attributess of "+e.reference)}i=c.mtime;a=c.atime}else if(e.date){i=e.date;a=e.date}if(e.atime_only&&e.mtime_only){}else if(e.atime_only){i=r.mtime}else if(e.mtime_only){a=r.atime}n.utimesSync(t,a,i)}e.exports=_touch;function tryStatFile(e){try{return s.statFollowLinks(e)}catch(e){return null}}},7286:(e,t,r)=>{var s=r(3687);var n=r(5747);function lpad(e,t){var r=""+t;if(r.length1:true}).map(function(t){return(e.count?lpad(7,t.count)+" ":"")+t.ln}).join("\n")+"\n";if(r){new s.ShellString(c).to(r);return""}else{return c}}e.exports=_uniq},4766:(e,t,r)=>{var s=r(3687);var n=r(5747);var o=r(5622);s.register("which",_which,{allowGlobbing:false,cmdOptions:{a:"all"}});var i=".com;.exe;.bat;.cmd;.vbs;.vbe;.js;.jse;.wsf;.wsh";var a=1;function isWindowsPlatform(){return process.platform==="win32"}function splitPath(e){return e?e.split(o.delimiter):[]}function isExecutable(e){try{n.accessSync(e,a)}catch(e){return false}return true}function checkPath(e){return n.existsSync(e)&&!s.statFollowLinks(e).isDirectory()&&(isWindowsPlatform()||isExecutable(e))}function _which(e,t){if(!t)s.error("must specify command");var r=isWindowsPlatform();var n=splitPath(process.env.PATH);var a=[];if(t.indexOf("/")===-1){var c=[""];if(r){var u=process.env.PATHEXT||i;c=splitPath(u.toUpperCase())}for(var l=0;l0&&!e.all)break;var f=o.resolve(n[l],t);if(r){f=f.toUpperCase()}var p=f.match(/\.[^<>:"/\|?*.]+$/);if(p&&c.indexOf(p[0])>=0){if(checkPath(f)){a.push(f);break}}else{for(var d=0;d0){return e.all?a:a[0]}return e.all?[]:null}e.exports=_which},4294:(e,t,r)=>{e.exports=r(4219)},4219:(e,t,r)=>{"use strict";var s=r(1631);var n=r(4016);var o=r(8605);var i=r(7211);var a=r(8614);var c=r(2357);var u=r(1669);t.httpOverHttp=httpOverHttp;t.httpsOverHttp=httpsOverHttp;t.httpOverHttps=httpOverHttps;t.httpsOverHttps=httpsOverHttps;function httpOverHttp(e){var t=new TunnelingAgent(e);t.request=o.request;return t}function httpsOverHttp(e){var t=new TunnelingAgent(e);t.request=o.request;t.createSocket=createSecureSocket;t.defaultPort=443;return t}function httpOverHttps(e){var t=new TunnelingAgent(e);t.request=i.request;return t}function httpsOverHttps(e){var t=new TunnelingAgent(e);t.request=i.request;t.createSocket=createSecureSocket;t.defaultPort=443;return t}function TunnelingAgent(e){var t=this;t.options=e||{};t.proxyOptions=t.options.proxy||{};t.maxSockets=t.options.maxSockets||o.Agent.defaultMaxSockets;t.requests=[];t.sockets=[];t.on("free",function onFree(e,r,s,n){var o=toOptions(r,s,n);for(var i=0,a=t.requests.length;i=this.maxSockets){n.requests.push(o);return}n.createSocket(o,function(t){t.on("free",onFree);t.on("close",onCloseOrRemove);t.on("agentRemove",onCloseOrRemove);e.onSocket(t);function onFree(){n.emit("free",t,o)}function onCloseOrRemove(e){n.removeSocket(t);t.removeListener("free",onFree);t.removeListener("close",onCloseOrRemove);t.removeListener("agentRemove",onCloseOrRemove)}})};TunnelingAgent.prototype.createSocket=function createSocket(e,t){var r=this;var s={};r.sockets.push(s);var n=mergeOptions({},r.proxyOptions,{method:"CONNECT",path:e.host+":"+e.port,agent:false,headers:{host:e.host+":"+e.port}});if(e.localAddress){n.localAddress=e.localAddress}if(n.proxyAuth){n.headers=n.headers||{};n.headers["Proxy-Authorization"]="Basic "+new Buffer(n.proxyAuth).toString("base64")}l("making CONNECT request");var o=r.request(n);o.useChunkedEncodingByDefault=false;o.once("response",onResponse);o.once("upgrade",onUpgrade);o.once("connect",onConnect);o.once("error",onError);o.end();function onResponse(e){e.upgrade=true}function onUpgrade(e,t,r){process.nextTick(function(){onConnect(e,t,r)})}function onConnect(n,i,a){o.removeAllListeners();i.removeAllListeners();if(n.statusCode!==200){l("tunneling socket could not be established, statusCode=%d",n.statusCode);i.destroy();var c=new Error("tunneling socket could not be established, "+"statusCode="+n.statusCode);c.code="ECONNRESET";e.request.emit("error",c);r.removeSocket(s);return}if(a.length>0){l("got illegal response body from proxy");i.destroy();var c=new Error("got illegal response body from proxy");c.code="ECONNRESET";e.request.emit("error",c);r.removeSocket(s);return}l("tunneling connection has established");r.sockets[r.sockets.indexOf(s)]=i;return t(i)}function onError(t){o.removeAllListeners();l("tunneling socket could not be established, cause=%s\n",t.message,t.stack);var n=new Error("tunneling socket could not be established, "+"cause="+t.message);n.code="ECONNRESET";e.request.emit("error",n);r.removeSocket(s)}};TunnelingAgent.prototype.removeSocket=function removeSocket(e){var t=this.sockets.indexOf(e);if(t===-1){return}this.sockets.splice(t,1);var r=this.requests.shift();if(r){this.createSocket(r,function(e){r.request.onSocket(e)})}};function createSecureSocket(e,t){var r=this;TunnelingAgent.prototype.createSocket.call(r,e,function(s){var o=e.request.getHeader("host");var i=mergeOptions({},r.options,{socket:s,servername:o?o.replace(/:.*$/,""):e.host});var a=n.connect(0,i);r.sockets[r.sockets.indexOf(s)]=a;t(a)})}function toOptions(e,t,r){if(typeof e==="string"){return{host:e,port:t,localAddress:r}}return e}function mergeOptions(e){for(var t=1,r=arguments.length;t{"use strict";Object.defineProperty(t,"__esModule",{value:true});function getUserAgent(){if(typeof navigator==="object"&&"userAgent"in navigator){return navigator.userAgent}if(typeof process==="object"&&"version"in process){return`Node.js/${process.version.substr(1)} (${process.platform}; ${process.arch})`}return""}t.getUserAgent=getUserAgent},2940:e=>{e.exports=wrappy;function wrappy(e,t){if(e&&t)return wrappy(e)(t);if(typeof e!=="function")throw new TypeError("need wrapper function");Object.keys(e).forEach(function(t){wrapper[t]=e[t]});return wrapper;function wrapper(){var t=new Array(arguments.length);for(var r=0;r{const t=[];for(const s of r){t.push(l.default.join(e,s))}return t})();const n=await u.create(s.join("\n"));const o=await n.glob();for await(const e of n.globGenerator()){a.info(`[INFO] delete ${e}`)}h.rm("-rf",o);return}t.deleteExcludedAssets=deleteExcludedAssets;async function copyAssets(e,t,r){a.info(`[INFO] prepare publishing assets`);if(!f.default.existsSync(t)){a.info(`[INFO] create ${t}`);await d.createDir(t)}const s=l.default.join(e,".git");if(f.default.existsSync(s)){a.info(`[INFO] delete ${s}`);h.rm("-rf",s)}a.info(`[INFO] copy ${e} to ${t}`);h.cp("-RfL",[`${e}/*`,`${e}/.*`],t);await deleteExcludedAssets(t,r);return}t.copyAssets=copyAssets;async function setRepo(e,t,r){const s=l.default.isAbsolute(e.PublishDir)?e.PublishDir:l.default.join(`${process.env.GITHUB_WORKSPACE}`,e.PublishDir);if(l.default.isAbsolute(e.DestinationDir)){throw new Error("destination_dir should be a relative path")}const n=(()=>{if(e.DestinationDir===""){return r}else{return l.default.join(r,e.DestinationDir)}})();a.info(`[INFO] ForceOrphan: ${e.ForceOrphan}`);if(e.ForceOrphan){await d.createDir(n);a.info(`[INFO] chdir ${r}`);process.chdir(r);await createBranchForce(e.PublishBranch);await copyAssets(s,n,e.ExcludeAssets);return}const o={exitcode:0,output:""};const i={listeners:{stdout:e=>{o.output+=e.toString()}}};try{o.exitcode=await c.exec("git",["clone","--depth=1","--single-branch","--branch",e.PublishBranch,t,r],i);if(o.exitcode===0){await d.createDir(n);if(e.KeepFiles){a.info("[INFO] Keep existing files")}else{a.info(`[INFO] clean up ${n}`);a.info(`[INFO] chdir ${n}`);process.chdir(n);await c.exec("git",["rm","-r","--ignore-unmatch","*"])}a.info(`[INFO] chdir ${r}`);process.chdir(r);await copyAssets(s,n,e.ExcludeAssets);return}else{throw new Error(`Failed to clone remote branch ${e.PublishBranch}`)}}catch(t){a.info(`[INFO] first deployment, create new branch ${e.PublishBranch}`);a.info(`[INFO] ${t.message}`);await d.createDir(n);a.info(`[INFO] chdir ${r}`);process.chdir(r);await createBranchForce(e.PublishBranch);await copyAssets(s,n,e.ExcludeAssets);return}}t.setRepo=setRepo;function getUserName(e){if(e){return e}else{return`${process.env.GITHUB_ACTOR}`}}t.getUserName=getUserName;function getUserEmail(e){if(e){return e}else{return`${process.env.GITHUB_ACTOR}@users.noreply.github.com`}}t.getUserEmail=getUserEmail;async function setCommitAuthor(e,t){if(e&&!t){throw new Error("user_email is undefined")}if(!e&&t){throw new Error("user_name is undefined")}await c.exec("git",["config","user.name",getUserName(e)]);await c.exec("git",["config","user.email",getUserEmail(t)])}t.setCommitAuthor=setCommitAuthor;function getCommitMessage(e,t,r,s,n){const o=(()=>{if(r){return`${s}@${n}`}else{return n}})();const i=(()=>{if(t){return t}else if(e){return`${e} ${o}`}else{return`deploy: ${o}`}})();return i}t.getCommitMessage=getCommitMessage;async function commit(e,t){try{if(e){await c.exec("git",["commit","--allow-empty","-m",`${t}`])}else{await c.exec("git",["commit","-m",`${t}`])}}catch(e){a.info("[INFO] skip commit");a.debug(`[INFO] skip commit ${e.message}`)}}t.commit=commit;async function push(e,t){if(t){await c.exec("git",["push","origin","--force",e])}else{await c.exec("git",["push","origin",e])}}t.push=push;async function pushTag(e,t){if(e===""){return}let r="";if(t){r=t}else{r=`Deployment ${e}`}await c.exec("git",["tag","-a",`${e}`,"-m",`${r}`]);await c.exec("git",["push","origin",`${e}`])}t.pushTag=pushTag},6144:function(e,t,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,t,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,s){if(s===undefined)s=r;e[s]=t[r]});var n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.prototype.hasOwnProperty.call(e,r))s(t,e,r);n(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});const i=o(r(2186));const a=o(r(399));(async()=>{try{await a.run()}catch(e){i.setFailed(`Action failed with "${e.message}"`)}})()},399:function(e,t,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,t,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,s){if(s===undefined)s=r;e[s]=t[r]});var n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.prototype.hasOwnProperty.call(e,r))s(t,e,r);n(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.run=void 0;const i=r(5438);const a=o(r(2186));const c=o(r(1514));const u=o(r(5438));const l=r(6450);const f=r(9516);const p=r(7213);const d=r(1314);async function run(){try{a.info("[INFO] Usage https://github.com/peaceiris/actions-gh-pages#readme");const e=l.getInputs();a.startGroup("Dump inputs");l.showInputs(e);a.endGroup();if(a.isDebug()){a.startGroup("Debug: dump context");console.log(i.context);a.endGroup()}const t=i.context.eventName;if(t==="pull_request"||t==="push"){const t=i.context.payload.repository.fork;const r=await d.skipOnFork(t,e.GithubToken,e.DeployKey,e.PersonalToken);if(r){a.warning("This action runs on a fork and not found auth token, Skip deployment");a.setOutput("skip","true");return}}a.startGroup("Setup auth token");const r=await f.setTokens(e);a.debug(`remoteURL: ${r}`);a.endGroup();a.startGroup("Prepare publishing assets");const s=new Date;const n=s.getTime();const o=await d.getWorkDirName(`${n}`);await p.setRepo(e,r,o);await d.addNoJekyll(o,e.DisableNoJekyll);await d.addCNAME(o,e.CNAME);a.endGroup();a.startGroup("Setup Git config");try{await c.exec("git",["remote","rm","origin"])}catch(e){a.info(`[INFO] ${e.message}`)}await c.exec("git",["remote","add","origin",r]);await c.exec("git",["add","--all"]);await p.setCommitAuthor(e.UserName,e.UserEmail);a.endGroup();a.startGroup("Create a commit");const h=`${process.env.GITHUB_SHA}`;const g=`${u.context.repo.owner}/${u.context.repo.repo}`;const m=p.getCommitMessage(e.CommitMessage,e.FullCommitMessage,e.ExternalRepository,g,h);await p.commit(e.AllowEmptyCommit,m);a.endGroup();a.startGroup("Push the commit or tag");await p.push(e.PublishBranch,e.ForceOrphan);await p.pushTag(e.TagName,e.TagMessage);a.endGroup();a.info("[INFO] Action successfully completed");return}catch(e){throw new Error(e.message)}}t.run=run},9516:function(e,t,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,t,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,s){if(s===undefined)s=r;e[s]=t[r]});var n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.prototype.hasOwnProperty.call(e,r))s(t,e,r);n(t,e);return t};var i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:true});t.setTokens=t.getPublishRepo=t.setPersonalToken=t.setGithubToken=t.setSSHKey=void 0;const a=o(r(2186));const c=o(r(1514));const u=o(r(5438));const l=o(r(7436));const f=i(r(5622));const p=i(r(5747));const d=r(3129).spawnSync;const h=r(3129).execFileSync;const g=r(1314);const m=r(7213);async function setSSHKey(e,t){a.info("[INFO] setup SSH deploy key");const r=await g.getHomeDir();const s=f.default.join(r,".ssh");await l.mkdirP(s);await c.exec("chmod",["700",s]);const n=f.default.join(s,"known_hosts");const o=`# ${m.getServerUrl().host}.com:22 SSH-2.0-babeld-1f0633a6\n${m.getServerUrl().host} ssh-rsa AAAAB3NzaC1yc2EAAAABIwAAAQEAq2A7hRGmdnm9tUDbO9IDSwBK6TbQa+PXYPCPy6rbTrTtw7PHkccKrpp0yVhp5HdEIcKr6pLlVDBfOLX9QUsyCOV0wzfjIJNlGEYsdlLJizHhbn2mUjvSAHQqZETYP81eFzLQNnPHt4EVVUh7VfDESU84KezmD5QlWpXLmvU31/yMf+Se8xhHTvKSCZIFImWwoG6mbUoWf9nzpIoaSjB+weqqUUmpaaasXVal72J+UX2B+2RPW3RcT0eOzQgqlJL3RKrTJvdsjE3JEAvGq3lGHSZXy28G3skua2SmVi/w4yCE6gbODqnTWlg7+wC604ydGXA8VJiS5ap43JXiUFFAaQ==\n`;p.default.writeFileSync(n,o+"\n");a.info(`[INFO] wrote ${n}`);await c.exec("chmod",["600",n]);const i=f.default.join(s,"github");p.default.writeFileSync(i,e.DeployKey+"\n");a.info(`[INFO] wrote ${i}`);await c.exec("chmod",["600",i]);const u=f.default.join(s,"config");const y=`Host ${m.getServerUrl().host}\n HostName ${m.getServerUrl().host}\n IdentityFile ~/.ssh/github\n User git\n`;p.default.writeFileSync(u,y+"\n");a.info(`[INFO] wrote ${u}`);await c.exec("chmod",["600",u]);if(process.platform==="win32"){a.warning(`Currently, the deploy_key option is not supported on the windows-latest.\nWatch https://github.com/peaceiris/actions-gh-pages/issues/87\n`);await d("Start-Process",["powershell.exe","-Verb","runas"]);await d("sh",["-c","'eval \"$(ssh-agent)\"'"],{shell:true});await c.exec("sc",["config","ssh-agent","start=auto"]);await c.exec("sc",["start","ssh-agent"])}await h("ssh-agent",["-a","/tmp/ssh-auth.sock"]);a.exportVariable("SSH_AUTH_SOCK","/tmp/ssh-auth.sock");await c.exec("ssh-add",[i]);return`git@${m.getServerUrl().host}:${t}.git`}t.setSSHKey=setSSHKey;function setGithubToken(e,t,r,s,n,o){a.info("[INFO] setup GITHUB_TOKEN");a.debug(`ref: ${n}`);a.debug(`eventName: ${o}`);let i=false;if(s){throw new Error(`The generated GITHUB_TOKEN (github_token) does not support to push to an external repository.\nUse deploy_key or personal_token.\n`)}if(o==="push"){i=n.match(new RegExp(`^refs/heads/${r}$`))!==null;if(i){throw new Error(`You deploy from ${r} to ${r}\nThis operation is prohibited to protect your contents\n`)}}return`https://x-access-token:${e}@${m.getServerUrl().host}/${t}.git`}t.setGithubToken=setGithubToken;function setPersonalToken(e,t){a.info("[INFO] setup personal access token");return`https://x-access-token:${e}@${m.getServerUrl().host}/${t}.git`}t.setPersonalToken=setPersonalToken;function getPublishRepo(e,t,r){if(e){return e}return`${t}/${r}`}t.getPublishRepo=getPublishRepo;async function setTokens(e){try{const t=getPublishRepo(e.ExternalRepository,u.context.repo.owner,u.context.repo.repo);if(e.DeployKey){return setSSHKey(e,t)}else if(e.PersonalToken){return setPersonalToken(e.PersonalToken,t)}else if(e.GithubToken){const r=u.context;const s=r.ref;const n=r.eventName;return setGithubToken(e.GithubToken,t,e.PublishBranch,e.ExternalRepository,s,n)}else{throw new Error("not found deploy key or tokens")}}catch(e){throw new Error(e.message)}}t.setTokens=setTokens},1314:function(e,t,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,t,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return t[r]}})}:function(e,t,r,s){if(s===undefined)s=r;e[s]=t[r]});var n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)if(r!=="default"&&Object.prototype.hasOwnProperty.call(e,r))s(t,e,r);n(t,e);return t};var i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:true});t.skipOnFork=t.addCNAME=t.addNoJekyll=t.createDir=t.getWorkDirName=t.getHomeDir=void 0;const a=o(r(2186));const c=o(r(7436));const u=i(r(5622));const l=i(r(5747));async function getHomeDir(){let e="";if(process.platform==="win32"){e=process.env["USERPROFILE"]||"C:\\"}else{e=`${process.env.HOME}`}a.debug(`homeDir: ${e}`);return e}t.getHomeDir=getHomeDir;async function getWorkDirName(e){const t=await getHomeDir();const r=u.default.join(t,`actions_github_pages_${e}`);return r}t.getWorkDirName=getWorkDirName;async function createDir(e){await c.mkdirP(e);a.debug(`Created directory ${e}`);return}t.createDir=createDir;async function addNoJekyll(e,t){if(t){return}const r=u.default.join(e,".nojekyll");if(l.default.existsSync(r)){return}l.default.closeSync(l.default.openSync(r,"w"));a.info(`[INFO] Created ${r}`)}t.addNoJekyll=addNoJekyll;async function addCNAME(e,t){if(t===""){return}const r=u.default.join(e,"CNAME");if(l.default.existsSync(r)){a.info(`CNAME already exists, skip adding CNAME`);return}l.default.writeFileSync(r,t+"\n");a.info(`[INFO] Created ${r}`)}t.addCNAME=addCNAME;async function skipOnFork(e,t,r,s){if(e){if(t===""&&r===""&&s===""){return true}}return false}t.skipOnFork=skipOnFork},2877:module=>{module.exports=eval("require")("encoding")},2357:e=>{"use strict";e.exports=require("assert")},3129:e=>{"use strict";e.exports=require("child_process")},6417:e=>{"use strict";e.exports=require("crypto")},8614:e=>{"use strict";e.exports=require("events")},5747:e=>{"use strict";e.exports=require("fs")},8605:e=>{"use strict";e.exports=require("http")},7211:e=>{"use strict";e.exports=require("https")},1631:e=>{"use strict";e.exports=require("net")},2087:e=>{"use strict";e.exports=require("os")},5622:e=>{"use strict";e.exports=require("path")},2413:e=>{"use strict";e.exports=require("stream")},4304:e=>{"use strict";e.exports=require("string_decoder")},8213:e=>{"use strict";e.exports=require("timers")},4016:e=>{"use strict";e.exports=require("tls")},8835:e=>{"use strict";e.exports=require("url")},1669:e=>{"use strict";e.exports=require("util")},8761:e=>{"use strict";e.exports=require("zlib")}};var __webpack_module_cache__={};function __nccwpck_require__(e){if(__webpack_module_cache__[e]){return __webpack_module_cache__[e].exports}var t=__webpack_module_cache__[e]={id:e,loaded:false,exports:{}};var r=true;try{__webpack_modules__[e].call(t.exports,t,t.exports,__nccwpck_require__);r=false}finally{if(r)delete __webpack_module_cache__[e]}t.loaded=true;return t.exports}(()=>{__nccwpck_require__.nmd=(e=>{e.paths=[];if(!e.children)e.children=[];return e})})();__nccwpck_require__.ab=__dirname+"/";return __nccwpck_require__(6144)})(); \ No newline at end of file