using gitea-list-pr action instead of re-inventing the wheel with curl...
This commit is contained in:
@@ -15,25 +15,19 @@ jobs:
|
||||
steps:
|
||||
- name: Checkout Repository
|
||||
uses: actions/checkout@v4
|
||||
- name: Verify URL
|
||||
run: |
|
||||
echo "Verifying URL: ${{ vars.RINOA_GITEA_API }}/repos/${{ github.repository }}/pulls"
|
||||
- name: Check if Pull Request Exists
|
||||
id: check-pr
|
||||
uses: prasiman/gocurl@v1
|
||||
uses: vicamo/gitea-list-pull-requests@v1
|
||||
with:
|
||||
url: ${{ vars.RINOA_GITEA_API }}/repos/${{ github.repository }}/pulls
|
||||
params: '{ "state": "open" }'
|
||||
method: "GET"
|
||||
headers: '{ "Authorization": "token ${{ secrets.GITEA_API_TOKEN }}" }'
|
||||
log-response: true
|
||||
token: ${{ secrets.BOT_GITEA_TOKEN }}
|
||||
server_url: $$ {{ vars.RINOA_GITEA_URL }}
|
||||
state: 'open'
|
||||
- name: Parse Response
|
||||
id: parse-response
|
||||
uses: yakubique/json-utils@v1.8
|
||||
with:
|
||||
input: ${{ steps.check-pr.response }}
|
||||
action: "get"
|
||||
key: "data"
|
||||
input: "${{ steps.check-pr.outputs.json }}"
|
||||
action: "none"
|
||||
# - name: Create Pull Request
|
||||
# if:
|
||||
# uses: arifer612/Gitea-PR-action@v1.2.0
|
||||
|
||||
Reference in New Issue
Block a user