Skip to content

Commit

Permalink
Added pre-commit and a basic config containing black+its config
Browse files Browse the repository at this point in the history
  • Loading branch information
s-weigand committed Oct 17, 2020
1 parent ed1c7e3 commit 6a251a8
Show file tree
Hide file tree
Showing 3 changed files with 32 additions and 0 deletions.
14 changes: 14 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v3.2.0
hooks:
- id: check-ast
- id: check-builtin-literals
- id: end-of-file-fixer
- id: trailing-whitespace

- repo: https://github.com/python/black
rev: 20.8b1
hooks:
- id: black
language_version: python3
17 changes: 17 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
[tool.black]
line-length = 99
target-version = ['py27', 'py35', 'py36', 'py37', 'py38']
exclude = '''
/(
\.eggs
| \.git
| \.hg
| \.mypy_cache
| \.tox
| \.venv
| _build
| buck-out
| build
| dist
)/
'''
1 change: 1 addition & 0 deletions requirements_dev.txt
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ pytest
pytest-runner
pytest-cov
coverage
pre-commit
flake8

#deployment
Expand Down

0 comments on commit 6a251a8

Please sign in to comment.