box-o-sand/sylvilagus/Makefile

29 lines
512 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
export GOPATH
test: build
go test $(PACKAGES)
build: deps
go install $(PACKAGES)
deps:
go list -f '{{range .Imports}}{{.}} {{end}}' $(PACKAGES) | xargs go get
fmt:
go fmt $(PACKAGES)
clean:
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