-
Notifications
You must be signed in to change notification settings - Fork 15
36 lines (31 loc) · 1.32 KB
/
release-notification.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
name: Release Notification
on:
release:
types: [published]
workflow_dispatch: # This allows manual triggering
jobs:
release-notification:
runs-on: ubuntu-latest
steps:
- name: Fetch latest release tag
run: |
latest_release=$(curl -s https://api.github.com/repos/${{ github.repository }}/releases/latest | jq -r .tag_name)
echo "LATEST_RELEASE_TAG=$latest_release" >> $GITHUB_ENV
- name: Send dispatch event to bot_playground repository
env:
PAT: ${{ secrets.TOKEN_SR }}
run: |
curl -X POST \
-H "Accept: application/vnd.github.v3+json" \
-H "Authorization: token $PAT" \
https://api.github.com/repos/clEsperanto/pyclesperanto/dispatches \
-d '{"event_type":"clic_update", "client_payload": {"release_tag": "${{ env.LATEST_RELEASE_TAG }}"}}'
- name: Send dispatch event to bot_playground repository
env:
PAT: ${{ secrets.TOKEN_SR }}
run: |
curl -X POST \
-H "Accept: application/vnd.github.v3+json" \
-H "Authorization: token $PAT" \
https://api.github.com/repos/clEsperanto/clesperantoj_prototype/dispatches \
-d '{"event_type":"clic_update", "client_payload": {"release_tag": "${{ env.LATEST_RELEASE_TAG }}"}}'