repos:
- repo: https://github.com/doublify/pre-commit-rust
rev: v1.0
hooks:
- id: fmt
name: cargo fmt
description: Format Rust code with rustfmt
entry: cargo fmt --all --
language: system
types: [rust]
pass_filenames: false
- id: cargo-check
name: cargo check
description: Check Rust code with cargo check
entry: cargo check
language: system
types: [rust]
pass_filenames: false
- id: clippy
name: cargo clippy
description: Lint Rust code with clippy
entry: bash -c 'cargo clippy --workspace -- -D warnings'
language: system
types: [rust]
pass_filenames: false