forked from nulix-dev/adonis-2fa
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add automatic release GitHub workflow
This commit adds a new automatic release workflow to the project. This workflow uses GitHub actions to draft the next release notes as pull requests are merged into the main branch. It also includes an auto-labeler to help categorize the different types of commits.
- Loading branch information
1 parent
4699283
commit 63fba9b
Showing
4 changed files
with
117 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,79 @@ | ||
name-template: 'v$RESOLVED_VERSION 🚀' | ||
tag-template: 'v$RESOLVED_VERSION' | ||
version-template: '$MAJOR.$MINOR.$PATCH' | ||
version-resolver: | ||
major: | ||
labels: | ||
- 'major' | ||
minor: | ||
labels: | ||
- 'minor' | ||
- 'enhancement' | ||
- 'feature' | ||
- 'dependency-update' | ||
patch: | ||
labels: | ||
- 'auto-update' | ||
- 'patch' | ||
- 'fix' | ||
- 'chore' | ||
- 'bugfix' | ||
- 'bug' | ||
- 'hotfix' | ||
default: 'patch' | ||
|
||
categories: | ||
- title: '🚀 Enhancements' | ||
labels: | ||
- 'enhancement' | ||
- 'feature' | ||
- 'patch' | ||
- title: '⬆️ Upgrades' | ||
labels: | ||
- 'upgrades' | ||
- title: '🐛 Bug Fixes' | ||
labels: | ||
- 'fix' | ||
- 'bugfix' | ||
- 'bug' | ||
- 'hotfix' | ||
- title: '🤖 Automatic Updates' | ||
labels: | ||
- 'auto-update' | ||
- title: '📝 Documentation' | ||
labels: | ||
- 'docs' | ||
|
||
autolabeler: | ||
- label: 'docs' | ||
files: | ||
- '*.md' | ||
- label: 'enhancement' | ||
title: '/enhancement|fixes/i' | ||
|
||
- label: 'upgrades' | ||
title: '/⬆️/i' | ||
|
||
- label: 'bugfix' | ||
title: '/bugfix/i' | ||
|
||
- label: 'bug' | ||
title: '/🐛|🐞|bug/i' | ||
|
||
- label: 'auto-update' | ||
title: '/🤖/i' | ||
|
||
- label: 'feature' | ||
title: '/🚀|🎉/i' | ||
|
||
change-template: | | ||
<details> | ||
<summary>$TITLE @$AUTHOR (#$NUMBER)</summary> | ||
$BODY | ||
</details> | ||
template: | | ||
## Changes | ||
$CHANGES |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
name: auto-release | ||
|
||
on: | ||
push: | ||
# branches to consider in the event; optional, defaults to all | ||
branches: | ||
- main | ||
# pull_request event is required only for autolabeler | ||
pull_request: | ||
# Only following types are handled by the action, but one can default to all as well | ||
types: [opened, reopened, synchronize] | ||
|
||
permissions: | ||
contents: read | ||
|
||
jobs: | ||
update_release_draft: | ||
permissions: | ||
# write permission is required to create a github release | ||
contents: write | ||
# write permission is required for autolabeler | ||
# otherwise, read permission is required at least | ||
pull-requests: write | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
# Drafts your next Release notes as Pull Requests are merged into "main" | ||
- uses: release-drafter/release-drafter@v6 | ||
with: | ||
publish: false | ||
prerelease: true | ||
config-name: auto-release.yml | ||
# allows autolabeler to run without unmerged PRs from being added to draft | ||
disable-releaser: ${{ github.ref_name != 'main' }} | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters