-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.pre-commit-config.yaml
49 lines (49 loc) · 1.7 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
default_install_hook_types:
- pre-commit
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.5.0
hooks:
- id: trailing-whitespace
- id: end-of-file-fixer
- id: check-yaml
# Allow !reference tags in .gitlab-ci.yml
# https://github.com/pre-commit/pre-commit-hooks/issues/701
args: ['--unsafe']
- id: check-added-large-files
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.3.2
hooks:
- id: ruff
- id: ruff-format
- repo: https://github.com/djlint/djLint
rev: v1.34.1
hooks:
- id: djlint-jinja
- id: djlint-reformat-jinja
- repo: local
hooks:
# This hook would need to be run inside a docker
# container or somewhere with access to the database.
# Due to time constraints, we haven't implemented
# that at the moment.
# We're only running this in the CI via tox.ini
# instead.
# - id: missing-migrations
# name: Check missing Django migrations
# description: This hook checks if changes has been made to models but not reflected into a migration.
# entry: ./manage makemigrations
# args: [--check, --dry-run, --no-input]
# language: system
# types_or: [python, directory]
# files: "models"
# require_serial: true
# pass_filenames: false
- id: outdated-translations
name: Check for outdated .PO files
description: This hook checks if the automatically generated .PO files need updating.
entry: make update-translations
language: system
types_or: [jinja, python, directory, pofile]
require_serial: true
pass_filenames: false