Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
56 changes: 56 additions & 0 deletions .github/workflows/colcon-build-test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
name: Colcon Build and Test

on:
push:
branches:
- '**'
pull_request:
branches:
- '**'

jobs:
build-and-test:
runs-on: ubuntu-latest

permissions:
contents: read

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
if: always()
run: |
cd colcon_ws
colcon test-result --all --verbose
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -49,3 +49,7 @@ qtcreator-*

# Catkin custom files
CATKIN_IGNORE

# Colcon workspace artifacts
install/
colcon_ws/
17 changes: 17 additions & 0 deletions torque-vectoring/package.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
<?xml version="1.0"?>
<?xml-model href="http://download.ros.org/schema/package_format3.xsd" schematypens="http://www.w3.org/2001/XMLSchema"?>
<package format="3">
<name>torque_vectoring</name>
<version>1.0.0</version>
<description>Torque Vectoring Library with Tests</description>
<maintainer email="maintainer@example.com">maintainer</maintainer>
<license>TODO</license>

<buildtool_depend>cmake</buildtool_depend>

<test_depend>gtest</test_depend>

<export>
<build_type>cmake</build_type>
</export>
</package>
Loading