From ed7110838e60379835d537e620006020fbae2513 Mon Sep 17 00:00:00 2001 From: Scott Lahteine Date: Thu, 2 Jul 2020 18:10:33 -0500 Subject: [PATCH] Patch Bad PR action --- .github/workflows/bad-target.md | 7 ------- .github/workflows/check-pr.yml | 21 +++++++++++++-------- 2 files changed, 13 insertions(+), 15 deletions(-) delete mode 100644 .github/workflows/bad-target.md diff --git a/.github/workflows/bad-target.md b/.github/workflows/bad-target.md deleted file mode 100644 index 048e56cfd1..0000000000 --- a/.github/workflows/bad-target.md +++ /dev/null @@ -1,7 +0,0 @@ -Thanks for your contribution! Unfortunately we can't accept PRs directed at release branches. We make patches to the bugfix branches and only later do we push them out as releases. - -Please redo this PR starting with the `bugfix-2.0.x` branch and be careful to target `bugfix-2.0.x` when resubmitting the PR. - -It may help to set your fork's default branch to `bugfix-2.0.x`. - -See [this page](http://marlinfw.org/docs/development/getting_started_pull_requests.html) for full instructions. diff --git a/.github/workflows/check-pr.yml b/.github/workflows/check-pr.yml index a6246a3786..744bdd20cf 100644 --- a/.github/workflows/check-pr.yml +++ b/.github/workflows/check-pr.yml @@ -1,6 +1,6 @@ # -# comment-pr.yml -# Add a comment to any PR directed to a release branch +# check-pr.yml +# Close PRs directed at release branches # name: PR Bad Target @@ -19,9 +19,14 @@ jobs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v1 - - uses: harupy/comment-on-pr@master - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - with: - filename: bad-target.md + - uses: peter-evans/close-pull@v1 + with: + delete-branch: false + comment: > + Thanks for your contribution! Unfortunately we can't accept PRs directed at release branches. We make patches to the bugfix branches and only later do we push them out as releases. + + Please redo this PR starting with the `bugfix-2.0.x` branch and be careful to target `bugfix-2.0.x` when resubmitting the PR. + + It may help to set your fork's default branch to `bugfix-2.0.x`. + + See [this page](http://marlinfw.org/docs/development/getting_started_pull_requests.html) for full instructions.