diff --git a/Makefile b/Makefile index 89ff453ef..1a1e996d1 100644 --- a/Makefile +++ b/Makefile @@ -5,6 +5,8 @@ reformat: $(PYTHON) -m black `git ls-files "*.py"` stylecheck: $(PYTHON) -m black --check `git ls-files "*.py"` +stylediff: + $(PYTHON) -m black --check --diff `git ls-files "*.py"` # Translations gettext: diff --git a/make.bat b/make.bat index 5f880d235..a02c1391e 100644 --- a/make.bat +++ b/make.bat @@ -21,6 +21,10 @@ exit /B %ERRORLEVEL% black --check !PYFILES! exit /B %ERRORLEVEL% +:stylediff +black --check --diff !PYFILES! +exit /B %ERRORLEVEL% + :newenv py -3.8 -m venv --clear .venv .\.venv\Scripts\python -m pip install -U pip setuptools diff --git a/tox.ini b/tox.ini index d532c4727..4ceecff4c 100644 --- a/tox.ini +++ b/tox.ini @@ -65,4 +65,4 @@ setenv = basepython = python3.8 extras = style commands = - make stylecheck + make stylediff