Skip to content

Commit

Permalink
Fix
Browse files Browse the repository at this point in the history
  • Loading branch information
nbdd0121 committed Jun 25, 2024
1 parent 04a91d1 commit 27bcacf
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions .github/workflows/private-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ on:
- "*"

permissions:
statuses: write
contents: write # For repository dispatch

jobs:
trigger:
Expand All @@ -26,14 +26,14 @@ jobs:
- name: Trigger Private CI
run: |
PAYLOAD='{"event_type":"cross-repo-ci","client_payload":{"target":"${{ github.repository_owner }}/lowrisc-private-ci/master/test.yml","sha":"${{ github.event.pull_request.head.sha || github.sha }}"'
if [ -n "${{ github.event.pull_request.number }}" ]; then
PAYLOAD+=',"pull_request":${{ github.event.pull_request.number }}"'
if [[ -n "${{ github.event.pull_request.number }}" ]]; then
PAYLOAD+=',"pull_request":${{ github.event.pull_request.number }}'
fi
PAYLOAD+='}}'
curl -L \
curl -fL \
-X POST \
-H "Accept: application/vnd.github+json" \
-H "Authorization: Bearer ${{ github.token }}>" \
-H "Authorization: Bearer ${{ github.token }}" \
-H "X-GitHub-Api-Version: 2022-11-28" \
https://api.github.com/repos/${{ github.repository }}/dispatches \
-d "$PAYLOAD"

0 comments on commit 27bcacf

Please sign in to comment.