Skip to content

Commit 6143be4

Browse files
authored
Merge pull request #37 from ethz-asl/feature/ci
Add CI
2 parents 3171f8e + 1a60562 commit 6143be4

File tree

1 file changed

+54
-0
lines changed

1 file changed

+54
-0
lines changed

.github/workflows/ubuntu20_04.yml

Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
name: mav_sensors
2+
on:
3+
pull_request:
4+
branches:
5+
- "master"
6+
push:
7+
branches:
8+
- "master"
9+
10+
jobs:
11+
build:
12+
runs-on: [self-hosted, linux]
13+
strategy:
14+
fail-fast: false
15+
matrix:
16+
rosdistro: ['noetic']
17+
gcc: ['8', '9', '10']
18+
container: ros:${{ matrix.rosdistro }}-ros-base-focal
19+
name: ROS ${{ matrix.rosdistro }} - GCC ${{ matrix.gcc }}
20+
steps:
21+
- uses: actions/checkout@v4
22+
name: Checkout lpp
23+
with:
24+
repository: ethz-asl/lpp
25+
token: ${{ secrets.PAT }}
26+
path: catkin_ws/src/lpp
27+
28+
- name: Install newest git version
29+
run: sudo apt update && sudo apt-get install -y software-properties-common && sudo add-apt-repository -y ppa:git-core/ppa && sudo apt-get update && sudo apt-get install -y git
30+
31+
- name: Install GCC version ${{ matrix.gcc }}
32+
run: sudo add-apt-repository ppa:ubuntu-toolchain-r/test -y && sudo apt update && sudo apt install -y gcc-${{ matrix.gcc }} g++-${{ matrix.gcc }} && sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-${{ matrix.gcc }} 100 --slave /usr/bin/g++ g++ /usr/bin/g++-${{ matrix.gcc }} && gcc --version && g++ --version
33+
34+
- name: Install catkin tools
35+
run: sudo apt install -y python3-rosdep python3-rosinstall python3-rosinstall-generator python3-wstool build-essential python3-catkin-tools
36+
37+
- name: Install system dependencies
38+
run: sudo apt install -y libgoogle-glog-dev
39+
40+
- uses: actions/checkout@v4
41+
name: Checkout mav_sensors
42+
with:
43+
repository: ethz-asl/mav_sensors
44+
submodules: recursive
45+
token: ${{ secrets.PAT }}
46+
path: catkin_ws/src/mav_sensors
47+
48+
- name: Build mav_sensors
49+
run: source /opt/ros/${{ matrix.rosdistro }}/setup.bash && catkin build mav_sensors_demo && source ${GITHUB_WORKSPACE}/catkin_ws/devel/setup.bash
50+
shell: bash
51+
working-directory: catkin_ws
52+
53+
54+

0 commit comments

Comments
 (0)