Skip to content

release: v0.2.5

release: v0.2.5 #122

Workflow file for this run

name: Build and Release
on:
push:
# branches:
# - dev-workflow
tags:
- "v*.*.*"
jobs:
build:
strategy:
fail-fast: false
matrix:
include:
- platform: "macos-latest"
target: aarch64-apple-darwin
architecture: aarch64
- platform: "macos-13"
target: x86_64-apple-darwin
architecture: x86_64
- platform: windows-latest
target: x86_64-pc-windows-msvc
architecture: x64
- platform: "ubuntu-22.04"
target: x86_64-unknown-linux-gnu
architecture: x86_64
runs-on: ${{ matrix.platform }}
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: setup rust
uses: dtolnay/rust-toolchain@stable
with:
targets: ${{ matrix.target }}
- run: rustup target add ${{ matrix.target }}
- uses: pnpm/action-setup@v4
name: Install pnpm
with:
version: 9
run_install: false
- name: Install Node.js
uses: actions/setup-node@v4
with:
node-version: 20
cache: "pnpm"
- name: install dependencies (ubuntu only)
if: matrix.platform == 'ubuntu-22.04'
run: |
sudo apt update
sudo apt install -y --no-install-recommends clang curl pkg-config libgtk-3-dev xz-utils libxv-dev libwebkit2gtk-4.1-dev \
libavcodec-dev \
libavdevice-dev \
libavfilter-dev \
libavformat-dev \
libavutil-dev \
- name: install dependencies (macos only)
if: matrix.platform == 'macos-latest' || matrix.platform == 'macos-13'
run: |
brew install pkg-config ffmpeg
- name: install dependencies (windows only)
env:
FFMPEG_VERSION: "latest"
FFMPEG_DOWNLOAD_URL: https://www.gyan.dev/ffmpeg/builds/ffmpeg-release-full-shared.7z
if: matrix.platform == 'windows-latest'
run: |
$VCINSTALLDIR = $(& "${env:ProgramFiles(x86)}\Microsoft Visual Studio\Installer\vswhere.exe" -latest -property installationPath)
Add-Content $env:GITHUB_ENV "LIBCLANG_PATH=${VCINSTALLDIR}\VC\Tools\LLVM\x64\bin`n"
Invoke-WebRequest "${env:FFMPEG_DOWNLOAD_URL}" -OutFile ffmpeg-release-full-shared.7z
7z x ffmpeg-release-full-shared.7z
mkdir ffmpeg
mv ffmpeg-*/* ffmpeg/
Add-Content $env:GITHUB_ENV "FFMPEG_DIR=${pwd}\ffmpeg`n"
Add-Content $env:GITHUB_PATH "${pwd}\ffmpeg\bin`n"
- name: install frontend dependencies
run: pnpm install
- name: Build Tauri App
run: |
pnpm tauri build --target ${{ matrix.target }}
- name: Upload build artifacts
uses: actions/upload-artifact@v4
with:
name: ${{ runner.os }}-${{ matrix.platform }}-artifacts
path: |
target/${{ matrix.target }}/release/bundle/dmg/*.dmg
target/${{ matrix.target }}/release/bundle/msi/*.msi
target/${{ matrix.target }}/release/bundle/appimage/*.AppImage
target/${{ matrix.target }}/release/bundle/deb/*.deb
release:
needs: build
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- name: Download artifacts
uses: actions/download-artifact@v4
with:
path: dist
- name: Display structure of downloaded files
run: ls -R dist/
- uses: ncipollo/release-action@v1
with:
artifacts: |
dist/**/dmg/*.dmg
dist/**/msi/*.msi
dist/**/appimage/*.AppImage