forked from Field-Robotics-Lab/dave
-
Notifications
You must be signed in to change notification settings - Fork 1
92 lines (85 loc) · 3.06 KB
/
jazzy-source-build.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
---
name: Jazzy Source Build
# yamllint disable-line rule:truthy
on:
workflow_dispatch:
push:
branches:
- ros2
paths:
- "**.hpp"
- "**.h"
- "**.cpp"
- "**.py"
- ".github/workflows/jazzy-source-build.yml"
- "**/package.xml"
- "**/CMakeLists.txt"
- "dave.jazzy.repos"
schedule:
# Run every day to detect flakiness and broken dependencies
- cron: "03 3 * * *"
env:
ros_distro: jazzy
ref: jazzy-release
os_name: ubuntu-latest
container: ubuntu:noble
jobs:
ros-jazzy-ubuntu-noble-source-build:
name: ros-jazzy-ubuntu-noble
runs-on: ubuntu-latest
container: ubuntu:noble
env:
# this will be src/{repo-owner}/{repo-name}
path: src/${{ github.repository }}
steps:
- name: "Determine prerequisites"
id: prereq
run: |
command -v sudo >/dev/null 2>&1 || (apt update && apt install -y sudo)
DEBIAN_FRONTEND=noninteractive sudo apt update && sudo apt upgrade -y
echo "need_node=$(command -v node >/dev/null 2>&1 && echo 0 || echo 1)"
>> $GITHUB_OUTPUT
# needed for github actions, and only if a bare ubuntu image is used
- uses: actions/setup-node@v4
# if: ${{ steps.prereq.outputs.need_node == '1' && !env.ACT }}
if: ${{ steps.prereq.outputs.need_node == '1' }}
- name: Install node
# Consider switching to https://github.com/actions/setup-node when it works
# https://github.com/nektos/act/issues/973
# if: ${{ steps.prereq.outputs.need_node == '1' && env.ACT }}
if: ${{ steps.prereq.outputs.need_node == '1' }}
run: |
sudo apt install -y curl
curl -sS https://webi.sh/node | sh
echo ~/.local/opt/node/bin >> $GITHUB_PATH
# needed only if a non-ros image is used
- uses: ros-tooling/[email protected]
with:
use-ros2-testing: true
- name: "Install ROS-Gazebo Framework Deps"
id: install-ros-gazebo
run: |
sudo /bin/bash -c "$(
curl -fsSL https://raw.githubusercontent.com/IOES-Lab/dave/ros2/extras/ros-jazzy-gz-harmonic-install.sh
)"
- uses: actions/checkout@v4
with:
path: ${{ env.path }}
- id: package_list_action
uses: ros-controls/ros2_control_ci/.github/actions/set-package-list@master
with:
path: ${{ env.path }}
- uses: ros-tooling/[email protected]
with:
target-ros2-distro: ${{ env.ros_distro }}
# ref: ${{ env.ref }}
package-name: ${{ steps.package_list_action.outputs.package_list }}
vcs-repo-file-url: |
https://raw.githubusercontent.com/ros2/ros2/${{ env.ref }}/ros2.repos
${{ env.path }}/extras/repos/dave.${{ env.ros_distro }}.repos
colcon-mixin-repository:
https://raw.githubusercontent.com/colcon/colcon-mixin-repository/master/index.yaml
- uses: actions/[email protected]
with:
name: colcon-logs-${{ env.os_name }}-${{ env.ros_distro }}
path: ros_ws/log