mirror of
https://github.com/built-aur/packages
synced 2024-08-14 23:01:15 +00:00
35 lines
1.3 KiB
Bash
35 lines
1.3 KiB
Bash
# Maintainer: MedzikUser <nivua1fn@duck.com>
|
|
pkgname='imgurs'
|
|
pkgver="0.11.2"
|
|
pkgrel=1
|
|
pkgdesc='CLI for a Imgur API written in Rust'
|
|
arch=('x86_64')
|
|
url="https://github.com/MedzikUser/imgurs"
|
|
license=('BSD3')
|
|
makedepends=('cargo')
|
|
optdepends=('libnotify: Notification support'
|
|
'xsel: Clipboard support'
|
|
'xclip: Clipboard support')
|
|
source=("${url}/archive/v${pkgver}.tar.gz")
|
|
sha256sums=('0d9739b5ea0ae128c2805a475f62c429aceaa80ae188544175b208ae87ba632c')
|
|
|
|
build() {
|
|
cd "${pkgname}-${pkgver}/imgurs-cli"
|
|
cargo build --release --locked
|
|
}
|
|
|
|
package() {
|
|
cd "${pkgname}-${pkgver}"
|
|
install -Dm 755 target/release/$pkgname "$pkgdir/usr/bin/$pkgname"
|
|
|
|
mkdir -p "$pkgdir"/usr/share/{bash-completion/completions,zsh/site-functions,fish/vendor_completions.d}
|
|
target/release/$pkgname completions bash > "$pkgdir"/usr/share/bash-completion/completions/$pkgname
|
|
target/release/$pkgname completions zsh > "$pkgdir"/usr/share/zsh/site-functions/_$pkgname
|
|
target/release/$pkgname completions fish > "$pkgdir"/usr/share/fish/vendor_completions.d/$pkgname.fish
|
|
|
|
mkdir -p "$pkgdir/usr/share/man/man1"
|
|
target/release/$pkgname manpage | gzip > "$pkgdir/usr/share/man/man1/$pkgname.1.gz"
|
|
|
|
install -Dm 644 LICENSE "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
|
|
}
|