/
tox.ini
50 lines (42 loc) · 933 Bytes
/
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
49
50
[tox]
envlist = mypy,test,pep8,docs
[testenv]
basepython = python3
usedevelop = True
setenv =
PYTHONDONTWRITEBYTECODE=1
deps =
-r{toxinidir}/requirements.txt
-r{toxinidir}/test-requirements.txt
envdir = {toxworkdir}/shared
[testenv:dev]
commands =
{posargs}
[testenv:test]
commands =
stestr --test-path ./logsearch run {posargs}
[testenv:pep8]
# run black in check mode and fail if it would change something
commands =
black --line-length 79 --check --diff ./logsearch
flake8 {posargs}
[testenv:black]
commands =
black --line-length 79 ./logsearch
[testenv:mypy]
commands =
mypy logsearch
[testenv:docs]
skip_install= True
envdir = {toxworkdir}/docs
deps =
allowlist_externals =
echo
bash
egrep
commands =
echo -e "\e[1;34mChecking for trailing whitespaces\e[1;0m"
bash -c '! egrep --color=always -n " +$" *.md'
[flake8]
show-source = True
exclude=.venv,.git,.tox,dist,doc,*lib/python*,*egg,build