Files
2026-07-13 13:12:33 +08:00

34 lines
904 B
YAML

name: PR body lint
"on":
pull_request:
types: [opened, edited, synchronize, reopened, ready_for_review]
permissions:
contents: read
pull-requests: read
jobs:
validate-body:
name: Validate PR body fields
runs-on: ubuntu-latest
timeout-minutes: 5
steps:
- name: Check out trusted workflow scripts
uses: actions/checkout@v4
with:
ref: ${{ github.event.repository.default_branch }}
persist-credentials: false
- name: Check out bootstrap body linter before first merge
if: ${{ hashFiles('.github/scripts/validate_pr_body.py') == '' }}
uses: actions/checkout@v4
with:
ref: ${{ github.event.pull_request.head.sha }}
persist-credentials: false
- name: Validate PR body fields
env:
PR_BODY_LINT_STRICT: "0"
run: python3 .github/scripts/validate_pr_body.py