Skip to content

feat: GitHub Actions Workflow #1

feat: GitHub Actions Workflow

feat: GitHub Actions Workflow #1

Workflow file for this run

name: Auto Build Artifacts
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
workflow_dispatch:
jobs:
build:
permissions:
contents: write
strategy:
fail-fast: false
matrix:
platform: [ macos-latest, ubuntu-20.04, windows-latest ]
runs-on: ${{ matrix.platform }}
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Install dependencies (Ubuntu only)
if: matrix.platform == 'ubuntu-20.04'
run: |
sudo apt-get update
sudo apt-get install -y libgtk-3-dev libwebkit2gtk-4.0-dev libappindicator3-dev librsvg2-dev patchelf
- name: Setup rust
uses: dtolnay/rust-toolchain@stable
- name: Setup node
uses: actions/setup-node@v4
with:
node-version: 20
- name: Install PNPM
run: npm i -g pnpm
- name: Install frontend dependencies
run: pnpm install --no-frozen-lockfile
- name: Build tauri app
uses: tauri-apps/tauri-action@v0
- name: Upload Artifact (Windows|EXE)
if: matrix.platform == 'windows-latest'
uses: actions/upload-artifact@v4
with:
name: MinecraftLanguageFileEditor-windows-exe
path: src-tauri/target/release/*.exe
- name: Upload Artifact (Windows|MSI)
if: matrix.platform == 'windows-latest'
uses: actions/upload-artifact@v4
with:
name: MinecraftLanguageFileEditorL-windows-msi
path: src-tauri/target/release/bundle/msi/*.msi
- name: Upload Artifact (Windows|NSIS)
if: matrix.platform == 'windows-latest'
uses: actions/upload-artifact@v4
with:
name: MinecraftLanguageFileEditor-windows-nsis
path: src-tauri/target/release/bundle/nsis/*.exe
- name: Upload Artifact (MacOS|DMG)
if: matrix.platform == 'macos-latest'
uses: actions/upload-artifact@v4
with:
name: MinecraftLanguageFileEditor-macos-dmg
path: src-tauri/target/release/bundle/dmg/*.dmg
- name: Upload Artifact (MacOS|APP)
if: matrix.platform == 'macos-latest'
uses: actions/upload-artifact@v4
with:
name: MinecraftLanguageFileEditor-macos-app
path: src-tauri/target/release/bundle/macos/*.app
- name: Upload Artifact (Ubuntu|DEB)
if: matrix.platform == 'ubuntu-20.04'
uses: actions/upload-artifact@v4
with:
name: MinecraftLanguageFileEditor-linux-deb
path: src-tauri/target/release/bundle/deb/*.deb
- name: Upload Artifact (Ubuntu|AppImage)
if: matrix.platform == 'ubuntu-20.04'
uses: actions/upload-artifact@v4
with:
name: MinecraftLanguageFileEditor-linux-appimage
path: src-tauri/target/release/bundle/appimage