mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2026-01-17 06:32:36 +01:00
58 lines
1.6 KiB
Plaintext
58 lines
1.6 KiB
Plaintext
# Contributor: dai9ah <dai9ah@protonmail.com>
|
|
# Maintainer: dai9ah <dai9ah@protonmail.com>
|
|
pkgname=ddgr
|
|
pkgver=1.6
|
|
pkgrel=0
|
|
pkgdesc="DuckDuckGo from the terminal"
|
|
url="https://github.com/jarun/ddgr"
|
|
arch="noarch"
|
|
license="GPL-3.0-or-later"
|
|
depends="python3"
|
|
subpackages="$pkgname-doc
|
|
$pkgname-bash-completion:bashcomp:noarch
|
|
$pkgname-fish-completion:fishcomp:noarch
|
|
$pkgname-zsh-completion:zshcomp:noarch
|
|
"
|
|
source="$pkgname-$pkgver.tar.gz::https://github.com/jarun/ddgr/archive/v$pkgver.tar.gz"
|
|
builddir="$srcdir/$pkgname-$pkgver"
|
|
|
|
check() {
|
|
cd "$builddir"
|
|
./ddgr --help > /dev/null
|
|
}
|
|
|
|
package() {
|
|
cd "$builddir"
|
|
make DESTDIR="$pkgdir" PREFIX=/usr install
|
|
}
|
|
|
|
bashcomp() {
|
|
pkgdesc="Bash completion for $pkgname"
|
|
install_if="$pkgname=$pkgver-r$pkgrel bash-completion"
|
|
|
|
mkdir -p "$subpkgdir"/usr/share/bash-completion/completions/
|
|
install -Dm644 "$builddir"/auto-completion/bash/* \
|
|
"$subpkgdir"/usr/share/bash-completion/completions/
|
|
}
|
|
|
|
fishcomp() {
|
|
pkgdesc="Fish completion for $pkgname"
|
|
install_if="$pkgname=$pkgver-r$pkgrel fish"
|
|
|
|
mkdir -p "$subpkgdir"/usr/share/fish/completions/
|
|
install -Dm644 "$builddir"/auto-completion/fish/* \
|
|
"$subpkgdir"/usr/share/fish/completions/
|
|
}
|
|
|
|
zshcomp() {
|
|
pkgdesc="Zsh completion for $pkgname"
|
|
install_if="$pkgname=$pkgver-r$pkgrel zsh"
|
|
|
|
mkdir -p "$subpkgdir"/usr/share/zsh/site-functions
|
|
install -Dm644 "$builddir"/auto-completion/zsh/* \
|
|
"$subpkgdir"/usr/share/zsh/site-functions/
|
|
|
|
}
|
|
|
|
sha512sums="e42c622ef94f82bee17315f3e3b40e4d19ab13ce6be05e016936a04ba8559c0911b0ac290c6c36d4905b8db2e71b2ed2e086c06294e76402ee6d3bb21f2a2bfa ddgr-1.6.tar.gz"
|