2023-10-18 23:20:53 +00:00

51 lines
1.5 KiB
Plaintext
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# Contributor: Orhun Parmaksız <orhunparmaksiz@gmail.com>
# Maintainer: Orhun Parmaksız <orhunparmaksiz@gmail.com>
pkgname=daktilo
pkgver=0.5.0
pkgrel=0
pkgdesc="Turn your keyboard into a typewriter"
url="https://github.com/orhun/daktilo"
arch="all"
license="MIT OR Apache-2.0"
depends="alsa-lib libxi-dev libxtst-dev"
makedepends="cargo cargo-auditable alsa-lib-dev"
subpackages="
$pkgname-doc
$pkgname-bash-completion
$pkgname-zsh-completion
$pkgname-fish-completion
"
options="net"
source="$pkgname-$pkgver.tar.gz::https://github.com/orhun/daktilo/archive/v$pkgver.tar.gz"
prepare() {
default_prepare
cargo fetch --target="$CTARGET" --locked
}
build() {
cargo auditable build --frozen --release
mkdir -p man
OUT_DIR=man/ target/release/daktilo-mangen
mkdir -p completions
OUT_DIR=completions/ target/release/daktilo-completions
}
check() {
OUT_DIR=target cargo test --frozen
}
package() {
install -Dm 755 "target/release/$pkgname" -t "$pkgdir/usr/bin"
install -Dm 644 README.md -t "$pkgdir/usr/share/doc/$pkgname"
install -Dm 644 "man/$pkgname.1" -t "$pkgdir/usr/share/man/man1"
install -Dm 644 "completions/$pkgname.bash" "$pkgdir/usr/share/bash-completion/completions/$pkgname"
install -Dm 644 "completions/$pkgname.fish" -t "$pkgdir/usr/share/fish/vendor_completions.d"
install -Dm 644 "completions/_$pkgname" -t "$pkgdir/usr/share/zsh/site-functions"
}
sha512sums="
059318cba86996f08540167c77ac5711aa470083ab92415dab3a37b82be3d22426450609b6dc9dad133d4bc8be58aaea1c56e017d501c79ff80eb4afa55d5826 daktilo-0.5.0.tar.gz
"