rosbash: tab complete on msg type for rostopic list and find
This commit is contained in:
parent
a5d76d438a
commit
57d2b29d43
|
@ -411,10 +411,20 @@ function _roscomplete_rostopic {
|
|||
COMPREPLY=($(compgen -W "$opts" -- ${arg}))
|
||||
;;
|
||||
find)
|
||||
# Need a clever way to do message searching
|
||||
opts=`_msg_opts ${COMP_WORDS[$COMP_CWORD]}`
|
||||
COMPREPLY=($(compgen -W "$opts" -- ${arg}))
|
||||
;;
|
||||
pub)
|
||||
# This takes more logic.
|
||||
opts=`rostopic list`
|
||||
COMPREPLY=($(compgen -W "$opts" -- ${arg}))
|
||||
;;
|
||||
esac
|
||||
elif [[ $COMP_CWORD == 3 ]]; then
|
||||
case ${COMP_WORDS[1]} in
|
||||
pub)
|
||||
opts=`_msg_opts ${COMP_WORDS[$COMP_CWORD]}`
|
||||
COMPREPLY=($(compgen -W "$opts" -- ${arg}))
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
|
|
Loading…
Reference in New Issue