Add 'versions' command to aptitude (Debian: #604393)

This commit is contained in:
David Paleino 2011-11-01 20:32:45 +01:00
parent c0ea434660
commit 15211e74fe

View File

@ -28,7 +28,7 @@ _aptitude()
local special i
for (( i=0; i < ${#words[@]}-1; i++ )); do
if [[ ${words[i]} == @(@(|re)install|@(|un)hold|@(|un)markauto|@(dist|full)-upgrade|download|show|forbid-version|purge|remove|changelog|why@(|-not)|keep@(|-all)|build-dep|@(add|remove)-user-tag) ]]; then
if [[ ${words[i]} == @(@(|re)install|@(|un)hold|@(|un)markauto|@(dist|full)-upgrade|download|show|forbid-version|purge|remove|changelog|why@(|-not)|keep@(|-all)|build-dep|@(add|remove)-user-tag|versions) ]]; then
special=${words[i]}
fi
#exclude some mutually exclusive options
@ -40,7 +40,7 @@ _aptitude()
case $special in
install|hold|markauto|unmarkauto|dist-upgrade|full-upgrade| \
download|show|changelog|why|why-not|build-dep|add-user-tag| \
remove-user-tag)
remove-user-tag|versions)
COMPREPLY=( $( apt-cache pkgnames $cur 2> /dev/null ) )
return 0
;;
@ -81,7 +81,7 @@ _aptitude()
hold unhold purge markauto unmarkauto why why-not \
dist-upgrade full-upgrade download search show \
forbid-version changelog keep-all build-dep \
add-user-tag remove-user-tag' -- "$cur" ) )
add-user-tag remove-user-tag versions' -- "$cur" ) )
fi
return 0