Add version to build
All checks were successful
Build and Publish / release (push) Successful in 1m6s

This commit is contained in:
2024-12-31 20:51:04 -05:00
parent 0cc5542ab6
commit 870760443e
29 changed files with 37 additions and 29 deletions

View File

@@ -2,16 +2,18 @@ CMD_NAME := git-project-manager
.PHONY: all test build install docs clean
VERSION ?= development # Default to "development" if VERSION is not set
all: test build install docs
test:
go test -v ./...
build: test
go build -o bin/${CMD_NAME}
go build -ldflags "-X gitea.libretechconsulting.com/rmcguire/git-project-manager/cmd.Version=$(VERSION)" -o bin/${CMD_NAME}
install:
go install -v .
go install -v -ldflags "-X gitea.libretechconsulting.com/rmcguire/git-project-manager/cmd.Version=$(VERSION)" .
docs:
bin/${CMD_NAME} docs md