forked from AprilNEA/OpenLogi
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathprek.toml
More file actions
36 lines (32 loc) · 955 Bytes
/
prek.toml
File metadata and controls
36 lines (32 loc) · 955 Bytes
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
# Configuration file for `prek`, a fast Git hook manager written in Rust.
# See https://prek.j178.dev for more information.
#:schema https://www.schemastore.org/prek.json
# Built-in hooks run natively in Rust — no repo clone, no Python venv, works offline.
[[repos]]
repo = "builtin"
hooks = [
{ id = "trailing-whitespace" },
{ id = "end-of-file-fixer" },
{ id = "check-yaml" },
{ id = "check-toml" },
{ id = "check-merge-conflict" },
{ id = "check-added-large-files" },
]
[[repos]]
repo = "local"
[[repos.hooks]]
id = "cargo-fmt"
name = "cargo fmt"
entry = "cargo fmt --all --"
language = "system"
types = ["rust"]
pass_filenames = false
# Clippy compiles the workspace, so keep it on pre-push rather than every commit.
[[repos.hooks]]
id = "cargo-clippy"
name = "cargo clippy"
entry = "cargo clippy --workspace --all-targets -- -D warnings"
language = "system"
types = ["rust"]
pass_filenames = false
stages = ["pre-push"]