From c566d24fbf0cf853b22d7d453261ecf891e0baa6 Mon Sep 17 00:00:00 2001 From: doublebrackets Date: Mon, 17 Mar 2025 20:25:23 +0530 Subject: [PATCH] replaced with $ROS_DISTRO Signed-off-by: doublebrackets --- .../build_docs/build_troubleshooting_guide.rst | 2 +- getting_started/index.rst | 12 ++++++------ setup_guides/odom/setup_odom_gz.rst | 2 +- setup_guides/odom/setup_odom_gz_classic.rst | 2 +- setup_guides/odom/setup_robot_localization.rst | 2 +- setup_guides/sdf/setup_sdf.rst | 2 +- setup_guides/sensors/mapping_localization.rst | 6 +++--- setup_guides/urdf/setup_urdf.rst | 4 ++-- tutorials/docs/camera_calibration.rst | 8 ++++---- tutorials/docs/navigation2_on_real_turtlebot3.rst | 4 ++-- tutorials/docs/navigation2_with_gps.rst | 2 +- tutorials/docs/navigation2_with_slam.rst | 8 ++++---- tutorials/docs/navigation2_with_stvl.rst | 4 ++-- 13 files changed, 29 insertions(+), 29 deletions(-) diff --git a/development_guides/build_docs/build_troubleshooting_guide.rst b/development_guides/build_docs/build_troubleshooting_guide.rst index c4f72c9149..55feefb31f 100644 --- a/development_guides/build_docs/build_troubleshooting_guide.rst +++ b/development_guides/build_docs/build_troubleshooting_guide.rst @@ -9,7 +9,7 @@ Common Nav2 Dependencies Build Failures * Make sure that .bashrc file has no ROS environment variables in it. Open new terminals and try to build the packages again. * Make sure to run rosdep for the correct ROS 2 distribution. - ``rosdep install -y -r -q --from-paths src --ignore-src --rosdistro `` + ``rosdep install -y -r -q --from-paths src --ignore-src --rosdistro $ROS_DISTRO`` * Make sure that the ``setup.bash`` is sourced in the ROS 2 installation or ROS 2 main build workspace, if applicable. Check if you can run talker and listener nodes. diff --git a/getting_started/index.rst b/getting_started/index.rst index 6053972d82..a11f4343fa 100644 --- a/getting_started/index.rst +++ b/getting_started/index.rst @@ -28,8 +28,8 @@ Thus, for Jazzy and newer, the installation packages and instructions are slight .. code-block:: bash - sudo apt install ros--navigation2 - sudo apt install ros--nav2-bringup + sudo apt install ros-$ROS_DISTRO-navigation2 + sudo apt install ros-$ROS_DISTRO-nav2-bringup 3. Install the demo robot (Turtlebot) for gazebo: @@ -37,14 +37,14 @@ For **Jazzy and newer**, install the Turtlebot 3 & 4 packages for Gazebo Modern. .. code-block:: bash - sudo apt install ros--nav2-minimal-tb* + sudo apt install ros-$ROS_DISTRO-nav2-minimal-tb* For **Iron and older**, install Turtlebot 3 packages for gazebo classic: .. code-block:: bash - sudo apt install ros--turtlebot3-gazebo + sudo apt install ros-$ROS_DISTRO-turtlebot3-gazebo Running the Example ******************* @@ -54,9 +54,9 @@ Running the Example .. code-block:: bash - source /opt/ros//setup.bash + source /opt/ros/$ROS_DISTRO/setup.bash export TURTLEBOT3_MODEL=waffle # Iron and older only with Gazebo Classic - export GAZEBO_MODEL_PATH=$GAZEBO_MODEL_PATH:/opt/ros//share/turtlebot3_gazebo/models # Iron and older only with Gazebo Classic + export GAZEBO_MODEL_PATH=$GAZEBO_MODEL_PATH:/opt/ros/$ROS_DISTRO/share/turtlebot3_gazebo/models # Iron and older only with Gazebo Classic 3. In the same terminal, run: diff --git a/setup_guides/odom/setup_odom_gz.rst b/setup_guides/odom/setup_odom_gz.rst index bcc4ee67d1..bab998e2a7 100644 --- a/setup_guides/odom/setup_odom_gz.rst +++ b/setup_guides/odom/setup_odom_gz.rst @@ -81,7 +81,7 @@ Setup and Prerequisites .. code-block:: shell - sudo apt install ros--ros-gz + sudo apt install ros-$ROS_DISTRO-ros-gz Adding Gazebo Plugins to a URDF/SDF =================================== diff --git a/setup_guides/odom/setup_odom_gz_classic.rst b/setup_guides/odom/setup_odom_gz_classic.rst index 9fabe53ca1..da99bd40eb 100644 --- a/setup_guides/odom/setup_odom_gz_classic.rst +++ b/setup_guides/odom/setup_odom_gz_classic.rst @@ -81,7 +81,7 @@ We also need to install the ``gazebo_ros_pkgs`` package to simulate odometry and .. code-block:: shell - sudo apt install ros--gazebo-ros-pkgs + sudo apt install ros-$ROS_DISTRO-gazebo-ros-pkgs You can test if you have successfully set up your ROS 2 and Gazebo environments by following the instructions `given here `_. diff --git a/setup_guides/odom/setup_robot_localization.rst b/setup_guides/odom/setup_robot_localization.rst index 2c6c20923f..b28c921086 100644 --- a/setup_guides/odom/setup_robot_localization.rst +++ b/setup_guides/odom/setup_robot_localization.rst @@ -29,7 +29,7 @@ First, install the ``robot_localization`` package using your machines package ma .. code-block:: shell - sudo apt install ros--robot-localization + sudo apt install ros-$ROS_DISTRO-robot-localization Next, we specify the parameters of the ``ekf_node`` using a YAML file. Create a directory named ``config`` at the root of your project and create a file named ``ekf.yaml``. Copy the following lines of code into your ``ekf.yaml`` file. diff --git a/setup_guides/sdf/setup_sdf.rst b/setup_guides/sdf/setup_sdf.rst index 2f14016117..41949537e8 100644 --- a/setup_guides/sdf/setup_sdf.rst +++ b/setup_guides/sdf/setup_sdf.rst @@ -17,7 +17,7 @@ We can also use our SDF with the robot_state_publisher using the following packa .. code-block:: shell - sudo apt install ros--sdformat-urdf + sudo apt install ros-$ROS_DISTRO-sdformat-urdf This package contains a C++ library and urdf_parser_plugin for converting SDFormat XML into URDF C++ structures. Installing it allows one to use SDFormat XML instead of URDF XML as a robot description. diff --git a/setup_guides/sensors/mapping_localization.rst b/setup_guides/sensors/mapping_localization.rst index ba995075a9..9d32a7a778 100644 --- a/setup_guides/sensors/mapping_localization.rst +++ b/setup_guides/sensors/mapping_localization.rst @@ -167,7 +167,7 @@ To be able to launch ``slam_toolbox``, make sure that you have installed the ``s .. code-block:: shell - sudo apt install ros--slam-toolbox + sudo apt install ros-$ROS_DISTRO-slam-toolbox We will launch the ``async_slam_toolbox_node`` of ``slam_toolbox`` using the package's built-in launch files. Open a new terminal and then execute the following lines: @@ -199,8 +199,8 @@ First, Make sure you have installed the Nav2 packages by executing the following .. code-block:: shell - sudo apt install ros--navigation2 - sudo apt install ros--nav2-bringup + sudo apt install ros-$ROS_DISTRO-navigation2 + sudo apt install ros-$ROS_DISTRO-nav2-bringup We will now launch Nav2 using the ``nav2_bringup``'s built-in launch file, ``navigation_launch.py`` . Open a new terminal and execute the following: diff --git a/setup_guides/urdf/setup_urdf.rst b/setup_guides/urdf/setup_urdf.rst index 23d0207f83..bcf21e9245 100644 --- a/setup_guides/urdf/setup_urdf.rst +++ b/setup_guides/urdf/setup_urdf.rst @@ -33,8 +33,8 @@ Let's begin by installing some additional ROS 2 packages that we will be using d .. code-block:: shell - sudo apt install ros--joint-state-publisher-gui - sudo apt install ros--xacro + sudo apt install ros-$ROS_DISTRO-joint-state-publisher-gui + sudo apt install ros-$ROS_DISTRO-xacro Next, create a directory for your project, initialize a ROS 2 workspace and give your robot a name. For ours, we'll be calling it ``sam_bot``. diff --git a/tutorials/docs/camera_calibration.rst b/tutorials/docs/camera_calibration.rst index 6599f571ed..321af4ceeb 100644 --- a/tutorials/docs/camera_calibration.rst +++ b/tutorials/docs/camera_calibration.rst @@ -18,16 +18,16 @@ Requirements 1- Install Camera Calibration Parser, Camera Info Manager and Launch Testing Ament Cmake using operating system’s package manager: - ``sudo apt install ros--camera-calibration-parsers`` + ``sudo apt install ros-$ROS_DISTRO-camera-calibration-parsers`` - ``sudo apt install ros--camera-info-manager`` + ``sudo apt install ros-$ROS_DISTRO-camera-info-manager`` - ``sudo apt install ros--launch-testing-ament-cmake`` + ``sudo apt install ros-$ROS_DISTRO-launch-testing-ament-cmake`` 2- Image Pipeline need to be built from source in your workspace with: - ``git clone -b git@github.com:ros-perception/image_pipeline.git`` + ``git clone -b $ROS_DISTRO git@github.com:ros-perception/image_pipeline.git`` **Also, make sure you have the following:** diff --git a/tutorials/docs/navigation2_on_real_turtlebot3.rst b/tutorials/docs/navigation2_on_real_turtlebot3.rst index af7bb079a2..5a31e556ed 100644 --- a/tutorials/docs/navigation2_on_real_turtlebot3.rst +++ b/tutorials/docs/navigation2_on_real_turtlebot3.rst @@ -34,7 +34,7 @@ The turtlebot3 software can be installed via the following or on the `turtlebot3 .. code-block:: bash - sudo apt install ros--turtlebot3 ros--turtlebot3-msgs ros--turtlebot3-bringup + sudo apt install ros-$ROS_DISTRO-turtlebot3 ros-$ROS_DISTRO-turtlebot3-msgs ros-$ROS_DISTRO-turtlebot3-bringup Tutorial Steps ============== @@ -44,7 +44,7 @@ Tutorial Steps Run the following commands first whenever you open a new terminal during this tutorial. -- ``source /opt/ros//setup.bash`` +- ``source /opt/ros/$ROS_DISTRO/setup.bash`` - ``export TURTLEBOT3_MODEL=waffle`` 1- Launch Turtlebot 3 diff --git a/tutorials/docs/navigation2_with_gps.rst b/tutorials/docs/navigation2_with_gps.rst index 2f777923b8..22e9c7db70 100644 --- a/tutorials/docs/navigation2_with_gps.rst +++ b/tutorials/docs/navigation2_with_gps.rst @@ -30,7 +30,7 @@ It is assumed ROS2 and Nav2 dependent packages are installed or built locally. A .. code-block:: bash - source /opt/ros//setup.bash + source /opt/ros/$ROS_DISTRO/setup.bash sudo apt install ros-$ROS_DISTRO-robot-localization sudo apt install ros-$ROS_DISTRO-mapviz sudo apt install ros-$ROS_DISTRO-mapviz-plugins diff --git a/tutorials/docs/navigation2_with_slam.rst b/tutorials/docs/navigation2_with_slam.rst index 959fadc2e0..829d464e64 100644 --- a/tutorials/docs/navigation2_with_slam.rst +++ b/tutorials/docs/navigation2_with_slam.rst @@ -27,11 +27,11 @@ If you don't have them installed, please follow :ref:`getting_started`. SLAM Toolbox can be installed via: - ``sudo apt install ros--slam-toolbox`` + ``sudo apt install ros-$ROS_DISTRO-slam-toolbox`` or from built from source in your workspace with: - ``git clone -b -devel git@github.com:stevemacenski/slam_toolbox.git`` + ``git clone -b $ROS_DISTRO-devel git@github.com:stevemacenski/slam_toolbox.git`` Tutorial Steps @@ -45,14 +45,14 @@ The turtlebot3 software can be installed via the following or on the `turtlebot3 .. code-block:: bash - sudo apt install ros--turtlebot3 ros--turtlebot3-msgs ros--turtlebot3-bringup + sudo apt install ros-$ROS_DISTRO-turtlebot3 ros-$ROS_DISTRO-turtlebot3-msgs ros-$ROS_DISTRO-turtlebot3-bringup If you have another robot, replace with your robot specific interfaces. Typically, this includes the robot state publisher of the URDF, simulated or physical robot interfaces, controllers, safety nodes, and the like. Run the following commands first whenever you open a new terminal during this tutorial. -- ``source /opt/ros//setup.bash`` +- ``source /opt/ros/$ROS_DISTRO/setup.bash`` - ``export TURTLEBOT3_MODEL=waffle`` diff --git a/tutorials/docs/navigation2_with_stvl.rst b/tutorials/docs/navigation2_with_stvl.rst index b884532768..c47c18f2ac 100644 --- a/tutorials/docs/navigation2_with_stvl.rst +++ b/tutorials/docs/navigation2_with_stvl.rst @@ -59,11 +59,11 @@ Follow the same process as in :ref:`getting_started` for installing and setting STVL can be installed in ROS 2 via the ROS Build Farm: -- ``sudo apt install ros--spatio-temporal-voxel-layer`` +- ``sudo apt install ros-$ROS_DISTRO-spatio-temporal-voxel-layer`` It can also be built from source by cloning the repository into your Navigation2 workspace: -- ``git clone -b -devel git@github.com:stevemacenski/spatio_temporal_voxel_layer`` +- ``git clone -b $ROS_DISTRO-devel git@github.com:stevemacenski/spatio_temporal_voxel_layer`` 1- Modify Navigation2 Parameter -------------------------------