Skip to content

Commit

Permalink
ci(build-and-test): and differential ci fixes
Browse files Browse the repository at this point in the history
Signed-off-by: M. Fatih Cırıt <[email protected]>
  • Loading branch information
M. Fatih Cırıt committed Jun 10, 2024
1 parent 6c31a30 commit 2af0c4e
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 43 deletions.
45 changes: 5 additions & 40 deletions .github/workflows/build-and-test-differential.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:
build-and-test-differential:
needs: prevent-no-label-execution
if: ${{ needs.prevent-no-label-execution.outputs.run == 'true' }}
runs-on: [self-hosted, linux, X64]
runs-on: ubuntu-latest
container: ${{ matrix.container }}${{ matrix.container-suffix }}
strategy:
fail-fast: false
Expand All @@ -28,15 +28,15 @@ jobs:
- -cuda
include:
- rosdistro: humble
container: ghcr.io/autowarefoundation/autoware-universe:humble-latest
container: ghcr.io/autowarefoundation/autoware:latest-prebuilt
build-depends-repos: build_depends.repos
steps:
- name: Check out repository
uses: actions/checkout@v3
with:
fetch-depth: 0
fetch-depth: 1

- name: Check disk space before build
- name: Show disk space before the tasks
run: df -h

- name: Remove exec_depend
Expand Down Expand Up @@ -72,40 +72,5 @@ jobs:
verbose: true
flags: differential

- name: Check disk space after build
- name: Show disk space after the tasks
run: df -h

clang-tidy-differential:
runs-on: [self-hosted, linux, X64]
container: ghcr.io/autowarefoundation/autoware-universe:humble-latest-cuda
needs: build-and-test-differential
steps:
- name: Check out repository
uses: actions/checkout@v3
with:
fetch-depth: 0

- name: Remove exec_depend
uses: autowarefoundation/autoware-github-actions/remove-exec-depend@v1

- name: Get modified packages
id: get-modified-packages
uses: autowarefoundation/autoware-github-actions/get-modified-packages@v1

- name: Get modified files
id: get-modified-files
uses: tj-actions/changed-files@v35
with:
files: |
**/*.cpp
**/*.hpp
- name: Run clang-tidy
if: ${{ steps.get-modified-files.outputs.all_changed_files != '' }}
uses: autowarefoundation/autoware-github-actions/clang-tidy@v1
with:
rosdistro: humble
target-packages: ${{ steps.get-modified-packages.outputs.modified-packages }}
target-files: ${{ steps.get-modified-files.outputs.all_changed_files }}
clang-tidy-config-url: https://raw.githubusercontent.com/autowarefoundation/autoware/main/.clang-tidy
build-depends-repos: build_depends.repos
8 changes: 5 additions & 3 deletions .github/workflows/build-and-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ on:
jobs:
build-and-test:
if: ${{ github.event_name != 'push' || github.ref_name == github.event.repository.default_branch }}
runs-on: ubuntu-latest
runs-on: [self-hosted, linux, X64]
container: ${{ matrix.container }}${{ matrix.container-suffix }}
strategy:
fail-fast: false
Expand All @@ -21,11 +21,13 @@ jobs:
- -cuda
include:
- rosdistro: humble
container: ghcr.io/autowarefoundation/autoware-universe:humble-latest
container: ghcr.io/autowarefoundation/autoware:latest-prebuilt
build-depends-repos: build_depends.repos
steps:
- name: Check out repository
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
fetch-depth: 1

- name: Free disk space (Ubuntu)
uses: jlumbroso/[email protected]
Expand Down

0 comments on commit 2af0c4e

Please sign in to comment.