aports/testing/trippy/APKBUILD

43 lines
1.3 KiB
Text

# Contributor: Simon Frankenberger <simon-alpine@fraho.eu>
# Maintainer: Simon Frankenberger <simon-alpine@fraho.eu>
pkgname=trippy
pkgver=0.13.0
pkgrel=0
pkgdesc="combines the functionality of traceroute and ping and is designed to assist with the analysis of networking issues."
url="https://github.com/fujiapple852/trippy/"
arch="all"
license="Apache-2.0"
makedepends="cargo cargo-auditable"
subpackages="
$pkgname-bash-completion
$pkgname-zsh-completion
"
source="https://github.com/fujiapple852/trippy/archive/$pkgver/trippy-v$pkgver.tar.gz"
prepare() {
default_prepare
cargo fetch --target="$CTARGET" --locked
}
build() {
cargo auditable build --release --frozen
local compgen="target/release/trip --generate"
[ -d completions ] || mkdir -v completions
$compgen bash >"completions/$pkgname"
$compgen zsh >"completions/_$pkgname"
}
check() {
cargo auditable test --frozen
}
package() {
install -Dm 755 -t "$pkgdir"/usr/bin target/release/trip
install -Dm 644 -t "$pkgdir"/usr/share/doc/"$pkgname" README.md
install -Dm 644 "completions/$pkgname" -t "$pkgdir/usr/share/bash-completion/completions/"
install -Dm 644 "completions/_$pkgname" -t "$pkgdir/usr/share/zsh/site-functions/"
}
sha512sums="
3863fadfd0d9cc39a8ef06193a866405774634e871f45280bac906ea11b618d631a401facb7774c4ad0ffa6a4f1c9a64bc80cbb1f50701ad646b460698881922 trippy-v0.13.0.tar.gz
"