Skip to content

Commit c924020

Browse files
github-actionsgithub-actions[bot]
github-actions
authored andcommitted
chore: sync files
Signed-off-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
1 parent abe8e3c commit c924020

4 files changed

+66
-5
lines changed

.github/workflows/check-build-depends.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ jobs:
2020
build-depends-repos: build_depends.repos
2121
steps:
2222
- name: Check out repository
23-
uses: actions/checkout@v3
23+
uses: actions/checkout@v4
2424

2525
- name: Remove exec_depend
2626
uses: autowarefoundation/autoware-github-actions/remove-exec-depend@v1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
name: clang-tidy-differential
2+
3+
on:
4+
pull_request:
5+
types:
6+
- opened
7+
- synchronize
8+
- reopened
9+
- labeled
10+
11+
jobs:
12+
make-sure-label-is-present:
13+
uses: autowarefoundation/autoware-github-actions/.github/workflows/make-sure-label-is-present.yaml@v1
14+
with:
15+
label: tag:run-clang-tidy-differential
16+
17+
clang-tidy-differential:
18+
needs: make-sure-label-is-present
19+
if: ${{ needs.make-sure-label-is-present.outputs.result == 'true' }}
20+
runs-on: ubuntu-latest
21+
container: ghcr.io/autowarefoundation/autoware:latest-prebuilt-cuda
22+
steps:
23+
- name: Set PR fetch depth
24+
run: echo "PR_FETCH_DEPTH=$(( ${{ github.event.pull_request.commits }} + 1 ))" >> "${GITHUB_ENV}"
25+
26+
- name: Checkout PR branch and all PR commits
27+
uses: actions/checkout@v4
28+
with:
29+
ref: ${{ github.event.pull_request.head.sha }}
30+
fetch-depth: ${{ env.PR_FETCH_DEPTH }}
31+
32+
- name: Show disk space before the tasks
33+
run: df -h
34+
35+
- name: Remove exec_depend
36+
uses: autowarefoundation/autoware-github-actions/remove-exec-depend@v1
37+
38+
- name: Get modified packages
39+
id: get-modified-packages
40+
uses: autowarefoundation/autoware-github-actions/get-modified-packages@v1
41+
42+
- name: Get modified files
43+
id: get-modified-files
44+
uses: tj-actions/changed-files@v42
45+
with:
46+
files: |
47+
**/*.cpp
48+
**/*.hpp
49+
50+
- name: Run clang-tidy
51+
if: ${{ steps.get-modified-files.outputs.all_changed_files != '' }}
52+
uses: autowarefoundation/autoware-github-actions/clang-tidy@v1
53+
with:
54+
rosdistro: humble
55+
target-packages: ${{ steps.get-modified-packages.outputs.modified-packages }}
56+
target-files: ${{ steps.get-modified-files.outputs.all_changed_files }}
57+
clang-tidy-config-url: https://raw.githubusercontent.com/autowarefoundation/autoware/main/.clang-tidy
58+
build-depends-repos: build_depends.repos
59+
60+
- name: Show disk space after the tasks
61+
run: df -h

.github/workflows/clang-tidy-pr-comments-manually.yaml

+2-2
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ jobs:
1111
runs-on: ubuntu-latest
1212
steps:
1313
- name: Check out repository
14-
uses: actions/checkout@v3
14+
uses: actions/checkout@v4
1515

1616
- name: Download analysis results
1717
run: |
@@ -36,7 +36,7 @@ jobs:
3636
3737
- name: Check out PR head
3838
if: ${{ steps.check-fixes-yaml-existence.outputs.exists == 'true' }}
39-
uses: actions/checkout@v3
39+
uses: actions/checkout@v4
4040
with:
4141
repository: ${{ steps.set-variables.outputs.pr-head-repo }}
4242
ref: ${{ steps.set-variables.outputs.pr-head-ref }}

.github/workflows/clang-tidy-pr-comments.yaml

+2-2
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ jobs:
1313
runs-on: ubuntu-latest
1414
steps:
1515
- name: Check out repository
16-
uses: actions/checkout@v3
16+
uses: actions/checkout@v4
1717

1818
- name: Download analysis results
1919
run: |
@@ -37,7 +37,7 @@ jobs:
3737
3838
- name: Check out PR head
3939
if: ${{ steps.check-fixes-yaml-existence.outputs.exists == 'true' }}
40-
uses: actions/checkout@v3
40+
uses: actions/checkout@v4
4141
with:
4242
repository: ${{ steps.set-variables.outputs.pr-head-repo }}
4343
ref: ${{ steps.set-variables.outputs.pr-head-ref }}

0 commit comments

Comments
 (0)