add build workflows #1
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build Wails App | |
on: | |
push: | |
tags: | |
- "v*.*.*" | |
jobs: | |
build: | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
os: [windows-latest, ubuntu-22.04] | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
- name: Setup Go | |
uses: actions/setup-go@v5 | |
with: | |
go-version: '1.23' | |
- name: Setup Node.js | |
uses: actions/setup-node@v4 | |
with: | |
node-version: '23' | |
- name: Install dependencies (frontend) | |
run: | | |
cd frontend | |
npm install | |
shell: bash | |
- name: Install dependencies (Linux) | |
if: matrix.os == 'ubuntu-22.04' | |
run: | | |
sudo apt update | |
sudo apt install -qq -y libgtk-3-dev libwebkit2gtk-4.0-dev build-essential | |
- name: Install Wails | |
run: go install github.com/wailsapp/wails/v2/cmd/wails@latest | |
- name: Build Wails App (Windows) | |
if: matrix.os == 'windows-latest' | |
run: wails build -platform windows/amd64 | |
shell: cmd | |
- name: Build Wails App (Linux) | |
if: matrix.os == 'ubuntu-22.04' | |
run: wails build -platform linux/amd64 | |
shell: bash | |
- name: Rename Output (Windows) | |
if: matrix.os == 'windows-latest' | |
run: mv build/bin/noteskeun.exe noteskeun-windows-amd64.exe | |
- name: Rename Output (Linux) | |
if: matrix.os == 'ubuntu-22.04' | |
run: mv build/bin/noteskeun noteskeun-linux-amd64 | |
- name: Upload Artifact to Release (Linux) | |
uses: softprops/action-gh-release@v2 | |
if: matrix.os == 'ubuntu-22.04' | |
with: | |
files: noteskeun-linux-amd64 | |
- name: Upload Artifact to Release (Windows) | |
uses: softprops/action-gh-release@v2 | |
if: matrix.os == 'windows-latest' | |
with: | |
files: noteskeun-windows-amd64.exe |