-
Notifications
You must be signed in to change notification settings - Fork 0
83 lines (71 loc) · 2.74 KB
/
test-build.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
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
name: Test Build
on:
workflow_dispatch:
jobs:
build-tauri:
permissions:
contents: write
strategy:
fail-fast: false
matrix:
config:
- os: ubuntu-latest
arch: x86_64
rust_target: x86_64-unknown-linux-gnu
- os: macos-13
arch: x86_64
rust_target: x86_64-apple-darwin
- os: macos-latest
arch: aarch64
rust_target: aarch64-apple-darwin
- os: windows-latest
arch: x86_64
rust_target: x86_64-pc-windows-msvc
runs-on: ${{ matrix.config.os }}
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v2
with:
version: 8.6.0
- uses: actions/setup-node@v3
with:
node-version: 18
cache: 'pnpm'
- name: install Rust nightly
uses: dtolnay/rust-toolchain@nightly
- name: Install dependencies (ubuntu only)
if: matrix.config.os == 'ubuntu-latest'
run: |
sudo apt-get update
sudo apt-get install -y libgtk-3-dev libwebkit2gtk-4.1-dev libappindicator3-dev librsvg2-dev patchelf libx11-dev libxdo-dev libxcb-shape0-dev libxcb-xfixes0-dev
sudo apt-get install -y libunwind-dev libgstreamer1.0-dev libgstreamer-plugins-base1.0-dev libgstreamer-plugins-bad1.0-dev gstreamer1.0-plugins-base gstreamer1.0-plugins-good gstreamer1.0-plugins-bad gstreamer1.0-plugins-ugly gstreamer1.0-libav gstreamer1.0-tools gstreamer1.0-x gstreamer1.0-alsa gstreamer1.0-gl gstreamer1.0-gtk3 gstreamer1.0-qt5 gstreamer1.0-pulseaudio
- name: Install dependencies (mac only)
if: matrix.config.os == 'macos-latest'
run: |
rustup target add aarch64-apple-darwin
- name: install frontend dependencies
run: pnpm install --no-frozen-lockfile # change this to npm or pnpm depending on which one you use
- name: Build Tauri App (MacOS Universal)
uses: tauri-apps/tauri-action@dev
if: matrix.config.os == 'macos-latest'
id: tauri-action-mac
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
releaseId: test-release
args: --target universal-apple-darwin
- name: Build Tauri App
uses: tauri-apps/tauri-action@dev
if: matrix.config.os != 'macos-latest'
id: tauri-action
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
releaseId: test-release
- name: Upload artifact
uses: actions/upload-artifact@v3
with:
name: tauri-client-app-artifact
path: |
${{ fromJSON(steps.tauri-action-mac.outputs.artifactPaths)[0] }}
${{ fromJSON(steps.tauri-action.outputs.artifactPaths)[0] }}