release #33
Workflow file for this run
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
name: release | |
on: | |
release: | |
types: [published] | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-go@v5 | |
with: | |
go-version-file: "go.mod" | |
- name: Install gobump | |
run: go install github.com/x-motemen/gobump/cmd/gobump@latest | |
- name: bump version | |
id: bump_version | |
run: | | |
git config user.name "GitHub Actions Bot" | |
git config user.email "<>" | |
VERSION=${GITHUB_REF#refs/tags/} | |
gobump set ${VERSION#v} -w | |
echo ::set-output name=VERSION::$VERSION | |
- name: Commit updates | |
uses: EndBug/add-and-commit@v9 | |
with: | |
new_branch: main | |
message: "[release] bump up ${{ steps.bump_version.outputs.VERSION }}" | |
add: "version.go" | |
tag: "${{ steps.bump_version.outputs.VERSION }} --force" | |
tag_push: "--force" | |
- name: Build | |
run: make build_all | |
- name: Release | |
uses: softprops/action-gh-release@v1 | |
with: | |
files: dist/* |