forked from pool/bash-completion
Copy from shells/bash-completion based on submit request 32973 from user poletti_marco OBS-URL: https://build.opensuse.org/request/show/32973 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/bash-completion?expand=0&rev=1
13 lines
536 B
Diff
13 lines
536 B
Diff
--- contrib/rpm.orig 2009-10-20 14:01:24.171874435 +0200
|
|
+++ contrib/rpm 2009-10-20 14:03:32.696958718 +0200
|
|
@@ -13,6 +13,9 @@
|
|
COMPREPLY=( $( sed -ne \
|
|
's|^\('$cur'[^[:space:]]*\)-[^[:space:]-]\+-[^[:space:]-]\+\.rpm$|\1|p' \
|
|
/var/log/rpmpkgs ) )
|
|
+ elif command -v rpmqpack >/dev/null; then
|
|
+ # SUSE's rpmqpack is faster than rpm -qa
|
|
+ COMPREPLY=( $(rpmqpack | grep "^$cur") )
|
|
else
|
|
_rpm_nodigsig
|
|
COMPREPLY=( $( rpm -qa $nodig $nosig --qf='%{NAME} ' "$cur*" ) )
|