-
-
Notifications
You must be signed in to change notification settings - Fork 1
/
.pre-commit-config.yaml
98 lines (82 loc) · 2.1 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
---
fail_fast: true
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.3.0
hooks:
- id: check-toml
stages: [commit]
- id: end-of-file-fixer
stages: [commit]
- id: trailing-whitespace
stages: [commit]
- id: check-yaml
stages: [commit]
- id: detect-private-key
stages: [commit]
- id: check-executables-have-shebangs
stages: [commit]
- id: check-shebang-scripts-are-executable
stages: [commit]
- repo: local
hooks:
- id: test
name: Run Tests
entry: poetry run python -m pytest
pass_filenames: false
language: system
stages: [push]
- id: checkov
name: Run Checkov
entry: |
poetry run checkov --config-file .checkov --baseline .checkov.baseline
pass_filenames: false
language: system
stages: [push]
- id: black
name: Run Black
entry: poetry run black
language: system
types: [file, python]
stages: [commit]
- id: isort
name: Run Isort
entry: poetry run isort
language: system
types: [file, python]
stages: [commit]
- id: flake8
name: Run Flake8
entry: poetry run pflake8
language: system
types: [file, python]
stages: [commit]
- id: yamllint
name: Run Yamllint
entry: poetry run yamllint
language: system
types: [file, yaml]
stages: [commit]
- id: bandit
name: Run Bandit
entry: poetry run bandit
language: system
types: [file, python]
args:
[
--configfile,
pyproject.toml,
--severity-level,
all,
--confidence-level,
all,
--quiet,
--format,
custom,
]
stages: [commit]
- id: commit-message
name: Check commit message
entry: poetry run cz check --commit-msg-file
language: system
stages: [commit-msg]