-
Notifications
You must be signed in to change notification settings - Fork 0
54 lines (51 loc) · 1.37 KB
/
ci.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
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
name: CI
permissions:
contents: write
on:
push:
tags:
- "v*"
jobs:
publish:
name: Deploying ${{ matrix.build_target }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
build_target: [macos, linux32, linux64]
include:
- build_target: macos
os: macos-latest
artifact_suffix: macos-x86_64
target_os: darwin
target_arch: amd64
- build_target: linux32
os: ubuntu-latest
artifact_suffix: linux-x86_32
target_arch: 386
target_os: linux
- build_target: linux64
os: ubuntu-latest
artifact_suffix: linux-x86_64
target_arch: amd64
target_os: linux
steps:
- name: Set up access
uses: actions/checkout@v4
- name: Set up Go
uses: actions/setup-go@v4
with:
go-version: '1.22.3'
- name: Build
run: GOOS=${{ matrix.target_os }} GOARCH=${{ matrix.target_arch }} go build
- name: Package
shell: bash
run: |
ls -la
strip lnch
tar czvf lnch-${{ matrix.artifact_suffix }}.tar.gz lnch*
- name: Release
uses: softprops/action-gh-release@v1
with:
files: lnch-${{ matrix.artifact_suffix }}.tar.gz
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}