mirror of
https://github.com/arcan1s/ahriman.git
synced 2025-06-28 06:41:43 +00:00
build: fix tox environment creation with the latest updates
This commit is contained in:
27
tox.ini
27
tox.ini
@ -1,6 +1,6 @@
|
||||
[tox]
|
||||
envlist = check, tests
|
||||
isolated_build = True
|
||||
isolated_build = true
|
||||
labels =
|
||||
release = version, docs, publish
|
||||
dependencies = -e .[journald,pacman,s3,shell,stats,validator,web]
|
||||
@ -27,7 +27,9 @@ description = Run common checks like linter, mypy, etc
|
||||
deps =
|
||||
{[tox]dependencies}
|
||||
-e .[check]
|
||||
pip_pre = true
|
||||
setenv =
|
||||
CFLAGS="-Wno-unterminated-string-initialization"
|
||||
MYPYPATH=src
|
||||
commands =
|
||||
autopep8 --exit-code --max-line-length 120 -aa -i -j 0 -r "src/{[tox]project_name}" "tests/{[tox]project_name}"
|
||||
@ -38,16 +40,16 @@ commands =
|
||||
|
||||
[testenv:docs]
|
||||
description = Generate source files for documentation
|
||||
allowlist_externals =
|
||||
bash
|
||||
find
|
||||
mv
|
||||
changedir = src
|
||||
depends =
|
||||
version
|
||||
deps =
|
||||
{[tox]dependencies}
|
||||
-e .[docs]
|
||||
changedir = src
|
||||
allowlist_externals =
|
||||
bash
|
||||
find
|
||||
mv
|
||||
setenv =
|
||||
SPHINX_APIDOC_OPTIONS=members,no-undoc-members,show-inheritance
|
||||
commands =
|
||||
@ -65,16 +67,16 @@ description = Generate html documentation
|
||||
deps =
|
||||
{[tox]dependencies}
|
||||
-e .[docs]
|
||||
recreate = True
|
||||
recreate = true
|
||||
commands =
|
||||
sphinx-build -b html -a -j auto -W docs {envtmpdir}{/}html
|
||||
|
||||
[testenv:publish]
|
||||
description = Create and publish release to GitHub
|
||||
depends =
|
||||
docs
|
||||
allowlist_externals =
|
||||
git
|
||||
depends =
|
||||
docs
|
||||
passenv =
|
||||
SSH_AUTH_SOCK
|
||||
commands =
|
||||
@ -89,15 +91,18 @@ description = Run tests
|
||||
deps =
|
||||
{[tox]dependencies}
|
||||
-e .[tests]
|
||||
pip_pre = true
|
||||
setenv =
|
||||
CFLAGS="-Wno-unterminated-string-initialization"
|
||||
commands =
|
||||
pytest {posargs}
|
||||
|
||||
[testenv:version]
|
||||
description = Bump package version
|
||||
deps =
|
||||
packaging
|
||||
allowlist_externals =
|
||||
sed
|
||||
deps =
|
||||
packaging
|
||||
commands =
|
||||
# check if version is set and validate it
|
||||
{envpython} -c 'from packaging.version import Version; Version("{posargs}")'
|
||||
|
Reference in New Issue
Block a user