forked from department-of-veterans-affairs/abd-vro
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.pre-commit-config.yaml
60 lines (52 loc) · 1.9 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
# 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
exclude: >
(?x)^(
app/src/docker/docker-compose.yml
)
# 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: v4.3.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$
- id: check-yaml
exclude: ^.*helm.*$
- id: destroyed-symlinks
- id: detect-private-key
exclude: ^svc-lighthouse-api/.*/test/resources/application-test.properties$
- 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
# https://flake8.pycqa.org/en/latest/user/using-hooks.html#usage-with-the-pre-commit-git-hooks-framework
- repo: https://github.com/PyCQA/flake8
rev: 5.0.4
hooks:
- id: flake8
args: [--max-line-length=255]
- repo: https://github.com/pycqa/isort
rev: 5.12.0
hooks:
- id: isort
- repo: https://github.com/zricethezav/gitleaks
rev: v8.15.0
hooks:
- id: gitleaks
# - repo: local
# hooks:
# - id: commit-message
# name: commit-message
# entry: scripts/commit-message.sh
# language: script
# stages: [commit-msg]