add CircleCI config

This commit is contained in:
ShuheiKubota 2019-11-09 15:30:19 +09:00
parent beaa07bf03
commit 6beeb6f004

30
.circleci/config.yml Normal file
View file

@ -0,0 +1,30 @@
# Golang CircleCI 2.0 configuration file
#
# Check https://circleci.com/docs/2.0/language-go/ for more details
version: 2
jobs:
build:
docker:
- image: circleci/golang:latest
working_directory: /go/src/github.com/shu-go/vvin
environment:
- GOPATH: /home/circleci/go
steps:
- run: echo 'export PATH=${GOPATH}/bin/:${PATH}' >> $BASH_ENV
- checkout
- run: go get -u github.com/Songmu/goxz/cmd/goxz github.com/tcnksm/ghr
- run: goxz -pv $(git describe --abbrev=0) -os "windows" -arch="386 amd64" -build-ldflags "-s -w -X main.Version=$(git describe --abbrev=0)" -include sample.bat
- run: ghr -t $GITHUB_TOKEN -u shu-go --replace $(git describe --abbrev=0) goxz/
workflows:
version: 2
test-build:
jobs:
- build:
filters:
branches:
only:
- master