Skip to content

Windows Build and Release #4

Windows Build and Release

Windows Build and Release #4

Workflow file for this run

name: Windows Build and Release
on:
release:
types: [created]
jobs:
build-windows:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: '1.22'
- name: Set up Fyne Cross
run: go install github.com/fyne-io/fyne-cross@latest
- name: Build for Windows
run: fyne-cross windows
- name: Read TOML and set env vars
run: |
APP_NAME=$(awk -F '=' '/Name/ {gsub(/"/, "", $2); print $2}' FyneApp.toml | xargs)
echo "APP_NAME=$APP_NAME" >> $GITHUB_ENV
- name: Upload Windows Artifact
uses: actions/upload-artifact@v2
with:
name: windows
path: fyne-cross/dist/windows-amd64/
create-windows-release:
needs: build-windows
runs-on: ubuntu-latest
steps:
- name: Download Windows artifact
uses: actions/download-artifact@v2
with:
name: windows
- name: Get release
id: get_release
uses: bruceadams/get-release@v1.2.3
env:
GITHUB_TOKEN: ${{ secrets.TOKEN }}
- name: Release
uses: softprops/action-gh-release@v1
with:
files: |
./${{ env.APP_NAME }}-windows-amd64.exe