-
-
Notifications
You must be signed in to change notification settings - Fork 0
55 lines (49 loc) · 1.33 KB
/
generate-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
name: Create Release Notes
on:
push:
tags:
- 'v*'
- '!v*-rc.*'
workflow_dispatch:
inputs:
slack-notify:
description: 'Notify Slack'
required: true
default: 'true'
type: choice
options:
- 'true'
- 'false'
env:
SLACK_NOTIFY: true
permissions: read-all
jobs:
create-release:
name: Create Release
permissions:
contents: write
uses: WolfSoftware/reusable-workflows/.github/workflows/reusable-generate-release.yml@master
secrets:
token: ${{ secrets.GITHUB_TOKEN }}
set-slack-notify:
name: Set Slack Notify
runs-on: ubuntu-latest
outputs:
slack-notify: ${{ steps.set-slack-notify.outputs.slack-notify }}
steps:
- name: Set Slack Notify
id: set-slack-notify
run: |
echo "slack-notify=${{ github.event.inputs.slack-notify || env.SLACK_NOTIFY }}" >> "${GITHUB_OUTPUT}"
slack-workflow-status:
if: always()
name: Slack (Local)
needs:
- create-release
- set-slack-notify
uses: WolfSoftware/reusable-workflows/.github/workflows/reusable-slack.yml@master
with:
slack_notify: ${{ needs.set-slack-notify.outputs.slack-notify }}
secrets:
token: ${{ secrets.GITHUB_TOKEN }}
slack_webhook_url: ${{ secrets.SLACK_WEBHOOK_URL }}