# Contributor: Bart Ribbers <bribbers@disroot.org>
maintainer="Bart Ribbers <bribbers@disroot.org>"
pkgname=py3-ovos-config
pkgver=1.0.0
pkgrel=0
pkgdesc="OVOS configuration manager library"
url="https://github.com/OpenVoiceOS/ovos-config"
arch="noarch"
license="Apache-2.0"
depends="
	py3-combo-lock
	py3-dateutil
	py3-ovos-utils
	py3-rich-click
	py3-watchdog
	py3-yaml
	"
makedepends="
	py3-gpep517
	py3-setuptools
	py3-wheel
	"
checkdepends="py3-pytest"
subpackages="$pkgname-pyc"
source="https://github.com/OpenVoiceOS/ovos-config/archive/$pkgver/ovos-config-$pkgver.tar.gz"
builddir="$srcdir/ovos-config-$pkgver"

build() {
	gpep517 build-wheel \
		--wheel-dir .dist \
		--output-fd 3 3>&1 >&2
}

check() {
	python3 -m venv --clear --without-pip --system-site-packages .testenv
	.testenv/bin/python3 -m installer .dist/*.whl
	.testenv/bin/python3 -m pytest
}

package() {
	python3 -m installer -d "$pkgdir" \
		.dist/*.whl
}

sha512sums="
94a642b94bfa4dde1481c31b05cce37f5c820b80454bae4536b1e7d9544b212e32d91b400c0100442f93e51885110c30e3bf79011ecd487f166af59e5ab6d10b  ovos-config-1.0.0.tar.gz
"
