-
Notifications
You must be signed in to change notification settings - Fork 4
/
.pre-commit-config.yaml
60 lines (54 loc) · 1.7 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
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.4.0
hooks:
# Git style
- id: check-added-large-files
- id: check-merge-conflict
- id: check-vcs-permalinks
- id: forbid-new-submodules
- id: no-commit-to-branch
args: ['--pattern', '/^((?!(feature|bugfix|breaking)\/(DATA-)[0-9]{3,}_).)*$/gm']
# Common errors
- id: end-of-file-fixer
- id: trailing-whitespace
args: [--markdown-linebreak=md]
- id: check-yaml
- id: check-merge-conflict
- id: check-executables-have-shebangs
# Cross platform
- id: check-case-conflict
- id: mixed-line-ending
args: [--fix=lf]
# Security
- id: detect-aws-credentials
args: ['--allow-missing-credentials']
- id: detect-private-key
- repo: https://github.com/antonbabenko/pre-commit-terraform
rev: v1.77.1
hooks:
- id: terraform_fmt
- id: terraform_tflint
args:
- --args=--disable-rule=terraform_required_version
- --args=--disable-rule=terraform_required_providers
- --args=--disable-rule=terraform_unused_declarations
- id: terraform_docs
args:
- --hook-config=--path-to-file=./README.md
- --hook-config=--add-to-exiting-file=true
- --hook-config=--create-file-if-not-exist=true
- --args=--sort-by required
- id: terraform_checkov
args:
- --args=-d .
- --args=--skip-check CKV2_GIT_1
- repo: https://github.com/Yelp/detect-secrets.git
rev: v1.4.0
hooks:
- id: detect-secrets
name: Detect secrets
always_run: true
description: Detects high entropy strings that are likely to be passwords.
entry: detect-secrets-hook
files: .*\.(json|yml|yaml|tf)$