add --version flag

ensure version is injected at build time in Taskfile/makefile
This commit is contained in:
2026-02-16 01:49:28 +00:00
parent fc6ac8fa4e
commit a70fdecdbb
3 changed files with 32 additions and 9 deletions

View File

@@ -6,7 +6,7 @@ BIN_DIR := bin
WINDOWS=$(BIN_DIR)/$(PROGRAM)_windows_amd64.exe
LINUX=$(BIN_DIR)/$(PROGRAM)_linux_amd64
MACOS=$(BIN_DIR)/$(PROGRAM)_darwin_amd64
VERSION=$(shell git log -n 1 --format=%h)
VERSION=$(shell git describe --tags $(shell git rev-list --tags --max-count=1))
.DEFAULT_GOAL := build