From 6fee789f76ac806d1321ee13f91f644b724e0736 Mon Sep 17 00:00:00 2001 From: "Federico M. Facca" Date: Wed, 27 Sep 2023 20:29:02 +0200 Subject: [PATCH] Update add-to-project.yaml --- .github/workflows/add-to-project.yaml | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-) diff --git a/.github/workflows/add-to-project.yaml b/.github/workflows/add-to-project.yaml index 39ab0b76..35ba210e 100644 --- a/.github/workflows/add-to-project.yaml +++ b/.github/workflows/add-to-project.yaml @@ -50,13 +50,10 @@ jobs: runs-on: ubuntu-latest steps: - if: github.event_name == 'pull_request' - uses: actions/github-script@v6 + uses: rowi1de/auto-assign-review-teams@v1.1.3 with: - github-token: ${{secrets.GITHUB_TOKEN}} - script: | - github.rest.pulls.requestReviewers({ - owner: context.repo.owner, - repo: context.repo.repo, - pull_number: context.payload.pull_request.number, - team_reviewers: ["backend-devs"] # replace this with any team existing in your Github org - }); + repo-token: ${{ secrets.GITHUB_TOKEN }} + teams: ${{ inputs.reviewers-team != '' && inputs.reviewers-team || 'backend-devs' }} # only works for GitHub Organisation/Teams + persons: ${{ inputs.reviewers-individuals }} # add individual persons here + include-draft: false # Draft PRs will be skipped (default: false) + skip-with-manual-reviewers: 1 # Skip this action, if the number of reviwers was already assigned (default: 0)