-
-
Notifications
You must be signed in to change notification settings - Fork 58
52 lines (42 loc) · 1.52 KB
/
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
# This workflow will...
name: Build
on:
push:
branches: ["master"]
workflow_dispatch:
jobs:
release:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [windows-latest, ubuntu-latest]
steps:
- name: Check out Git repository
uses: actions/checkout@v4
- name: Use Node.js
uses: actions/setup-node@v4
with:
node-version: 22.11.0
cache: "npm"
- run: npm ci
- run: npm run package
# Install and setup Flatpak for Ubuntu
- name: Install flatpak packages (Ubuntu only)
if: matrix.os == 'ubuntu-latest'
run: sudo apt-get install -y flatpak flatpak-builder
- name: Setup flatpak repo (Ubuntu only)
if: matrix.os == 'ubuntu-latest'
run: |
flatpak remote-add --if-not-exists --user \
flathub https://flathub.org/repo/flathub.flatpakrepo
# Build Flatpak package
- name: Build Flatpak (Ubuntu only)
if: matrix.os == 'ubuntu-latest'
run: |
env DEBUG="@malept/flatpak-bundler" \
npx electron-builder --config electron-builder.config.js --publish never --linux flatpak
- name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: release-${{ matrix.os }}
path: release