openpencil/.github/workflows/pr-review-guidance.yml
2026-06-07 09:10:47 +03:00

42 lines
1.3 KiB
YAML

name: PR review guidance
on:
pull_request_review:
types: [submitted]
issue_comment:
types: [created, edited]
concurrency:
group: pr-review-guidance-${{ github.event.pull_request.number || github.event.issue.number }}
cancel-in-progress: false
jobs:
# This job only records CodeRabbit PR review guidance and never runs contributor code.
pr-review-guidance:
name: Record PR review guidance
runs-on: ubuntu-latest
permissions:
contents: read
pull-requests: read
steps:
- name: Check out trusted workflow scripts
uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5
with:
ref: ${{ github.event.repository.default_branch }}
persist-credentials: false
- name: Set up Node.js
uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020
with:
node-version: 24
- name: Record CodeRabbit review guidance
env:
GITHUB_TOKEN: ${{ github.token }}
run: |
if [ ! -f tools/pr-review-guidance/src/index.ts ]; then
echo "Trusted PR review guidance helper is not present on the default branch yet."
exit 0
fi
node --experimental-strip-types tools/pr-review-guidance/src/index.ts