opengoal-launcher/.github/workflows/build.yaml

60 lines
1.3 KiB
YAML
Raw Normal View History

2022-04-15 21:47:14 -04:00
name: Build
on:
push:
branches:
- main
tags:
- v*
pull_request:
branches:
- main
jobs:
build:
name: App
2022-04-15 21:47:14 -04:00
strategy:
fail-fast: false
matrix:
platform: [ubuntu-latest, windows-latest]
runs-on: ${{ matrix.platform }}
steps:
- uses: actions/checkout@v3
2022-04-15 21:47:14 -04:00
- name: Setup Node
uses: actions/setup-node@v3
2022-04-15 21:47:14 -04:00
with:
node-version: 16
cache: npm
2022-04-15 21:47:14 -04:00
- name: Install Rust Stable
2022-04-15 21:47:14 -04:00
uses: actions-rs/toolchain@v1
with:
toolchain: stable
- uses: Swatinem/rust-cache@v2
name: Cache Rust Build
with:
shared-key: tauri-build-${{ matrix.platform }}
workspaces: src-tauri
- name: Install Linux Dependencies
2022-04-15 21:47:14 -04:00
if: matrix.platform == 'ubuntu-latest'
run: |
sudo apt-get update
sudo apt-get install -y libgtk-3-dev webkit2gtk-4.0 libappindicator3-dev librsvg2-dev libglew2.1 patchelf
2022-04-15 21:47:14 -04:00
- name: Install NPM Dependencies and Mock Binaries
2022-04-15 21:47:14 -04:00
run: |
npm ci
2022-04-16 01:08:46 -04:00
npm run mock-bin
2022-04-15 21:47:14 -04:00
npm run build
- uses: tauri-apps/tauri-action@v0
name: Build Tauri App
timeout-minutes: 30
2022-04-15 21:47:14 -04:00
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
TAURI_PRIVATE_KEY: ${{ secrets.TAURI_PRIVATE_KEY }}