Skip to content

version update

version update #9

Workflow file for this run

name: Release
on:
push:
tags:
- "v*"
workflow_dispatch:
jobs:
publish-tauri:
permissions:
contents: write
strategy:
fail-fast: false
matrix:
include:
- platform: "macos-latest" # for Arm based macs (M1 and above).
args: "--target aarch64-apple-darwin"
- platform: "macos-latest" # for Intel based macs.
args: "--target x86_64-apple-darwin"
- platform: "ubuntu-22.04" # Ubuntu x86_64
args: ""
- platform: "windows-latest" # Windows x86_64
args: "--target x86_64-pc-windows-msvc"
runs-on: ${{ matrix.platform }}
steps:
- uses: actions/checkout@v4
- name: setup node
uses: actions/setup-node@v4
with:
node-version: lts/*
- name: Rust cache
uses: swatinem/rust-cache@v2
- name: install Rust stable
uses: dtolnay/rust-toolchain@stable
with:
# Those targets are only used on macos runners so it's in an `if` to slightly speed up windows and linux builds.
targets: ${{ matrix.platform == 'macos-latest' && 'aarch64-apple-darwin,x86_64-apple-darwin' || '' }}
- name: install frontend dependencies
run: npm install
working-directory: ./desktop
# Install OpenCL for Windows
- name: Install OpenCL
run: vcpkg.exe install opencl
if: matrix.platform == 'windows-latest'
# Run pre build on macOS / Linux
- name: Run pre_build.sh on ${{ matrix.platform }}
run: C:\msys64\msys2_shell.cmd -defterm -use-full-path -no-start -ucrt64 -here -c "scripts/pre_build.sh"
if: matrix.platform == 'windows-latest'
# Run pre build on Linux / MacOS
- name: Run pre_build.sh on ${{ matrix.platform }}
run: ./scripts/pre_build.sh
if: matrix.platform == 'ubuntu-22.04' || matrix.platform == 'macos-latest'
# Install tauri cli with patch on macOS aarch64
- name: Install custom tauri cli
run: cargo install tauri-cli --git https://github.com/thewh1teagle/tauri --branch temp-macos-signing-without-runtime-config --debug
if: matrix.args == '--target aarch64-apple-darwin'
- name: Build for aarch64
uses: tauri-apps/tauri-action@v0
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
TAURI_SIGNING_PRIVATE_KEY: ${{ secrets.TAURI_PRIVATE_KEY }}
TAURI_SIGNING_PRIVATE_KEY_PASSWORD: ${{ secrets.TAURI_KEY_PASSWORD }}
with:
tagName: v__VERSION__ # the action automatically replaces __VERSION__ with the app version.
releaseName: "v__VERSION__"
releaseBody: "See the assets to download this version and install."
releaseDraft: true
prerelease: false
args: ${{ matrix.args }}
projectPath: './desktop'
tauriScript: cargo tauri
if: matrix.args == '--target aarch64-apple-darwin'
- name: Build
uses: tauri-apps/tauri-action@v0
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
TAURI_SIGNING_PRIVATE_KEY: ${{ secrets.TAURI_PRIVATE_KEY }}
TAURI_SIGNING_PRIVATE_KEY_PASSWORD: ${{ secrets.TAURI_KEY_PASSWORD }}
with:
tagName: v__VERSION__ # the action automatically replaces __VERSION__ with the app version.
releaseName: "v__VERSION__"
releaseBody: "See the assets to download this version and install."
releaseDraft: true
prerelease: false
args: ${{ matrix.args }}
projectPath: './desktop'
if: matrix.args != '--target aarch64-apple-darwin'