docs: clarify low-effort PR handling

This commit is contained in:
Danila Poyarkov 2026-06-07 01:23:23 +03:00
parent e66a20747e
commit ae4a0f9882
3 changed files with 10 additions and 10 deletions

View file

@ -156,7 +156,7 @@ await github<unknown>(`/repos/${owner}/${repo}/issues/${issueNumber}/labels`, {
await github<unknown>(`/repos/${owner}/${repo}/issues/${issueNumber}/comments`, {
method: 'POST',
body: JSON.stringify({
body: 'Closing this as invalid because CodeRabbit failed the PR Hygiene check. See `CONTRIBUTING.md` and the PR template before opening a new PR.'
body: 'Closing this as a low-effort PR because CodeRabbit failed the PR Hygiene check. See `CONTRIBUTING.md` and the PR template before opening a new PR. If you are sure this was closed by mistake, please file an issue with a link to this PR and the relevant context.'
})
})

View file

@ -1,4 +1,4 @@
name: Close invalid PRs
name: Close low-effort PRs
on:
pull_request_review:
@ -7,13 +7,13 @@ on:
types: [created, edited]
concurrency:
group: close-invalid-prs-${{ github.event.pull_request.number || github.event.issue.number }}
group: close-low-effort-prs-${{ github.event.pull_request.number || github.event.issue.number }}
cancel-in-progress: false
jobs:
# This job only reacts to CodeRabbit PR Hygiene pre-merge failures and never runs contributor code.
close-invalid:
name: Close PRs failed by PR Hygiene
close-low-effort:
name: Close low-effort PRs
runs-on: ubuntu-latest
permissions:
contents: read
@ -31,12 +31,12 @@ jobs:
with:
node-version: 24
- name: Close PR when CodeRabbit fails PR Hygiene
- name: Close low-effort PR when CodeRabbit fails PR Hygiene
env:
GITHUB_TOKEN: ${{ github.token }}
run: |
if [ ! -f .github/scripts/close-invalid-prs.ts ]; then
echo "Trusted close-invalid helper is not present on the default branch yet."
if [ ! -f .github/scripts/close-low-effort-prs.ts ]; then
echo "Trusted close-low-effort helper is not present on the default branch yet."
exit 0
fi
node --experimental-strip-types .github/scripts/close-invalid-prs.ts
node --experimental-strip-types .github/scripts/close-low-effort-prs.ts

View file

@ -41,7 +41,7 @@ Pull requests must be reviewable without guessing the author's intent.
Do not submit placeholder PRs. Remove template comments before opening a PR. Do not leave dangling issue references such as `Fixes #`, `TODO`, `TBD`, empty headings, unfilled sections, or similar unfinished text.
PRs from external contributors that ignore the template, omit validation, are not written in English, or otherwise do not follow these guidelines may be labeled `invalid` and closed automatically.
CodeRabbit enforces these PR rules through PR Hygiene checks. Low-effort PRs from external contributors that ignore the template, omit validation, are not written in English, or otherwise do not follow these guidelines may be labeled `invalid` and closed automatically. If you are unsure how to fix something, please open a detailed issue instead of submitting a placeholder PR. If you are sure your PR was closed by mistake, please file an issue with the PR link and context.
## Quality checks