Skip to content

Commit e0e6ca3

Browse files
Update CI workflow for C++ SDK (#53)
* Update CI workflow for C++ SDK * Move gen-desired-state.yml to app workflows
1 parent 0eeb7a0 commit e0e6ca3

File tree

2 files changed

+33
-11
lines changed

2 files changed

+33
-11
lines changed

src/cpp-sdk/workflows/ci.yml

+33-11
Original file line numberDiff line numberDiff line change
@@ -28,34 +28,56 @@ on:
2828
branches:
2929
- main
3030
jobs:
31+
conan-package:
32+
runs-on: ubuntu-22.04
33+
container: ghcr.io/eclipse-velocitas/devcontainer-base-images/cpp:v0.3
34+
name: Check Conan package
35+
strategy:
36+
matrix:
37+
host: ["linux_x86_64"]
38+
fail-fast: false
39+
40+
41+
steps:
42+
- name: Checkout repository
43+
uses: actions/checkout@v4
44+
45+
- name: Fix dubious ownership
46+
run: |
47+
git config --global --add safe.directory $( pwd )
48+
49+
- name: install prerequisites
50+
run: |
51+
sudo apt-get update && sudo apt-get install -y ninja-build clang-format-14 clang-tidy-14 cppcheck
52+
pip3 install -r requirements.txt
53+
54+
- name: Create conan package
55+
run: |
56+
conan create --build=missing -pr:b ./.conan/profiles/linux_x86_64_release -pr:h ./.conan/profiles/${{ matrix.host }}_release . ci/testing
57+
3158
build-and-publish:
3259
runs-on: ubuntu-22.04
3360
name: "Build, Test and Lint"
61+
container: ghcr.io/eclipse-velocitas/devcontainer-base-images/cpp:v0.3
62+
3463
steps:
3564
- name: Checkout repository
3665
uses: actions/checkout@v4
3766

38-
- name: Clone vehicle_model repository
39-
uses: actions/checkout@v4
40-
with:
41-
repository: eclipse-velocitas/vehicle-model-cpp
42-
path: "./app/vehicle_model"
67+
- name: Fix dubious ownership
68+
run: |
69+
git config --global --add safe.directory $( pwd )
4370
4471
- name: install prerequisites
4572
run: |
4673
sudo apt-get update && sudo apt-get install -y ninja-build clang-format-14 clang-tidy-14 cppcheck
4774
pip3 install -r requirements.txt
4875
49-
- name: Set up GCC
50-
uses: egor-tensin/setup-gcc@v1
51-
with:
52-
version: 11
53-
5476
- name: Install dependencies
5577
run: ./install_dependencies.sh -r
5678

5779
- name: build
58-
run: ./build.sh -r
80+
run: ./build.sh -r --cov
5981

6082
- name: unittests
6183
run: build/bin/sdk_utests

0 commit comments

Comments
 (0)