From 08d50b496f93a07fdd77e770ab3672544046119a Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Mon, 2 Feb 2026 18:35:08 +0000 Subject: [PATCH 1/4] Initial plan From e0d500816f3bf4d66a2d6da1da620d481de35306 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Mon, 2 Feb 2026 18:36:51 +0000 Subject: [PATCH 2/4] Add GitHub Action for colcon build and test Co-authored-by: teixdavide <114567030+teixdavide@users.noreply.github.com> --- .github/workflows/colcon-build-test.yml | 52 +++++++++++++++++++++++++ .gitignore | 4 ++ torque-vectoring/package.xml | 17 ++++++++ 3 files changed, 73 insertions(+) create mode 100644 .github/workflows/colcon-build-test.yml create mode 100644 torque-vectoring/package.xml diff --git a/.github/workflows/colcon-build-test.yml b/.github/workflows/colcon-build-test.yml new file mode 100644 index 0000000..985d048 --- /dev/null +++ b/.github/workflows/colcon-build-test.yml @@ -0,0 +1,52 @@ +name: Colcon Build and Test + +on: + push: + branches: + - '**' + pull_request: + branches: + - '**' + +jobs: + build-and-test: + runs-on: ubuntu-latest + + steps: + - name: Checkout code + uses: actions/checkout@v4 + + - name: Setup Python + uses: actions/setup-python@v5 + with: + python-version: '3.10' + + - name: Install colcon + run: | + python -m pip install --upgrade pip + pip install colcon-common-extensions + + - name: Install dependencies + run: | + sudo apt-get update + sudo apt-get install -y cmake build-essential + + - name: Create colcon workspace + run: | + mkdir -p colcon_ws/src + cp -r torque-vectoring colcon_ws/src/ + + - name: Build with colcon + run: | + cd colcon_ws + colcon build --cmake-args -DCMAKE_BUILD_TYPE=Release + + - name: Test with colcon + run: | + cd colcon_ws + colcon test + + - name: Show test results + run: | + cd colcon_ws + colcon test-result --verbose diff --git a/.gitignore b/.gitignore index 35d74bb..7a26ab2 100644 --- a/.gitignore +++ b/.gitignore @@ -49,3 +49,7 @@ qtcreator-* # Catkin custom files CATKIN_IGNORE + +# Colcon workspace artifacts +install/ +colcon_ws/ diff --git a/torque-vectoring/package.xml b/torque-vectoring/package.xml new file mode 100644 index 0000000..fafb122 --- /dev/null +++ b/torque-vectoring/package.xml @@ -0,0 +1,17 @@ + + + + torque_vectoring + 1.0.0 + Torque Vectoring Library with Tests + maintainer + TODO + + cmake + + gtest + + + cmake + + From 83774ce81157a44b71e95d09eaaf2970d3381dc7 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Mon, 2 Feb 2026 18:37:33 +0000 Subject: [PATCH 3/4] Improve test result reporting in workflow Co-authored-by: teixdavide <114567030+teixdavide@users.noreply.github.com> --- .github/workflows/colcon-build-test.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/colcon-build-test.yml b/.github/workflows/colcon-build-test.yml index 985d048..f62090f 100644 --- a/.github/workflows/colcon-build-test.yml +++ b/.github/workflows/colcon-build-test.yml @@ -47,6 +47,7 @@ jobs: colcon test - name: Show test results + if: always() run: | cd colcon_ws - colcon test-result --verbose + colcon test-result --all --verbose From a875bd96d30026970f6fa1480ee0fc6eb12a02b6 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Mon, 2 Feb 2026 18:38:11 +0000 Subject: [PATCH 4/4] Add explicit GITHUB_TOKEN permissions for security Co-authored-by: teixdavide <114567030+teixdavide@users.noreply.github.com> --- .github/workflows/colcon-build-test.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/colcon-build-test.yml b/.github/workflows/colcon-build-test.yml index f62090f..95fd73c 100644 --- a/.github/workflows/colcon-build-test.yml +++ b/.github/workflows/colcon-build-test.yml @@ -12,6 +12,9 @@ jobs: build-and-test: runs-on: ubuntu-latest + permissions: + contents: read + steps: - name: Checkout code uses: actions/checkout@v4