-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.pre-commit-config.yaml
62 lines (60 loc) · 1.66 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
default_stages: [commit]
default_language_version:
python: python3.10
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.3.0
hooks:
- id: check-json
- id: check-yaml
- id: check-toml
- id: check-xml
- id: debug-statements
- id: end-of-file-fixer
# Override default [push, commit]
stages: [commit]
- id: requirements-txt-fixer
- id: trailing-whitespace
# Override default [push, commit]
stages: [commit]
- id: fix-encoding-pragma
args:
- --remove
- repo: https://github.com/asottile/pyupgrade
rev: v2.34.0
hooks:
- id: pyupgrade
args:
# We need percent format for sentry
- --keep-percent-format
- --keep-runtime-typing
- --py310-plus
- repo: https://github.com/psf/black
rev: 22.3.0
hooks:
- id: black
- repo: https://github.com/timothycrosley/isort
rev: 5.10.1
hooks:
- id: isort
- repo: https://github.com/Lucas-C/pre-commit-hooks
rev: v1.2.0
hooks:
- id: forbid-crlf
- id: remove-crlf
- repo: https://github.com/PyCQA/flake8
# flake8 has to be placed after hooks modifying the code
# (otherwise the reported line numbers would be inaccurate)
rev: 6.0.0
hooks:
- id: flake8
- repo: https://github.com/pre-commit/mirrors-mypy
# mypy has to be placed after hooks modifying the code
# (otherwise the reported line numbers would be inaccurate)
rev: v0.961
hooks:
- id: mypy
additional_dependencies: [typing_extensions]
- repo: meta
hooks:
- id: check-useless-excludes