summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Makefile6
-rw-r--r--tox.ini25
2 files changed, 31 insertions, 0 deletions
diff --git a/Makefile b/Makefile
index 12c254c9..72faa04a 100644
--- a/Makefile
+++ b/Makefile
@@ -128,6 +128,12 @@ deb-src:
doc:
tox -e doc
+fmt:
+ tox -e do_format && tox -e check_format
+
+fmt-tip:
+ tox -e do_format_tip && tox -e check_format_tip
+
# Spell check && filter false positives
_CHECK_SPELLING := find doc -type f -exec spellintian {} + | \
grep -v -e 'doc/rtd/topics/cli.rst: modules modules' \
diff --git a/tox.ini b/tox.ini
index 43401e8e..26588585 100644
--- a/tox.ini
+++ b/tox.ini
@@ -80,6 +80,24 @@ commands =
{[testenv:mypy]commands}
{[testenv:pylint]commands}
+[testenv:check_format_tip]
+deps =
+ black
+ flake8
+ isort
+ mypy
+ pylint
+ pytest
+ types-jsonschema
+ types-oauthlib
+ types-pyyaml
+ types-requests
+ types-setuptools
+ -r{toxinidir}/test-requirements.txt
+ -r{toxinidir}/integration-requirements.txt
+commands =
+ {[testenv:check_format]commands}
+
[testenv:do_format]
deps =
black=={[format_deps]black}
@@ -88,6 +106,13 @@ commands =
{envpython} -m isort .
{envpython} -m black .
+[testenv:do_format_tip]
+deps =
+ black
+ isort
+commands =
+ {[testenv:do_format]commands}
+
[testenv:py3]
deps =
-r{toxinidir}/test-requirements.txt