You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: action.yml
+172-62
Original file line number
Diff line number
Diff line change
@@ -5,118 +5,228 @@ branding:
5
5
icon: "check-circle"
6
6
color: "green"
7
7
inputs:
8
-
thread-comments:
9
-
description: >-
10
-
Set this option to 'true' or 'false' to enable or disable the use of
11
-
thread comments as feedback. Set this to 'update' to update an existing comment
12
-
if one exists; the value 'true' will always delete an old comment and post a new one
13
-
if necessary. Defaults to false.
14
-
required: false
15
-
default: 'false'
16
-
no-lgtm:
17
-
description: >-
18
-
Set this option to true or false to enable or disable the use of a thread comment that
19
-
basically says 'Looks Good To Me' (when all checks pass). Defaults to true.
20
-
See `thread-comments` option for further details.
21
-
required: false
22
-
default: true
23
-
step-summary:
24
-
description: >
25
-
Set this option to true to append content as part of workflow's job summary. Defaults to false.
26
-
27
-
See implementation details in GitHub's documentation about
28
-
[Adding a job summary](https://docs.github.com/en/actions/using-workflows/workflow-commands-for-github-actions#adding-a-job-summary).
29
-
This option is independent of the `thread-comments` option, rather this option uses the same content that
30
-
the `thread-comments` option would use.
31
-
required: false
32
-
default: false
33
-
file-annotations:
34
-
description: Set this option to false to disable the use of file annotations as feedback. Defaults to true.
35
-
required: false
36
-
default: true
37
8
style:
38
-
description: >
39
-
The style rules to use (defaults to 'llvm').
40
-
Set this to 'file' to have clang-format use the closest relative .clang-format file.
9
+
description: |
10
+
The style rules to use.
11
+
12
+
- Set this to `file` to have clang-format use the closest relative .clang-format file.
13
+
- Set this to a blank string (`''`) to disable the use of clang-format entirely.
14
+
- Any code style supported by the specified version of clang-format.
41
15
required: false
42
16
default: "llvm"
17
+
minimum-version: '1.2.0'
43
18
extensions:
44
-
description: >
45
-
The file extensions to run the action against.
46
-
This comma-separated string defaults to 'c,h,C,H,cpp,hpp,cc,hh,c++,h++,cxx,hxx'.
19
+
description: The file extensions to run the action against. This is a comma-separated string.
47
20
required: false
48
21
default: "c,h,C,H,cpp,hpp,cc,hh,c++,h++,cxx,hxx"
22
+
minimum-version: '1.2.0'
49
23
tidy-checks:
50
-
description: >
51
-
A string of regex-like patterns specifying what checks clang-tidy will use.
52
-
This defaults to 'boost-*,bugprone-*,performance-*,readability-*,portability-*,modernize-*,clang-analyzer-*,cppcoreguidelines-*'. See also clang-tidy docs for more info.
24
+
description: |
25
+
Comma-separated list of globs with optional `-` prefix.
26
+
Globs are processed in order of appearance in the list.
27
+
Globs without `-` prefix add checks with matching names to the set,
28
+
globs with the `-` prefix remove checks with matching names from the set of enabled checks.
29
+
This option's value is appended to the value of the 'Checks' option in a .clang-tidy file (if any).
30
+
31
+
- It is possible to disable clang-tidy entirely by setting this option to `'-*'`.
32
+
- It is also possible to rely solely on a .clang-tidy config file by specifying this option as a blank string (`''`).
The relative path to the repository root directory. The default value '.' is relative to the runner's GITHUB_WORKSPACE environment variable.
38
+
The relative path to the repository root directory.
39
+
This path is relative to the path designated as the runner's `GITHUB_WORKSPACE` environment variable.
58
40
required: false
59
-
default: "."
41
+
default: '.'
42
+
minimum-version: '1.2.0'
60
43
version:
61
-
description: "The desired version of the clang tools to use. Accepted options are strings which can be 18, 17, 16, 15, 14, 13, 12, 11, 10, 9, 8 or 7. Defaults to 12."
44
+
description: |
45
+
The desired version of the [clang-tools](https://github.com/cpp-linter/clang-tools-pip) to use.
46
+
Accepted options are strings which can be 18, 17, 16, 15, 14, 13, 12, 11, 10, 9, 8 or 7.
47
+
48
+
- Set this option to a blank string (`''`) to use the platform's default installed version.
49
+
- This value can also be a path to where the clang tools are installed (if using a custom install location).
62
50
required: false
63
-
default: "12"
51
+
default: 12
52
+
minimum-version: '1.2.0'
64
53
verbosity:
65
-
description: A hidden option to control the action's log verbosity. This is the `logging` level (defaults to `info`).
54
+
description: |
55
+
This controls the action's verbosity in the workflow's logs.
56
+
Supported options are `info` or `debug`.
57
+
This option does not affect the verbosity of resulting thread comments or file annotations.
58
+
59
+
The verbosity can also be engaged by enabling debug logs when
60
+
[re-running jobs or workflows](https://docs.github.com/en/actions/managing-workflow-runs/re-running-workflows-and-jobs).
66
61
required: false
67
62
default: info
63
+
minimum-version: '1.3.0'
68
64
lines-changed-only:
69
-
description: Set this option to 'true' to only analyze changes in the event's diff. Defaults to 'false'.
65
+
description: |
66
+
This controls what part of the files are analyzed. The following values are accepted:
67
+
68
+
- `false`: All lines in a file are analyzed.
69
+
- `true`: Only lines in the diff that contain additions are analyzed.
70
+
- `diff`: All lines in the diff are analyzed (including unchanged lines but not subtractions).
71
+
72
+
!!! info "Important"
73
+
This feature requires special permissions to perform successfully.
- In the case of multiple paths, you can use a pipe character ('|')
81
-
to separate the multiple paths. Multiple lines are forbidden as input to this option.
95
+
- In the case of multiple paths, you can use a pipe character (`|`)
96
+
to separate the multiple paths. Multiple lines are forbidden as an input to this option;
97
+
it must be a single string.
82
98
- This can also have files, but the file's relative path has to be specified
83
99
as well.
84
-
- There is no need to use './' for each entry; a blank string ('') represents
85
-
the repo-root path (specified by the `repo-root` input option).
86
-
- Path(s) containing a space should be inside single quotes.
87
-
- Submodules are automatically ignored.
88
-
- Prefix a path with a bang (`!`) to make it explicitly not ignored - order of
89
-
multiple paths does take precedence. The `!` prefix can be applied to
90
-
submodules if desired.
91
-
- Glob patterns are not supported here. All asterisk characters ('*') are literal.
92
-
required: false
93
-
default: ".github"
100
+
- There is no need to use `./` for each entry; a blank string (`''`) represents
101
+
the [`repo-root`](#repo-root) path.
102
+
- Submodules are automatically ignored. Hidden directories (beginning with a `.`) are also ignored
103
+
automatically.
104
+
- Prefix a path with a bang (`!`) to make it explicitly _not_ ignored. The order of
105
+
multiple paths does _not_ take precedence. The `!` prefix can be applied to
106
+
a submodule's path (if desired) but not hidden directories.
107
+
- Glob patterns are not supported here. All asterisk characters (`*`) are literal.
108
+
required: false
109
+
default: '.github'
110
+
minimum-version: '1.3.0'
111
+
thread-comments:
112
+
description: |
113
+
This controls the behavior of posted thread comments as feedback. The following options are supported:
114
+
115
+
- `true`: enable the use of thread comments. This will always delete an outdated thread comment and post a new comment (triggering a notification for every comment).
116
+
- `update`: update an existing thread comment if one already exists. This option does not trigger a new notification for every thread comment update.
117
+
- `false`: disable the use of thread comments.
118
+
119
+
!!! info "Important"
120
+
This feature requires special permissions to perform successfully.
121
+
See our [documented permissions](permissions.md)
122
+
123
+
> [!NOTE]
124
+
> If run on a private repository, then this feature is disabled because the GitHub REST API behaves differently for thread comments on a private repository.
Set this option to true or false to enable or disable the use of a
132
+
thread comment or pull request review that basically says 'Looks Good To Me' (when all checks pass).
133
+
The default value, `true` means no LGTM comment posted.
134
+
135
+
See [`thread-comments`](#thread-comments), [`tidy-review`](#tidy-review),
136
+
and [`format-review`](#format-review) options for further details.
137
+
required: false
138
+
default: true
139
+
minimum-version: '2.6.2'
140
+
step-summary:
141
+
description: |
142
+
Set this option to true to append content as part of workflow's job summary.
143
+
144
+
See implementation details in GitHub's documentation about
145
+
[Adding a job summary](https://docs.github.com/en/actions/using-workflows/workflow-commands-for-github-actions#adding-a-job-summary).
146
+
This option is independent of the [`thread-comments`](#thread-comments) option,
147
+
rather this option uses the same content that the
148
+
[`thread-comments`](#thread-comments) option would use.
149
+
150
+
> [!NOTE]
151
+
> The [`no-lgtm`](#no-lgtm) option is _not_ applied to step summaries.
152
+
required: false
153
+
default: false
154
+
minimum-version: '2.6.0'
155
+
file-annotations:
156
+
description: |
157
+
Set this option to false to disable the use of file annotations as feedback.
158
+
required: false
159
+
default: true
160
+
minimum-version: '1.4.3'
94
161
database:
95
-
description: The directory containing compile_commands.json file.
162
+
description: The directory containing compilation database (like compile_commands.json) file.
96
163
required: false
97
164
default: ""
165
+
minimum-version: '1.4.0'
98
166
extra-args:
99
-
description: A string of extra arguments passed to clang-tidy for use as compiler arguments. Multiple arguments are separated by spaces so the argument name and value should use an '=' sign instead of a space.
167
+
description: |
168
+
A string of extra arguments passed to clang-tidy for use as compiler arguments.
169
+
Multiple arguments are separated by spaces so the argument name and value should
170
+
use an `=` sign instead of a space.
171
+
172
+
!!! example
173
+
174
+
``` yaml
175
+
extra-args: '-std=c++17 -Wall'
176
+
```
177
+
This will be passed to clang-tidy as multiple `--extra-arg` options:
0 commit comments