Skip to content

Commit 8e289a0

Browse files
committed
Add auto tagging on master branch
#minor
1 parent 977ce41 commit 8e289a0

File tree

2 files changed

+17
-0
lines changed

2 files changed

+17
-0
lines changed

.github/workflows/build.yml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,3 +28,10 @@ jobs:
2828
with:
2929
name: dist
3030
path: dist
31+
- name: Bump version and push tag
32+
uses: anothrNick/[email protected]
33+
if: github.ref == 'refs/heads/master'
34+
env:
35+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
36+
WITH_V: true
37+
DEFAULT_BUMP: patch

README.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ It includes:
1717
- dependency management using [Go Modules](https://github.com/golang/go/wiki/Modules),
1818
- linting with [golangci-lint](https://github.com/golangci/golangci-lint),
1919
- build automation via [Make](https://www.gnu.org/software/make), [GitHub Actions](https://github.com/features/actions),
20+
- auto-tagging via [Github Tag Bump](https://github.com/marketplace/actions/github-tag-bump) GitHub Action,
2021
- releasing using [GoReleaser](https://github.com/goreleaser/goreleaser).
2122

2223
`Star` this repository if you find it valuable and worth maintaining.
@@ -36,6 +37,15 @@ It includes:
3637
- Terminal: `make all` to execute a full build.
3738
- Visual Studio Code: `Terminal``Run Build Task... (CTRL+ALT+B)` to execute a fast build.
3839

40+
## Release
41+
42+
The release workflow is triggered each time a tag with `v` prefix is pushed.
43+
44+
This repo uses [Github Tag Bump](https://github.com/marketplace/actions/github-tag-bump) for auto tagging on master branch. It automatically triggers the release workflow.
45+
46+
- Add `#minor` to your commit message to bump minor version.
47+
- Add `#major` to your commit message to bump major version. DANGER! Use it with caution and make sure you understand the consequences. More info: [Go Wiki](https://github.com/golang/go/wiki/Modules#releasing-modules-v2-or-higher), [Go Blog][https://blog.golang.org/v2-go-modules].
48+
3949
## Maintainance
4050

4151
Remember to update Go version in [.github/workflows](.github/workflows), [Makefile](Makefile) and [devcontainer.json](.devcontainer/devcontainer.json).

0 commit comments

Comments
 (0)