29 lines
534 B
Makefile
29 lines
534 B
Makefile
GUIVERSION = $(shell cd ~/go/src/go.wit.com/gui; git describe --tags)
|
|
|
|
all: build
|
|
|
|
vet:
|
|
@#GO111MODULE=off go build
|
|
@GO111MODULE=off go vet -x
|
|
@echo this go library package builds okay
|
|
|
|
build:
|
|
@GO111MODULE=off go build -v -x -o junk \
|
|
-ldflags "-X main.GUIVERSION=${GUIVERSION}" \
|
|
-ldflags "-X go.wit.com/gui.GUIVERSION=${GUIVERSION}"
|
|
./junk
|
|
|
|
goimports:
|
|
goimports -w *.go
|
|
|
|
redomod:
|
|
rm -f go.*
|
|
goimports -w *.go
|
|
GO111MODULE= go mod init
|
|
GO111MODULE= go mod tidy
|
|
|
|
|
|
actual: redomod
|
|
GO111MODULE= go build -x -o junk
|
|
./junk
|