Skip to content
Snippets Groups Projects
Commit 85fd9f92 authored by Angus Lees's avatar Angus Lees
Browse files

Add travis-ci config

parent ec020f8f
No related branches found
No related tags found
No related merge requests found
language: go
go:
- 1.7
- 1.8
install:
- go build -i .
script:
- make test vet
cache:
directories:
- $GOPATH/src
- $GOPATH/pkg
......@@ -2,6 +2,10 @@ VERSION = dev-$(shell date +%FT%T%z)
GO = go
GO_FLAGS = -ldflags="-X main.version=$(VERSION)"
GOFMT = gofmt
# TODO: Simplify this once ./... ignores ./vendor
GO_PACKAGES = ./cmd/... ./utils/...
all: kubecfg
......@@ -9,9 +13,16 @@ kubecfg:
$(GO) build $(GO_FLAGS) .
test:
$(GO) test ./cmd/...
$(GO) test $(GO_PACKAGES)
vet:
$(GO) vet $(GO_PACKAGES)
fmt:
$(GOFMT) -s -w $(shell $(GO) list -f '{{.Dir}}' $(GO_PACKAGES))
clean:
$(RM) ./kubecfg
.PHONY: all test clean kubecfg
.PHONY: all test clean vet fmt
.PHONY: kubecfg
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment