summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorMaciej Dems2021-10-18 08:03:59 +0200
committerMaciej Dems2021-10-18 08:03:59 +0200
commit0a72421e0912b1f0f14ed01234b115128efde509 (patch)
tree7860c2a2af7f2db4063848e29ca0f9542724f292
parentdc7b5873a9ca0c0375310b398882a216767b7f21 (diff)
downloadaur-0a72421e0912b1f0f14ed01234b115128efde509.tar.gz
AUR search and other fixes
-rw-r--r--.SRCINFO5
-rw-r--r--.gitignore2
-rw-r--r--PKGBUILD4
-rw-r--r--_pamac20
4 files changed, 12 insertions, 19 deletions
diff --git a/.SRCINFO b/.SRCINFO
index f9e00f5fe38f..6af11b6559cd 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,13 +1,12 @@
pkgbase = pamac-zsh-completions
pkgdesc = ZSH completions for pamac
- pkgver = 0.6
+ pkgver = 0.7
pkgrel = 1
arch = any
license = GPL
depends = zsh
depends = pamac
source = _pamac
- sha256sums = 12281bc86d5c6359a1b46a2c167a1a04f53ff7279d84912b5c84e1f0466b71ab
+ sha256sums = d1e23a0093494dc8868962695493c6f476f8730ced945e29b910b7de4443358f
pkgname = pamac-zsh-completions
-
diff --git a/.gitignore b/.gitignore
index 43d261a5d822..811022b71111 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,3 +1,3 @@
pkg
src
-*.pkg.tar.xz
+*.pkg.tar.*
diff --git a/PKGBUILD b/PKGBUILD
index c5be3422275f..b5de25e0e0a6 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,13 +1,13 @@
# Maintainer: Maciej Dems <macdems@gmail.com>
pkgname=pamac-zsh-completions
-pkgver=0.6
+pkgver=0.7
pkgrel=1
pkgdesc="ZSH completions for pamac"
depends=('zsh' 'pamac')
license=('GPL')
arch=('any')
source=('_pamac')
-sha256sums=('12281bc86d5c6359a1b46a2c167a1a04f53ff7279d84912b5c84e1f0466b71ab')
+sha256sums=('d1e23a0093494dc8868962695493c6f476f8730ced945e29b910b7de4443358f')
package() {
mkdir -p "${pkgdir}/usr/share/zsh/site-functions"
diff --git a/_pamac b/_pamac
index a1ee5b78a0d6..f070ebe557e7 100644
--- a/_pamac
+++ b/_pamac
@@ -36,7 +36,7 @@ _pamac_completions_all_packages() {
typeset -U packages
${seq} _wanted repo_packages expl "repository/package" compadd ${sep[@]} ${(@)packages}
else
- packages=( $(_call_program packages pacman -Sql) )
+ packages=( $(_call_program packages pamac search -q ${words[CURRENT]}) )
typeset -U packages
${seq} _wanted packages expl "packages" compadd ${sep[@]} - "${(@)packages}"
@@ -62,12 +62,6 @@ _pamac_completions_installed_packages() {
compadd "$@" -a packages
}
-_pamac_all_packages() {
- _alternative : \
- 'localpkgs:local packages:_pamac_completions_installed_packages' \
- 'repopkgs:repository packages:_pamac_completions_all_packages'
-}
-
_pamac_completions_all_packages_and_groups() {
_alternative : \
'pkgs:packages:_pamac_completions_all_packages' \
@@ -169,7 +163,7 @@ _pamac_command_info() {
_arguments : \
"(1 * -)--help[show help for command]" \
"(-a --aur)"{-a,--aur}"[also search in AUR]" \
- "*:packages:_pamac_all_packages"
+ "*:packages:_pamac_completions_all_packages"
}
_pamac_command_list() {
@@ -180,14 +174,14 @@ _pamac_command_list() {
"(-m --foreign)"{-m,--foreign}"[list packages that were not found in the repositories]" \
"(-g --groups)"{-g,--groups}"[list all packages that are members of the given groups, if no group is given list all groups]:groups:_pamac_completions_all_groups" \
"(-r --repos)"{-r,--repos}"[list all packages available in the given repos, if no repo is given list all repos]:repos:_pamac_completions_repositories" \
- "(-f --files)"{-f,--files}"[list files owned by the given packages]:packages:_pamac_all_packages"
+ "(-f --files)"{-f,--files}"[list files owned by the given packages]:packages:_pamac_completions_all_packages"
}
_pamac_command_install() {
_arguments : \
"(1 * -)--help[show help for command]" \
- "(--ignore)--ignore[ignore a package upgrade, multiple packages can be specified by separating them with a comma]:packages:_pamac_all_packages" \
- "(--overwrite)--override[overwrite conflicting files, multiple patterns can be specified by separating them with a comma]:glob:_files" \
+ "(--ignore)--ignore[ignore a package upgrade, multiple packages can be specified by separating them with a comma]:packages:_pamac_completions_all_packages" \
+ "(--overwrite)--overwrite[overwrite conflicting files, multiple patterns can be specified by separating them with a comma]:glob:_files" \
"(--no-confirm)--no-confirm[bypass any and all confirmation messages]" \
"*:packages:_pamac_completions_all_packages_groups_and_local"
}
@@ -207,7 +201,7 @@ _pamac_command_clone() {
"(--builddir)--builddir[build directory, if no directory is given the one specified in pamac.conf file is used]:dir:_path_files -/" \
"(-r --recurse)"{-r,--recurse}"[also clone needed dependencies]" \
"(--overwrite)--overwrite[overwrite existing files]" \
- "*:packages:_pamac_all_packages"
+ "*:packages:_pamac_completions_all_packages"
}
_pamac_command_build() {
@@ -217,7 +211,7 @@ _pamac_command_build() {
"(-k --keep)"{-k,--keep}"[keep built packages in cache after installation]" \
"(--no-clone)--no-clone[do not clone build files from AUR, only use local files]" \
"(--no-confirm)--no-confirm[bypass any and all confirmation messages]" \
- "*:packages:_pamac_all_packages"
+ "*:packages:_pamac_completions_all_packages"
}
_pamac_command_remove() {