From 571777ede8ddd3dba0acb9a7d54820a08a6954f1 Mon Sep 17 00:00:00 2001 From: Jared Jacobson Date: Mon, 13 Sep 2021 10:49:11 +1000 Subject: [PATCH] Modify build script --- build.sh | 17 +---------------- 1 file changed, 1 insertion(+), 16 deletions(-) diff --git a/build.sh b/build.sh index 8196fc653..f1f06e676 100755 --- a/build.sh +++ b/build.sh @@ -2,22 +2,7 @@ # Put installed packages into ./bin export GOBIN=$PWD/`dirname $0`/bin - -if [ -d ".git" ] -then - export BUILD=`git rev-parse --short HEAD || ""` - export BRANCH=`(git symbolic-ref --short HEAD | tr -d \/ ) || ""` - if [ "$BRANCH" = master ] - then - export BRANCH="" - fi - - export FLAGS="-X github.com/matrix-org/dendrite/internal.branch=$BRANCH -X github.com/matrix-org/dendrite/internal.build=$BUILD" -else - export FLAGS="" -fi - -mkdir -p bin +export FLAGS="" CGO_ENABLED=1 go build -trimpath -ldflags "$FLAGS" -v -o "bin/" ./cmd/...