diff --git a/.github/workflows/new_pull_request.yml b/.github/workflows/new_pull_request.yml new file mode 100644 index 0000000000..40b32154b2 --- /dev/null +++ b/.github/workflows/new_pull_request.yml @@ -0,0 +1,24 @@ +# This workflow runs whenever a new pull request is created +name: New Pull Request + +# Only run for "main" branch PRs +on: + pull_request: + branches: + - main + +jobs: + automation: + runs-on: ubuntu-latest + steps: + # Assign the PR to whomever created it. This is useful for visualizing assignments on project boards + # See https://github.com/marketplace/actions/pull-request-assigner + - name: Assign PR to creator + uses: thomaseizinger/assign-pr-creator-action@v1.0.0 + if: github.event_name == 'pull_request' && github.event.action == 'opened' + # Note, this authentication token is created automatically + # See: https://docs.github.com/en/actions/configuring-and-managing-workflows/authenticating-with-the-github_token + with: + repo-token: ${{ secrets.GITHUB_TOKEN }} + # Ignore errors. It is possible the PR was created by someone who cannot be assigned + continue-on-error: true