Skip to content

Commit bd4a86f

Browse files
committed
Add GitHub Actions release workflow
Add .github/workflows/release.yml to automate releases triggered by tag pushes (v*). The workflow creates a GitHub Release (named "Prasaran <tag>") with a brief body, then builds the Tauri app across a matrix (ubuntu-22.04, windows-latest, macOS aarch64 and x86_64). It sets up Node and Rust, installs Ubuntu native deps when needed, runs npm ci, and uses tauri-apps/tauri-action to produce platform installers/artifacts and attach them to the created release.
1 parent 6b0f2c4 commit bd4a86f

File tree

1 file changed

+87
-0
lines changed

1 file changed

+87
-0
lines changed

.github/workflows/release.yml

Lines changed: 87 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,87 @@
1+
name: Release
2+
3+
on:
4+
push:
5+
tags:
6+
- 'v*'
7+
8+
jobs:
9+
create-release:
10+
runs-on: ubuntu-latest
11+
outputs:
12+
release_id: ${{ steps.create-release.outputs.id }}
13+
release_upload_url: ${{ steps.create-release.outputs.upload_url }}
14+
steps:
15+
- name: Checkout repository
16+
uses: actions/checkout@v4
17+
18+
- name: Create Release
19+
id: create-release
20+
uses: actions/create-release@v1
21+
env:
22+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
23+
with:
24+
tag_name: ${{ github.ref_name }}
25+
release_name: Prasaran ${{ github.ref_name }}
26+
body: |
27+
## Prasaran ${{ github.ref_name }}
28+
29+
Lightweight stream viewer for Facebook Live and YouTube Live.
30+
Designed for OBS Window Capture on low-power hardware.
31+
32+
### Downloads
33+
- **Windows**: `.msi` installer or `.exe` setup
34+
- **macOS**: `.dmg` disk image
35+
- **Linux**: `.deb`, `.rpm`, or `.AppImage`
36+
draft: false
37+
prerelease: false
38+
39+
build-tauri:
40+
needs: create-release
41+
permissions:
42+
contents: write
43+
strategy:
44+
fail-fast: false
45+
matrix:
46+
include:
47+
- platform: ubuntu-22.04
48+
args: ''
49+
- platform: windows-latest
50+
args: ''
51+
- platform: macos-latest
52+
args: '--target aarch64-apple-darwin'
53+
- platform: macos-latest
54+
args: '--target x86_64-apple-darwin'
55+
56+
runs-on: ${{ matrix.platform }}
57+
steps:
58+
- name: Checkout repository
59+
uses: actions/checkout@v4
60+
61+
- name: Setup Node.js
62+
uses: actions/setup-node@v4
63+
with:
64+
node-version: 'lts/*'
65+
cache: 'npm'
66+
67+
- name: Install Rust stable
68+
uses: dtolnay/rust-toolchain@stable
69+
with:
70+
targets: ${{ matrix.platform == 'macos-latest' && 'aarch64-apple-darwin,x86_64-apple-darwin' || '' }}
71+
72+
- name: Install dependencies (Ubuntu)
73+
if: matrix.platform == 'ubuntu-22.04'
74+
run: |
75+
sudo apt-get update
76+
sudo apt-get install -y libwebkit2gtk-4.1-dev libappindicator3-dev librsvg2-dev patchelf
77+
78+
- name: Install frontend dependencies
79+
run: npm ci
80+
81+
- name: Build Tauri app
82+
uses: tauri-apps/tauri-action@v0
83+
env:
84+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
85+
with:
86+
releaseId: ${{ needs.create-release.outputs.release_id }}
87+
args: ${{ matrix.args }}

0 commit comments

Comments
 (0)