apt-build, apt-get, aptitude: Load _comp_dpkg_installed_packages on demand.

This commit is contained in:
Ville Skyttä 2011-10-26 19:29:33 +03:00
parent 889e1ae13e
commit 5811d47f0e
3 changed files with 6 additions and 3 deletions

View File

@ -19,7 +19,8 @@ _apt_build()
return 0
;;
remove)
COMPREPLY=( $( _comp_dpkg_installed_packages "$cur" ) )
COMPREPLY=( \
$( _xfunc dpkg _comp_dpkg_installed_packages "$cur" ) )
return 0
;;
*)

View File

@ -17,7 +17,8 @@ _apt_get()
remove|autoremove|purge)
if [ -f /etc/debian_version ]; then
# Debian system
COMPREPLY=( $( _comp_dpkg_installed_packages $cur ) )
COMPREPLY=( $( \
_xfunc dpkg _comp_dpkg_installed_packages $cur ) )
else
# assume RPM based
_xfunc rpm _rpm_installed_packages

View File

@ -45,7 +45,8 @@ _aptitude()
return 0
;;
purge|remove|reinstall|forbid-version)
COMPREPLY=( $( _comp_dpkg_installed_packages "$cur" ) )
COMPREPLY=( \
$( _xfunc dpkg _comp_dpkg_installed_packages "$cur" ) )
return 0
;;
unhold)