-
Notifications
You must be signed in to change notification settings - Fork 7
/
.pre-commit-config.yaml
92 lines (86 loc) · 2.4 KB
/
.pre-commit-config.yaml
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
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.6.0
hooks:
- id: trailing-whitespace
stages: [push]
- id: end-of-file-fixer
stages: [push]
- id: check-added-large-files
stages: [push]
- id: fix-byte-order-marker
stages: [push]
- id: check-case-conflict
stages: [push]
- id: check-shebang-scripts-are-executable
stages: [push]
- id: check-merge-conflict
stages: [push]
- id: mixed-line-ending
stages: [push]
- id: check-symlinks
stages: [push]
- id: check-ast
stages: [push]
- id: debug-statements
stages: [push]
- id: requirements-txt-fixer
types: [file]
files: (requirements.txt|requirements-dev.txt)
stages: [push]
- id: check-toml
stages: [push]
- id: check-json
stages: [push]
- id: detect-private-key
stages: [commit, push]
- repo: https://github.com/astral-sh/ruff-pre-commit
# Ruff version.
rev: v0.6.2
hooks:
# Run the linter.
- id: ruff
args: [--fix]
types_or: [python, pyi, jupyter]
stages: [commit, push]
# Run the formatter.
- id: ruff-format
types_or: [python, pyi, jupyter]
stages: [commit, push]
- repo: local
hooks:
- id: check-identities
require_serial: true
name: check-identities
entry: .githooks/check_identities.sh
stages: [commit, push]
language: script
- repo: https://github.com/commitizen-tools/commitizen
rev: v3.27.0 # This specifies that we are using version 3.27.0 of the commitizen repository
hooks:
- id: commitizen
stages: [commit-msg]
- id: commitizen-branch
stages: [push]
- repo: https://github.com/pappasam/toml-sort
rev: v0.23.1
hooks:
- id: toml-sort-fix
exclude: ".*poetry.lock|.*_static"
- repo: https://github.com/Lucas-C/pre-commit-hooks
rev: v1.5.5
hooks:
- id: forbid-crlf
- id: remove-crlf
- id: forbid-tabs
- id: remove-tabs
args: [--whitespaces-count, "4"]
- repo: https://github.com/codespell-project/codespell
rev: v2.3.0
hooks:
- id: codespell
exclude: "CHANGELOG.md|tests/.*|README.md"
- repo: https://github.com/gitleaks/gitleaks
rev: v8.18.4
hooks:
- id: gitleaks