-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.pre-commit-config.yaml
90 lines (78 loc) · 2.16 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
repos:
- repo: local
hooks:
- id: isort
name: isort
language: system
entry: isort
types: [python]
- id: black
name: black
language: system
entry: black
types: [python]
- id: trailing-whitespace
name: trailing-whitespace
language: system
entry: trailing-whitespace-fixer
types: [python]
exclude: __main__\.py
- id: end-of-file-fixer
name: end-of-file-fixer
language: system
entry: end-of-file-fixer
types: [python]
- id: mixed-line-ending
name: mixed-line-ending
language: system
entry: mixed-line-ending
types: [python]
args: ["--fix=lf"]
- id: fix-encoding-pragma
name: fix-encoding-pragma
language: system
entry: fix-encoding-pragma
types: [python]
args: ["--remove"]
- id: check-case-conflict
name: check-case-conflict
language: system
entry: check-case-conflict
types: [python]
- id: check-docstring-first
name: check-docstring-first
language: system
entry: check-docstring-first
types: [python]
exclude: (a2c|actorch/envs/utils|algorithm|distributed_trainable|network|reinforce|version)\.py
- id: check-merge-conflict
name: check-merge-conflict
language: system
entry: check-merge-conflict
types: [file]
- id: flake8
name: flake8 except __init__.py
language: system
entry: flake8
types: [python]
exclude: examples|(/__init__|__main__)\.py$
- id: flake8
name: flake8 only __init__.py
language: system
entry: flake8
types: [python]
# Ignore unused imports in __init__.py
args: ["--extend-ignore=F401"]
files: /__init__\.py$
- id: mypy
name: mypy
language: system
entry: mypy
types: [python]
exclude: (conf\.py|setup\.py|^tests/)
- id: pytest
name: pytest
language: system
entry: pytest
types: [python]
files: ^test