diff options
-rw-r--r-- | gentoo | 18 |
1 files changed, 16 insertions, 2 deletions
@@ -1099,7 +1099,7 @@ _equery() if [[ $j -lt $COMP_CWORD ]]; then j=$((j + 1)) case $i in - @(belongs|ch@(anges|eck)|dep@(ends|graph)|files|glsa|list|s@(ize|tats)|uses|which|hasuse|b|c|k|d|g|f|a|h|l|s|t|u|w)) + @(belongs|ch@(anges|eck)|dep@(ends|graph)|files|glsa|list|meta|s@(ize|tats)|uses|which|hasuse|b|c|k|d|g|f|a|h|l|m|s|t|u|w)) mode=$i ;; esac @@ -1114,7 +1114,7 @@ _equery() COMPREPLY=($(compgen -W "-q --quiet -C --nocolor -h --help -V --version" -- $cur)) ;; *) - COMPREPLY=($(compgen -W "belongs changes check depends depgraph files glsa hasuse list size stats uses which" -- $cur)) + COMPREPLY=($(compgen -W "belongs changes check depends depgraph files glsa hasuse list meta size stats uses which" -- $cur)) ;; esac ;; @@ -1247,6 +1247,20 @@ _equery() esac fi ;; + m?(eta)) + # Only complete if the previous entry on the command line is not + # a package name. + if [[ ${prev} == ${mode} || ${prev:0:1} == "-" ]]; then + case $cur in + -*) + COMPREPLY=($(compgen -W "--help -h --description -d --herd -H --keywords -k --maintainer -m --useflags -u --upstream -U --xml -x" -- $cur)) + ;; + *) + _pkgname -A $cur + ;; + esac + fi + ;; k|check) # Only complete if the previous entry on the command line is not # a package name. |