-
Notifications
You must be signed in to change notification settings - Fork 0
53 lines (47 loc) · 1.43 KB
/
release-drafter.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
name: Release CI
on:
release:
types:
- published
push:
tags:
- v[0-9]+.[0-9]+.[0-9]+(-[a-zA-Z]+[0-9]+)?
branches:
- master
# This ensures that previous jobs for the workflow are canceled when the ref is
# updated.
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
update_release_draft:
name: "Release Drafter"
runs-on: ubuntu-latest
steps:
# Drafts your next Release notes as Pull Requests are merged into "default branch"
- uses: release-drafter/release-drafter@v5
env:
GITHUB_TOKEN: ${{ secrets.GIT_TOKEN }}
release_notify:
name: "Release Notifier"
runs-on: ubuntu-latest
if: startsWith(github.ref, 'refs/tags/')
needs:
- update_release_draft
steps:
- id: latest_release
uses: thebritican/[email protected]
- uses: dawidd6/[email protected]
with:
server_address: ${{ secrets.SMTP_HOST }}
server_port: ${{ secrets.SMTP_PORT }}
username: ${{ secrets.SMTP_USERNAME }}
password: ${{ secrets.SMTP_PASSWORD }}
subject: ${{ github.repository }} release is out!
convert_markdown: true
html_body: |
# Release ${{ steps.latest_release.outputs.tag_name }}
***
${{ steps.latest_release.outputs.body }}
to: ${{ secrets.MAIL_TO }}
from: OmsBot