From 0c21c327dfb16f0a4fb5952bf1dfc6e401a0de3a Mon Sep 17 00:00:00 2001 From: Robin Salen <30937548+Nashtare@users.noreply.github.com> Date: Wed, 26 Jun 2024 13:36:22 -0400 Subject: [PATCH] ci: add PR check job (#1604) --- .github/pr_checking.yml | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 .github/pr_checking.yml diff --git a/.github/pr_checking.yml b/.github/pr_checking.yml new file mode 100644 index 00000000..5bed881a --- /dev/null +++ b/.github/pr_checking.yml @@ -0,0 +1,22 @@ +name: PR check + +on: + pull_request_target: + types: + - opened + - edited + - synchronize + +jobs: + title: + name: Validate PR + runs-on: ubuntu-latest + if: ${{ + github.event.pull_request.author_association != 'CONTRIBUTOR' && + github.event.pull_request.author_association != 'MEMBER' && + ( + contains(fromJSON(secrets.RESTRICTED_KEYWORDS), github.event.pull_request.title) || + contains(fromJSON(secrets.RESTRICTED_KEYWORDS), github.event.pull_request.description + ) }} + steps: + - run: gh pr close