-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.pre-commit-hooks.yaml
More file actions
113 lines (100 loc) · 2.29 KB
/
Copy path.pre-commit-hooks.yaml
File metadata and controls
113 lines (100 loc) · 2.29 KB
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
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
---
- id: ansible-lint
name: ansible-lint
description: This hook runs ansible-lint.
entry: ansible-lint
args:
- -v
- --force-color
language: system
# do not pass files to ansible-lint, see:
# https://github.com/ansible/ansible-lint/issues/611
pass_filenames: false
always_run: true
- id: tf-fmt
name: Terraform fmt
entry: hooks/tf-fmt.sh
language: script
files: \.tf$
exclude: \.+.terraform\/.*$
require_serial: true
- id: tflint
name: tflint
description: Linter for Terraform source code
entry: hooks/tflint.sh
language: script
files: \.tf$
exclude: \.+.terraform\/.*$
- id: tf-checkov
name: checkov
description: Runs checkov on Terraform resourcecs
entry: hooks/tf_checkov.sh
language: script
always_run: false
files: \.tf$
exclude: \.terraform\/.*$
require_serial: true
- id: trivy
name: trivy
description: Scans for misconfigurations, vulnerabilities and secrets.
require_serial: true
entry: hooks/trivy.sh
language: script
- id: tf-validate
name: Terraform validation
entry: hooks/tf-validate.sh
language: script
files: \.tf$
exclude: \.+.terraform\/.*$
require_serial: true
- id: yamllint
name: yamllint
entry: hooks/yamllint.sh
language: script
files: \.ya?ml$
require_serial: true
- id: go-fmt
name: gofmt
entry: hooks/go-fmt.sh
language: script
files: \.go$
exclude: vendor\/.*$
- id: golangci-lint
name: golangci-lint
entry: hooks/golangci-lint.sh
types: [go]
language: script
require_serial: true
pass_filenames: true
- id: go-unit-tests
name: go unit tests
entry: hooks/go-unit-tests.sh
types: [go]
language: script
require_serial: true
pass_filenames: false
- id: shellcheck
name: Shellcheck
entry: hooks/shellcheck.sh
language: script
types:
- shell
- id: conventional-commit
name: Conventional commit checker
entry: hooks/conventional-commit.sh
language: script
description: Check whether commit messages comply with the conventional commit format
always_run: true
stages:
- commit-msg
- id: pylint
name: pylint
entry: hooks/pylint.sh
language: script
files: \.py$
- id: "gitleaks"
name: "Detect hardcoded secrets"
description: "Detect hardcoded secrets using Gitleaks"
entry: "hooks/gitleaks.sh"
language: "script"
pass_filenames: false