aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLeo <thinkabit.ukim@gmail.com>2020-02-25 18:38:51 -0300
committerLeo <thinkabit.ukim@gmail.com>2020-02-25 19:50:20 -0300
commitff7a81e27355c764ce517a46d5742ec11911c196 (patch)
tree4894e45b8f16e7959e5a055916092ac45a4aca7d
parent442d18875f69d9a90295a0fd2354b39debb1ef96 (diff)
downloadaports-ff7a81e27355c764ce517a46d5742ec11911c196.tar.gz
aports-ff7a81e27355c764ce517a46d5742ec11911c196.tar.bz2
aports-ff7a81e27355c764ce517a46d5742ec11911c196.tar.xz
community/wl-clipboard: split shell completion
-rw-r--r--community/wl-clipboard/APKBUILD26
1 files changed, 23 insertions, 3 deletions
diff --git a/community/wl-clipboard/APKBUILD b/community/wl-clipboard/APKBUILD
index 2b3fbb678c..3724491779 100644
--- a/community/wl-clipboard/APKBUILD
+++ b/community/wl-clipboard/APKBUILD
@@ -2,16 +2,19 @@
# Maintainer: Robert Sacks <robert@sacks.email>
pkgname=wl-clipboard
pkgver=2.0.0
-pkgrel=2
+pkgrel=3
pkgdesc="Command-line copy/paste utilities for Wayland"
url="https://github.com/bugaevc/wl-clipboard"
arch="all"
license="GPL-3.0-or-later"
options="!check" # No test suite
makedepends="meson ninja wayland-dev wayland-protocols"
-subpackages="$pkgname-doc"
+subpackages="
+ $pkgname-doc
+ $pkgname-zsh-completion:zshcomp:noarch
+ $pkgname-bash-completion:bashcomp:noarch
+ "
source="$pkgname-$pkgver.tar.gz::https://github.com/bugaevc/wl-clipboard/archive/v$pkgver.tar.gz"
-builddir="$srcdir/$pkgname-$pkgver"
build() {
meson \
@@ -28,4 +31,21 @@ package() {
DESTDIR="$pkgdir" ninja -C build install
}
+bashcomp() {
+ depends=""
+ pkgdesc="Bash completions for $pkgname"
+ install_if="$pkgname=$pkgver-r$pkgrel bash-completion"
+
+ cd "$pkgdir" || return 0
+ amove /usr/share/bash-completion/completions
+}
+
+zshcomp() {
+ depends=""
+ pkgdesc="Zsh completions for $pkgname"
+ install_if="$pkgname=$pkgver-r$pkgrel zsh"
+
+ amove usr/share/zsh/site-functions
+}
+
sha512sums="a719b7197b0dec247ef50d800d8f10f3c377e41ff6d79ebfb4da50f2581d24a25ff987985e7a8f68842fdf8e706527d0b9ee3545c0044673110963b3ba8b55f1 wl-clipboard-2.0.0.tar.gz"