-
Notifications
You must be signed in to change notification settings - Fork 2
73 lines (61 loc) · 2 KB
/
dist-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
name: Snapshot Builds
on:
push:
branches:
- main
jobs:
build-snapshot:
strategy:
fail-fast: false
matrix:
# using oldest available version of ubuntu for compatibility reasons
# see: https://tauri.app/v1/guides/building/linux
os: [windows-latest, ubuntu-20.04]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout Repository
uses: actions/checkout@v4
- name: Get Revision Hash
shell: bash
run: echo "SHA_SHORT=$(git rev-parse --short HEAD)" >> $GITHUB_ENV
- name: Set Up Node.JS Environment
uses: actions/setup-node@master
with:
node-version: 20
- name: Set Up PNPM
uses: pnpm/action-setup@v3
with:
version: ^9.4.0
run_install: false
- name: Get PNPM Store Directory
id: pnpm-cache
shell: bash
run: |
echo "STORE_PATH=$(pnpm store path)" >> $GITHUB_OUTPUT
- name: Setup PNPM Cache
uses: actions/cache@v4
with:
path: ${{ steps.pnpm-cache.outputs.STORE_PATH }}
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
restore-keys: |
${{ runner.os }}-pnpm-store-
- name: Install Dependencies from NPM
run: pnpm i
- name: Compile Application (Windows)
if: matrix.os == 'windows-latest'
run: pnpm build:win
- name: Upload .msi Snapshot (Windows)
if: matrix.os == 'windows-latest'
uses: actions/upload-artifact@v4
with:
name: SNAPSHOT-${{ env.SHA_SHORT }}-vincent-windows-x64
path: dist/*.msi
- name: Compile Application (Linux)
if: matrix.os == 'ubuntu-20.04'
run: pnpm build:linux
- name: Upload .AppImage Snapshot (Linux)
if: matrix.os == 'ubuntu-20.04'
uses: actions/upload-artifact@v4
with:
name: SNAPSHOT-${{ env.SHA_SHORT }}-vincent-linux-appimage-x64
path: dist/*.AppImage