forked from linorobot/linorobot2_hardware
-
Notifications
You must be signed in to change notification settings - Fork 14
48 lines (41 loc) · 1.38 KB
/
rolling-firmware-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
name: ROS Rolling Firmware Build
# Get the default branch name from the repository settings
env:
DEFAULT_BRANCH: ${{ github.event.repository.default_branch }}
on:
pull_request:
# Run only on PRs to the default branch (usually main or master)
branches:
- DEFAULT_BRANCH
# Don't run when the following files are changed which don't effect firmware.
paths-ignore:
- 'docs/**'
- .gitignore
- LICENSE
- README.md
push:
# Run on pushes to any branches except these distro-specific branches
branches-ignore:
- iron*
- humble*
- galactic*
- foxy*
# Don't run when the following files are changed which don't effect firmware.
paths-ignore:
- 'docs/**'
- .gitignore
- LICENSE
- README.md
# Run daily at midnight to detect flakiness and broken dependencies
schedule:
- cron: '0 0 * * *'
# Allow manual triggering
workflow_dispatch:
jobs:
firmware:
# The current file calls the firmware workflow with the following parameters
uses: ./.github/workflows/reusable-platformio-ci.yml
with:
ros_distro: rolling
# The reference field will be set to the default branch only if the event that triggered the workflow is schedule. Otherwise, it will be left blank.
reference: ${{ github.event_name == 'schedule' && github.event.repository.default_branch || '' }}