-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.pre-commit-config.yaml
More file actions
124 lines (113 loc) · 3.07 KB
/
.pre-commit-config.yaml
File metadata and controls
124 lines (113 loc) · 3.07 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
114
115
116
117
118
119
120
121
122
123
124
---
ci:
# Do not commit changes from running pre-commit for pull requests.
autofix_prs: false
# Autoupdate hooks weekly (this is the default).
autoupdate_schedule: weekly
default_language_version:
# force all unspecified python hooks to run python3
python: python
repos:
# Check the pre-commit configuration
- repo: meta
hooks:
- id: check-useless-excludes
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v6.0.0
hooks:
- id: check-case-conflict
- id: check-executables-have-shebangs
- id: check-json
- id: check-merge-conflict
- id: check-shebang-scripts-are-executable
- id: check-symlinks
- id: check-toml
- id: check-vcs-permalinks
- id: check-xml
- id: debug-statements
- id: destroyed-symlinks
- id: detect-aws-credentials
args:
- --allow-missing-credentials
- id: detect-private-key
- id: end-of-file-fixer
- id: mixed-line-ending
args:
- --fix=lf
- id: pretty-format-json
exclude: ^(package-lock\.json|package\.json|tsconfig\.json)$
args:
- --autofix
- id: requirements-txt-fixer
- id: trailing-whitespace
# Text file hooks
- repo: https://github.com/igorshubovych/markdownlint-cli
rev: v0.48.0
hooks:
- id: markdownlint
args:
- --config=.mdl_config.yaml
- repo: https://github.com/rbubley/mirrors-prettier
rev: v3.8.1
hooks:
- id: prettier
- repo: https://github.com/adrienverge/yamllint
rev: v1.38.0
hooks:
- id: yamllint
args:
- --strict
# GitHub Actions hooks
- repo: https://github.com/python-jsonschema/check-jsonschema
rev: 0.37.0
hooks:
- id: check-github-actions
- id: check-github-workflows
# pre-commit hooks
- repo: https://github.com/pre-commit/pre-commit
rev: v4.5.1
hooks:
- id: validate_manifest
# Nix hooks
- repo: https://github.com/nix-community/nixpkgs-fmt
rev: v1.3.0
hooks:
- id: nixpkgs-fmt
# Shell script hooks
- repo: https://github.com/scop/pre-commit-shfmt
rev: v3.13.0-1
hooks:
- id: shfmt
args:
# List files that will be formatted
- --list
# Write result to file instead of stdout
- --write
# Indent by two spaces
- --indent
- "2"
# Binary operators may start a line
- --binary-next-line
# Switch cases are indented
- --case-indent
# Redirect operators are followed by a space
- --space-redirects
- repo: https://github.com/shellcheck-py/shellcheck-py
rev: v0.11.0.1
hooks:
- id: shellcheck
- repo: https://github.com/PyCQA/isort
rev: 8.0.1
hooks:
- id: isort
# Docker hooks
- repo: https://github.com/IamTheFij/docker-pre-commit
rev: v3.0.1
hooks:
- id: docker-compose-check
# Packer hooks
- repo: https://github.com/cisagov/pre-commit-packer
rev: v0.3.1
hooks:
- id: packer_fmt
- id: packer_validate