hoarder/.travis.yml
2016-06-17 10:12:56 -04:00

31 lines
913 B
YAML

branches:
except:
- /^v[0-9]+\.[0-9]+\.[0-9]+$/
language: go
go:
- 1.6
env:
- DATE=$(date '+%s') TAG="$(echo ${TRAVIS_BRANCH} | sed 's/-prerelease//g')-prerelease"
before_install:
- go get github.com/mitchellh/gox
- go get github.com/tcnksm/ghr
install:
- go get ./cmd/hoarder
# There are no tests at the moment :(
script:
- "true"
after_success:
- "[ \"${TRAVIS_PULL_REQUEST}\" = \"false\" ] && gox -ldflags \"-X 'main.buildVersion=${BUILD_VERSION} (${TRAVIS_COMMIT})' -X 'main.buildDate=${DATE}'\" -output \"dist/hoarder_{{.OS}}_{{.Arch}}\" ./cmd/hoarder || false"
- '[ "${TRAVIS_PULL_REQUEST}" = "false" ] && ghr --username tblyler --token "${GITHUB_TOKEN}" --replace --prerelease --debug "${TAG}" dist/ || false'
notifications:
email:
on_success: change
on_failure: change