File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1010
1111jobs :
1212
13- sonarcloud-secrets :
14- name : SonarCloud check secrets are present
15- runs-on : ubuntu-latest
16- outputs :
17- sonar : ${{ steps.check-secrets.outputs.sonar }}
18- steps :
19- - name : Check secrets are present
20- id : check-secrets
21- run : |
22- if [ -n "${{ secrets.SONAR_TOKEN }}" ]; then
23- echo "sonar=yes" >> $GITHUB_OUTPUT
24- else
25- echo "sonar=no" >> $GITHUB_OUTPUT
26- echo "::warning ::SONAR_TOKEN non set"
27- fi
28-
29- sonarcloud :
13+ sonarqube-cloud :
3014 name : SonarCloud Scan and Report
31- needs : [ "tests-coverage", " sonarcloud-secrets" ]
15+ needs : [ "sonarcloud-secrets" ]
3216 if : ${{ needs.sonarcloud-secrets.outputs.sonar == 'yes' }}
3317 runs-on : " ubuntu-latest"
3418 steps :
19+ - name : Check SONAR_TOKEN secret
20+ run : |
21+ if [ -z "${{ secrets.SONAR_TOKEN }}" ]; then
22+ echo "::warning ::SONAR_TOKEN non set"
23+ exit 1
24+ fi
3525 - name : Checkout
3626 uses : actions/checkout@v4
3727 - name : Unshallow clone to provide blame information
You can’t perform that action at this time.
0 commit comments