Skip to content

Commit

Permalink
run flake8 via pre-commit instead of tox
Browse files Browse the repository at this point in the history
  • Loading branch information
HarryET committed Sep 30, 2020
1 parent ecc04d0 commit df15ba5
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 10 deletions.
1 change: 1 addition & 0 deletions .pre-commit-config.yaml
Expand Up @@ -18,6 +18,7 @@ repos:
rev: 3.8.2 # pick a git hash / tag to point to
hooks:
- id: flake8
additional_dependencies: [flake8-click, flake8-bugbear]

- repo: https://github.com/psf/black
rev: 19.10b0
Expand Down
16 changes: 6 additions & 10 deletions tox.ini
Expand Up @@ -3,8 +3,8 @@ envlist =
py36,
py37,
py38,
flake8,
coverage
coverage,
pre-commit

[testenv]
deps =
Expand All @@ -22,18 +22,14 @@ commands =
pip install -e .[test]
pytest --cov=hibpcli --cov=tests --cov-report term-missing --cov-report html

[testenv:flake8]
deps =
flake8
flake8-click
flake8-bugbear
commands =
flake8 src tests setup.py

[flake8]
max-line-length = 88
ignore = E231 # clashes with black

[testenv:pre-commit]
skip_install = true
deps = pre-commit
commands = pre-commit run --all-files --show-diff-on-failure

[isort]
known_third_party = click,hibpcli,httpx,pykeepass,pytest,setuptools

0 comments on commit df15ba5

Please sign in to comment.