Skip to content
This repository has been archived by the owner on Dec 30, 2024. It is now read-only.

Commit

Permalink
add ros2 (#7)
Browse files Browse the repository at this point in the history
Add ROS2 ci workflow
  • Loading branch information
fixposition-support authored Mar 30, 2023
1 parent 215bd2f commit c9970e3
Show file tree
Hide file tree
Showing 3 changed files with 52 additions and 3 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/build_test_ros.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,12 @@ jobs:
config:
- name: "melodic"
container:
image: "ros:melodic"
image: "osrf/ros:melodic-desktop-full"
env:
ROS_DISTRO: melodic
- name: "noetic"
container:
image: "ros:noetic"
image: "osrf/ros:noetic-desktop-full"
env:
ROS_DISTRO: noetic

Expand All @@ -41,7 +41,7 @@ jobs:
sudo apt-get update
sudo apt-get install -y libeigen3-dev libyaml-cpp-dev libgtest-dev python3-osrf-pycommon python3-catkin-tools
- name: Install Gtest
if: matrix.config.container.image == 'ros:melodic'
if: matrix.config.container.image == 'osrf/ros:melodic-desktop-full'
run: |
cd /usr/src/gtest
sudo cmake .
Expand Down
48 changes: 48 additions & 0 deletions .github/workflows/build_test_ros2.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
name: Build and Test with ROS2

on:
push:
branches: [main]
pull_request:
branches: [main]

jobs:
build:
name: ${{ matrix.config.name }}
runs-on: ubuntu-latest

strategy:
fail-fast: false
matrix:
config:
- name: "humble"
container:
image: "osrf/ros:humble-desktop-full"
env:
ROS_DISTRO: humble
- name: "foxy"
container:
image: "osrf/ros:foxy-desktop"
env:
ROS_DISTRO: foxy

container: ${{ matrix.config.container }}

defaults:
run:
shell: bash

steps:
- uses: actions/checkout@v3
with:
path: src/fixposition_gnss_tf
- name: Set up Deps
run: |
sudo apt-get update
sudo apt-get install -y libeigen3-dev libyaml-cpp-dev libgtest-dev python3-osrf-pycommon
- name: Build and Test
run: |
source /opt/ros/$ROS_DISTRO/setup.bash
colcon build --packages-up-to fixposition_gnss_tf --cmake-args -DBUILD_TESTING=ON
colcon test --packages-up-to fixposition_gnss_tf
colcon test-result --test-result-base build/fixposition_gnss_tf/
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

- [Ubuntu 20.04 / 22.04 ![](./../../actions/workflows/build_test_cmake.yml/badge.svg)](./../../actions/workflows/build_test_cmake.yml)
- [ROS1 melodic / noetic ![](./../../actions/workflows/build_test_ros.yml/badge.svg)](./../../actions/workflows/build_test_ros.yml)
- [ROS2 foxy / humble ![](./../../actions/workflows/build_test_ros2.yml/badge.svg)](./../../actions/workflows/build_test_ros2.yml)

`fixposition_gnss_tf`

Expand Down

0 comments on commit c9970e3

Please sign in to comment.