ci: ditch fyne-cross #4
This file contains 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 | |
on: push | |
jobs: | |
build: | |
name: "Build Dungeondraft-GoPackager (${{ matrix.target.os }}, ${{ matrix.go-version }})" | |
runs-on: ${{ matrix.target.host || 'ubuntu-latest' }} | |
env: | |
GO111MODULE: on | |
strategy: | |
fail-fast: false | |
matrix: | |
go-version: ["1.23.x"] | |
target: | |
- os: linux | |
- os: windows | |
ext: .exe | |
host: windows-latest | |
- os: darwin | |
host: macos-latest | |
steps: | |
- name: Setup Go environment | |
id: setup-go | |
uses: actions/setup-go@v3 | |
with: | |
go-version: ${{ matrix.go-version }} | |
- name: Checkout code | |
uses: actions/checkout@v3 | |
- name: Cache build artifacts | |
uses: actions/cache@v4 | |
with: | |
path: | | |
~/go/pkg/mod | |
~/.cache/go-build | |
~/.cache/fyne-cross | |
key: ${{ runner.os }}-build-cache-${{ hashFiles('**/go.sum') }} | |
- name: Install Fyne | |
run: go install fyne.io/fyne/v2/cmd/fyne@latest | |
- name: install go deps | |
run: go mod download | |
- name: Build gui | |
run: | | |
fyne package \ | |
${{ matrix.target.args }} \ | |
--src ./cmd/dungeondraft-packager | |
ls -R fyne-cross | |
- name: Build cli | |
run: | | |
go build ./cmd/dungeondraft-packager-cli | |
ls . |