-
Notifications
You must be signed in to change notification settings - Fork 16
Expand file tree
/
Copy path.pre-commit-config.yaml
More file actions
38 lines (34 loc) · 1.04 KB
/
.pre-commit-config.yaml
File metadata and controls
38 lines (34 loc) · 1.04 KB
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
# See https://pre-commit.com for more information
# See https://pre-commit.com/hooks.html for more hooks
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-yaml
- id: check-added-large-files
- repo: https://github.com/astral-sh/ruff-pre-commit
# Ruff version.
rev: v0.12.4
hooks:
# Run the formatter first.
- id: ruff-format
exclude: ruff.xml
# Then run the linter.
- id: ruff
exclude: ruff.xml
- repo: https://github.com/PyCQA/bandit
rev: 1.8.0
hooks:
- id: bandit
args: ['-c', 'pyproject.toml']
- repo: local
hooks:
- id: check-django-allauth-prod
name: Check django-allauth is production-ready
entry: |
bash -c 'if grep -E "(editable.*django-allauth|django-allauth.*\.\./)" pyproject.toml; then echo "ERROR: Local django-allauth detected. Run make prod-allauth first."; exit 1; fi'
language: system
files: pyproject.toml
pass_filenames: false