summary refs log tree commit diff
diff options
context:
space:
mode:
authorAdam Spiers <adamspiers@users.sourceforge.net>2001-08-15 13:33:49 +0000
committerAdam Spiers <adamspiers@users.sourceforge.net>2001-08-15 13:33:49 +0000
commit3df9884871ff48175fd26ecdaf7d10b472cdda5d (patch)
tree320f0ea59b42ba98695fa1fca1441279071ba020
parentd4e7ce1b9cb8d199e93e5842fac6a80ce43c6b7c (diff)
downloadzsh-3df9884871ff48175fd26ecdaf7d10b472cdda5d.tar.gz
zsh-3df9884871ff48175fd26ecdaf7d10b472cdda5d.tar.xz
zsh-3df9884871ff48175fd26ecdaf7d10b472cdda5d.zip
15630: update caching policy for newer versions of rpm.
-rw-r--r--ChangeLog5
-rw-r--r--Completion/Redhat/Command/_rpm5
2 files changed, 9 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index d663b187b..00e5e1c30 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2001-08-15  Adam Spiers  <adam@spiers.net>
+
+	* 15630: Completion/Redhat/Command/_rpm: update caching policy
+	for newer versions of rpm.
+
 2001-08-14  Clint Adams  <clint@zsh.org>
 
 	* 15629: Completion/Unix/Command/_zip: unzip -Z
diff --git a/Completion/Redhat/Command/_rpm b/Completion/Redhat/Command/_rpm
index a174f1aa6..635d28989 100644
--- a/Completion/Redhat/Command/_rpm
+++ b/Completion/Redhat/Command/_rpm
@@ -272,7 +272,10 @@ _rpms_caching_policy () {
   oldp=( "$1"(mw+1) )
   (( $#oldp )) && return 0
 
-  [[ /var/lib/rpm/packages.rpm -nt "$1" ]]
+  pkg_indices=( /var/lib/rpm/{packages.rpm,Packages}(N) )
+  for pkg_index in $pkg_indices; do
+    [[ "$pkg_index" -nt "$1" ]] && return 0
+  done
 }
 
 _rpm "$@"