From 23dd080d18ab2bbb528f056bb083672c359e04e9 Mon Sep 17 00:00:00 2001 From: mia Date: Tue, 25 Jun 2024 15:12:57 -0700 Subject: add zsh completions --- PKGBUILD | 7 ++++--- compdef.zsh | 2 ++ 2 files changed, 6 insertions(+), 3 deletions(-) create mode 100755 compdef.zsh diff --git a/PKGBUILD b/PKGBUILD index 880f455..0ca8b12 100644 --- a/PKGBUILD +++ b/PKGBUILD @@ -1,11 +1,11 @@ pkgname=zoner pkgver=1 -pkgrel=1 +pkgrel=2 arch=(any) makedepends=(python-build python-installer python-wheel) depends=(python-requests) -source=(pyproject.toml zoner.py) -sha256sums=(SKIP SKIP) +source=(pyproject.toml zoner.py compdef.zsh) +sha256sums=(SKIP SKIP SKIP) license=(MIT) build() { @@ -14,4 +14,5 @@ build() { package() { python -m installer --destdir="$pkgdir" "$srcdir"/dist/*.whl + install -Dm644 "$srcdir/compdef.zsh" "$pkgdir/usr/share/zsh/site-functions/_zoner" } diff --git a/compdef.zsh b/compdef.zsh new file mode 100755 index 0000000..23cacc4 --- /dev/null +++ b/compdef.zsh @@ -0,0 +1,2 @@ +#compdef zoner +compadd $(ls ~/.config/zoner | grep -Po '.*(?=\.zone)') -- cgit 1.4.1