Logic testing for PR creation.
This commit is contained in:
@@ -25,9 +25,13 @@ jobs:
|
|||||||
id: check-pr
|
id: check-pr
|
||||||
run: |
|
run: |
|
||||||
echo "Checking for existing PR..."
|
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
|
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
|
- name: Get PR status
|
||||||
id: get-pr-status
|
id: get-pr-status
|
||||||
uses: yakubique/json-utils@v1.8
|
uses: yakubique/json-utils@v1.8
|
||||||
|
|||||||
Reference in New Issue
Block a user