-
Notifications
You must be signed in to change notification settings - Fork 8
/
Copy pathaction.yml
63 lines (59 loc) · 1.87 KB
/
action.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
name: 'action-clang-tidy'
description: 'Check repository using clang-tidy'
author: 'HorstBaerbel / Bim Overbohm'
branding:
icon: check-circle
color: gray-dark
inputs:
scandir:
description: 'Scan directory'
required: false
default: '.'
builddir:
description: 'Build directory'
required: false
default: 'build'
excludedirs:
description: 'Exclude directories'
required: false
default: ''
extensions:
description: 'File extensions to include in check'
required: false
default: 'c,h,C,H,cpp,hpp,cc,hh,c++,h++,cxx,hxx'
cmakeoptions:
description: 'Additional options to pass to cmake'
required: false
default: ''
useexistingbuild:
description: 'Use existing build'
required: false
default: 'false'
runs:
using: 'composite'
steps:
- if: ${{ ! inputs.useexistingbuild }}
shell: bash
run: echo 'Running cmake in docker container'
- if: ${{ ! inputs.useexistingbuild }}
name: 'Copy run-clang-tidy.py to dockerfile context'
shell: bash
run: cp ./action-clang-tidy/run-clang-tidy.py ./action-clang-tidy/build_within_docker/run-clang-tidy.py
- if: ${{ inputs.useexistingbuild }}
shell: bash
run: echo 'Using existing cmake configuration in ${{ inputs.builddir }} directory'
- if: ${{ inputs.useexistingbuild }}
uses: ./action-clang-tidy/use_existing_build
with:
scandir: ${{ inputs.scandir }}
builddir: ${{ inputs.builddir }}
excludedirs: ${{ inputs.excludedirs }}
extensions: ${{ inputs.extensions }}
- if: ${{ ! inputs.useexistingbuild }}
uses: ./action-clang-tidy/build_within_docker
with:
scandir: ${{ inputs.scandir }}
builddir: ${{ inputs.builddir }}
excludedirs: ${{ inputs.excludedirs }}
extensions: ${{ inputs.extensions }}
cmakeoptions: ${{ inputs.cmakeoptions }}