You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
vereinsverwaltung/.pre-commit-config.yaml

72 lines
2.1 KiB
YAML

# See https://pre-commit.com for more information
# See https://pre-commit.com/hooks.html for more hooks
exclude: (migrations/|static/|.gitignore)
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.4.0
hooks:
- id: trailing-whitespace
- id: end-of-file-fixer
- id: check-added-large-files
- id: detect-private-key
- repo: https://github.com/PyCQA/isort
rev: '5.12.0'
hooks:
- id: isort
- repo: https://github.com/PyCQA/flake8
rev: '5.0.4'
hooks:
- id: flake8
additional_dependencies: [
'flake8-bugbear==22.12.6',
'flake8-debugger==4.1.2',
'flake8-django==1.1.5',
'flake8-pep3101==2.0.0',
'flake8-print==5.0.0',
'flake8-quotes==3.3.2',
'flake8-eradicate==1.4.0',
]
- repo: https://github.com/Riverside-Healthcare/djLint
rev: v1.23.3
hooks:
- id: djlint-django
- repo: https://github.com/adamchainz/django-upgrade
rev: "1.13.0"
hooks:
- id: django-upgrade
args: [--target-version, "4.2"]
- repo: local
hooks:
- id: django-makemigrations-check
name: Check Django Migrations
entry: poetry run python manage.py makemigrations --dry-run --check --no-input
language: system
types: [python]
pass_filenames: false
- repo: https://github.com/python-poetry/poetry
rev: '1.5.0'
hooks:
- id: poetry-check
- id: poetry-lock
args: ["--no-update"]
- id: poetry-export
args: ["-f", "requirements.txt", "-o", "requirements.txt", "-E", "production"]
- repo: https://github.com/PyCQA/bandit
rev: '1.7.5'
hooks:
- id: bandit
exclude: test_.*
- repo: https://github.com/Lucas-C/pre-commit-hooks-safety
rev: 'v1.3.1'
hooks:
- id: python-safety-dependencies-check
files: requirements.txt
- repo: local
hooks:
- id: pytest-check
name: pytest
entry: poetry run pytest
language: system
pass_filenames: false
always_run: true