GoTomato/.goreleaser.yaml
Sebastian Mark 93f39507c1 feat(gorleaser): set version from git tag on build
- make `GoTomatoVersion` a variable and default it to "devel"
- add ldflags to `.goreleaser.yaml` for version tagging
- remove "v" from output of `-version`
2024-11-10 09:15:16 +01:00

43 lines
634 B
YAML

# vim: set ts=2 sw=2 tw=0 fo=cnqoj
version: 2
before:
hooks:
- rm -fr ./dist
- go mod tidy
builds:
- goos:
- linux
goarch:
- amd64
- arm64
env:
- CGO_ENABLED=0
ldflags:
- -s -w -X git.smsvc.net/pomodoro/GoTomato/internal/metadata.GoTomatoVersion={{.Version}}
upx:
- enabled: true
compress: best
lzma: true
changelog:
sort: desc
filters:
exclude:
- "bump version to"
archives:
- format: binary
release:
gitea:
owner: pomodoro
name: GoTomato
mode: replace
gitea_urls:
download: http://git.smsvc.net
api: http://git.smsvc.net/api/v1