forked from segmentio/analytics-ruby
-
Notifications
You must be signed in to change notification settings - Fork 5
41 lines (39 loc) · 1.09 KB
/
slack-notify.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
name: Notify Slack Channel
on:
release:
types: [created]
jobs:
deploy-tag:
name: Notify Slack
runs-on: ubuntu-latest
steps:
- name: Send message to Slack channel
id: slack
uses: slackapi/[email protected]
env:
SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }}
PROJECT_NAME: 'Ruby(Async) SDK'
with:
channel-id: "${{ secrets.SLACK_RELEASE_CHANNEL_ID }}"
payload: |
{
"blocks": [
{
"type": "header",
"text": {
"type": "plain_text",
"text": "New release: ${{ env.PROJECT_NAME }}"
}
},
{
"type": "divider"
},
{
"type": "section",
"text": {
"type": "mrkdwn",
"text": "*Release: <${{ github.event.release.html_url }}|${{ github.event.release.tag_name }}>*"
}
}
]
}