Re-testing flow.
This commit is contained in:
@@ -57,6 +57,8 @@ jobs:
|
|||||||
name: SonarQube Analysis
|
name: SonarQube Analysis
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
needs: check-and-create-pr
|
needs: check-and-create-pr
|
||||||
|
outputs:
|
||||||
|
qg_status: ${{ steps.quality-gate.outputs.quality-gate-status }}
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout Code
|
- name: Checkout Code
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
@@ -130,8 +132,8 @@ jobs:
|
|||||||
# Job 3: Merge PR if Quality Gate passes
|
# Job 3: Merge PR if Quality Gate passes
|
||||||
dry-run-merge-pr:
|
dry-run-merge-pr:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
needs: [check-and-create-pr, sonarqube-analysis]
|
needs: sonarqube-analysis
|
||||||
if: needs.sonarqube-analysis.outputs.quality_gate_status == 'PASSED'
|
if: needs.sonarqube-analysis.outputs.qg_status == 'PASSED'
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout Code
|
- name: Checkout Code
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
@@ -145,19 +147,19 @@ jobs:
|
|||||||
up: true
|
up: true
|
||||||
up-opts: -d --dry-run
|
up-opts: -d --dry-run
|
||||||
|
|
||||||
- name: Merge PR in Gitea
|
# - name: Merge PR in Gitea
|
||||||
uses: prasiman/gocurl@v1
|
# uses: prasiman/gocurl@v1
|
||||||
with:
|
# with:
|
||||||
url: "${{ secrets.GITEA_INSTANCE_URL }}/repos/${{ github.repository_owner }}/${{ github.event.repository.name }}/pulls/${{ needs.check-and-create-pr.outputs.pr_index }}"
|
# url: "${{ secrets.GITEA_INSTANCE_URL }}/repos/${{ github.repository_owner }}/${{ github.event.repository.name }}/pulls/${{ needs.check-and-create-pr.outputs.pr_index }}"
|
||||||
method: "POST"
|
# method: "POST"
|
||||||
headers: '{ "Authorization": "token ${{ secrets.GITEA_API_TOKEN }}", "Content-Type": "application/json" }'
|
# headers: '{ "Authorization": "token ${{ secrets.GITEA_API_TOKEN }}", "Content-Type": "application/json" }'
|
||||||
params: >-
|
# params: >-
|
||||||
{
|
# {
|
||||||
"Do": "merge",
|
# "Do": "merge",
|
||||||
"delete_branch_after_merge": true,
|
# "delete_branch_after_merge": true,
|
||||||
"force_merge": true,
|
# "force_merge": true,
|
||||||
"merge_when_checks_succeed": true
|
# "merge_when_checks_succeed": true
|
||||||
}
|
# }
|
||||||
|
|
||||||
- name: Confirm Merge
|
# - name: Confirm Merge
|
||||||
run: echo "PR has been successfully merged into main."
|
# run: echo "PR has been successfully merged into main."
|
||||||
|
|||||||
Reference in New Issue
Block a user