Logic testing for PR creation.

This commit is contained in:
2024-12-17 11:49:12 -05:00
parent 999641aa05
commit 96c03848c9
@@ -25,9 +25,13 @@ jobs:
id: check-pr
run: |
echo "Checking for existing PR..."
pr_http_status=$(curl ${{ vars.RINOA_GITEA_URL }}/api/v1/repos/${{ github.repository }}/pulls/main/${{ github.ref_name }} -X 'GET' -H 'Accept: application/json' -H 'Authorization: ${{ secrets.BOT_GITEA_TOKEN }}' -s | jq '{index: .number, state: .state}')
pr_status=$(curl ${{ vars.RINOA_GITEA_URL }}/api/v1/repos/${{ github.repository }}/pulls/main/${{ github.ref_name }} -X 'GET' -H 'Accept: application/json' -H 'Authorization: ${{ secrets.BOT_GITEA_TOKEN }}' -s | jq '{index: .number, state: .state}')
echo "pr_http_status=$pr_http_status" >> $GITHUB_OUTPUT
- name: var test
run: |
echo "pr_http_status: ${{ steps.check-pr.outputs.pr_http_status }}"
- name: Get PR status
id: get-pr-status
uses: yakubique/json-utils@v1.8