2023-11-17 10:51:44 +00:00

47 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.

# Maintainer: Orhun Parmaksız <orhunparmaksiz@gmail.com>
pkgname=cargo-shuttle
pkgver=0.33.0
pkgrel=0
pkgdesc="Cargo command for the Shuttle platform"
url="https://github.com/shuttle-hq/shuttle"
license="Apache"
# s390x, ppc64le, riscv64: blocked by ring crate
arch="all !s390x !ppc64le !riscv64"
makedepends="cargo cargo-auditable"
subpackages="
$pkgname-doc
$pkgname-bash-completion
$pkgname-fish-completion
$pkgname-zsh-completion
"
source="https://github.com/shuttle-hq/shuttle/archive/v$pkgver/shuttle-$pkgver.tar.gz"
builddir="$srcdir/shuttle-$pkgver"
# tests require git/submodules to be initialized
options="!check"
prepare() {
default_prepare
cargo fetch --locked
}
build() {
cargo auditable build -p "$pkgname" --release --frozen
mkdir -p completions/
local compgen="target/release/$pkgname generate -s"
$compgen bash >"completions/$pkgname.bash"
$compgen fish >"completions/$pkgname.fish"
$compgen zsh >"completions/_$pkgname"
}
package() {
install -Dm755 "target/release/$pkgname" -t "$pkgdir/usr/bin/"
install -Dm644 README.md -t "$pkgdir/usr/share/doc/$pkgname"
install -Dm644 "completions/$pkgname.bash" "$pkgdir/usr/share/bash-completion/completions/$pkgname"
install -Dm644 "completions/$pkgname.fish" -t "$pkgdir/usr/share/fish/vendor_completions.d"
install -Dm644 "completions/_$pkgname" -t "$pkgdir/usr/share/zsh/site-functions"
}
sha512sums="
2ff81ac0dd0ba4c615670ee5792ea680ed0a029b479523663b6ab8797eaf86c4dbb8a47e32e7656b1c476ed7e034cdfeff3a564aa816697bcc9c3f93b1829583 shuttle-0.33.0.tar.gz
"