pkgname=mkdocs-minify-plugin
pkgver=0.8.0
pkgrel=2
pkgdesc="A mkdocs plugin to minify the HTML of a page before it is written to disk"
url="https://github.com/byrnereese/mkdocs-minify-plugin"
license=("MIT")
arch=("any")
depends=("mkdocs" "python-htmlmin2" "python-jsmin" "python-csscompressor")
makedepends=("python-setuptools" "python-build" "python-installer" "python-wheel" git)
source=("source::git+$url#tag=${pkgver}")
sha256sums=('f181ded457113f023908e4d227479e9f18394eb88ef8e9aa001d6f1c8b04b21d')

build(){
	cd source
	python -m build --wheel --no-isolation
}

package(){
	cd source
	install -vDm644 -t \
		"${pkgdir}/usr/share/licenses/${pkgname}" LICENSE
	python -m installer --destdir="$pkgdir" dist/*.whl
}
