Kavita/.github/workflows/pr-check.yml
2026-03-03 14:40:28 -06:00

24 lines
587 B
YAML

name: Validate PR Body
on:
pull_request:
branches: [ main, develop, canary ]
types: [opened, synchronize, edited]
jobs:
check_pr:
runs-on: ubuntu-24.04
steps:
- name: Check PR Body
uses: actions/github-script@v7
with:
script: |
const checkBody = (bodyText) => {
if (/["`]/.test(bodyText)) {
core.setFailed('PR body must not contain double-quotes or backticks.');
}
};
const body = context.payload.pull_request?.body || '';
checkBody(body);