# Maintainer: aquabeam pkgname=xshot-git pkgver=r12.b84afb1 pkgrel=2 pkgdesc='XS Screenshot Tool for X11' arch=('x86_64') url=https://github.com/hydrobeam/xshot license=('MIT') depends=('libxcb' 'libx11') makedepends=('cargo' 'git') provides=("${pkgname%-git}") conflicts=("${pkgname%-git}") source=("$pkgname::git+$url.git") sha256sums=(SKIP) # If there are no tags then use number of revisions since beginning of the history: pkgver() { cd "$pkgname" printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short=7 HEAD)" } prepare() { cargo fetch --locked --manifest-path=$pkgname/Cargo.toml --target="$CARCH-unknown-linux-gnu" } build() { cd "$pkgname" export RUSTUP_TOOLCHAIN=stable cargo build --release --locked find target -name xshot.fish | xargs dirname > out_dir } check() { cd "$pkgname" export RUSTUP_TOOLCHAIN=stable cargo test --release --locked } package() { cd "$pkgname" local OUT_DIR=$(