2021-10-18 08:49:16 +00:00
|
|
|
VERSION=$(shell git describe --tags --abbrev=0)
|
|
|
|
BUILD=$(shell git rev-parse --short HEAD)
|
|
|
|
PROJ := $(shell basename "$(PWD)")
|
|
|
|
HUB=hub.kumoly.io
|
|
|
|
HUB_PROJECT=tools
|
|
|
|
|
|
|
|
LDFLAGS=-ldflags "-X main.Version=${VERSION} -X main.Build=${BUILD} -w"
|
|
|
|
|
|
|
|
default: build
|
|
|
|
|
2021-10-18 15:53:49 +00:00
|
|
|
clean:
|
|
|
|
rm -rf dist
|
|
|
|
|
|
|
|
run: build
|
|
|
|
$(shell cd dist; ./${PROJ} -log configui.log)
|
|
|
|
|
2021-10-18 08:49:16 +00:00
|
|
|
.PHONY: build
|
|
|
|
build:
|
2021-10-20 15:58:14 +00:00
|
|
|
npm run build
|
2021-10-18 08:49:16 +00:00
|
|
|
go build ${LDFLAGS} -o dist/${PROJ}
|