box-o-sand/sylvilagus/go/Makefile

33 lines
615 B
Makefile
Raw Normal View History

CLEAN_GOPATH := $(shell echo $(GOPATH) | tr ":" "\n" | grep -v '^$$' | grep -v $(PWD) | tr "\n" ":")
GOPATH := $(PWD):$(CLEAN_GOPATH)
PACKAGES := \
meatballhat.com/sylvilagus-conntest \
meatballhat.com/sylvilagus-chapter02-hello-world-consumer \
meatballhat.com/sylvilagus-chapter02-hello-world-producer
export GOPATH
test: build
go test $(PACKAGES)
build: deps
go install $(PACKAGES)
deps:
2012-11-13 00:05:13 +00:00
go get $(PACKAGES)
fmt:
go fmt $(PACKAGES)
clean:
2012-11-22 19:07:11 +00:00
go clean $(PACKAGES)
rm -v bin/*
2012-11-11 02:24:16 +00:00
find pkg -name '*.a' -exec rm -v {} \;
env:
@echo GOPATH=$(GOPATH)
@echo PACKAGES=$(PACKAGES)
.PHONY: all clean env fmt