forked from serenita-org/vero
-
Notifications
You must be signed in to change notification settings - Fork 0
36 lines (28 loc) · 875 Bytes
/
Copy pathpre-commit.yml
File metadata and controls
36 lines (28 loc) · 875 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
name: pre-commit
permissions:
contents: read
on:
pull_request:
branches: [ "master" ]
push:
branches: [ "master" ]
jobs:
pre-commit:
runs-on: ubuntu-latest
env:
PRE_COMMIT_HOME: ${{ github.workspace }}/.pre-commit
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- name: Install uv
uses: astral-sh/setup-uv@f0ec1fc3b38f5e7cd731bb6ce540c5af426746bb # v6.1.0
with:
activate-environment: true
- name: Cache pre-commit
uses: actions/cache@5a3ec84eff668545956fd18022155c47e93e2684 # v4.2.3
with:
path: ${{ env.PRE_COMMIT_HOME }}
key: pre-commit-${{ hashFiles('.pre-commit-config.yaml') }}
restore-keys: |
pre-commit-
- name: Run pre-commit
run: uv run pre-commit run --all-files --show-diff-on-failure --color=always