Created
December 13, 2018 17:29
-
-
Save L-P/78b28dfd1fc2c2458c91193af9ea9411 to your computer and use it in GitHub Desktop.
Generic golang command Makefile
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
VERSION=$(shell git describe --tags) | |
BUILDFLAGS=-ldflags '-X main.Version=${VERSION}' | |
EXEC=$(shell basename "$(shell pwd)") | |
all: $(EXEC) | |
$(EXEC): | |
go build ${BUILDFLAGS} | |
.PHONY: $(EXEC) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment