-
Notifications
You must be signed in to change notification settings - Fork 214
/
.pre-commit-config.yaml
97 lines (97 loc) · 2.53 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
exclude: ^(.travis.yml|.pre-commit-config.yaml|.bumpversion.cfg)$
fail_fast: true
repos:
- repo: https://github.com/pre-commit/mirrors-isort
rev: v5.10.1
hooks:
- id: isort
# language_version: python3.6
- repo: https://github.com/ambv/black
rev: 22.3.0
hooks:
- id: black
exclude: regions_to_partitions.py
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v2.4.0
hooks:
- id: check-case-conflict
- id: end-of-file-fixer
- id: mixed-line-ending
args:
- --fix=lf
- id: trailing-whitespace
- id: flake8
additional_dependencies:
- flake8-bugbear>=19.3.0
- flake8-builtins>=1.4.1
- flake8-commas>=2.0.0
- flake8-comprehensions>=2.1.0
- flake8-debugger>=3.1.0
- flake8-pep3101>=1.2.1
- flake8-print>=3.1.0
# language_version: python3.6
- id: pretty-format-json
args:
- --autofix
- --indent=4
- --no-sort-keys
- id: check-merge-conflict
- repo: https://github.com/pre-commit/pygrep-hooks
rev: v1.9.0
hooks:
- id: python-check-blanket-noqa
- id: python-check-mock-methods
- id: python-no-log-warn
- repo: https://github.com/PyCQA/bandit
rev: 1.7.4
hooks:
- id: bandit
files: "^taskcat/"
#- repo: https://github.com/pre-commit/mirrors-mypy
# rev: v0.761
# hooks:
# - id: mypy
# files: "^taskcat/"
- repo: local
hooks:
- id: update-schema
name: update-schema
description: generate schema from dataclasses
entry: ./generate_schema.py
language: system
pass_filenames: false
always_run: true
- id: git-secrets-register-aws
name: git-secrets-register-aws
description: Register AWS patterns with git-secrets
entry: git-secrets --register-aws
language: system
always_run: true
pass_filenames: false
- id: git-secrets
name: git-secrets
description: Run git-secrets
entry: git-secrets --scan
language: system
always_run: true
- id: update-region-mappings
name: update-region-mappings
description: update region-partition mappings
entry: ./update_partition_region_map.py
language: system
pass_filenames: false
always_run: true
- id: pylint-local
name: pylint-local
description: Run pylint in the local virtualenv
entry: pylint "--disable=C0209" "taskcat/" "bin/"
language: system
pass_filenames: false
always_run: true
- id: pytest-local
name: pytest-local
description: Run pytest in the local virtualenv
entry: pytest --cov="./taskcat/"
language: system
pass_filenames: false
always_run: true