This commit is contained in:
Taylor Howell
2026-02-18 12:35:08 +00:00
parent 6b197e198a
commit bb0b5ca521
2 changed files with 26 additions and 0 deletions
+20
View File
@@ -0,0 +1,20 @@
# Run pre-commit hooks on files changed in the PR only.
name: lint
on:
pull_request:
jobs:
pre-commit:
name: pre-commit
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: actions/setup-python@v5
with:
python-version: "3.12"
- uses: pre-commit/action@v3.0.1
with:
extra_args: --from-ref ${{ github.event.pull_request.base.sha }} --to-ref ${{ github.event.pull_request.head.sha }}