From dbbdf7124598e210c5e437c4a8e04aadb875d8b0 Mon Sep 17 00:00:00 2001 From: Renovate Bot Date: Tue, 15 Mar 2022 13:42:31 +0000 Subject: [PATCH 1/2] chore(deps): update actions/github-script action to v6 --- .github/workflows/main.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 6e9f62833aa..2e9f64fa3d0 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -83,7 +83,7 @@ jobs: working-directory: ./scripts - name: Create PR - uses: actions/github-script@v4.0.2 + uses: actions/github-script@v6.0.0 with: github-token: ${{secrets.YOSHI_CODE_BOT_TOKEN}} script: | From 291c0ef35b799e0e816d2980660b6a898d430a41 Mon Sep 17 00:00:00 2001 From: Anthonios Partheniou Date: Tue, 15 Mar 2022 14:23:19 +0000 Subject: [PATCH 2/2] chore: make script compatible with actions/github-script@v6.0.0 --- .github/workflows/main.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 2e9f64fa3d0..923ef772479 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -92,7 +92,7 @@ jobs: const branch = 'update-discovery-artifacts-${{ steps.date.outputs.current_date }}' let prBody = `${{ steps.pr_body.outputs.change_summary }}` const prTitle = 'chore: Update discovery artifacts' - const pullRequests = await github.pulls.list({ + const pullRequests = await github.rest.pulls.list({ owner: owner, repo: repo, head: `${owner}:${branch}`, @@ -101,7 +101,7 @@ jobs: if (pullRequests.data.length === 1) { prNumber = pullRequests.data[0].number - await github.pulls.update({ + await github.rest.pulls.update({ owner: owner, repo: repo, pull_number: prNumber, @@ -110,7 +110,7 @@ jobs: }) console.log('Updated PR') } else { - const createPrResult = await github.pulls.create({ + const createPrResult = await github.rest.pulls.create({ owner: owner, repo: repo, base: 'main',