61
.pre-commit-config.yaml
Normal file
61
.pre-commit-config.yaml
Normal file
@ -0,0 +1,61 @@
|
||||
repos:
|
||||
- repo: https://github.com/pre-commit/pre-commit-hooks
|
||||
rev: v2.1.0
|
||||
hooks:
|
||||
- id: trailing-whitespace
|
||||
- repo: local
|
||||
hooks:
|
||||
- id: fmt
|
||||
types:
|
||||
- rust
|
||||
name: cargo fmt
|
||||
language: system
|
||||
entry: cargo
|
||||
pass_filenames: false
|
||||
args:
|
||||
- fmt
|
||||
- --
|
||||
- --config
|
||||
- use_try_shorthand=true,imports_granularity=Crate
|
||||
|
||||
- id: clippy
|
||||
types:
|
||||
- rust
|
||||
name: cargo clippy
|
||||
language: system
|
||||
pass_filenames: false
|
||||
entry: cargo
|
||||
args:
|
||||
- clippy
|
||||
- --all-features
|
||||
- --all
|
||||
- -p
|
||||
- rustus
|
||||
- --
|
||||
- -W
|
||||
- clippy::all
|
||||
- -W
|
||||
- clippy::pedantic
|
||||
- -D
|
||||
- warnings
|
||||
|
||||
- id: check
|
||||
types:
|
||||
- rust
|
||||
name: cargo check
|
||||
language: system
|
||||
entry: cargo
|
||||
pass_filenames: false
|
||||
args:
|
||||
- check
|
||||
|
||||
- id: check-all
|
||||
types:
|
||||
- rust
|
||||
name: cargo check all
|
||||
language: system
|
||||
entry: cargo
|
||||
pass_filenames: false
|
||||
args:
|
||||
- check
|
||||
- --all-features
|
Reference in New Issue
Block a user