From a020e37e75ef0143b0ec7ccb93d2980b83497e84 Mon Sep 17 00:00:00 2001 From: Barry Pollard Date: Mon, 4 Oct 2021 19:17:02 +0100 Subject: [PATCH] Fix github scripts to v5 (#2032) --- .github/workflows/deploy-PROD-slim.yml | 4 ++-- .github/workflows/deploy-PROD-standard.yml | 4 ++-- .github/workflows/deploy-RELEASE-slim.yml | 4 ++-- .github/workflows/deploy-RELEASE-standard.yml | 4 ++-- .github/workflows/stale.yml | 2 +- 5 files changed, 9 insertions(+), 9 deletions(-) diff --git a/.github/workflows/deploy-PROD-slim.yml b/.github/workflows/deploy-PROD-slim.yml index 668d0610..529b7ee3 100644 --- a/.github/workflows/deploy-PROD-slim.yml +++ b/.github/workflows/deploy-PROD-slim.yml @@ -133,7 +133,7 @@ jobs: # https://octokit.github.io/rest.js/v18#issues-create github-token: ${{secrets.GITHUB_TOKEN}} script: | - const create = await github.issues.create({ + const create = await github.api.issues.create({ owner: context.repo.owner, repo: context.repo.repo, title: "Failed to deploy to production", @@ -152,7 +152,7 @@ jobs: # https://octokit.github.io/rest.js/v18#issues-create github-token: ${{secrets.GITHUB_TOKEN}} script: | - github.issues.addAssignees({ + github.api.issues.addAssignees({ owner: context.repo.owner, repo: context.repo.repo, issue_number: "${{ steps.create-issue.outputs.result }}", diff --git a/.github/workflows/deploy-PROD-standard.yml b/.github/workflows/deploy-PROD-standard.yml index 379b96e7..6cdab04f 100644 --- a/.github/workflows/deploy-PROD-standard.yml +++ b/.github/workflows/deploy-PROD-standard.yml @@ -133,7 +133,7 @@ jobs: # https://octokit.github.io/rest.js/v18#issues-create github-token: ${{secrets.GITHUB_TOKEN}} script: | - const create = await github.issues.create({ + const create = await github.api.issues.create({ owner: context.repo.owner, repo: context.repo.repo, title: "Failed to deploy to production", @@ -152,7 +152,7 @@ jobs: # https://octokit.github.io/rest.js/v18#issues-create github-token: ${{secrets.GITHUB_TOKEN}} script: | - github.issues.addAssignees({ + github.api.issues.addAssignees({ owner: context.repo.owner, repo: context.repo.repo, issue_number: "${{ steps.create-issue.outputs.result }}", diff --git a/.github/workflows/deploy-RELEASE-slim.yml b/.github/workflows/deploy-RELEASE-slim.yml index d0e1a86e..5ea1bb95 100644 --- a/.github/workflows/deploy-RELEASE-slim.yml +++ b/.github/workflows/deploy-RELEASE-slim.yml @@ -167,7 +167,7 @@ jobs: # https://octokit.github.io/rest.js/v18#issues-create github-token: ${{secrets.GITHUB_TOKEN}} script: | - const create = await github.issues.create({ + const create = await github.api.issues.create({ owner: context.repo.owner, repo: context.repo.repo, title: "Failed to deploy release to production", @@ -186,7 +186,7 @@ jobs: # https://octokit.github.io/rest.js/v18#issues-create github-token: ${{secrets.GITHUB_TOKEN}} script: | - github.issues.addAssignees({ + github.apiissues.addAssignees({ owner: context.repo.owner, repo: context.repo.repo, issue_number: "${{ steps.create-issue.outputs.result }}", diff --git a/.github/workflows/deploy-RELEASE-standard.yml b/.github/workflows/deploy-RELEASE-standard.yml index f6f3d3c1..082fdd74 100644 --- a/.github/workflows/deploy-RELEASE-standard.yml +++ b/.github/workflows/deploy-RELEASE-standard.yml @@ -167,7 +167,7 @@ jobs: # https://octokit.github.io/rest.js/v18#issues-create github-token: ${{secrets.GITHUB_TOKEN}} script: | - const create = await github.issues.create({ + const create = await github.api.issues.create({ owner: context.repo.owner, repo: context.repo.repo, title: "Failed to deploy release to production", @@ -186,7 +186,7 @@ jobs: # https://octokit.github.io/rest.js/v18#issues-create github-token: ${{secrets.GITHUB_TOKEN}} script: | - github.issues.addAssignees({ + github.api.issues.addAssignees({ owner: context.repo.owner, repo: context.repo.repo, issue_number: "${{ steps.create-issue.outputs.result }}", diff --git a/.github/workflows/stale.yml b/.github/workflows/stale.yml index 3523e8f9..6c98a731 100644 --- a/.github/workflows/stale.yml +++ b/.github/workflows/stale.yml @@ -53,7 +53,7 @@ jobs: uses: actions/github-script@v5 with: script: | - github.issues.removeLabel({ + github.rest.issues.removeLabel({ issue_number: context.issue.number, owner: context.repo.owner, repo: context.repo.repo,