How to install ROS2 Jazzy Desktop on Ubuntu 24.04
sudo apt install software-properties-common
sudo add-apt-repository universe
sudo apt update && sudo apt install curl -y
sudo curl -sSL https://raw.githubusercontent.com/ros/rosdistro/master/ros.key -o /usr/share/keyrings/ros-archive-keyring.gpg
echo "deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/ros-archive-keyring.gpg] http://packages.ros.org/ros2/ubuntu $(. /etc/os-release && echo $UBUNTU_CODENAME) main" | sudo tee /etc/apt/sources.list.d/ros2.list > /dev/null
sudo apt update
sudo apt -y install ros-jazzy-desktop
After that, you can activate ROS2 using
source /opt/ros/jazzy/setup.bash
You can also add a shortcut for activating ROS using
echo "alias startros='source /opt/ros/jazzy/setup.bash'" >> ~/.bashrc
or for zsh
:
echo "alias startros='source /opt/ros/jazzy/setup.bash'" >> ~/.zshrc
Once you have either restarted your shell, or logged back and logged back in, you can activate ROS2 by typing startros
:
startros
If this post helped you, please consider buying me a coffee or donating via PayPal to support research & publishing of new posts on TechOverflow