summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile10
1 files changed, 9 insertions, 1 deletions
diff --git a/Makefile b/Makefile
index 85844a9..d94a15f 100644
--- a/Makefile
+++ b/Makefile
@@ -1,5 +1,13 @@
+VERSION = $(shell git describe --tags)
+
all:
- GO111MODULE=off go build -v -x
+ GO111MODULE=off go build -v -x \
+ -ldflags "-X main.VERSION=${VERSION}"
+ ./helloworld
+
+install:
+ GO111MODULE=off go install -v -x \
+ -ldflags "-X main.VERSION=${VERSION}"
./helloworld
gocui: