From 47805d086d02d911dd4326e5942950e7781297d7 Mon Sep 17 00:00:00 2001 From: Hunter Long Date: Mon, 13 Aug 2018 22:59:51 -0700 Subject: [PATCH] makefile with travis --- .travis.yml | 2 +- Makefile | 10 ++++------ 2 files changed, 5 insertions(+), 7 deletions(-) diff --git a/.travis.yml b/.travis.yml index 809cf6cb..663e286d 100644 --- a/.travis.yml +++ b/.travis.yml @@ -18,7 +18,6 @@ services: env: global: - - VERSION=0.37 - DB_HOST=localhost - DB_USER=travis - DB_PASS= @@ -59,6 +58,7 @@ before_script: - make deps script: + - make install - make test - if [[ "$TRAVIS_BRANCH" == "master" ]]; then make coverage; fi diff --git a/Makefile b/Makefile index 32f3d70d..c9341ddd 100644 --- a/Makefile +++ b/Makefile @@ -1,4 +1,5 @@ VERSION=0.37 +GOPATH:=$(GOPATH) GOCMD=`which go` GOBUILD=$(GOCMD) build GOCLEAN=$(GOCMD) clean @@ -8,6 +9,7 @@ GOINSTALL=$(GOCMD) install XGO=GOPATH=$(GOPATH) $(GOPATH)/bin/xgo -go 1.10.x --dest=build BUILDVERSION=-ldflags="-X main.VERSION=$(VERSION)" BINARY_NAME=statup +RICE=$(GOPATH)/bin/rice DOCKER=`which docker` PATH:=/usr/local/bin:$(GOPATH)/bin:$(PATH) @@ -76,12 +78,8 @@ deps: $(GOGET) github.com/karalabe/xgo $(GOGET) github.com/GeertJohan/go.rice $(GOGET) github.com/GeertJohan/go.rice/rice - cd cmd && $(GOGET) - cd notifiers && $(GOGET) - cd handlers && $(GOGET) - cd core && $(GOGET) - cd types && $(GOGET) - cd utils && $(GOGET) + $(GOINSTALL) github.com/GeertJohan/go.rice/rice + $(GOGET) -d ./... clean: rm -rf build