# Maintainer: Cowington Post <cowingtonpost@gmail.com>
pkgname=ttyper
pkgver=1.6.0
pkgrel=0
pkgdesc="Terminal-based typing test"
url="https://github.com/max-niederman/ttyper/"
arch="all"
license="MIT"
makedepends="cargo cargo-auditable"
source="https://github.com/max-niederman/ttyper/archive/refs/tags/v$pkgver/ttyper-$pkgver.tar.gz
	"

prepare() {
	default_prepare

	cargo fetch --target="$CTARGET" --locked
}

build() {
	cargo auditable build --frozen --release
}

check() {
	cargo test --frozen
}

package() {
	install -Dm755 target/release/ttyper -t "$pkgdir"/usr/bin
}

sha512sums="
2d3f82b1409651dc5a2e81e10d2cd531a5454dd278d77fa588d1036c192d1a49ad38652580b903d3a121f4a5c1984d46bcdf812684444d2ee80d2336822debf2  ttyper-1.6.0.tar.gz
"
