Some checks failed
ci / build-test (push) Has been cancelled
ci / docker-build (push) Has been cancelled
Desktop App / Build SPA (push) Has been cancelled
Desktop App / macOS (arm64) (push) Has been cancelled
Desktop App / Linux (amd64) (push) Has been cancelled
Desktop App / Create Release (push) Has been cancelled
99 lines
2.7 KiB
YAML
99 lines
2.7 KiB
YAML
name: Desktop App
|
|
on:
|
|
push:
|
|
branches:
|
|
- main
|
|
tags:
|
|
- 'desktop-*'
|
|
- 'v[0-9]+.[0-9]+.[0-9]*'
|
|
|
|
jobs:
|
|
build-ui:
|
|
name: Build SPA
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- uses: actions/setup-node@v4
|
|
with:
|
|
node-version: '22'
|
|
cache: 'npm'
|
|
cache-dependency-path: web/package-lock.json
|
|
- run: npm ci
|
|
working-directory: web
|
|
- run: npm run build
|
|
working-directory: web
|
|
- uses: actions/upload-artifact@v4
|
|
with:
|
|
name: spa-dist
|
|
path: web/dist/
|
|
|
|
build-macos-arm64:
|
|
name: macOS (arm64)
|
|
needs: build-ui
|
|
runs-on: macos-14
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- uses: actions/download-artifact@v4
|
|
with:
|
|
name: spa-dist
|
|
path: cmd/desktop/frontend/dist/
|
|
- uses: actions/setup-go@v5
|
|
with:
|
|
go-version: '1.26'
|
|
- run: go install github.com/wailsapp/wails/v3/cmd/wails3@latest
|
|
- run: wails3 build -clean
|
|
working-directory: cmd/desktop
|
|
env:
|
|
CGO_ENABLED: 1
|
|
- run: |
|
|
cd cmd/desktop/build/bin
|
|
zip -r oikos-desktop-darwin-arm64.zip oikos-desktop.app
|
|
- uses: actions/upload-artifact@v4
|
|
with:
|
|
name: oikos-desktop-darwin-arm64
|
|
path: cmd/desktop/build/bin/oikos-desktop-darwin-arm64.zip
|
|
|
|
build-linux-amd64:
|
|
name: Linux (amd64)
|
|
needs: build-ui
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- uses: actions/download-artifact@v4
|
|
with:
|
|
name: spa-dist
|
|
path: cmd/desktop/frontend/dist/
|
|
- uses: actions/setup-go@v5
|
|
with:
|
|
go-version: '1.26'
|
|
- run: sudo apt-get update && sudo apt-get install -y libgtk-3-dev libwebkit2gtk-4.1-dev
|
|
- run: go install github.com/wailsapp/wails/v3/cmd/wails3@latest
|
|
- run: wails3 build -clean
|
|
working-directory: cmd/desktop
|
|
env:
|
|
CGO_ENABLED: 1
|
|
- uses: actions/upload-artifact@v4
|
|
with:
|
|
name: oikos-desktop-linux-amd64
|
|
path: cmd/desktop/build/bin/oikos-desktop
|
|
|
|
release:
|
|
name: Create Release
|
|
needs: [build-macos-arm64, build-linux-amd64]
|
|
runs-on: ubuntu-latest
|
|
if: startsWith(github.ref, 'refs/tags/')
|
|
steps:
|
|
- uses: actions/download-artifact@v4
|
|
with:
|
|
name: oikos-desktop-darwin-arm64
|
|
- uses: actions/download-artifact@v4
|
|
with:
|
|
name: oikos-desktop-linux-amd64
|
|
- name: Release
|
|
uses: https://gitea.com/actions/release-action@v1
|
|
with:
|
|
files: |
|
|
oikos-desktop-darwin-arm64.zip
|
|
oikos-desktop-linux-amd64
|
|
api_key: ${{ secrets.GITEA_TOKEN }}
|