Skip to content

Commit a1c53ea

Browse files
committed
ci: speed up Debug job (build-only)
1 parent 5b298eb commit a1c53ea

File tree

1 file changed

+13
-3
lines changed

1 file changed

+13
-3
lines changed

.github/workflows/ros-build-test.yml

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,15 @@ jobs:
1111
strategy:
1212
fail-fast: false
1313
matrix:
14-
build_type: [ Debug, Release ]
14+
include:
15+
- build_type: Release
16+
build_testing: "ON"
17+
run_tests: true
18+
# Full Debug + tests is too slow for GitHub-hosted runners; still build Debug
19+
# (without tests) to catch compilation issues.
20+
- build_type: Debug
21+
build_testing: "OFF"
22+
run_tests: false
1523

1624
runs-on: ubuntu-latest
1725
container:
@@ -30,7 +38,7 @@ jobs:
3038
- name: System deps
3139
run: |
3240
apt-get update && apt-get install -y --no-install-recommends \
33-
build-essential cmake git \
41+
build-essential cmake git ninja-build \
3442
curl ca-certificates gnupg lsb-release \
3543
python3-colcon-common-extensions python3-rosdep python3-pip \
3644
python3-dev pybind11-dev \
@@ -85,9 +93,11 @@ jobs:
8593
shell: bash
8694
run: |
8795
source /opt/ros/jazzy/setup.bash
88-
colcon build --cmake-args -DCMAKE_BUILD_TYPE=${{ matrix.build_type }}
96+
colcon build --event-handlers console_direct+ \
97+
--cmake-args -GNinja -DCMAKE_BUILD_TYPE=${{ matrix.build_type }} -DBUILD_TESTING=${{ matrix.build_testing }}
8998
9099
- name: Test
100+
if: ${{ matrix.run_tests }}
91101
shell: bash
92102
run: |
93103
source install/setup.bash

0 commit comments

Comments
 (0)