diff options
-rw-r--r-- | .SRCINFO | 2 | ||||
-rw-r--r-- | PKGBUILD | 27 |
2 files changed, 20 insertions, 9 deletions
@@ -1,6 +1,6 @@ pkgbase = notmuch-mailmover-git pkgdesc = notmuch-mailmover is a tool to move notmuch tagged mails into Maildir folders - pkgver = v0.1.0.r12.gad4f9e6 + pkgver = v0.1.0.r63.gf693028 pkgrel = 1 url = https://github.com/michaeladler/notmuch-mailmover arch = i686 @@ -1,7 +1,8 @@ # Maintainer: Michael Adler <therisen06@gmail.com> -pkgname=notmuch-mailmover-git -pkgver=v0.1.0.r12.gad4f9e6 +_pkgname=notmuch-mailmover +pkgname=${_pkgname}-git +pkgver=v0.1.0.r63.gf693028 pkgrel=1 pkgdesc='notmuch-mailmover is a tool to move notmuch tagged mails into Maildir folders' arch=('i686' 'x86_64' 'armv6h' 'armv7h') @@ -15,29 +16,39 @@ source=("${pkgname%-*}::git+$url") sha256sums=('SKIP') pkgver() { - cd "${pkgname%-*}" + cd "${_pkgname}" git describe --tags | sed 's/\([^-]*-g\)/r\1/;s/-/./g' } prepare() { - cd "${pkgname%-*}" + cd "${_pkgname}" cargo fetch --locked --target "$CARCH-unknown-linux-gnu" } build() { - cd "${pkgname%-*}" + cd "${_pkgname}" export RUSTUP_TOOLCHAIN=stable export CARGO_TARGET_DIR=target cargo build --frozen --release --all-features } check() { - cd "${pkgname%-*}" + cd "${_pkgname}" export RUSTUP_TOOLCHAIN=stable cargo test --frozen --all-features } package() { - cd "${pkgname%-*}" - install -Dm0755 -t "$pkgdir/usr/bin/" "target/release/${pkgname%-*}" + cd "${_pkgname}" + install -Dm0755 -t "$pkgdir/usr/bin/" "target/release/${_pkgname}" + install -Dm644 LICENSE "$pkgdir/usr/share/licenses/${_pkgname}/LICENSE" + + # completions + install -Dm644 share/notmuch-mailmover.bash "$pkgdir/usr/share/bash-completion/completions/notmuch-mailmover" + install -Dm644 share/_notmuch-mailmover "$pkgdir/usr/share/zsh/site-functions/_notmuch-mailmover" + install -Dm644 share/notmuch-mailmover.fish "$pkgdir/usr/share/fish/vendor_completions.d/notmuch-mailmover.fish" + + # man page + mkdir -p "$pkgdir/usr/share/man/man1" + gzip --best --stdout <share/notmuch-mailmover.1 >"$pkgdir/usr/share/man/man1/notmuch-mailmover.1.gz" } |