Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

travis.yml updates #4

Merged
merged 1 commit into from
Mar 14, 2017
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 21 additions & 6 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,13 +1,10 @@
language: go

go:
- 1.6.x
- 1.7.x
- 1.8
- tip

install:
- go get -t ./...
- go get github.com/golang/lint/golint
- go get github.com/gordonklaus/ineffassign
- go get github.com/opennota/check/cmd/aligncheck
Expand All @@ -16,13 +13,31 @@ install:
- go get github.com/client9/misspell/cmd/misspell

script:
- go get -t ./...
- diff <(echo -n) <(gofmt -s -d .)
- ineffassign .
- go test -race ./...
- go vet -race ./...
- aligncheck .
- structcheck .
- varcheck .
- misspell -error .
# recompile with glide AFTER doing code checks, as errors in dependencies in vendor/ will get caught ¯\_(ツ)_/¯
- go get -v github.com/Masterminds/glide
- cd $GOPATH/src/github.com/Masterminds/glide && git checkout tags/v0.12.3 && go install && cd -
- glide install
- go get ./...

after_success:
- go get github.com/mitchellh/gox
- go get github.com/tcnksm/ghr
- gox -output "dist/{{.OS}}_{{.Arch}}/{{.Dir}}/{{.Dir}}"
# make an dist/OS_ARCH.tar.gz for each, but put the binary in the top level
- for i in $(find dist -mindepth 1 -maxdepth 1 -type d); do tar -czf "$i".tar.gz -C "$i" "."; done

after_script:
- golint ./...
deploy:
provider: script
script: ghr --username bengadbois --token $GITHUB_TOKEN --replace --debug $(git tag -l --contains HEAD) dist/
skip_cleanup: true
on:
tags: true
go: 1.8