diff options
| author | Shulhan <ms@kilabit.info> | 2023-05-15 20:24:09 +0700 |
|---|---|---|
| committer | Shulhan <ms@kilabit.info> | 2023-05-15 20:24:09 +0700 |
| commit | d887d308d9afad21a7b6b6385713c6c4ee0b1463 (patch) | |
| tree | 488c83958dab7257c9dbafb55f70eadee6107f70 | |
| parent | 77cef2851517e313d64161faabde7659e8969011 (diff) | |
| download | gotp-d887d308d9afad21a7b6b6385713c6c4ee0b1463.tar.xz | |
all: remove setting Version in Makefile using ldflags
Use the constant Version instead, no need to automate this.
While at it, fix the test coverage HTML output file name.
| -rw-r--r-- | Makefile | 7 | ||||
| -rw-r--r-- | gotp.go | 2 |
2 files changed, 3 insertions, 6 deletions
@@ -3,18 +3,15 @@ .PHONY: all test build install serve-doc -VERSION:=$(shell git describe --tags) -LDFLAGS:=-ldflags "-s -w -X 'git.sr.ht/~shulhan/gotp.Version=$(VERSION)'" - all: test build test: CGO_ENABLED=1 go test -race -failfast -coverprofile=cover.out ./... - go tool cover -html=cover.out -o cover.out + go tool cover -html=cover.out -o cover.html build: mkdir -p _sys/usr/bin/ - go build $(LDFLAGS) -o _sys/usr/bin/ ./cmd/... + go build -o _sys/usr/bin/ ./cmd/... install: build install -D _sys/usr/bin/gotp $(DESTDIR)/usr/bin/gotp @@ -25,7 +25,7 @@ const ( ) var ( - Version = `0.2.3` + Version = `0.3.0-dev` ) // normalizeLabel convert non alpha number, hyphen, underscore, or period |
