erg/.pre-commit-config.yaml
Shunsuke Shibayama ddb483c2cf fix: minor bugs
2023-06-25 23:06:40 +09:00

29 lines
941 B
YAML

repos:
- repo: local
hooks:
- id: rustfmt
exclude: ^doc/|^.github/|^.gitmessage|.md
name: rustfmt
description: Check if all files follow the rustfmt style
entry: cargo fmt --all
language: system
pass_filenames: false
- id: cargo-test
exclude: ^doc/|^.github/|^.gitmessage|.md
name: Cargo test
entry: cargo test -- --nocapture
language: system
pass_filenames: false
# - id: rust-clippy
# name: Rust clippy
# description: Run cargo clippy on files included in the commit
# entry: cargo clippy --all-targets --all-features -- -Dclippy::all
# language: system
# pass_filenames: false
# types: [file, rust]
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.3.0
hooks:
- id: end-of-file-fixer
- id: trailing-whitespace
- id: check-merge-conflict