Only execute the planet commands if we're tab-completing after 'rico planet'.
This commit is contained in:
parent
1321a766c0
commit
4718f1657b
|
@ -100,7 +100,6 @@ _rico()
|
|||
# removing the empty string on the next line breaks things. such as my brain.
|
||||
cmds=$( echo '' '--help' ; for x in ${tmpoutput} ; do echo ${x} ; done )
|
||||
makeopts="--disable-inline --no-deps -p --prefix --no-prim -v -vv --help -h"
|
||||
planetcmds=$( echo '' '--help' ; for x in `rico planet --help 2>&1 | sed -n -e 's/^ \(.[^ ]*\).*/\1/p'` ; do echo ${x} ; done )
|
||||
|
||||
#
|
||||
# Complete the arguments to some of the basic commands.
|
||||
|
@ -120,6 +119,7 @@ _rico()
|
|||
esac
|
||||
;;
|
||||
planet)
|
||||
planetcmds=$( echo '' '--help' ; for x in `rico planet --help 2>&1 | sed -n -e 's/^ \(.[^ ]*\).*/\1/p'` ; do echo ${x} ; done )
|
||||
COMPREPLY=( $(compgen -W "${planetcmds}" -- ${cur}) )
|
||||
;;
|
||||
--help)
|
||||
|
|
Loading…
Reference in New Issue
Block a user