Skip to content

Commit

Permalink
[POC] Add pyupgrade via pre-commit
Browse files Browse the repository at this point in the history
new file:   .pre-commit-config.yaml
modified:   tox.ini
  • Loading branch information
jugmac00 committed Jul 7, 2020
1 parent 8b64b6a commit 630db55
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 1 deletion.
11 changes: 11 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
repos:
- repo: https://github.com/asottile/pyupgrade
rev: v2.6.2
hooks:
- id: pyupgrade
args: [--py36-plus]

- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v3.1.0
hooks:
- id: debug-statements
8 changes: 7 additions & 1 deletion tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,8 @@ envlist =
py38,
py39,
lint,
coverage-report
pre-commit,
coverage-report,

[testenv]
coverage_run = {env:WIN_COV:coverage run}
Expand Down Expand Up @@ -95,3 +96,8 @@ deps =
commands =
- isort --check-only --recursive {toxinidir}/src setup.py
flake8 src docs setup.py

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

0 comments on commit 630db55

Please sign in to comment.