Skip to content

Commit 5b65c69

Browse files
committed
Adding the release drafter action to create draft release notes
As PRs are merged to main release drafter will create a draft release and fill out the release notes template. PRs will be bucketed into fix, feature, or improvement based on labels. We need to tag our PRs with the appropriate labels to get the automatic bucketing. However PRs can always be moved around when we create the release PR.
1 parent 3b143cd commit 5b65c69

File tree

2 files changed

+66
-0
lines changed

2 files changed

+66
-0
lines changed

.github/release-drafter.yml

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
name-template: $RESOLVED_VERSION
2+
tag-template: $RESOLVED_VERSION
3+
categories:
4+
- title: 🚀 Features
5+
label: Enhancement / Feature
6+
- title: 🐛 Bug Fixes
7+
label: Bug
8+
- title: 🧰 Improvements
9+
label: Improvement
10+
change-template: '- $TITLE (#$NUMBER)'
11+
version-resolver:
12+
major:
13+
labels:
14+
- 'major'
15+
minor:
16+
labels:
17+
- 'minor'
18+
patch:
19+
labels:
20+
- 'patch'
21+
default: patch
22+
template: |
23+
## Other Changes
24+
25+
$CHANGES

.github/workflows/release-drafter.yml

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
name: Release Drafter
2+
3+
on:
4+
push:
5+
# branches to consider in the event; optional, defaults to all
6+
branches:
7+
- main
8+
# pull_request event is required only for autolabeler
9+
pull_request:
10+
# Only following types are handled by the action, but one can default to all as well
11+
types: [opened, reopened, synchronize]
12+
# pull_request_target event is required for autolabeler to support PRs from forks
13+
# pull_request_target:
14+
# types: [opened, reopened, synchronize]
15+
16+
permissions:
17+
contents: read
18+
19+
jobs:
20+
update_release_draft:
21+
permissions:
22+
# write permission is required to create a github release
23+
contents: write
24+
# write permission is required for autolabeler
25+
# otherwise, read permission is required at least
26+
pull-requests: write
27+
runs-on: ubuntu-latest
28+
steps:
29+
# (Optional) GitHub Enterprise requires GHE_HOST variable set
30+
#- name: Set GHE_HOST
31+
# run: |
32+
# echo "GHE_HOST=${GITHUB_SERVER_URL##https:\/\/}" >> $GITHUB_ENV
33+
34+
# Drafts your next Release notes as Pull Requests are merged into "master"
35+
- uses: release-drafter/release-drafter@v5
36+
# (Optional) specify config name to use, relative to .github/. Default: release-drafter.yml
37+
# with:
38+
# config-name: my-config.yml
39+
# disable-autolabeler: true
40+
env:
41+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 commit comments

Comments
 (0)