Skip to content

Commit 43aba2d

Browse files
committed
fix: Forsøker å fikse oppdatering av sarif filen.
Feilen ligger trolig i denne delen `jq '...' code-analyzer-report.sarif > code-analyzer-report.sarif shellet truncata filen til null før jq kjører. No
1 parent 1d4e33a commit 43aba2d

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

.github/workflows/ciStaticCodeValidation.yml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -105,6 +105,9 @@ jobs:
105105
- name: Check SARIF file
106106
if: ${{ !cancelled() && steps.paths.outcome == 'success' }}
107107
run: |
108+
echo "::group::Print SARIF file before check"
109+
cat code-analyzer-report.sarif
110+
echo "::endgroup::"
108111
echo "::group::Check SARIF file"
109112
jq --arg wd "$GITHUB_WORKSPACE" '
110113
if .runs == [] then
@@ -130,9 +133,9 @@ jobs:
130133
else
131134
.
132135
end
133-
' code-analyzer-report.sarif > code-analyzer-report.sarif
136+
' code-analyzer-report.sarif > temp.sarif && mv temp.sarif code-analyzer-report.sarif
134137
echo "::endgroup::"
135-
echo "::group::Print SARIF file"
138+
echo "::group::Print SARIF file after check"
136139
cat code-analyzer-report.sarif
137140
echo "::endgroup::"
138141

0 commit comments

Comments
 (0)