1
0
Fork 0

Makefile: set version from git tag

This commit is contained in:
Henrik Hautakoski 2025-10-16 22:46:42 +02:00
parent d3fea6ec4b
commit 9786dc2c53

View file

@ -1,5 +1,6 @@
GO=go GO=go
GOLDFLAGS=-v -s -w VERSION=$(shell git describe --always --tags --dirty --match="v*")
GOLDFLAGS=-v -s -w -X main.version="$(VERSION)"
GOBUILDFLAGS=-v -p $(shell nproc) -ldflags="$(GOLDFLAGS)" GOBUILDFLAGS=-v -p $(shell nproc) -ldflags="$(GOLDFLAGS)"
.PHONY: build test .PHONY: build test