generated from communitiesuk/funding-service-design-TEMPLATE
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.pre-commit-config.yaml
39 lines (36 loc) · 999 Bytes
/
.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
ci:
autofix_prs: false
# mypy needs a lot of dependencies installed, and we hit limits in precommit.ci on the size of the dependencies
# which causes precommit to fail. So we now run precommit mypy in github actions separately.
skip: [mypy]
default_language_version:
python: python3.11
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v5.0.0
hooks:
- id: trailing-whitespace
- id: end-of-file-fixer
- id: check-ast
- repo: https://github.com/astral-sh/ruff-pre-commit
# Ruff version. If bumping this, please also bump requirements-dev.in
rev: v0.9.3
hooks:
# Run the linter.
- id: ruff
args: [ --fix ]
# Run the formatter.
- id: ruff-format
- repo: local
hooks:
- id: mypy
name: Run type checks
language: system
types: [python]
entry: mypy .
pass_filenames: false
- repo: https://github.com/djlint/djLint
rev: v1.36.4
hooks:
- id: djlint-jinja
types_or: ['html', 'jinja']