# Maintainer: Achmad Fathoni # Contributor: Tong Chunli pkgname=python-colcon-package-information _name=${pkgname:7} pkgver=0.4.0 pkgrel=1 pkgdesc="An extension for colcon-core to provide information about the packages." arch=(any) url="https://pypi.org/project/colcon-package-information/" license=('Apache') depends=('python-colcon-core') makedepends=('python-setuptools' 'flake8') source=( https://github.com/colcon/colcon-package-information/archive/refs/tags/${pkgver}.tar.gz https://github.com/myint/scspell/archive/refs/tags/v2.2.tar.gz) sha256sums=('1ea7d25cb0ccafc8f7c7ab56e49aad27cf67c15091c3fad6418808c4d3ab6cd8' '04c6a795a9e0ef4571678eb9fc503bcf39106a975691336af778f31a01027082') build() { cd ${srcdir}/${_name}-${pkgver} python -m build --wheel --no-isolation } check() { cd ${srcdir}/${_name}-${pkgver}/test export PYTHONPATH="${srcdir}/scspell-2.2:${srcdir}/${_name}-${pkgver}" ls test*.py | xargs -I {} pytest {} } package() { cd ${srcdir}/${_name}-${pkgver} python -m installer --destdir="${pkgdir}" dist/*.whl install -D -m644 README.rst -t "${pkgdir}/usr/share/doc/${pkgname}" }