Skip to content

Update .goreleaser.yaml to exclude Linux ARM64 builds and clarify rel… #3

Update .goreleaser.yaml to exclude Linux ARM64 builds and clarify rel…

Update .goreleaser.yaml to exclude Linux ARM64 builds and clarify rel… #3

Workflow file for this run

name: Release
on:
push:
tags:
- 'v*' # Triggers on version tags like v1.0.0, v1.2.3, etc.
workflow_dispatch: # Allows manual triggering from GitHub UI
inputs:
version:
description: 'Version tag (e.g., v1.0.0)'
required: true
type: string
permissions:
contents: write # Required for creating releases
id-token: write # Required for OIDC authentication (if using)
jobs:
release:
name: Build and Release
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v6
with:
fetch-depth: 0 # Required for changelog generation
- name: Set up Go
uses: actions/setup-go@v6
with:
go-version: '1.25.5'
cache-dependency-path: go.sum
- name: Set up Node.js
uses: actions/setup-node@v6
with:
node-version: '20'
cache: 'npm'
cache-dependency-path: frontend/package-lock.json
- name: Build frontend
run: |
cd frontend
npm ci
npm run build
cd ..
- name: Install Wails CLI
run: |
go install github.com/wailsapp/wails/v2/cmd/wails@latest
- name: Install system dependencies (Linux)
if: runner.os == 'Linux'
run: |
sudo apt-get update
sudo apt-get install -y libgtk-3-dev libwebkit2gtk-4.1-dev libappindicator3-dev librsvg2-dev patchelf
- name: Install system dependencies (macOS)
if: runner.os == 'Darwin'
run: |
brew install webkit2gtk
- name: Install Goreleaser
uses: goreleaser/goreleaser-action@v6
with:
version: latest
install-only: true
- name: Set version from tag
id: version
env:
EVENT_NAME: ${{ github.event_name }}
INPUT_VERSION: ${{ github.event.inputs.version }}
GITHUB_REF: ${{ github.ref }}
run: |
if [ "$EVENT_NAME" == "workflow_dispatch" ]; then
VERSION="$INPUT_VERSION"
git tag -a "$VERSION" -m "Release $VERSION" || true
git push origin "$VERSION" || true
else
VERSION="${GITHUB_REF#refs/tags/}"
fi
echo "version=$VERSION" >> $GITHUB_OUTPUT
echo "Version: $VERSION"
- name: Set environment variables
env:
GITHUB_REPOSITORY: ${{ github.repository }}
run: |
echo "GITHUB_OWNER=${GITHUB_REPOSITORY%/*}" >> $GITHUB_ENV
echo "GITHUB_REPO_NAME=${GITHUB_REPOSITORY#*/}" >> $GITHUB_ENV
- name: Run Goreleaser
uses: goreleaser/goreleaser-action@v6
with:
version: latest
args: release --clean
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GITHUB_OWNER: ${{ env.GITHUB_OWNER }}
GITHUB_REPO_NAME: ${{ env.GITHUB_REPO_NAME }}
# Uncomment and set these when you have code signing certificates
# APPLE_CERTIFICATE: ${{ secrets.APPLE_CERTIFICATE }}
# APPLE_CERTIFICATE_PASSWORD: ${{ secrets.APPLE_CERTIFICATE_PASSWORD }}
# APPLE_TEAM_ID: ${{ secrets.APPLE_TEAM_ID }}
# WINDOWS_CERTIFICATE: ${{ secrets.WINDOWS_CERTIFICATE }}
# WINDOWS_CERTIFICATE_PASSWORD: ${{ secrets.WINDOWS_CERTIFICATE_PASSWORD }}
# WINDOWS_CERTIFICATE_THUMBPRINT: ${{ secrets.WINDOWS_CERTIFICATE_THUMBPRINT }}