-
Notifications
You must be signed in to change notification settings - Fork 5
44 lines (40 loc) · 1017 Bytes
/
release.yaml
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
31
32
33
34
35
36
37
38
39
40
41
42
43
44
name: Build and release
on:
push:
tags:
- "*.*.*"
workflow_dispatch:
jobs:
build-and-release:
strategy:
matrix:
goos: [linux, windows, darwin]
goarch: ["386", amd64, arm64]
exclude:
- goarch: "386"
goos: darwin
- goarch: arm64
goos: windows
include:
- goos: darwin
os: macos-latest
- goos: linux
os: ubuntu-latest
- goos: windows
os: ubuntu-latest
suffix: .exe
runs-on: ${{ matrix.os }}
env:
GOOS: ${{ matrix.goos }}
GOARCH: ${{ matrix.goarch }}
steps:
- uses: actions/checkout@v3
- uses: actions/setup-go@v3
with:
go-version: stable
- name: Build
run: go build -ldflags "-X main.version=$GITHUB_REF_NAME" -o wedl-$GOOS-$GOARCH${{ matrix.suffix }}
- name: Release
uses: softprops/action-gh-release@v1
with:
files: wedl-*-*