-
-
Notifications
You must be signed in to change notification settings - Fork 578
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ci: implement automated release workflow with GoReleaser
- Add GitHub Actions workflow for GoReleaser - Configure GoReleaser to skip builds - Set up changelog groups for features, bug fixes, enhancements, refactors, build process updates, and documentation updates Signed-off-by: appleboy <appleboy.tw@gmail.com>
- Loading branch information
Showing
2 changed files
with
61 additions
and
0 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,33 @@ | ||
name: Goreleaser | ||
|
||
on: | ||
push: | ||
tags: | ||
- "*" | ||
|
||
permissions: | ||
contents: write | ||
|
||
jobs: | ||
goreleaser: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
|
||
- name: Setup go | ||
uses: actions/setup-go@v5 | ||
with: | ||
go-version: "^1" | ||
|
||
- name: Run GoReleaser | ||
uses: goreleaser/goreleaser-action@v6 | ||
with: | ||
# either 'goreleaser' (default) or 'goreleaser-pro' | ||
distribution: goreleaser | ||
version: latest | ||
args: release --clean | ||
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
builds: | ||
- # If true, skip the build. | ||
# Useful for library projects. | ||
# Default is false | ||
skip: true | ||
|
||
changelog: | ||
use: github | ||
groups: | ||
- title: Features | ||
regexp: "^.*feat[(\\w)]*:+.*$" | ||
order: 0 | ||
- title: "Bug fixes" | ||
regexp: "^.*fix[(\\w)]*:+.*$" | ||
order: 1 | ||
- title: "Enhancements" | ||
regexp: "^.*chore[(\\w)]*:+.*$" | ||
order: 2 | ||
- title: "Refactor" | ||
regexp: "^.*refactor[(\\w)]*:+.*$" | ||
order: 3 | ||
- title: "Build process updates" | ||
regexp: ^.*?(build|ci)(\(.+\))??!?:.+$ | ||
order: 4 | ||
- title: "Documentation updates" | ||
regexp: ^.*?docs?(\(.+\))??!?:.+$ | ||
order: 4 | ||
- title: Others |