-
Notifications
You must be signed in to change notification settings - Fork 104
/
.pre-commit-config.yaml
39 lines (35 loc) · 1.19 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
# See: https://pre-commit.com/hooks.html
# Must put flake8 in separate group so 'black' is executed first
# WARNING: Make sure to keep flags in sync with ci/run-linter.sh
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.1.0
hooks:
- id: double-quote-string-fixer
- id: check-docstring-first
- id: check-merge-conflict
- id: end-of-file-fixer
- id: trailing-whitespace
- repo: https://github.com/pre-commit/mirrors-isort
rev: v5.10.1
hooks:
- id: isort
args: ['--line-width=88', '--multi-line=3', '--force-grid-wrap=0', '--trailing-comma']
exclude: '(^docs|__init__)'
- repo: https://github.com/PyCQA/flake8
rev: 4.0.1
hooks:
- id: flake8
args: ['--max-line-length=88', '--ignore=W503,E402,E731,E741']
# apply once this handles long tables better
# - repo: https://github.com/PyCQA/doc8
# rev: 0.10.1
# hooks:
# - id: doc8
# args: ['--max-line-length', '88', '--allow-long-titles']
# apply after function keyword args can be ignored
# - repo: https://github.com/ambv/black
# rev: 22.1.0
# hooks:
# - id: black
# args: ['--line-length', '88', '--skip-string-normalization']