Skip to content

Commit

Permalink
Configure travis CI
Browse files Browse the repository at this point in the history
  • Loading branch information
yugui committed May 9, 2015
1 parent 4747d51 commit 69ea3ce
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 1 deletion.
26 changes: 26 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
language: go

go:
- 1.3
- tip
before_install:
- cd /tmp
- wget https://github.com/google/protobuf/archive/v3.0.0-alpha-2.tar.gz
- tar xvzf v3.0.0-alpha-2.tar.gz
- cd protobuf-3.0.0-alpha-2
- ./autogen.sh
- ./configure
- make
- sudo make install
- go get github.com/golang/lint/golint
- go get golang.org/x/tools/cmd/vet
install:
- go get github.com/gengo/grpc-gateway/protoc-gen-grpc-gateway
script:
- make examples
- test -z "$(git -C $GOPATH/src/github.com/gengo/grpc-gateway status --porcelain)"
- go test -v github.com/gengo/grpc-gateway/protoc-gen-grpc-gateway/... --logtostderr
- golint github.com/gengo/grpc-gateway/protoc-gen-grpc-gateway
- golint github.com/gengo/grpc-gateway/runtime
- go tool vet $GOPATH/src/github.com/gengo/grpc-gateway/protoc-gen-grpc-gateway
- go tool vet $GOPATH/src/github.com/gengo/grpc-gateway/runtime
5 changes: 4 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -48,11 +48,14 @@ $(EXAMPLE_DEPSRCS): $(GO_PLUGIN) $(EXAMPLE_DEPS)
$(EXAMPLE_GWSRCS): $(GATEWAY_PLUGIN) $(EXAMPLES)
protoc -I $(PROTOC_INC_PATH) -I. -I$(GOOGLEAPIS_DIR) --plugin=$(GATEWAY_PLUGIN) --grpc-gateway_out=logtostderr=true,$(PKGMAP):. $(EXAMPLES)

test: $(EXAMPLE_SVCSRCS) $(EXAMPLE_GWSRCS) $(EXAMPLE_DEPSRCS)
examples: $(EXAMPLE_SVCSRCS) $(EXAMPLE_GWSRCS) $(EXAMPLE_DEPSRCS)
test: examples
go test $(PKG)/...

clean distclean:
realclean:
rm -f $(OPTIONS_GO)
rm -f $(EXAMPLE_SVCSRCS) $(EXAMPLE_DEPSRCS)
rm -f $(EXAMPLE_GWSRCS)

.PHONY: generate examples test clean distclean realclean

0 comments on commit 69ea3ce

Please sign in to comment.