Skip to content

Commit aaabf97

Browse files
committed
Set correct version on static-build
Right now, we are compiling into a container. Doing this Makefile.main is not getting correct VERSION env var because we dont have TRAVIS_TAG in the container. To avoid this problem, we are setting always our VERSION when make static-build is called. Signed-off-by: Antonio Navarro Perez <[email protected]>
1 parent 07fab5e commit aaabf97

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Makefile

+1-1
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ static-package:
3131
docker rm gitbase-temp
3232

3333
# target used in the Dockerfile to build the static binary
34-
static-build: VERSION ?= $(shell git describe --exact-match --tags 2>/dev/null || "dev-$(git rev-parse --short HEAD)$(test -n "`git status --porcelain`" && echo "-dirty" || true)")
34+
static-build: VERSION = $(shell git describe --exact-match --tags 2>/dev/null || "dev-$(git rev-parse --short HEAD)$(test -n "`git status --porcelain`" && echo "-dirty" || true)")
3535
static-build: LD_FLAGS += -linkmode external -extldflags '-static -lz' -s -w
3636
static-build: GO_BUILD_PATH ?= github.com/src-d/gitbase/...
3737
static-build:

0 commit comments

Comments
 (0)