Styling config

This commit is contained in:
Ludovic Stephan 2020-06-13 17:19:08 +02:00
parent 6e51e555f6
commit 8e9770a26b
2 changed files with 52 additions and 0 deletions

9
pyproject.toml Normal file
View file

@ -0,0 +1,9 @@
[tool.black]
# Automatically ignore files in .gitignore (opened at this time):
# https://github.com/ambv/black/issues/475
exclude = '''
/(
\.pyc
| venv
)/
'''

43
setup.cfg Normal file
View file

@ -0,0 +1,43 @@
[coverage:run]
source =
bda
bds
clubs
cof
events
gestioncof
kfet
petitscours
shared
omit =
*migrations*
*test*.py
branch = true
[coverage:report]
precision = 2
show_missing = true
[flake8]
exclude = migrations
max-line-length = 88
ignore =
# whitespace before ':' (not PEP8-compliant for slicing)
E203,
# lambda expression
E731,
# line break before binary operator (not PEP8-compliant)
W503
[isort]
# For black compat: https://github.com/ambv/black#how-black-wraps-lines
combine_as_imports = true
default_section = THIRDPARTY
force_grid_wrap = 0
include_trailing_comma = true
known_django = django
known_first_party = bda,bds,clubs,cof,events,gestioncof,kfet,petitscours,shared
line_length = 88
multi_line_output = 3
not_skip = __init__.py
sections = FUTURE,STDLIB,THIRDPARTY,FIRSTPARTY,LOCALFOLDER