-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.pre-commit-config.yaml
103 lines (103 loc) · 2.6 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
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
default_language_version:
python: python3.7
exclude: '^tests/samples/.*$'
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.3.0
hooks:
- id: trailing-whitespace
- id: check-added-large-files
- id: check-ast
- id: check-json
- id: check-merge-conflict
- id: check-shebang-scripts-are-executable
- id: check-symlinks
- id: check-toml
- id: check-vcs-permalinks
- id: check-xml
- id: check-yaml
- id: debug-statements
- id: destroyed-symlinks
- id: detect-aws-credentials
args: [ '--allow-missing-credentials' ]
- id: detect-private-key
- id: end-of-file-fixer
- id: fix-byte-order-marker
- id: fix-encoding-pragma
args: [ '--remove' ]
- id: forbid-new-submodules
- id: mixed-line-ending
args: [ '--fix=lf' ]
- id: name-tests-test
args: [ '--pytest-test-first' ]
- id: pretty-format-json
args: [
'--autofix',
'--indent 4',
'--no-sort-keys'
]
- repo: local
hooks:
- id: pylint
name: pylint
entry: pylint
language: system
types: [ python ]
args:
[
'--verbose',
'--rcfile=.pylintrc',
'-rn', # Only display messages
'-sn', # Don't display the score
]
- repo: https://github.com/PyCQA/autoflake
rev: v1.7.7
hooks:
- id: autoflake
name: autoflake
entry: autoflake
language: python
"types": [ python ]
require_serial: true
args: [
'--config=.autoflake.cfg',
]
- repo: https://github.com/PyCQA/isort
rev: 5.10.1
hooks:
- id: isort
args: [
'--verbose',
'--settings-path=.isort.cfg',
]
- repo: https://github.com/psf/black
rev: 22.10.0
hooks:
- id: black
language_version: python3
args: [
'--verbose',
'--config=.black',
'--diff',
]
- repo: https://github.com/asottile/blacken-docs
rev: v1.12.1
hooks:
- id: blacken-docs
additional_dependencies: [ black ]
- repo: https://github.com/PyCQA/flake8
rev: 5.0.4
hooks:
- id: flake8
additional_dependencies: [
mccabe,
pyflakes,
pycodestyle,
flake8-builtins,
flake8-comprehensions,
]
args: [
'--verbose',
'--config=.flake8',
'--require-plugins=mccabe,pyflakes,pycodestyle,flake8-builtins,flake8-comprehensions',
]