-
Notifications
You must be signed in to change notification settings - Fork 10
Expand file tree
/
Copy path.pre-commit-config.yaml
More file actions
51 lines (47 loc) · 1.21 KB
/
.pre-commit-config.yaml
File metadata and controls
51 lines (47 loc) · 1.21 KB
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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
exclude: '.*\.(csv|msp)$'
default_stages: [pre-commit]
default_language_version:
python: python3.12
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v5.0.0
hooks:
- id: trailing-whitespace
- id: end-of-file-fixer
- id: check-json
- id: check-toml
- id: check-xml
- id: check-yaml
- id: debug-statements
- id: check-builtin-literals
- id: check-case-conflict
- id: check-docstring-first
- id: detect-private-key
# Ruff linter (primary linter)
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.4.4
hooks:
- id: ruff
args: [--fix, --exit-non-zero-on-fix, .]
# Flake8 (optional, for CI or legacy)
- repo: https://github.com/pycqa/flake8
rev: 7.0.0
hooks:
- id: flake8
additional_dependencies: []
args: [
"--count",
"--select=E9,F63,F7,F82",
"--show-source",
"--statistics"
]
- id: flake8
name: flake8 (warnings)
additional_dependencies: []
args: [
"--count",
"--exit-zero",
"--max-complexity=10",
"--max-line-length=127",
"--statistics"
]