warn when switching between ROS distros

This commit is contained in:
Dirk Thomas 2012-12-06 08:46:11 +00:00
parent 5db18bac96
commit df65bc049a
1 changed files with 3 additions and 0 deletions

View File

@ -3,6 +3,9 @@
# scrub old ROS bin dirs, to avoid accidentally finding the wrong executables
export PATH=`python -c "import os; print(os.pathsep.join([x for x in \"$PATH\".split(os.pathsep) if not any([d for d in ['cturtle', 'diamondback', 'electric', 'fuerte'] if d in x])]))"`
if [ -n "$ROS_DISTRO" -a "$ROS_DISTRO" != "groovy" ]; then
echo "ROS_DISTRO was set to '$ROS_DISTRO' before. Please make sure that the environment does not mix paths from different distributions."
fi
export ROS_DISTRO=groovy
# python function to generate ROS package path based on all workspaces