Testing out PR comment.
This commit is contained in:
@@ -105,9 +105,6 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
json: ${{ steps.json-cleanup.outputs.conditions }}
|
json: ${{ steps.json-cleanup.outputs.conditions }}
|
||||||
|
|
||||||
- name: Verify markdown output
|
|
||||||
run: echo "${{ steps.convert-json-to-md.outputs.table }}"
|
|
||||||
|
|
||||||
# Step 2: Post SonarQube results as comment (using curl commands and Gitea API)
|
# Step 2: Post SonarQube results as comment (using curl commands and Gitea API)
|
||||||
# - name: Post SonarQube Results as Comment
|
# - name: Post SonarQube Results as Comment
|
||||||
# run: |
|
# run: |
|
||||||
@@ -120,6 +117,16 @@ jobs:
|
|||||||
# "body": "SonarQube analysis results:\n\n- Bugs: ${{ env.SONAR_BUGS }}\n- Vulnerabilities: ${{ env.SONAR_VULNERABILITIES }}\n- Code Smells: ${{ env.SONAR_CODE_SMELLS }}\n- Coverage: ${{ env.SONAR_COVERAGE }}%\n- Duplications: ${{ env.SONAR_DUPLICATIONS }}%\n- Quality Gate Status: ${{ env.SONAR_QUALITY_GATE_STATUS }}"
|
# "body": "SonarQube analysis results:\n\n- Bugs: ${{ env.SONAR_BUGS }}\n- Vulnerabilities: ${{ env.SONAR_VULNERABILITIES }}\n- Code Smells: ${{ env.SONAR_CODE_SMELLS }}\n- Coverage: ${{ env.SONAR_COVERAGE }}%\n- Duplications: ${{ env.SONAR_DUPLICATIONS }}%\n- Quality Gate Status: ${{ env.SONAR_QUALITY_GATE_STATUS }}"
|
||||||
# }'
|
# }'
|
||||||
|
|
||||||
|
- name: Post SonarQube Results as Comment
|
||||||
|
run: |
|
||||||
|
curl ${{ vars.RINOA_GITEA_URL }}/api/v1/repos/${{ github.repository }}/pulls/${{ github.pull_request.number }}/reviews \
|
||||||
|
-X POST \
|
||||||
|
-H 'Accept: application/json' \
|
||||||
|
-H 'Authorization: token ${{ secrets.BOT_GITEA_TOKEN }}' \
|
||||||
|
-H 'Content-Type: application/json' \
|
||||||
|
-d '{
|
||||||
|
"body": "SonarQube analysis results:\n\n${{ steps.convert-json-to-md.outputs.table }}\n\n${{ steps.quality-gate.outputs.quality-gate-status }}"
|
||||||
|
}'
|
||||||
# # Job 3: Merge PR if Quality Gate passes
|
# # Job 3: Merge PR if Quality Gate passes
|
||||||
# merge-pr:
|
# merge-pr:
|
||||||
# runs-on: ubuntu-latest
|
# runs-on: ubuntu-latest
|
||||||
|
|||||||
Reference in New Issue
Block a user