-
Notifications
You must be signed in to change notification settings - Fork 0
/
.pre-commit-config.yaml
67 lines (61 loc) · 1.61 KB
/
.pre-commit-config.yaml
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
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
# Install pre-commit hooks via:
# pre-commit install
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.5.0
hooks:
- id: end-of-file-fixer
- id: trailing-whitespace
- id: check-merge-conflict
- id: check-yaml
- id: check-json
- id: fix-encoding-pragma
args: [--remove]
- id: mixed-line-ending
args: [--fix=lf]
- repo: https://github.com/asottile/pyupgrade
rev: v3.15.0
hooks:
- id: pyupgrade
args: [--py37-plus]
- repo: https://github.com/ikamensh/flynt/
rev: 1.0.1
hooks:
- id: flynt
args: [--line-length=120, --fail-on-change]
- repo: https://github.com/executablebooks/mdformat
rev: "0.7.16"
hooks:
- id: mdformat
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.1.13
hooks:
- id: ruff-format
- id: ruff
args: [--fix, --exit-non-zero-on-fix, --show-fixes]
- repo: https://github.com/macisamuele/language-formatters-pre-commit-hooks
rev: v2.12.0
hooks:
- id: pretty-format-toml
args: [--autofix]
exclude: >-
(?x)^(
pyproject.toml
)$
- id: pretty-format-yaml
args: [--autofix, --preserve-quotes, --offset, "2"]
exclude: >-
(?x)^(
tests/.*|
environment.yml
)$
- repo: https://github.com/pre-commit/mirrors-mypy
rev: v1.8.0
hooks:
- id: mypy
args: [--config-file=pyproject.toml]
exclude: &exclude_files >
(?x)^(
docs/.*|
tests/.*(?<!\.py)$
)$