Skip to content

Commit

Permalink
chore: update dispatch event type (#4698) (#4701)
Browse files Browse the repository at this point in the history
* cherry pick #4698 to release-5.0

Signed-off-by: ti-srebot <[email protected]>

* Update dispatch.yml

resolve conflict

Co-authored-by: Yini Xu <[email protected]>
  • Loading branch information
ti-srebot and YiniXu9506 authored Jan 25, 2021
1 parent c7b201d commit 99f9e83
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion .github/workflows/dispatch.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,19 @@ jobs:
steps:
- uses: actions/checkout@v2


- name: Extract branch, repo and sha
shell: bash
id: extract_info
run: |
echo "::set-output name=branch::${GITHUB_REF#refs/heads/}"
echo "::set-output name=repo::$(cut -d'/' -f2 <<< ${{ github.repository }})"
echo "::set-output name=sha::$(sha=${{ github.sha }}; echo ${sha:0:6})"
- name: Repository Dispatch
uses: peter-evans/[email protected]
with:
token: ${{ secrets.PR_TRIGGER_BUILD_TOKEN }}
repository: pingcap/website-docs/
event-type: triggered
event-type: ${{ steps.extract_info.outputs.repo }}/${{ steps.extract_info.outputs.branch }}-${{ steps.extract_info.outputs.sha }}
client-payload: '{"ref": "${{ github.ref }}", "sha": "${{ github.sha }}", "repo": "${{ github.repository }}"}'

0 comments on commit 99f9e83

Please sign in to comment.