# Contributor: Fabian Affolter # Maintainer: Fabian Affolter pkgname=py3-ansi2html _pyname=ansi2html pkgver=1.7.0 pkgrel=1 pkgdesc="Convert text with ANSI color codes to HTML" url="http://github.com/ralphbean/ansi2html/" arch="noarch" license="LGPL-3.0-or-later" depends="py3-six" makedepends="py3-setuptools_scm py3-setuptools-scm-git-archive py3-wheel py3-installer py3-build" checkdepends="py3-pytest py3-mock py3-nose" replaces="py-ansi2html py2-ansi2html" _pypiprefix="${_pyname%${_pyname#?}}" source="https://files.pythonhosted.org/packages/source/$_pypiprefix/$_pyname/$_pyname-$pkgver.tar.gz" builddir="$srcdir"/$_pyname-$pkgver options="!check" # Upstream tests are stupid build() { export SETUPTOOLS_SCM_PRETEND_VERSION=$pkgver python3 -m build --no-isolation --wheel . } check() { PYTHONPATH="$(pwd)" pytest-3 } package() { python3 -m installer --destdir="$pkgdir" \ dist/ansi2html-$pkgver-py3-none-any.whl } sha512sums=" bcae0de9874899bd8440853b8279f3b2c4ed46e24bf807221ddc9d1bfa39647e2efd178aefc2fd39bad27b53890270b6ff7c150a0b8e74581b8323ef7a16c977 ansi2html-1.7.0.tar.gz "