We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4eb828e commit f3947f1Copy full SHA for f3947f1
.github/workflows/notif-push-to-slack.yml
@@ -0,0 +1,35 @@
1
+#https://docs.github.com/en/webhooks/webhook-events-and-payloads#push
2
+name: notify-push
3
+on:
4
+ push:
5
+ branches:
6
+ - develop
7
+jobs:
8
+ notify:
9
+ runs-on: ubuntu-latest
10
+ if: github.event.pusher.name == 'bigorn0'
11
+ env:
12
+ AUTHOR: ${{ github.event.pusher.name }}
13
+ steps:
14
+ - name: notify
15
+ run: echo "${AUTHOR}"
16
+ - name: notify slack
17
+ id: slack
18
+ uses: slackapi/[email protected]
19
+ with:
20
+ channel-id: 'develop-direct-pushes'
21
+ payload: |
22
+ {
23
+ "text": " ${{ github.event.head_commit.url }}",
24
+ "blocks": [
25
26
+ "type": "section",
27
+ "text": {
28
+ "type": "mrkdwn",
29
+ "text": "Direct push to develop: ${{ github.event.head_commit.url }}"
30
+ }
31
32
+ ]
33
34
35
+ SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }}
0 commit comments