-
Notifications
You must be signed in to change notification settings - Fork 114
Expand file tree
/
Copy path.pre-commit-config.yaml
More file actions
34 lines (32 loc) · 933 Bytes
/
.pre-commit-config.yaml
File metadata and controls
34 lines (32 loc) · 933 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
# See https://pre-commit.com for more information
# See https://pre-commit.com/hooks.html for more hooks
repos:
- repo: local
hooks:
# Abort the commit if there is one or more linting errors
- id: lint
name: Check no linting errors
entry: ruff check --config ruff.toml
language: python
files: |
(?x)^(
generator/generate\.py|
tests/.*\.py|
generated/3.0/vlc\.py|
generated/dev/vlc\.py|
dev_setup\.py
)$
minimum_pre_commit_version: "2.9.2"
# Abort the commit if code wasn't formatted
- id: format
name: Check code is formatted
entry: ruff format --config ruff.toml --check --diff
language: python
files: |
(?x)^(
generator/generate\.py|
tests/.*\.py|
dev_setup\.py|
generator/templates/.*\.py
)$
minimum_pre_commit_version: "2.9.2"