Skip to content

Commit

Permalink
Vendored dependancies using go mod (cloudflare#246)
Browse files Browse the repository at this point in the history
* Vendored dependancys using `go mod`

* Adjust .travis.yml to use vendor correctly

Using info from https://arslan.io/2018/08/26/using-go-modules-with-vendor-support-on-travis-ci/ .
  • Loading branch information
tresni authored and patryk committed Nov 13, 2018
1 parent a6b6cfd commit efe50e3
Show file tree
Hide file tree
Showing 83 changed files with 16,101 additions and 4 deletions.
22 changes: 18 additions & 4 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,14 +1,28 @@
language: go
sudo: false

env:
global:
- MOD_VENDOR=""

matrix:
fast_finish: true
include:
- go: 1.9.x
- go: 1.10.x
- go: 1.11.x
env:
- GO111MODULE=on
- MOD_VENDOR="-mod=vendor"
- go: 1.x
env: LATEST=true
env:
- LATEST=true
- GO111MODULE=on
- MOD_VENDOR="-mod=vendor"
- go: tip
env:
- GO111MODULE=on
- MOD_VENDOR="-mod=vendor"
allow_failures:
- go: tip

Expand All @@ -20,10 +34,10 @@ install:
- # skip

script:
- go get -t -v ./...
- if [ "$GO111MODULE" != "on" ]; then go get -t -v ./... ; else true; fi
- golint -set_exit_status . cmd/flarectl
- go vet $(go list ./... | grep -v /vendor/)
- go test -v -race ./...
- go vet $MOD_VENDOR $(go list $MOD_VENDOR ./... | grep -v /vendor/)
- go test -v -race $MOD_VENDOR ./...
# Only build binaries from the latest Go release.
- if [ "${LATEST}" = "true" ]; then gox -os="linux darwin windows" -arch="amd64" -output="flarectl.{{.OS}}.{{.Arch}}" -ldflags "-X main.Rev=`git rev-parse --short HEAD`" -verbose ./...; fi

Expand Down
13 changes: 13 additions & 0 deletions go.mod
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
module github.com/cloudflare/cloudflare-go

require (
github.com/codegangsta/cli v1.20.0
github.com/davecgh/go-spew v1.1.1 // indirect
github.com/mattn/go-runewidth v0.0.3 // indirect
github.com/olekukonko/tablewriter v0.0.1
github.com/pkg/errors v0.8.0
github.com/pmezard/go-difflib v1.0.0 // indirect
github.com/stretchr/testify v1.2.2
golang.org/x/net v0.0.0-20181029044818-c44066c5c816 // indirect
golang.org/x/time v0.0.0-20180412165947-fbb02b2291d2
)
2 changes: 2 additions & 0 deletions vendor/github.com/codegangsta/cli/.flake8

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions vendor/github.com/codegangsta/cli/.gitignore

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

27 changes: 27 additions & 0 deletions vendor/github.com/codegangsta/cli/.travis.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit efe50e3

Please sign in to comment.