We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent a5c3155 commit be2026cCopy full SHA for be2026c
.github/workflows/sonar.yml
@@ -1,6 +1,3 @@
1
-# This workflow will build a golang project
2
-# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-go
3
-
4
name: Sonar Report
5
6
on:
@@ -25,6 +22,7 @@ jobs:
25
22
run: go test -coverpkg=./... -coverprofile=coverage.out -json ./... > sonar-report.json
26
23
27
24
- name: Upload coverage reports to Sonar
28
- uses: sonarsource/sonarcloud-github-action@master
29
env:
30
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
+ if: github.event.pull_request.head.repo.full_name == github.repository || env.SONAR_TOKEN != ''
+ uses: sonarsource/sonarcloud-github-action@master
0 commit comments