mirror of
https://github.com/ohmyzsh/ohmyzsh.git
synced 2026-05-01 04:30:37 +02:00
Display interface instead of ROS_IP when calling rosinterface
This commit is contained in:
parent
460570acb1
commit
ad82862e2a
1 changed files with 5 additions and 1 deletions
|
|
@ -76,7 +76,11 @@ rosmaster() {
|
|||
|
||||
rosinterface() {
|
||||
|
||||
[ $# -eq 0 ] && echo "$ROS_IP" && return 0
|
||||
if [ $# -eq 0 ]; then
|
||||
[ "$ROS_IP" ] && ifconfig | sed '/./{H;$!d};x;/'"$ROS_IP"'/!d' |
|
||||
egrep -o '^[[:alnum:]]+'
|
||||
return 0
|
||||
fi
|
||||
|
||||
local ros_interface_tag='ros_interface'
|
||||
local ros_interfaces="$(_omz_ros_config_get_line $ros_interface_tag)"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue