Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
58 changes: 32 additions & 26 deletions .github/release-drafter.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,11 @@
# always applies dependencies alongside them, and that is categorised.
# Note that `categories` is an array: a repo that overrides it via _extends
# replaces the whole array rather than appending to it.
# $RESOLVED_VERSION follows the version-resolver below, so a PR labelled
# enhancement drafts a minor and a PR labelled bug drafts a patch. The previous
# $NEXT_PATCH_VERSION always drafted a patch, which meant every minor release in
# the org had to be retitled by hand before publishing.
# $RESOLVED_VERSION follows the semver-increment of each category, so a PR
# labelled enhancement drafts a minor and a PR labelled bug drafts a patch. The
# previous $NEXT_PATCH_VERSION always drafted a patch, which meant every minor
# release in the org had to be retitled by hand before publishing. A PR with no
# categorised label drafts a patch, release-drafter's own fallback.
#
# tag-template here is a fallback with no artifact prefix, and no repo should
# rely on it: every repo tags as <artifact>-<version>, so each one overrides
Expand All @@ -24,40 +25,45 @@ tag-template: $RESOLVED_VERSION
version-template: $MAJOR.$MINOR.$PATCH

categories:
- type: pre-exclude
when:
labels: [reverted, skip-changelog]
- title: ":boom: Breaking changes"
labels: [breaking]
semver-increment: major
when:
labels: [breaking]
- title: 🚨 Removed
labels: [removed]
semver-increment: minor
when:
labels: [removed]
- title: 🚀 New features and improvements
labels: [enhancement]
semver-increment: minor
when:
labels: [enhancement]
- title: 🐛 Bug Fixes
labels: [bug]
semver-increment: patch
when:
labels: [bug]
- title: 📝 Documentation updates
labels: [documentation]
semver-increment: patch
when:
labels: [documentation]
- title: 👻 Maintenance
labels: [maintenance]
semver-increment: patch
when:
labels: [maintenance]
- title: 🔧 Build
labels: [build]
semver-increment: patch
when:
labels: [build]
# Applied automatically by Dependabot. This is ~85% of all labelled items in
# the org, so it is collapsed behind a summary line rather than being allowed
# to bury every other category.
- title: 📦 Dependency updates
labels: [dependencies]
semver-increment: patch
collapse-after: 10

exclude-labels:
- reverted
- skip-changelog

# Derive the next version from the labels already being applied.
version-resolver:
major:
labels: [breaking]
minor:
labels: [enhancement, removed]
patch:
labels: [bug, documentation, maintenance, build, dependencies]
default: patch
when:
labels: [dependencies]

change-template: '- $TITLE ([#$NUMBER]($URL)) @$AUTHOR'

Expand Down