2016-08-26 08:38:22 +00:00
|
|
|
workspace:
|
|
|
|
base: /go
|
2017-08-27 01:41:52 +00:00
|
|
|
path: src/github.com/drone-plugins/drone-github-release
|
2015-11-23 00:07:57 +00:00
|
|
|
|
2016-08-26 08:38:22 +00:00
|
|
|
pipeline:
|
|
|
|
test:
|
|
|
|
image: golang:1.6
|
|
|
|
environment:
|
|
|
|
- CGO_ENABLED=0
|
|
|
|
commands:
|
|
|
|
- go vet
|
|
|
|
- go test -cover -coverprofile=coverage.out
|
|
|
|
- go build -ldflags "-s -w -X main.build=$DRONE_BUILD_NUMBER" -a -tags netgo
|
|
|
|
|
2017-08-27 01:41:52 +00:00
|
|
|
publish:
|
|
|
|
image: plugins/docker
|
2016-08-26 08:38:22 +00:00
|
|
|
repo: plugins/github-release
|
|
|
|
tags: [ "latest", "1.0", "1" ]
|
2017-08-27 01:41:52 +00:00
|
|
|
secrets: [docker_username, docker_password]
|
2015-11-23 00:07:57 +00:00
|
|
|
when:
|
|
|
|
branch: master
|
2016-08-26 08:38:22 +00:00
|
|
|
event: push
|