ros-industrial / industrial_ci

Easy continuous integration repository for ROS repositories
Apache License 2.0
248 stars 129 forks source link

Add colcon arguments for selecting packages to build #859

Open rafal-gorecki opened 7 months ago

rafal-gorecki commented 7 months ago

Hello,

  1. I'm looking for some solutions: to add option --packages-up-to <package_name> during the colcon build and test phase. How can be it done on Github Actions?
  2. I'd like to also add global environment variable, how can I add it? I try following solutions, but it didn't work:
      - uses: ros-industrial/industrial_ci@master
        env:
          ROS_DISTRO: ${{matrix.ROS_DISTRO}}
          global:
            - BEFORE_INIT='export HUSARION_ROS_BUILD_TYPE=simulation'

    Regards

CihatAltiparmak commented 5 months ago

Hello,

  1. I'm looking for some solutions: to add option --packages-up-to <package_name> during the colcon build and test phase. How can be it done on Github Actions?

Hello,

I solved the first one by giving colcon relavant arguments after cmake arguments. You can use this trick like below.

https://github.com/CihatAltiparmak/moveit_middleware_benchmark/blob/efc00b8968db64879e2c355c23ed3f43ca5600ae/.github/workflows/industrial_ci.yml#L13

When you ran this CI, you will see this command.

https://github.com/CihatAltiparmak/moveit_middleware_benchmark/actions/runs/9604667418/job/26490644523#step:3:1492

mathias-luedtke commented 3 months ago

Another options it to remove the additional packages (actually directories) after cloning, see https://github.com/ros-industrial/industrial_ci/blob/master/doc/index.rst#workspace-management