From dc3ab0df67e8d4affa3f9e257f96b84810faa664 Mon Sep 17 00:00:00 2001 From: Luis Camero Date: Tue, 21 Jan 2025 13:38:00 -0500 Subject: [PATCH 1/3] Add multi-repo CI --- .github/workflows/ci.yml | 69 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 69 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 8aae003..98fe59c 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -61,3 +61,72 @@ jobs: clearpath_robot clearpath_sensors vcs-repo-file-url: dependencies.repos + clearpath_robot_src_head_ci: + name: Humble Clearpath Source with Head Branch + runs-on: ubuntu-22.04 + steps: + - uses: actions/checkout@v3 + - uses: actions/checkout@v3 + with: + repository: clearpathrobotics/repos-dep-update-action + ref: 0.0.1 + path: repos-dep-update-action + - name: Extract branch name + shell: bash + run: echo "branch=${GITHUB_HEAD_REF:-${GITHUB_REF#refs/heads/}}" >> $GITHUB_OUTPUT + id: extract_branch + - name: Use repos update action + uses: ./repos-dep-update-action/ + with: + branch: ${{ steps.extract_branch.outputs.branch }} + input: dependencies.repos + output: updated_dependencies.repos + - name: Updated dependencies + run: | + cat updated_dependencies.repos + - uses: ros-tooling/setup-ros@v0.7 + with: + required-ros-distributions: jazzy + - uses: ros-tooling/action-ros-ci@v0.3 + id: action_ros_ci_step + with: + target-ros2-distro: jazzy + package-name: | + clearpath_diagnostics + clearpath_generator_robot + clearpath_robot + clearpath_sensors + vcs-repo-file-url: updated_dependencies.repos + clearpath_robot_src_base_ci: + name: Humble Clearpath Source with Base Branch + runs-on: ubuntu-22.04 + steps: + - uses: actions/checkout@v3 + - uses: actions/checkout@v3 + with: + repository: clearpathrobotics/repos-dep-update-action + ref: 0.0.1 + path: repos-dep-update-action + - name: Use repos update action + uses: ./repos-dep-update-action/ + with: + branch: ${{ github.event.pull_request.base.ref }} + input: dependencies.repos + output: updated_dependencies.repos + - name: Updated dependencies + run: | + cat updated_dependencies.repos + - uses: ros-tooling/setup-ros@v0.7 + with: + required-ros-distributions: jazzy + - uses: ros-tooling/action-ros-ci@v0.3 + id: action_ros_ci_step + with: + target-ros2-distro: jazzy + package-name: | + clearpath_diagnostics + clearpath_generator_robot + clearpath_robot + clearpath_sensors + vcs-repo-file-url: updated_dependencies.repos + From 5b4753b2bf37d0280c9895faf25b6667e3ded3e1 Mon Sep 17 00:00:00 2001 From: Luis Camero Date: Tue, 21 Jan 2025 14:08:26 -0500 Subject: [PATCH 2/3] Change jazzy to humble --- .github/workflows/ci.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 98fe59c..3fe0008 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -86,11 +86,11 @@ jobs: cat updated_dependencies.repos - uses: ros-tooling/setup-ros@v0.7 with: - required-ros-distributions: jazzy + required-ros-distributions: humble - uses: ros-tooling/action-ros-ci@v0.3 id: action_ros_ci_step with: - target-ros2-distro: jazzy + target-ros2-distro: humble package-name: | clearpath_diagnostics clearpath_generator_robot @@ -118,11 +118,11 @@ jobs: cat updated_dependencies.repos - uses: ros-tooling/setup-ros@v0.7 with: - required-ros-distributions: jazzy + required-ros-distributions: humble - uses: ros-tooling/action-ros-ci@v0.3 id: action_ros_ci_step with: - target-ros2-distro: jazzy + target-ros2-distro: humble package-name: | clearpath_diagnostics clearpath_generator_robot From 6ed684d2b0e4d4327a6faa94e24bf2ac90e52be3 Mon Sep 17 00:00:00 2001 From: Luis Camero Date: Tue, 21 Jan 2025 14:24:13 -0500 Subject: [PATCH 3/3] Skip if not pull request --- .github/workflows/ci.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 3fe0008..ed5e27e 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -98,6 +98,7 @@ jobs: clearpath_sensors vcs-repo-file-url: updated_dependencies.repos clearpath_robot_src_base_ci: + if: github.event_name == 'pull_request' name: Humble Clearpath Source with Base Branch runs-on: ubuntu-22.04 steps: