-
Notifications
You must be signed in to change notification settings - Fork 7
/
Copy path.pre-commit-config.yaml
37 lines (37 loc) · 1.14 KB
/
.pre-commit-config.yaml
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
# See https://pre-commit.com for more information
# See https://pre-commit.com/hooks.html for more hooks
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v3.2.0
hooks:
- id: trailing-whitespace
exclude: .+\.(patch|log)$
- id: end-of-file-fixer
exclude: .+\.(patch|log)$
- id: check-yaml
- id: check-added-large-files
- repo: https://github.com/ComPWA/taplo-pre-commit
rev: v0.9.3
hooks:
- id: taplo-format
- repo: local
hooks:
- id: cargo-check
name: Check cargo workspace
description: Check the cargo workspace for errors
entry: cargo check --workspace
language: system
files: (.+\.rs|.*Cargo.(toml|lock))$
pass_filenames: false
- id: cargo-fmt
name: Format cargo workspace
description: Format the cargo workspace
entry: cargo fmt --all
language: system
files: src/.+\.rs$
pass_filenames: false
- id: cargo-spellcheck
name: Spellchecking documentation
entry: cargo spellcheck --code 1
language: system
files: (.+\.rs|docs/.+\.md)$