-
Notifications
You must be signed in to change notification settings - Fork 7
/
.pre-commit-config.yaml
50 lines (43 loc) · 1.6 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
# Run pre-commit against all files by executing: pre-commit run --all-files
# Auto-update the config to the latest repos' versions by executing: pre-commit autoupdate
# Rather than disabling particular hooks (https://pre-commit.com/#temporarily-disabling-hooks), add an `exclude`
# https://pre-commit.com/#regular-expressions
# https://pre-commit.com/#confining-hooks-to-run-at-certain-stages
# default_stages: [commit]
repos:
- repo: meta
hooks:
- id: check-useless-excludes
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v5.0.0
hooks: # https://github.com/pre-commit/pre-commit-hooks#hooks-available
- id: check-merge-conflict
- id: check-executables-have-shebangs
- id: check-shebang-scripts-are-executable
exclude: ^(scripts/.*\.src)|(.*/entrypoint.sh)$
- id: check-yaml
- id: destroyed-symlinks
- id: detect-private-key
- id: end-of-file-fixer # https://stackoverflow.com/questions/2287967/why-is-it-recommended-to-have-empty-line-in-the-end-of-a-source-file
- id: fix-byte-order-marker
- id: mixed-line-ending
- id: requirements-txt-fixer
- id: trailing-whitespace
- repo: https://github.com/zricethezav/gitleaks
rev: v8.20.1
hooks:
- id: gitleaks
# Python project specific hooks
- repo: https://github.com/pycqa/isort
rev: 5.13.2
hooks:
- id: isort
args: ["--profile", "black"]
- repo: https://github.com/astral-sh/ruff-pre-commit
# Ruff version.
rev: v0.6.9
hooks:
# Run the linter.
- id: ruff
# Run the formatter.
- id: ruff-format