-
Notifications
You must be signed in to change notification settings - Fork 1
/
.travis.yml
52 lines (42 loc) · 1.28 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
sudo: false
branches:
only:
- master
- develop
language: go
go:
- "1.9"
- "1.10"
os:
- linux
# - osx
install: true
git:
depth: 1
before_install:
- if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then sudo add-apt-repository ppa:ethereum/ethereum -y; fi
- if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then sudo apt-get update -q; fi
- if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then sudo apt-get install abigen solc -y; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew update; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew unlink python; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew tap ethereum/ethereum; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew install ethereum; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then travis_wait 60 brew install solidity; fi
before_script:
- GO_FILES=$(find . -iname '*.go' -type f | grep -v /vendor/)
- go get github.com/golang/lint/golint
- go get honnef.co/go/tools/cmd/megacheck
- go get github.com/fzipp/gocyclo
- go get github.com/ethereum/go-ethereum
- go generate ./...
- go get -t -v ./...
script:
- go test -v -race ./...
- go vet ./...
- megacheck ./...
- gocyclo -over 19 $GO_FILES
- golint -set_exit_status $(go list ./...)
cache:
apt: true
# directories:
# - $HOME/Library/Caches/Homebrew