-
Notifications
You must be signed in to change notification settings - Fork 1
/
tox.ini
48 lines (45 loc) · 1.1 KB
/
tox.ini
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
[tox]
envlist = lint,py27,py36,py37,pre-commit
[testenv]
deps =
pre-commit
pytest-sugar
sh
setenv =
GIT_AUTHOR_NAME = "test"
GIT_COMMITTER_NAME = "test"
GIT_AUTHOR_EMAIL = "[email protected]"
GIT_COMMITTER_EMAIL = "[email protected]"
commands =
pytest
pre-commit try-repo .
whitelist_externals =
rm
bash
[testenv:pre-commit]
skip_install = true
deps = pre-commit
commands = pre-commit run --all-files --show-diff-on-failure
[testenv:lint]
description = Performs linting, style checks, metadata-validation, packaging
skip_install = true
deps =
pep517>=0.5.0
pre-commit
twine
commands =
pre-commit run -a
bash -c "rm -rf {toxinidir}/dist/ && mkdir -p {toxinidir}/dist/"
python -m pep517.build \
--source \
--binary \
--out-dir {toxinidir}/dist/ \
{toxinidir}
twine check dist/*
[testenv:upload]
description = Builds the packages and uploads them to https://pypi.org
envdir={toxworkdir}/lint
deps={[testenv:lint]deps}
commands =
{[testenv:lint]commands}
twine upload --disable-progress-bar --skip-existing --verbose dist/*