-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathprek.toml
More file actions
161 lines (130 loc) · 3.16 KB
/
prek.toml
File metadata and controls
161 lines (130 loc) · 3.16 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
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
# Managed by copier — template baseline above, project-specific content below
default_stages = ["pre-commit"]
default_install_hook_types = ["pre-commit", "commit-msg"]
[[repos]]
repo = "https://github.com/pre-commit/pre-commit-hooks"
rev = "v6.0.0"
[[repos.hooks]]
id = "trailing-whitespace"
args = ["--markdown-linebreak-ext=md"]
priority = 0
[[repos.hooks]]
id = "end-of-file-fixer"
exclude = '\.jinja$'
priority = 0
[[repos.hooks]]
id = "check-toml"
priority = 0
[[repos.hooks]]
id = "check-yaml"
args = ["--allow-multiple-documents"]
priority = 0
[[repos.hooks]]
id = "check-json"
priority = 0
[[repos.hooks]]
id = "check-case-conflict"
priority = 0
[[repos.hooks]]
id = "mixed-line-ending"
args = ["--fix=lf"]
priority = 0
[[repos.hooks]]
id = "check-xml"
types = ["text"]
files = '\\.(xml|iml)$'
priority = 0
[[repos.hooks]]
id = "check-added-large-files"
args = ["--maxkb=500"]
priority = 0
[[repos.hooks]]
id = "check-merge-conflict"
stages = ["pre-commit", "pre-push"]
priority = 0
[[repos.hooks]]
id = "no-commit-to-branch"
name = "Block commits to main"
args = ["--branch", "main"]
stages = ["pre-commit", "pre-push"]
priority = 0
[[repos]]
repo = "https://github.com/editorconfig-checker/editorconfig-checker"
rev = "v3.6.1"
[[repos.hooks]]
id = "editorconfig-checker"
name = "Enforce .editorconfig rules"
priority = 0
[[repos]]
repo = "local"
[[repos.hooks]]
id = "lower-case-commit-title"
name = "Lowercase commit title"
stages = ["commit-msg"]
entry = "grep --basic-regexp --null-data --only-matching '^[a-z0-9!:() ]\\+'"
language = "system"
priority = 0
[[repos.hooks]]
id = "conventional-commit"
name = "Follows conventional commit format"
stages = ["commit-msg"]
entry = "cog verify --file"
language = "system"
priority = 0
[[repos.hooks]]
id = "nix-fmt"
name = "Format nix files"
entry = "nix fmt"
types = ["nix"]
language = "system"
priority = 0
[[repos.hooks]]
id = "no-duplicate-flake-inputs"
name = "No duplicate flake inputs (use follows)"
entry = "bash -c 'grep -o \"narHash.*\" flake.lock | sort | uniq -d | grep -q . && exit 1 || exit 0'"
language = "system"
files = '^flake\.lock$'
pass_filenames = false
priority = 0
[[repos.hooks]]
id = "block-yml-extension"
name = "Block .yml files (use .yaml instead)"
entry = "Rename *.yml files to end with *.yaml"
language = "fail"
types = ["text"]
files = '\\.yml$'
priority = 0
[[repos]]
repo = "https://github.com/rhysd/actionlint"
rev = "v1.7.11"
[[repos.hooks]]
id = "actionlint"
name = "Lint GitHub Actions workflows"
priority = 0
[[repos]]
repo = "https://github.com/python-jsonschema/check-jsonschema"
rev = "0.37.0"
[[repos.hooks]]
id = "check-github-actions"
name = "Validate GitHub Actions metadata"
priority = 0
[[repos.hooks]]
id = "check-github-workflows"
name = "Validate GitHub Workflows schema"
priority = 0
[[repos]]
repo = "https://github.com/renovatebot/pre-commit-hooks"
rev = "43.76.4"
[[repos.hooks]]
id = "renovate-config-validator"
name = "Validate Renovate config (strict)"
args = ["--strict"]
priority = 0
[[repos]]
repo = "https://github.com/gitleaks/gitleaks"
rev = "v8.30.0"
[[repos.hooks]]
id = "gitleaks"
name = "Detect hardcoded secrets"
priority = 0
# ~~~ Add project-specific repos below this line ~~~