Merge pull request #4716 from hugovk/pre-commit-diff

CI: Show diff when pre-commit fails
This commit is contained in:
Andrew Murray 2020-06-28 20:02:44 +10:00 committed by GitHub
commit 77c098b01f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 6 additions and 3 deletions

View File

@ -16,7 +16,7 @@ jobs:
- uses: actions/checkout@v2
- name: pip cache
uses: actions/cache@v1
uses: actions/cache@v2
with:
path: ~/.cache/pip
key: lint-pip-${{ hashFiles('**/setup.py') }}
@ -46,4 +46,6 @@ jobs:
- name: Lint
run: tox -e lint
env:
PRE_COMMIT_COLOR: always

View File

@ -9,5 +9,5 @@ line_length = 88
multi_line_output = 3
[tool:pytest]
addopts = -ra
addopts = -ra --color=yes
testpaths = Tests

View File

@ -24,9 +24,10 @@ deps =
[testenv:lint]
commands =
pre-commit run --all-files
pre-commit run --all-files --show-diff-on-failure
check-manifest
deps =
pre-commit
check-manifest
skip_install = true
passenv = PRE_COMMIT_COLOR