language: go
dist: trusty

go:
  - 1.11.x
  - 1.12.x

env:
  matrix:
  - TARGET=amd64
  - TARGET=arm
  - TARGET=arm64
  - TARGET=ppc64le
  - TARGET=s390x

matrix:
  fast_finish: true

install:
 - go get golang.org/x/tools/cmd/cover
 - go get github.com/modocache/gover
 - go get github.com/mattn/goveralls
 - go get -t ./...

script:
 - >
    if [ "${TARGET}" == "amd64" ]; then
      GOARCH="${TARGET}" ./test.sh;
    else
      GOARCH="${TARGET}" go list ./... | xargs -n1 go build -v -o /dev/null
    fi

notifications:
  email: false

git:
  depth: 9999999
