ROS 2 workspace template for Docker with VSCode
If you use Windows switch to Windows branch.
- Download Docker Engine (instruction)
- Optionally, you can follow a post-installation steps from Docker documentation
- Download and install Visual Studio Code with command:
sudo apt-get install code - Open VS Code and install an extension (shortcut CTRL+SHIFT+X) with the name
"Remote Development".
Open Terminal and paste command below:
test -d ~/ros2_ws_misr/.git && (cd ~/ros2_ws_misr && git fetch && git reset --hard origin/jazzy) || (cd ~ && git clone -b jazzy https://github.com/LRMPUT/ros2_ws_misr.git) && xhost +local: && code ~/ros2_ws_misrIn VS Code:
- press button in the notification (bottom-right corner of the screen)
"Reopen in Container" - OR press
F1and type "Reopen in...", select"Dev Containers: Rebuild and Reopen in Container", click Enter - Wait for the container to set up
Execute setup script with the command:
./src/setup_ws.shBuild the workspace:
colcon build --symlink-installSource environment:
source install/setup.bash