Skip to content

Commit 2556d6b

Browse files
author
Achille Roussel
committed
add release workflow
1 parent cade4ba commit 2556d6b

File tree

1 file changed

+40
-0
lines changed

1 file changed

+40
-0
lines changed

.github/workflows/release.yaml

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
name: Release
2+
3+
on:
4+
push:
5+
tags:
6+
- "v*.*.*"
7+
8+
jobs:
9+
build:
10+
runs-on: ubuntu-latest
11+
steps:
12+
- name: Checkout
13+
uses: actions/checkout@v2
14+
15+
- name: Setup
16+
uses: actions/setup-go@v2
17+
with:
18+
go-version: 1.17
19+
20+
- name: Test
21+
run: |
22+
go mod vendor
23+
GOOS=linux GOARCH=amd64 go build -o kubectl-curl_linux_amd64
24+
GOOS=linux GOARCH=arm64 go build -o kubectl-curl_linux_arm64
25+
GOOS=darwin GOARCH=amd64 go build -o kubectl-curl_darwin_amd64
26+
GOOS=darwin GOARCH=arm64 go build -o kubectl-curl_darwin_arm64
27+
GOOS=windows GOARCH=amd64 go build -o kubectl-curl_windows_amd64.exe
28+
GOOS=windows GOARCH=arm64 go build -o kubectl-curl_windows_arm64.exe
29+
30+
- name: Release
31+
uses: softprops/action-gh-release@v1
32+
with:
33+
files: |
34+
LICENSE
35+
kubectl-curl_linux_amd64
36+
kubectl-curl_linux_arm64
37+
kubectl-curl_darwin_amd64
38+
kubectl-curl_darwin_arm64
39+
kubectl-curl_windows_amd64.exe
40+
kubectl-curl_windows_arm64.exe

0 commit comments

Comments
 (0)