-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathprek.toml
More file actions
46 lines (43 loc) · 1.02 KB
/
prek.toml
File metadata and controls
46 lines (43 loc) · 1.02 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
# 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
fail_fast = true
exclude = { glob = ["target/**"] }
[[repos]]
repo = "builtin"
hooks = [
{ id = "trailing-whitespace" },
{ id = "end-of-file-fixer" },
{ id = "check-toml" },
]
[[repos]]
repo = "local"
hooks = [
{
id = "cargo-fmt",
name = "cargo fmt",
entry = "cargo fmt --all -- --check",
language = "system",
types = ["rust"],
pass_filenames = false,
priority = 0,
},
{
id = "cargo-clippy",
name = "cargo clippy",
entry = "cargo clippy --workspace --all-targets --features source-build -- -D warnings",
language = "system",
types = ["rust"],
pass_filenames = false,
priority = 10,
},
{
id = "cargo-test",
name = "cargo test",
entry = "cargo test --workspace --features source-build",
language = "system",
types = ["rust"],
pass_filenames = false,
priority = 20,
},
]