pre-commit: check clippies and format in pre-commit to avoid CI fail
All checks were successful
test / AoC 2024 (push) Successful in 2m55s

This commit is contained in:
Keenan Tims 2024-12-13 23:51:34 -08:00
parent b060de20c7
commit 003bc3212d
Signed by: ktims
GPG Key ID: 11230674D69038D4

View File

@ -1,16 +1,30 @@
repos: repos:
- repo: https://github.com/LiquidFun/aoc_tiles - repo: local
rev: 0.6.2 hooks:
hooks: - id: rust-linting
- id: aoc-tiles name: Rust linting
# Optionally use these arguments. Auto add tiles to git adds the tiles to git, entry: cargo fmt --all --
# possibly amends your commit by creating the tile images and updating the README. pass_filenames: true
# Language sorting shows the preference of the order of the languages to use. types: [file, rust]
# Exclude paterns are globs which can be used to exclude files when creating language: system
# the tiles. See the customization section in the README for more flags. - id: rust-clippy
# Simply remove the comments (#) below for args and the flags you want. name: Rust clippy
args: entry: cargo clippy --lib --all-features --tests -- -D warnings
- --auto-add-tiles-to-git=amend pass_filenames: false
- --overwrite-year=2024 types: [file, rust]
# - --language-sorting=jl,kt,py,rs language: system
# - --exclude-patterns=2021/*/*.apl,2021/*/*.py,2021/*/*.cpp - repo: https://github.com/LiquidFun/aoc_tiles
rev: 0.6.2
hooks:
- id: aoc-tiles
# Optionally use these arguments. Auto add tiles to git adds the tiles to git,
# possibly amends your commit by creating the tile images and updating the README.
# Language sorting shows the preference of the order of the languages to use.
# Exclude paterns are globs which can be used to exclude files when creating
# the tiles. See the customization section in the README for more flags.
# Simply remove the comments (#) below for args and the flags you want.
args:
- --auto-add-tiles-to-git=amend
- --overwrite-year=2024
# - --language-sorting=jl,kt,py,rs
# - --exclude-patterns=2021/*/*.apl,2021/*/*.py,2021/*/*.cpp