From f18dc293fd47cf344a1c6ea068acfc91b30ccc7b Mon Sep 17 00:00:00 2001 From: sloum Date: Thu, 12 Nov 2020 20:51:21 -0800 Subject: [PATCH] Removes previous version build system in favor of simple variable --- Makefile | 10 +--------- main.go | 5 ++--- 2 files changed, 3 insertions(+), 12 deletions(-) diff --git a/Makefile b/Makefile index ddbc4bc..cca7657 100644 --- a/Makefile +++ b/Makefile @@ -13,17 +13,9 @@ test : GOCMD := go1.11.13 # %:z - so settle for %z. BUILD_TIME := ${shell date "+%Y-%m-%dT%H:%M%z"} -# If VERSION is empty or not defined use the contents of the VERSION file -VERSION := ${shell git describe --exact-match 2> /dev/null} -ifndef VERSION - VERSION := ${shell cat ./VERSION} -endif - -LDFLAGS := -ldflags "-s -X main.version=${VERSION} -X main.build=${BUILD_TIME}" - .PHONY: build build: - ${GOCMD} build ${LDFLAGS} -o ${BINARY} + ${GOCMD} build -o ${BINARY} .PHONY: install install: install-bin install-man install-desktop clean diff --git a/main.go b/main.go index 82c27da..bee9c41 100644 --- a/main.go +++ b/main.go @@ -35,8 +35,7 @@ import ( "tildegit.org/sloum/bombadillo/gemini" ) -var version string -var build string +var version string = "2.3.3" var bombadillo *client var helplocation string = "gopher://bombadillo.colorfield.space:70/1/user-guide.map" @@ -211,7 +210,7 @@ func main() { flag.Usage = printHelp flag.Parse() if *getVersion { - fmt.Printf("Bombadillo %s - build %s\n", version, build) + fmt.Printf("Bombadillo %s\n", version) os.Exit(0) } args := flag.Args()