diff options
author | Luis Martinez | 2021-08-31 19:00:37 -0500 |
---|---|---|
committer | Luis Martinez | 2021-08-31 19:01:07 -0500 |
commit | 6fc832b5fa21b10b2b7447f2322b6d6e8c23767d (patch) | |
tree | de7eb41102ad2d6f32e8185fbdc9589ed0d4e3dd | |
parent | 25ea87fe4c3109786bb65a3626504a52191493de (diff) | |
download | aur-6fc832b5fa21b10b2b7447f2322b6d6e8c23767d.tar.gz |
update in accordance to updated Rust packaging guidelines
-rw-r--r-- | .SRCINFO | 5 | ||||
-rw-r--r-- | PKGBUILD | 37 |
2 files changed, 25 insertions, 17 deletions
@@ -1,7 +1,7 @@ pkgbase = zoxide-git pkgdesc = A fast cd command that learns your habits - pkgver = 0.6.0.r4.g1828414 - pkgrel = 3 + pkgver = 0.7.4.r9.g9ff8993 + pkgrel = 1 url = https://github.com/ajeetdsouza/zoxide arch = x86_64 arch = armv7h @@ -16,4 +16,3 @@ pkgbase = zoxide-git sha512sums = SKIP pkgname = zoxide-git - @@ -1,9 +1,9 @@ -# Maintainer: Luis Martinez +# Maintainer: Luis Martinez <luis dot martinez at disroot dot org> # Credit: desbma + pkgname=zoxide-git -_pkgname=zoxide -pkgver=0.6.0.r4.g1828414 -pkgrel=3 +pkgver=0.7.4.r9.g9ff8993 +pkgrel=1 pkgdesc='A fast cd command that learns your habits' arch=('x86_64' 'armv7h' 'aarch64') url="https://github.com/ajeetdsouza/zoxide" @@ -12,23 +12,32 @@ depends=('gcc-libs') makedepends=('cargo' 'git') provides=("${pkgname%-git}") conflicts=("${pkgname%-git}") -source=("${pkgname}::git+${url}") +source=("$pkgname::git+$url") sha512sums=('SKIP') pkgver() { - cd "${pkgname}" - git describe --long --tags | sed 's/^v//;s/\([^-]*-g\)/r\1/;s/-/./g' + git -C "$pkgname" describe --long --tags | sed 's/^v//;s/\([^-]*-g\)/r\1/;s/-/./g' +} + +prepare() { + cd "$pkgname" + cargo update + cargo fetch --locked --target "$CARCH-unknown-linux-gnu" } build() { - cd "${pkgname}" - cargo build --release --locked --all-features --target-dir=target + export RUSTUP_TOOLCHAIN=stable + export CARGO_TARGET_DIR=target + cd "$pkgname" + cargo build --release --frozen --all-features } package() { - cd "${pkgname}" - install -Dm 755 -t "${pkgdir}/usr/bin" ./target/release/zoxide - install -Dm 644 LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE" - find man -name '*.1' -type f \ - -exec install -Dm 644 '{}' -t "${pkgdir}/usr/share/man/man1/" \; + cd "$pkgname" + install -Dm 755 -t "$pkgdir/usr/bin" target/release/zoxide + install -Dm 644 LICENSE -t "$pkgdir/usr/share/licenses/$pkgname/" + install -Dm 644 man/*.1 -t "$pkgdir/usr/share/man/man1/" + install -Dm 644 contrib/completions/zoxide.bash "$pkgdir/usr/share/bash-completion/completions/zoxide" + install -Dm 644 contrib/completions/_zoxide -t "$pkgdir/usr/share/zsh/site-completions/" + install -Dm 644 contrib/completions/zoxide.fish -t "$pkgdir/usr/share/fish/vendor_completions.d/" } |