diff --git a/tools/rosbash/rosbash b/tools/rosbash/rosbash index 13327f8b..b3dcd36e 100644 --- a/tools/rosbash/rosbash +++ b/tools/rosbash/rosbash @@ -638,6 +638,9 @@ function _roscomplete_rostopic { elif [[ $COMP_CWORD == 3 ]]; then opts=`_msg_opts ${COMP_WORDS[$COMP_CWORD]}` COMPREPLY=($(compgen -W "$opts" -- ${arg})) + elif [[ $COMP_CWORD == 4 ]]; then + opts=`rosrun rosmsg rosmsgproto msg -s ${COMP_WORDS[3]}` + COMPREPLY="$opts" fi ;; esac @@ -664,6 +667,14 @@ function _roscomplete_rosservice { COMPREPLY=($(compgen -W "$opts" -- ${arg})) ;; esac + elif [[ $COMP_CWORD == 3 ]]; then + case ${COMP_WORDS[1]} in + call) + type=`rosservice type ${COMP_WORDS[2]}` + opts=`rosrun rosmsg rosmsgproto srv -s ${type}` + COMPREPLY="$opts" + ;; + esac fi } diff --git a/tools/rosbash/roszsh b/tools/rosbash/roszsh index e0599c44..9fdafcdb 100644 --- a/tools/rosbash/roszsh +++ b/tools/rosbash/roszsh @@ -423,6 +423,9 @@ function _roscomplete_rostopic { elif [[ ${CURRENT} == 4 ]]; then opts=`_msg_opts ${=${(s: :)words[-1]}}` reply=(${=opts}) + elif [[ ${CURRENT} == 5 ]]; then + opts=`rosrun rosmsg rosmsgproto msg -s ${=${(s: :)words[-1]}}` + reply=(${=opts}) fi ;; esac @@ -450,6 +453,14 @@ function _roscomplete_rosservice { reply=(${=opts}) ;; esac + elif [[ ${CURRENT} == 4 ]]; then + case ${=${(s: :)words}[2]} in + call) + type=`rosservice type ${=${(s: :)words[-1]}}` + opts=`rosrun rosmsg rosmsgproto srv -s ${type}` + reply=(${=opts}) + ;; + esac fi }