Attempting to correct Go project layout
This commit is contained in:
parent
bbb709be31
commit
80e5b8fa5e
@ -1,32 +1,16 @@
|
||||
CLEAN_GOPATH := $(shell echo $(GOPATH) | tr ":" "\n" | grep -v '^$$' | grep -v $(PWD) | tr "\n" ":")
|
||||
GOPATH := $(PWD):$(CLEAN_GOPATH)
|
||||
REPO_BASE := github.com/meatballhat/box-o-sand/sylvilagus/go
|
||||
PACKAGES := \
|
||||
meatballhat.com/sylvilagus-conntest \
|
||||
meatballhat.com/sylvilagus-chapter02-hello-world-consumer \
|
||||
meatballhat.com/sylvilagus-chapter02-hello-world-producer
|
||||
|
||||
export GOPATH
|
||||
|
||||
$(REPO_BASE)/sylvilagus-conntest \
|
||||
$(REPO_BASE)/sylvilagus-chapter02-hello-world-consumer \
|
||||
$(REPO_BASE)/sylvilagus-chapter02-hello-world-producer
|
||||
|
||||
test: build
|
||||
go test $(PACKAGES)
|
||||
go test -x -v $(PACKAGES)
|
||||
|
||||
build: deps
|
||||
go install $(PACKAGES)
|
||||
go install -x $(PACKAGES)
|
||||
|
||||
deps:
|
||||
go get $(PACKAGES)
|
||||
go get -x $(PACKAGES)
|
||||
|
||||
fmt:
|
||||
go fmt $(PACKAGES)
|
||||
|
||||
clean:
|
||||
go clean $(PACKAGES)
|
||||
rm -v bin/*
|
||||
find pkg -name '*.a' -exec rm -v {} \;
|
||||
|
||||
env:
|
||||
@echo GOPATH=$(GOPATH)
|
||||
@echo PACKAGES=$(PACKAGES)
|
||||
|
||||
.PHONY: all clean env fmt
|
||||
.PHONY: test build deps
|
||||
|
1
sylvilagus/go/sylvilagus.go
Normal file
1
sylvilagus/go/sylvilagus.go
Normal file
@ -0,0 +1 @@
|
||||
package sylvilagus
|
Loading…
Reference in New Issue
Block a user