-
Notifications
You must be signed in to change notification settings - Fork 21
Expand file tree
/
Copy path.pre-commit-config.yaml
More file actions
68 lines (68 loc) · 1.93 KB
/
.pre-commit-config.yaml
File metadata and controls
68 lines (68 loc) · 1.93 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
exclude: '^r10k_modules/'
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v6.0.0
hooks:
- id: check-executables-have-shebangs
- id: check-json
- id: check-yaml
# - id: detect-private-key
- id: end-of-file-fixer
- id: trailing-whitespace
- repo: https://github.com/chriskuehl/puppet-pre-commit-hooks.git
rev: v2.2.0
hooks:
- id: puppet-validate
exclude: '^modules/\w+/plans'
- id: erb-validate
- id: epp-validate
- id: puppet-lint
args:
- --fix
- --fail-on-warnings
- --no-documentation-check
- --no-slash_comments
- --no-unquoted_resource_title
- --no-140chars-check
- repo: https://github.com/jumanjihouse/pre-commit-hooks
rev: 3.0.0
hooks:
- id: shellcheck
- repo: https://github.com/gruntwork-io/pre-commit
rev: v0.1.30
hooks:
- id: terraform-fmt
- id: terraform-validate
# - id: tflint
- repo: local
hooks:
# pre-commit hooks that will block erb scripts
# - enable once we've gotten rid of them all
# - https://mozilla-hub.atlassian.net/browse/RELOPS-1832
# - https://mozilla-hub.atlassian.net/browse/RELOPS-1833
#
# - id: erb-no-shebang
# name: .erb and .epp files must not have a shebang
# language: pygrep
# entry: '^#!'
# files: \.(erb|epp)$
# - id: forbid-scriptlike-erb
# name: Disallow script-like ERB/EPP filenames
# language: system
# entry: |
# bash -c '
# ret=0
# for f in "$@"; do
# if [[ "$f" =~ \.(sh|bash|zsh|ps1|cmd)\.erb$ ]]; then
# echo "Disallowed ERB/EPP filename (scripts should not be templated): $f"
# ret=1
# fi
# done
# exit $ret
# '
# files: \.(sh|bash|zsh|ps1|cmd)\.(erb|epp)$
- id: templated-script-checker
name: Syntax check ERB/EPP-templated scripts
language: system
entry: .pre-commit/templated_script_checker.py
types: [file]