peco.peco/wercker.yml
Daisuke Maki 9e7d2af44d tweak
2014-06-22 07:39:36 +09:00

49 lines
1.5 KiB
YAML

box: motemen/golang-goxc
build:
steps:
- setup-go-workspace
- script:
name: go get
code: |
go version
go get -t ./...
- script:
name: go test
code: |
go test ./...
- script:
name: goxc build & archive
code: |
goxc -tasks='xc archive' -bc 'linux,!386 windows darwin' -d $WERCKER_OUTPUT_DIR/ -resources-include='README*' -resources-include='Changes'
- script:
name: output release tag
code: |
git describe --tags --exact --match 'v*' > $WERCKER_OUTPUT_DIR/.release_tag || true
deploy:
steps:
- script:
name: restore release tag
code: |
export RELEASE_TAG=$(cat .release_tag)
- motemen/github-create-release:
token: $GITHUB_TOKEN
tag: $RELEASE_TAG
# Try as I might, I can't see any linux_386 builds in my wercker box
# - wercker/github-upload-asset:
# token: $GITHUB_TOKEN
# file: snapshot/peco_linux_386.tar.gz
- wercker/github-upload-asset:
token: $GITHUB_TOKEN
file: snapshot/peco_linux_amd64.tar.gz
- wercker/github-upload-asset:
token: $GITHUB_TOKEN
file: snapshot/peco_darwin_386.zip
- wercker/github-upload-asset:
token: $GITHUB_TOKEN
file: snapshot/peco_darwin_amd64.zip
- wercker/github-upload-asset:
token: $GITHUB_TOKEN
file: snapshot/peco_windows_386.zip
- wercker/github-upload-asset:
token: $GITHUB_TOKEN
file: snapshot/peco_windows_amd64.zip