Commit 25bd0fefd7
Unsigned
Layout: unified · split
.pre-commit-config.yaml added +22
| @@ -0,0 +1,22 @@ | |||
| 1 | repos: | ||
| 2 | - repo: https://github.com/pre-commit/pre-commit-hooks | ||
| 3 | rev: v2.2.3 | ||
| 4 | hooks: | ||
| 5 | - id: check-yaml | ||
| 6 | - id: end-of-file-fixer | ||
| 7 | - id: trailing-whitespace | ||
| 8 | |||
| 9 | - repo: local | ||
| 10 | hooks: | ||
| 11 | - id: fmt | ||
| 12 | name: fmt | ||
| 13 | language: system | ||
| 14 | types: [file, rust] | ||
| 15 | entry: cargo fmt -- --check | ||
| 16 | |||
| 17 | - id: test | ||
| 18 | name: test | ||
| 19 | language: system | ||
| 20 | files: '\.rs$' | ||
| 21 | entry: cargo test --lib | ||
| 22 | pass_filenames: false | ||