Skip to content

Add CI for ROS2.

Add CI for ROS2. #1

Workflow file for this run

name: Build & Test
on:
push:
branches: [ noetic, jazzy ]
pull_request:
branches: [ noetic, jazzy ]
jobs:
Linting:
name: Lint Code Base
runs-on: ubuntu-latest
steps:
- name: Checkout Code
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Lint Code Base
uses: github/super-linter/slim@v4
env:
VALIDATE_CLANG_FORMAT: true
# VALIDATE_PYTHON_BLACK: true
VALIDATE_ALL_CODEBASE: true
DEFAULT_BRANCH: master
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
build-and-test:
needs: Linting
runs-on: [ubuntu-20.04]
container:
image: rostooling/setup-ros-docker:ubuntu-focal-ros-noetic-ros-base-latest
steps:
- name: install catkin
run: |
sudo apt-get update
sudo apt-get install -y python3-catkin-tools python3-empy
- uses: actions/checkout@v4
with:
path: hector/src
- name: rosdep
run: |
cd $GITHUB_WORKSPACE/hector/src
rosdep update
rosdep install -y --from-paths . --ignore-src --rosdistro noetic
- name: build
run: |
cd $GITHUB_WORKSPACE/hector
catkin config --extend /opt/ros/noetic --cmake-args -DCMAKE_BUILD_TYPE=Release
cd $GITHUB_WORKSPACE/hector/src
catkin build
- name: build_and_test
run: |
cd $GITHUB_WORKSPACE/hector/src
catkin test hector_math