Skip to content

Commit 4a4acc3

Browse files
committed
Fix coverity yml
1 parent 7c155b9 commit 4a4acc3

File tree

1 file changed

+15
-6
lines changed

1 file changed

+15
-6
lines changed

.github/workflows/coverity_scan.yml

Lines changed: 15 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@ permissions:
77

88
jobs:
99
coverity_scan:
10-
if: github.event_name == 'pull_request'
1110
runs-on: ubuntu-latest
1211
name: Coverity Scan
1312
steps:
@@ -35,8 +34,18 @@ jobs:
3534
- name: Submit results to Coverity
3635
run: |
3736
tar czf cov-int.tgz cov-int
38-
curl --form token="${{ secrets.COVERITY_TOKEN }}" \
39-
40-
--form version="GitHub PR #${{ github.event.pull_request.number }}" \
41-
--form description="CI run for PR" \
42-
https://scan.coverity.com/builds?project=gabime%2Fspdlog
37+
response=$(curl --silent --show-error --fail \
38+
--form token="${{ secrets.COVERITY_TOKEN }}" \
39+
40+
--form version="GitHub PR #${{ github.event.pull_request.number }}" \
41+
--form description="CI run for PR" \
42+
https://scan.coverity.com/builds?project=gabime%2Fspdlog)
43+
44+
echo "$response"
45+
46+
if echo "$response" | grep -qi "Build successfully submitted"; then
47+
echo "Coverity upload succeeded"
48+
else
49+
echo "Coverity upload failed or was rejected"
50+
exit 1
51+
fi

0 commit comments

Comments
 (0)