-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy path.pre-commit-config.yaml
More file actions
62 lines (62 loc) · 1.71 KB
/
Copy path.pre-commit-config.yaml
File metadata and controls
62 lines (62 loc) · 1.71 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
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.4.0
hooks:
- id: check-merge-conflict
- id: check-yaml
- id: check-toml
- id: end-of-file-fixer
- id: trailing-whitespace
- repo: local
hooks:
- id: fmt
name: fmt
description: Format files with cargo fmt.
entry: cargo fmt
language: system
types: [rust]
args: ["--all", "--", "--check"]
- id: cargo-check
name: cargo check
description: Check the package for errors.
entry: cargo check
args: ["--workspace", "--all-targets"]
language: system
types: [rust]
pass_filenames: false
- id: clippy
name: clippy
description: Lint rust sources
entry: cargo clippy
language: system
args: ["--workspace", "--all-targets", "--", "-D", "warnings"]
types: [rust]
pass_filenames: false
- id: docs
name: docs
description: Build documentation
entry: cargo
args: ["doc", "--all-features", "--no-deps"]
language: system
types: [rust]
pass_filenames: false
- repo: https://github.com/astral-sh/ruff-pre-commit
# Ruff version.
rev: v0.11.13
hooks:
- id: ruff-check
args: ["--fix", "--unsafe-fixes", "--config", "ruff.toml"]
- id: ruff-format
- repo: https://github.com/pre-commit/mirrors-mypy
rev: v1.10.0
hooks:
- id: mypy
args:
[
"--allow-subclassing-any",
"--strict",
"--ignore-missing-imports",
"--scripts-are-modules",
"--install-types",
"--non-interactive",
]