mirror of
https://github.com/python-pillow/Pillow.git
synced 2024-12-27 18:36:17 +03:00
Merge pull request #4716 from hugovk/pre-commit-diff
CI: Show diff when pre-commit fails
This commit is contained in:
commit
77c098b01f
4
.github/workflows/lint.yml
vendored
4
.github/workflows/lint.yml
vendored
|
@ -16,7 +16,7 @@ jobs:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v2
|
||||||
|
|
||||||
- name: pip cache
|
- name: pip cache
|
||||||
uses: actions/cache@v1
|
uses: actions/cache@v2
|
||||||
with:
|
with:
|
||||||
path: ~/.cache/pip
|
path: ~/.cache/pip
|
||||||
key: lint-pip-${{ hashFiles('**/setup.py') }}
|
key: lint-pip-${{ hashFiles('**/setup.py') }}
|
||||||
|
@ -46,4 +46,6 @@ jobs:
|
||||||
|
|
||||||
- name: Lint
|
- name: Lint
|
||||||
run: tox -e lint
|
run: tox -e lint
|
||||||
|
env:
|
||||||
|
PRE_COMMIT_COLOR: always
|
||||||
|
|
||||||
|
|
|
@ -9,5 +9,5 @@ line_length = 88
|
||||||
multi_line_output = 3
|
multi_line_output = 3
|
||||||
|
|
||||||
[tool:pytest]
|
[tool:pytest]
|
||||||
addopts = -ra
|
addopts = -ra --color=yes
|
||||||
testpaths = Tests
|
testpaths = Tests
|
||||||
|
|
3
tox.ini
3
tox.ini
|
@ -24,9 +24,10 @@ deps =
|
||||||
|
|
||||||
[testenv:lint]
|
[testenv:lint]
|
||||||
commands =
|
commands =
|
||||||
pre-commit run --all-files
|
pre-commit run --all-files --show-diff-on-failure
|
||||||
check-manifest
|
check-manifest
|
||||||
deps =
|
deps =
|
||||||
pre-commit
|
pre-commit
|
||||||
check-manifest
|
check-manifest
|
||||||
skip_install = true
|
skip_install = true
|
||||||
|
passenv = PRE_COMMIT_COLOR
|
||||||
|
|
Loading…
Reference in New Issue
Block a user