forked from Hyperfoil/Horreum
-
Notifications
You must be signed in to change notification settings - Fork 0
31 lines (31 loc) · 977 Bytes
/
notify-clients.yaml
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
name: Notify clients
on:
push:
branches:
- master
- 0.15
paths:
- "docs/site/content/en/openapi/openapi.yaml"
jobs:
clients-notification:
runs-on: ubuntu-latest
strategy:
matrix:
clients:
- name: Golang
repository: Hyperfoil/horreum-client-golang
- name: Python
repository: Hyperfoil/horreum-client-python
steps:
- name: Extract trigger branch
id: extractor
shell: bash
run: |
echo "current_branch=${GITHUB_HEAD_REF:-${GITHUB_REF#refs/heads/}}" >> $GITHUB_OUTPUT
- name: Notify ${{ matrix.clients.name }} client
uses: peter-evans/repository-dispatch@v3
with:
token: ${{ secrets.CLIENTS_NOTIFICATION_TOKEN }}
repository: ${{ matrix.clients.repository }}
event-type: detected-horreum-openapi-change
client-payload: '{"branch": "${{ steps.extractor.outputs.current_branch }}"}'