-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathprek.toml
More file actions
135 lines (123 loc) · 3.98 KB
/
prek.toml
File metadata and controls
135 lines (123 loc) · 3.98 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
# Configuration file for `prek`, a git hook framework written in Rust.
# See https://prek.j178.dev for more information.
#:schema https://www.schemastore.org/prek.json
minimum_prek_version = "0.3.8"
default_install_hook_types = ["pre-commit", "pre-push"]
[[repos]]
repo = "https://github.com/zizmorcore/zizmor-pre-commit"
rev = "ea2eb407b4cbce87cf0d502f36578950494f5ac9" # frozen: v1.23.1
hooks = [
{ id = "zizmor" },
]
[[repos]]
repo = "https://github.com/pre-commit/pre-commit-hooks"
rev = "3e8a8703264a2f4a69428a0aa4dcb512790b2c8c" # frozen: v6.0.0
hooks = [
{ id = "check-merge-conflict" },
{ id = "check-yaml" },
{ id = "check-added-large-files" },
{ id = "detect-private-key" },
{ id = "end-of-file-fixer" },
{ id = "trailing-whitespace" },
{ id = "mixed-line-ending" },
]
[[repos]]
repo = "https://github.com/rhysd/actionlint"
rev = "914e7df21a07ef503a81201c76d2b11c789d3fca" # frozen: v1.7.12
hooks = [
{ id = "actionlint", files = '^\.github/workflows/.*\.(yml|yaml)$' },
]
[[repos]]
repo = "https://github.com/astral-sh/ruff-pre-commit"
rev = "b831c3dc5d27d9da294ae4e915773b99aa24a7c5" # frozen: v0.15.10
hooks = [
{ id = "ruff", args = ["--fix"], files = '^\.github/scripts/.*\.py$' },
{ id = "ruff-format", files = '^\.github/scripts/.*\.py$' },
]
[[repos]]
repo = "https://github.com/igorshubovych/markdownlint-cli"
rev = "e72a3ca1632f0b11a07d171449fe447a7ff6795e" # frozen: v0.48.0
hooks = [
{ id = "markdownlint", args = ["--fix"] },
]
[[repos]]
repo = "https://github.com/shellcheck-py/shellcheck-py"
rev = "745eface02aef23e168a8afb6b5737818efbea95" # frozen: v0.11.0.1
hooks = [
{ id = "shellcheck", files = '^\.github/scripts/.*\.sh$' },
]
[[repos]]
repo = "https://github.com/macisamuele/language-formatters-pre-commit-hooks"
rev = "4380fbb73a154b5f5624794c1c78d9719ccc860f" # frozen: v2.16.0
hooks = [
{ id = "pretty-format-java", args = ["--autofix"], files = '(^|/)src/.*\.java$' },
]
[[repos]]
repo = "https://github.com/Yelp/detect-secrets"
rev = "01886c8a910c64595c47f186ca1ffc0b77fa5458" # frozen: v1.5.0
hooks = [
{ id = "detect-secrets", args = ["--disable-plugin", "HexHighEntropyString"] },
]
[[repos]]
repo = "https://github.com/betterleaks/betterleaks"
rev = "31746c9420b19a592848b21d6d8977d53cc6da0e" # frozen: v1.1.2
hooks = [
{ id = "betterleaks" },
]
[[repos]]
repo = "https://github.com/trufflesecurity/trufflehog"
rev = "47e7b7cd74f578e1e3145d48f669f22fd1330ca6" # frozen: v3.94.3
hooks = [
{ id = "trufflehog", stages = ["manual"] },
]
[[repos]]
repo = "local"
hooks = [
{
id = "check-pom-consistency",
name = "Check POM/dependabot consistency",
language = "python",
language_version = "python3",
additional_dependencies = ["defusedxml==0.7.1"],
entry = "python3 .github/scripts/check-pom-consistency.py",
files = '^pom\.xml$|^\.github/dependabot\.yml$',
pass_filenames = false,
},
{
id = "check-hook-revisions-frozen",
name = "Check hook revisions are frozen",
language = "system",
entry = "python3 .github/scripts/check-hook-revisions-frozen.py",
files = '^prek\.toml$',
pass_filenames = false,
},
{
id = "poutine",
name = "Analyze workflows (Poutine)",
language = "system",
entry = "poutine",
args = ["analyze_local", ".", "--format", "pretty", "--fail-on-violation"],
files = '^\.github/workflows/.*\.ya?ml$|^\.github/actions/.*\.ya?ml$',
pass_filenames = false,
},
{
id = "unit-tests",
name = "Unit tests",
language = "system",
entry = "./mvnw",
args = ["-B", "-ntp", "-P!integration-tests", "test"],
files = '^api/src/|^cli/src/|^maven-plugin/src/|(^|/)pom\.xml$',
pass_filenames = false,
stages = ["pre-push"],
},
{
id = "integration-tests",
name = "Integration tests",
language = "system",
entry = "./mvnw",
args = ["-B", "-ntp", "-DskipTests", "-Pintegration-tests", "verify"],
files = '^maven-plugin/src/.*\.java$|^maven-plugin/src/it/|^maven-plugin/pom\.xml$',
pass_filenames = false,
stages = ["pre-push"],
},
]