-
Notifications
You must be signed in to change notification settings - Fork 2
/
.drone.yml
30 lines (29 loc) · 938 Bytes
/
.drone.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
kind: pipeline
type: docker
name: default
steps:
- name: build
image: golang:1.19
commands:
- go test ./...
- GOOS=linux GOARCH=amd64 go build -ldflags "-s -w" -o release/plugin-linux-amd64
- GOOS=linux GOARCH=arm64 go build -ldflags "-s -w" -o release/plugin-linux-arm64
- GOOS=darwin GOARCH=amd64 go build -ldflags "-s -w" -o release/plugin-darwin-amd64
- GOOS=darwin GOARCH=arm64 go build -ldflags "-s -w" -o release/plugin-darwin-arm64
- GOOS=windows GOARCH=amd64 go build -ldflags "-s -w" -o release/plugin-windows-amd64.exe
- name: release amd64 binary
image: plugins/github-release
settings:
files:
- release/plugin-linux-amd64
- release/plugin-linux-arm64
- release/plugin-darwin-amd64
- release/plugin-darwin-arm64
- release/plugin-windows-amd64.exe
api_key:
from_secret: github_token
when:
ref:
- refs/tags/*
depends_on:
- build