Fetch tags before snapcraft build

This commit is contained in:
Zachary Yedidia 2020-02-13 19:57:31 -05:00
parent b2d7c8c5d4
commit 6a0e4b5564
2 changed files with 5 additions and 1 deletions

View file

@ -17,6 +17,10 @@ build:
build-dbg:
go build -ldflags "-s -w $(ADDITIONAL_GO_LINKER_FLAGS)" ./cmd/micro
build-tags:
git fetch --tags
go build -ldflags "-s -w $(GOVARS) $(ADDITIONAL_GO_LINKER_FLAGS)" ./cmd/micro
# Builds micro after building the runtime and checking dependencies
build-all: runtime build

View file

@ -20,6 +20,6 @@ parts:
build-snaps: [go]
build-attributes: [no-patchelf]
override-build: |
make build
make build-tags
mkdir $SNAPCRAFT_PART_INSTALL/bin
mv ./micro $SNAPCRAFT_PART_INSTALL/bin/