forked from x3dom/x3dom
-
Notifications
You must be signed in to change notification settings - Fork 0
47 lines (45 loc) · 1.42 KB
/
dispatch_release.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
37
38
39
40
41
42
43
44
45
46
47
name: Dispatch Release
on:
release:
types: [released]
push:
branches:
- main
- master
paths-ignore:
- '.github/**'
jobs:
stable:
runs-on: ubuntu-latest
if: ${{ github.event_name == 'release' }}
steps:
- name: Get App token
id: app_token
uses: getsentry/action-github-app-token@v3
with:
app_id: ${{ secrets.APP_ID }}
private_key: ${{ secrets.PRIVATE_KEY }}
- name: Dispatch stable release
uses: peter-evans/repository-dispatch@v3
with:
token: ${{ steps.app_token.outputs.token }}
repository: x3dom/x3dom-stable
event-type: x3dom-released
client-payload: '{"repository": "${{ github.repository }}", "ref": "${{ github.ref }}", "tag_name": "${{ github.event.release.tag_name }}"}'
dev:
runs-on: ubuntu-latest
if: ${{ github.event_name == 'push' }}
steps:
- name: Get App token
id: app_token
uses: getsentry/action-github-app-token@v3
with:
app_id: ${{ secrets.APP_ID }}
private_key: ${{ secrets.PRIVATE_KEY }}
- name: Dispatch dev release
uses: peter-evans/repository-dispatch@v3
with:
token: ${{ steps.app_token.outputs.token }}
repository: x3dom/x3dom-dev
event-type: x3dom-pushed
client-payload: '{"repository": "${{ github.repository }}", "ref": "${{ github.ref }}"}'