-
Notifications
You must be signed in to change notification settings - Fork 2
156 lines (140 loc) · 5.13 KB
/
ros.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
# Copyright (C) 2023 Martin Scheiber and Christian Brommer,
# Control of Networked Systems, University of Klagenfurt, Austria.
#
# All rights reserved.
#
# This software is licensed under the terms of the BSD-2-Clause-License with
# no commercial use allowed, the full terms of which are made available
# in the LICENSE file. No license in patents is granted.
#
# You can contact the author at <[email protected]> and
# <[email protected]>.
name: ROS
on:
push:
branches: [ "main", "development" ]
paths:
- 'src/**'
- 'docker/install_ros1_*.sh'
- '.github/workflows/ros.yml'
pull_request:
branches: [ "main", "development"]
jobs:
ros_ci:
name: ROS ${{ matrix.ROS_DISTRO }} (${{ matrix.BUILD_TYPE }})
runs-on: ubuntu-latest
container: ros:${{ matrix.ROS_DISTRO }}-ros-core
strategy:
fail-fast: false
matrix:
ROS_DISTRO: [noetic, melodic]
BUILD_TYPE: [Release, Debug]
env:
BADGE_CREATION: ${{ github.event_name == 'push' && github.ref == 'refs/heads/main' && github.repository_owner == 'aau-cns' }}
steps:
- name: Create Badge (running)
if: ${{ env.BADGE_CREATION == 'true' }}
uses: schneegans/[email protected]
with:
auth: ${{ secrets.GIST_SECRET }}
gistID: d4b4eee830e1c61a17ed35ecf413f8d1
filename: build_ros_${{ matrix.ROS_DISTRO }}_${{ matrix.BUILD_TYPE }}.json
label: ${{ matrix.ROS_DISTRO }}
message: running
color: orange
namedLogo: ROS
- name: Get newest Git version
run: >
apt update && apt install --no-install-recommends -y
software-properties-common
&& add-apt-repository ppa:git-core/ppa
&& apt update
&& apt install --no-install-recommends -y git
- name: Create Catkin Workspace
run: mkdir -p ${{github.workspace}}/flightstack_cws
- name: Checkout Latest Version
uses: actions/checkout@v3
with:
path: ${{github.workspace}}/flightstack_cws
submodules: recursive
- name: Install Dependencies
working-directory: ${{github.workspace}}/flightstack_cws
run: >
docker/install_ros1_${{ matrix.ROS_DISTRO }}_dependencies.sh
# apt update && apt install --no-install-recommends -y
# doxygen
# graphviz
# build-essential
# libeigen3-dev
# libgoogle-glog-dev
# libgflags-dev
# libgeographic-dev
# geographiclib-tools
# ros-${{ matrix.ROS_DISTRO }}-dynamic-reconfigure
# ros-${{ matrix.ROS_DISTRO }}-eigen-conversions
# ros-${{ matrix.ROS_DISTRO }}-tf
# ros-${{ matrix.ROS_DISTRO }}-tf2-ros
# ros-${{ matrix.ROS_DISTRO }}-tf2-eigen
# ros-${{ matrix.ROS_DISTRO }}-mavlink
# ros-${{ matrix.ROS_DISTRO }}-nodelet
# ros-${{ matrix.ROS_DISTRO }}-geographic-msgs
# ros-${{ matrix.ROS_DISTRO }}-angles
# ros-${{ matrix.ROS_DISTRO }}-diagnostic-updater
# ros-${{ matrix.ROS_DISTRO }}-urdf
# ros-${{ matrix.ROS_DISTRO }}-control-toolbox
# - name: Install ROS-dependent dependencies
# if: ${{ matrix.ROS_DISTRO == 'noetic' }}
# run: >
# apt update && apt install --no-install-recommends -y
# python3-catkin-tools
# python3-catkin-pkg
# python3-rospkg
# python3-rosdep
# python3-rosinstall-generator
# python3-future
# python3-lxml
# - name: Install ROS-dependent dependencies
# if: ${{ matrix.ROS_DISTRO != 'noetic' }}
# run: >
# apt update && apt install --no-install-recommends -y
# python-catkin-tools
# python-rosdep
# python-rosinstall-generator
# python-future
# python-lxml
- name: Build
working-directory: ${{github.workspace}}/flightstack_cws
run: /bin/bash -c 'source /opt/ros/${{ matrix.ROS_DISTRO }}/setup.bash; catkin build -DCMAKE_BUILD_TYPE=${{ matrix.BUILD_TYPE }};'
- name: Create Badge (success)
if: ${{ success() && env.BADGE_CREATION == 'true' }}
uses: schneegans/[email protected]
with:
auth: ${{ secrets.GIST_SECRET }}
gistID: d4b4eee830e1c61a17ed35ecf413f8d1
filename: build_ros_${{ matrix.ROS_DISTRO }}_${{ matrix.BUILD_TYPE }}.json
label: ${{ matrix.ROS_DISTRO }}
message: passing
color: green
namedLogo: ROS
- name: Create Badge (failure)
if: ${{ failure() && env.BADGE_CREATION == 'true' }}
uses: schneegans/[email protected]
with:
auth: ${{ secrets.GIST_SECRET }}
gistID: d4b4eee830e1c61a17ed35ecf413f8d1
filename: build_ros_${{ matrix.ROS_DISTRO }}_${{ matrix.BUILD_TYPE }}.json
label: ${{ matrix.ROS_DISTRO }}
message: failure
isError: true
namedLogo: ROS
- name: Create Badge (cancelled)
if: ${{ cancelled() && env.BADGE_CREATION == 'true' }}
uses: schneegans/[email protected]
with:
auth: ${{ secrets.GIST_SECRET }}
gistID: d4b4eee830e1c61a17ed35ecf413f8d1
filename: build_ros_${{ matrix.ROS_DISTRO }}_${{ matrix.BUILD_TYPE }}.json
label: ${{ matrix.ROS_DISTRO }}
message: cancelled
color: inactive
namedLogo: ROS