Skip to content

Commit 5f07d64

Browse files
Bump cpp-linter from 1.6.0 to 1.6.1 (#163)
* Bump cpp-linter from 1.6.0 to 1.6.1 Bumps [cpp-linter](https://github.com/cpp-linter/cpp-linter) from 1.6.0 to 1.6.1. - [Release notes](https://github.com/cpp-linter/cpp-linter/releases) - [Commits](cpp-linter/cpp-linter@v1.6.0...v1.6.1) --- updated-dependencies: - dependency-name: cpp-linter dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> * update action inputs (and README correspondingly) * update pre-commit hooks * update example in README demonstrates how to update comments (in a PR only) instead of posting new ones. --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Brendan <2bndy5@gmail.com>
1 parent 3a896db commit 5f07d64

File tree

4 files changed

+26
-5
lines changed

4 files changed

+26
-5
lines changed

.pre-commit-config.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
repos:
22
- repo: https://github.com/pre-commit/pre-commit-hooks
3-
rev: v4.3.0
3+
rev: v4.5.0
44
hooks:
55
- id: trailing-whitespace
66
- id: end-of-file-fixer

README.md

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,9 @@ jobs:
4545
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
4646
with:
4747
style: file
48+
# The following value will only update a single comment
49+
# in a pull request's thread. Set it to false to disable the comment. # Set it to true to post a new comment (and delete the old comment).
50+
thread-comments: ${{ github.event_name == 'pull_request' && 'update' }}
4851

4952
- name: Fail fast?!
5053
if: steps.linter.outputs.checks-failed > 0
@@ -124,12 +127,18 @@ jobs:
124127

125128
#### `thread-comments`
126129

127-
- **Description**: Set this option to true to enable the use of thread comments as feedback.
130+
- **Description**: Set this option to true to enable the use of thread comments as feedback. Set this to 'update' to update an existing comment if one exists; the value 'true' will always delete an old comment and post a new one if necessary.
128131
- To use thread comments, the `GITHUB_TOKEN` (provided by Github to each repository) must be declared as an environment
129132
variable. See [Authenticating with the GITHUB_TOKEN](https://docs.github.com/en/actions/reference/authentication-in-a-workflow)
130133
- Default: false
131134
- NOTE: 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.
132135

136+
#### `no-lgtm`
137+
138+
- **Description**: Set this option to true or false to enable or disable the use of a thread comment that basically says 'Looks Good To Me' (when all checks pass).
139+
- See `thread-comments` option for further details.
140+
- Default: true (as is no LGTM comment used)
141+
133142
#### `step-summary`
134143

135144
- **Description**: Set this option to true to append content as part of workflow's job summary.

action.yml

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,20 @@ branding:
66
color: "green"
77
inputs:
88
thread-comments:
9-
description: Set this option to true to enable the use of thread comments as feedback. Defaults to false.
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.
1014
required: false
11-
default: 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
1223
step-summary:
1324
description: >
1425
Set this option to true to append content as part of workflow's job summary. Defaults to false.
@@ -134,6 +145,7 @@ runs:
134145
--lines-changed-only=${{ inputs.lines-changed-only }} \
135146
--files-changed-only=${{ inputs.files-changed-only }} \
136147
--thread-comments=${{ inputs.thread-comments }} \
148+
--no-lgtm=${{ inputs.no-lgtm }} \
137149
--step-summary=${{ inputs.step-summary }} \
138150
--ignore="${{ inputs.ignore }}" \
139151
--database=${{ inputs.database }} \

requirements.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,4 @@ clang-tools==0.8.0
44

55
# cpp-linter core Python executable package
66
# For details please see: https://github.com/cpp-linter/cpp-linter
7-
cpp-linter==1.6.0
7+
cpp-linter==1.6.1

0 commit comments

Comments
 (0)