1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
# Generated by dev-configs
default_install_hook_types:
- pre-commit
- commit-msg
repos:
- repo: local
hooks:
- id: clippy
name: clippy (lint .rs files)
entry: cargo clippy -- -D warnings
language: system
pass_filenames: false
stages:
- pre-commit
- repo: local
hooks:
- id: needs-prefix
name: commit message needs to have a prefix
language: pygrep
entry: '^(chore|ci|style|test|feat|fix|build|docs|refactor|perf)!?(\([a-z]+\))?: (?![A-Z])(?![a-z]+(ed|ing)\s).*$'
args:
- '--multiline'
- '--negate'
stages:
- commit-msg
- repo: local
hooks:
- id: rustfmt
name: rustfmt (format .rs files)
entry: rustfmt --edition 2024
language: system
types:
stages:
- pre-commit
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v6.0.0
hooks:
- id: trailing-whitespace
- id: end-of-file-fixer