-
Notifications
You must be signed in to change notification settings - Fork 0
106 lines (92 loc) · 2.88 KB
/
snapshot.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
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
name: "Snapshot Build"
on:
workflow_dispatch:
permissions:
contents: write
packages: write
jobs:
build-windows:
name: Build snapshot Windows
runs-on: windows-latest
strategy:
fail-fast: false
matrix:
goos: [ windows ]
goarch: [ amd64, arm64 ]
steps:
- uses: actions/checkout@v4
- uses: ./
name: "Common Setup"
- name: Doctor
run: |
wails doctor
- name: Build
run: |
wails build -clean -platform ${{ matrix.goos }}/${{ matrix.goarch }} -trimpath -ldflags "-s -w -X 'main.GitCommit=${{env.GITHUB_SHA_SHORT}}' -X 'main.Version=${{env.GITHUB_REF_NAME}}'"
mkdir -p ./out
mv ./build/bin/ftb-debug-ui.exe ./out/ftb-debug-${{ matrix.goos }}-${{ matrix.goarch }}.exe
- name: Archive artifacts
uses: actions/upload-artifact@v4
with:
name: ftb-debug-${{ matrix.goos }}-${{ matrix.goarch }}
overwrite: true
path: |
out/*
build-linux:
name: Build snapshot Linux
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
goos: [ linux ]
goarch: [ amd64 ]
steps:
- uses: actions/checkout@v4
- uses: ./
name: "Common Setup"
- name: Linux Setup
run: |
sudo apt-get update
sudo apt-get install -y libgtk-3-dev libwebkit2gtk-4.0-dev
- name: Doctor
run: |
wails doctor
- name: Build
run: |
wails build -clean -platform ${{ matrix.goos }}/${{ matrix.goarch }} -trimpath -ldflags "-s -w -X 'main.GitCommit=$(GITHUB_SHA_SHORT)' -X 'main.Version=$(GITHUB_REF_NAME)'"
mkdir -p ./out
mv ./build/bin/ftb-debug-ui ./out/ftb-debug-${{ matrix.goos }}-${{ matrix.goarch }}
- name: Archive artifacts
uses: actions/upload-artifact@v4
with:
name: ftb-debug-${{ matrix.goos }}-${{ matrix.goarch }}
overwrite: true
path: |
out/*
build-macos:
name: Build snapshot macOS
runs-on: macos-latest
strategy:
fail-fast: false
matrix:
goos: [ darwin ]
goarch: [ amd64, arm64 ]
steps:
- uses: actions/checkout@v4
- uses: ./
name: "Common Setup"
- name: Doctor
run: |
wails doctor
- name: Build
run: |
wails build -clean -platform ${{ matrix.goos }}/${{ matrix.goarch }} -trimpath -ldflags "-s -w -X 'shared.GitCommit=$(GITHUB_SHA_SHORT)' -X 'shared.Version=$(GITHUB_REF_NAME)'"
mkdir -p ./out
cd ./build/bin; zip -r ../../out/ftb-debug-${{ matrix.goos }}-${{ matrix.goarch }}.zip ftb-debug-ui.app
- name: Archive artifacts
uses: actions/upload-artifact@v4
with:
name: ftb-debug-${{ matrix.goos }}-${{ matrix.goarch }}
overwrite: true
path: |
out/*