Skip to content

Commit

Permalink
minor fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
rbonghi committed Oct 30, 2021
1 parent 299e243 commit 2d953e3
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions nanosaur/scripts/nanosaur
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ bold=`tput bold`
red=`tput setaf 1`
green=`tput setaf 2`
yellow=`tput setaf 3`
blue=`tput setaf 4`
reset=`tput sgr0`

# Load platform
Expand Down Expand Up @@ -710,10 +711,11 @@ fi
if [ -z "${VIRTUAL_ENV_DISABLE_PROMPT-}" ] ; then
_OLD_VIRTUAL_PS1="${PS1-}"
# Rewrite PS1
if [ -z ${ROS_DOMAIN_ID+x} ] ; then
PS1="${bold}($ROBOT_NAME)${reset} ${PS1-}"
else
PS1="${bold}($ROBOT_NAME id=$ROS_DOMAIN_ID)${reset} ${PS1-}"
PS1="${bold}($ROBOT_NAME)${reset} ${PS1-}"
if [ ! -z ${ROS_DOMAIN_ID+x} ] ; then
if [ $ROS_DOMAIN_ID -ne 0 ]; then
PS1="${bold}${blue}id=$ROS_DOMAIN_ID${reset} ${PS1-}"
fi
fi
export PS1
fi
Expand Down

0 comments on commit 2d953e3

Please sign in to comment.