Ensure we label with proper tags and version the build

This commit is contained in:
Marc Di Luzio 2020-06-23 18:47:59 +01:00
parent 996970fd81
commit 98349b8935

View file

@ -42,7 +42,7 @@ parts:
override-pull: |
snapcraftctl pull
snapcraftctl set-version $(git describe --always --long --dirty --tags)
git describe --exact-match HEAD 2> /dev/null && snapcraftctl set-grade "stable" || snapcraftctl set-grade "devel"
git describe --exact-match --tags HEAD 2> /dev/null && snapcraftctl set-grade "stable" || snapcraftctl set-grade "devel"
sed -i "s/undefined/$(git describe --always --long --dirty --tags)/" pkg/version/version.go
# TODO: Add the version into the build itself (currently using ldflags)
# TODO: Server needs /usr/share/dict/words