# Contributor: Robin Candau <robincandau@protonmail.com>
# Maintainer: Robin Candau <robincandau@protonmail.com>
pkgname=typobuster
pkgver=1.0.0
pkgrel=0
pkgdesc="Lightweight editor with text transformations and auto-correction"
url="https://github.com/nwg-piotr/typobuster"
arch="noarch"
license="GPL-3.0-only"
depends="python3 py3-cairo py3-gobject3"
makedepends="py3-gpep517 py3-build py3-installer py3-wheel py3-setuptools gtk+3.0-dev glib-dev gtksourceview4-dev gspell-dev"
source="$pkgname-$pkgver.tar.gz::https://github.com/nwg-piotr/typobuster/archive/v$pkgver.tar.gz"
options="!check" # no test suite

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

package() {
	gpep517 install-wheel --destdir "$pkgdir" .dist/*.whl

	install -Dm 644 "$pkgname.svg" "$pkgdir/usr/share/pixmaps/$pkgname.svg"
	install -Dm 644 "$pkgname.desktop" "$pkgdir/usr/share/applications/$pkgname.desktop"
	install -Dm 644 README.md "$pkgdir/usr/share/doc/$pkgname/README.md"
}

sha512sums="
71b522b428759d32260b9370282a420b2e711b626b6ce3a77e421292f20aa9a87e0a325f4d4c33a1805d885bf530c3b3bf3e6dd7ee3bf71a684f2ccbec4e6c24  typobuster-1.0.0.tar.gz
"
