Reputation: 9798
Using the following configuration of pre-commit
.pre-commit-config.yml
:
repos:
- repo: https://github.com/psf/black
rev: 24.8.0
hooks:
- id: black
language_version: python3
and pyproject.toml
:
[tool.black]
line-length = 88
skip-string-normalization = true
extend-exclude = '''
^.+/migrations/.*\.py$
'''
when running:
pre-commit run --all-files
the migration directories are still being formatted.
Upvotes: -1
Views: 31