generated from okp4/template-oss
-
Notifications
You must be signed in to change notification settings - Fork 128
93 lines (87 loc) · 3.46 KB
/
notify-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
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
name: Notify release
on:
release:
types: [published]
jobs:
notify-discord:
runs-on: ubuntu-22.04
steps:
- name: Notify Discord
uses: fjogeleit/http-request-action@v1
with:
url: ${{ secrets.DISCORD_WEBHOOK }}
method: 'POST'
customHeaders: '{"Content-Type": "application/json"}'
data: |-
{
"avatar_url": "https://avatars.githubusercontent.com/u/98603954?v=4",
"username": "Bot Anik",
"content": "🚨 A new version of @${{github.repository}} ${{ github.event.release.tag_name }} has been released! 🎉\n\n👉 Changelog: https://github.com/${{ github.repository }}/releases/tag/${{ github.event.release.tag_name }}\n👉 Official repo: https://github.com/${{ github.repository }}"
}
update-docs:
runs-on: ubuntu-22.04
steps:
- name: Update modules docs repository
uses: fjogeleit/http-request-action@v1
with:
url: 'https://api.github.com/repos/axone-protocol/docs/actions/workflows/39152549/dispatches'
method: 'POST'
customHeaders: '{"Accept": "application/vnd.github+json", "Authorization": "Bearer ${{ secrets.OPS_TOKEN }}"}'
data: |-
{
"ref": "main",
"inputs": {
"version": "${{ github.event.release.tag_name }}",
"repository": "${{github.repository}}",
"section": "modules",
"docs_directory": "docs/proto/*"
}
}
- name: Update commands docs repository
uses: fjogeleit/http-request-action@v1
with:
url: 'https://api.github.com/repos/axone-protocol/docs/actions/workflows/39152549/dispatches'
method: 'POST'
customHeaders: '{"Accept": "application/vnd.github+json", "Authorization": "Bearer ${{ secrets.OPS_TOKEN }}"}'
data: |-
{
"ref": "main",
"inputs": {
"version": "${{ github.event.release.tag_name }}",
"repository": "${{github.repository}}",
"section": "commands",
"docs_directory": "docs/command/*"
}
}
- name: Update predicates docs repository
uses: fjogeleit/http-request-action@v1
with:
url: 'https://api.github.com/repos/axone-protocol/docs/actions/workflows/39152549/dispatches'
method: 'POST'
customHeaders: '{"Accept": "application/vnd.github+json", "Authorization": "Bearer ${{ secrets.OPS_TOKEN }}"}'
data: |-
{
"ref": "main",
"inputs": {
"version": "${{ github.event.release.tag_name }}",
"repository": "${{github.repository}}",
"section": "predicates",
"docs_directory": "docs/predicates/*"
}
}
update-docs-version:
runs-on: ubuntu-22.04
steps:
- name: Update docs version
uses: fjogeleit/http-request-action@v1
with:
url: 'https://api.github.com/repos/axone-protocol/docs/actions/workflows/37674835/dispatches'
method: 'POST'
customHeaders: '{"Accept": "application/vnd.github+json", "Authorization": "Bearer ${{ secrets.OPS_TOKEN }}"}'
data: |-
{
"ref": "main",
"inputs": {
"axonedVersion": "${{ github.event.release.tag_name }}"
}
}