-
Notifications
You must be signed in to change notification settings - Fork 1
/
.pre-commit-config.yaml
87 lines (78 loc) · 2.3 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
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
# Initial content coming from
# https://github.com/pre-commit/pre-commit-hooks/blob/master/.pre-commit-config.yaml
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.4.0
hooks:
- id: trailing-whitespace
- id: end-of-file-fixer
- id: check-docstring-first
- id: check-json
- id: check-added-large-files
- id: check-yaml
- id: debug-statements
## Disabled because it compains about additional modules used in testing
#- id: name-tests-test
# args: ['--django']
- id: requirements-txt-fixer
- id: check-ast
- id: check-builtin-literals
- id: check-byte-order-marker
- id: check-case-conflict
- id: check-docstring-first
- id: check-executables-have-shebangs
- id: check-merge-conflict
- id: check-symlinks
- id: check-toml
- id: check-vcs-permalinks
- id: check-xml
- id: file-contents-sorter
- id: forbid-new-submodules
- id: mixed-line-ending
- id: pretty-format-json
- id: sort-simple-yaml
- repo: https://github.com/ambv/black
rev: 23.3.0
hooks:
- id: black
language_version: python3
# ruff is a replacement for flake8
- repo: https://github.com/charliermarsh/ruff-pre-commit
rev: v0.0.262
hooks:
- id: ruff
- repo: https://github.com/pre-commit/pre-commit
rev: v3.2.2
hooks:
- id: validate_manifest
- repo: https://github.com/asottile/reorder_python_imports
rev: v3.9.0
hooks:
- id: reorder-python-imports
args: [--py3-plus]
- repo: https://github.com/asottile/pyupgrade
rev: v3.3.1
hooks:
- id: pyupgrade
args: [--py36-plus]
- repo: https://github.com/asottile/add-trailing-comma
rev: v2.4.0
hooks:
- id: add-trailing-comma
args: [--py36-plus]
- repo: https://github.com/pre-commit/mirrors-mypy
rev: v1.2.0
hooks:
- id: mypy
additional_dependencies: [types-all, types-attrs]
- repo: https://github.com/jumanjihouse/pre-commit-hooks
rev: 3.0.0 # or specific git tag
hooks:
- id: shfmt
- repo: https://github.com/pre-commit/mirrors-prettier
rev: "v3.0.0-alpha.8-for-vscode"
hooks:
- id: prettier
exclude_types: [html]
stages: [commit]
# end