GoTomato/Taskfile.yml

42 lines
916 B
YAML
Raw Normal View History

version: '3'
vars:
2024-11-08 16:44:10 +00:00
VERSIONFILE: version.txt
RELEASE:
sh: svu next --strip-prefix
2024-11-08 16:44:10 +00:00
BRANCH:
2024-11-08 15:00:57 +00:00
sh: git branch --show-current
2024-11-08 16:44:10 +00:00
COMMIT:
sh: git rev-parse --short --verify {{.BRANCH}}
COMMITMSG: "chore: bump version to v{{.RELEASE}}"
tasks:
release:tag:
desc: Create a new tag
cmds:
- git tag v{{.RELEASE}}
- git push --tags
release:file:
desc: Update version.txt
generates:
- version.txt
cmds:
- echo {{.RELEASE}} >{{.VERSIONFILE}}
- git add {{.VERSIONFILE}}
- git commit -m "{{.COMMITMSG}}"
- git push
release:goreleaser:
desc: Create a new release with goreleaser
cmds:
- goreleaser release --clean
dorelease:
desc: Do all release steps
2024-11-08 16:44:10 +00:00
prompt: Create new release v{{.RELEASE}} from {{.COMMIT}}@{{.BRANCH}}?
cmds:
- task: release:file
- task: release:tag
- task: release:goreleaser