From 0827173781c81e2687bf5a10e0c1ad036064565d Mon Sep 17 00:00:00 2001 From: Sam Sung <51686767+samwhosung@users.noreply.github.com> Date: Sun, 2 Aug 2026 06:07:18 +0700 Subject: [PATCH] =?UTF-8?q?ci:=20auto-close=20pull=20requests=20=E2=80=94?= =?UTF-8?q?=20not=20accepting=20PRs,=20use=20Discord?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/close-prs.yml | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 .github/workflows/close-prs.yml diff --git a/.github/workflows/close-prs.yml b/.github/workflows/close-prs.yml new file mode 100644 index 00000000..f2b9dfc8 --- /dev/null +++ b/.github/workflows/close-prs.yml @@ -0,0 +1,21 @@ +# GitHub has no switch to disable pull requests, so this closes them on arrival. +# Uses pull_request_target (base-repo context, no PR code checked out) so it can +# comment and close on PRs from forks. +name: close-prs +on: + pull_request_target: + types: [opened, reopened] +permissions: + pull-requests: write +jobs: + close: + runs-on: ubuntu-latest + steps: + - run: | + gh pr comment "$PR" --repo "$REPO" --body \ + "Thanks for the interest! benilla is a solo project and isn't taking pull requests for now — please bring bug reports and ideas to the Discord instead: https://discord.gg/wJSJx467G4" + gh pr close "$PR" --repo "$REPO" + env: + GH_TOKEN: ${{ github.token }} + PR: ${{ github.event.pull_request.number }} + REPO: ${{ github.repository }}