File tree Expand file tree Collapse file tree 1 file changed +11
-3
lines changed
Expand file tree Collapse file tree 1 file changed +11
-3
lines changed Original file line number Diff line number Diff line change @@ -145,6 +145,14 @@ jobs:
145145 output-file : hadolint.txt
146146 no-fail : true
147147
148+ - name : Read Hadolint report file
149+ id : read_hadolint
150+ if : ${{ inputs.hadolint }}
151+ run : |
152+ echo "report<<EOF" >> "$GITHUB_OUTPUT"
153+ cat hadolint.txt >> "$GITHUB_OUTPUT"
154+ echo "EOF" >> "$GITHUB_OUTPUT"
155+
148156 - name : Find existing Hadolint comment
149157 if : github.event_name == 'pull_request' && inputs.hadolint
150158 id : find_hadolint
@@ -155,7 +163,7 @@ jobs:
155163 body-includes : ' Hadolint Dockerfile Lint Results'
156164
157165 - name : Create or update Hadolint comment
158- if : github.event_name == 'pull_request' && inputs.hadolint && steps.hadolint .outputs.report != ''
166+ if : github.event_name == 'pull_request' && inputs.hadolint && steps.read_hadolint .outputs.report != ''
159167 uses : peter-evans/create-or-update-comment@v4
160168 with :
161169 token : ${{ secrets.GITHUB_TOKEN }}
@@ -165,9 +173,9 @@ jobs:
165173 body : |
166174 <!-- hadolint-scan -->
167175 ### 🐳 Hadolint Dockerfile Lint Results
168- <details><summary>Click to expand</summary>
176+ <details><summary>Click to expand detailed results </summary>
169177
170178 ```bash
171- ${{ steps.hadolint .outputs.report }}
179+ ${{ steps.read_hadolint .outputs.report }}
172180 ```
173181 </details>
You can’t perform that action at this time.
0 commit comments