Run installer builds only on demand so CI never waits for a missing runner
All checks were successful
Validate Kaleido Desktop / validate (push) Successful in 1m23s
All checks were successful
Validate Kaleido Desktop / validate (push) Successful in 1m23s
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
parent
835cdad98b
commit
4478d2206d
3 changed files with 48 additions and 44 deletions
44
.forgejo/workflows/build-installers.yml
Normal file
44
.forgejo/workflows/build-installers.yml
Normal file
|
|
@ -0,0 +1,44 @@
|
|||
name: Build Kaleido Desktop installers
|
||||
# Started by hand (Actions, then this workflow, then Run). Each platform needs a runner
|
||||
# with its label; without one the job would wait indefinitely, so this never runs on
|
||||
# push. Releases can instead be built with scripts/build.ps1 and published with
|
||||
# scripts/publish-release.mjs.
|
||||
on:
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
build:
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
include:
|
||||
- os: windows
|
||||
runner: windows-latest
|
||||
# - os: macos
|
||||
# runner: macos-latest
|
||||
# - os: linux
|
||||
# runner: ubuntu-latest
|
||||
runs-on: ${{ matrix.runner }}
|
||||
timeout-minutes: 90
|
||||
steps:
|
||||
- uses: https://data.forgejo.org/actions/checkout@v4.4.0
|
||||
- name: Build (Windows)
|
||||
if: matrix.os == 'windows'
|
||||
shell: pwsh
|
||||
env:
|
||||
TAURI_SIGNING_PRIVATE_KEY: ${{ secrets.TAURI_SIGNING_PRIVATE_KEY }}
|
||||
TAURI_SIGNING_PRIVATE_KEY_PASSWORD: ${{ secrets.TAURI_SIGNING_PRIVATE_KEY_PASSWORD }}
|
||||
run: ./scripts/build.ps1
|
||||
- name: Build (macOS / Linux)
|
||||
if: matrix.os != 'windows'
|
||||
env:
|
||||
TAURI_SIGNING_PRIVATE_KEY: ${{ secrets.TAURI_SIGNING_PRIVATE_KEY }}
|
||||
TAURI_SIGNING_PRIVATE_KEY_PASSWORD: ${{ secrets.TAURI_SIGNING_PRIVATE_KEY_PASSWORD }}
|
||||
run: |
|
||||
sh scripts/fetch-libmpv.sh
|
||||
npm ci
|
||||
npx tauri build
|
||||
- uses: https://data.forgejo.org/actions/upload-artifact@v4
|
||||
with:
|
||||
name: kaleido-${{ matrix.os }}
|
||||
path: src-tauri/target/release/bundle/
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
name: Validate and publish Kaleido Desktop
|
||||
name: Validate Kaleido Desktop
|
||||
on:
|
||||
push:
|
||||
branches: [main]
|
||||
|
|
@ -28,44 +28,3 @@ jobs:
|
|||
curl -fsSL https://sh.rustup.rs | sh -s -- -y --profile minimal
|
||||
. "$HOME/.cargo/env"
|
||||
mkdir -p dist && cargo check --manifest-path src-tauri/Cargo.toml
|
||||
|
||||
# Signed installers per platform for version tags. Each OS needs a runner with
|
||||
# its label; set the repository variable DESKTOP_RUNNERS=true once they exist.
|
||||
# Until then, build with scripts/build.ps1 and attach the files to the release.
|
||||
build:
|
||||
if: startsWith(github.ref, 'refs/tags/v') && vars.DESKTOP_RUNNERS == 'true'
|
||||
needs: validate
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
include:
|
||||
- os: windows
|
||||
runner: windows-latest
|
||||
# - os: macos
|
||||
# runner: macos-latest
|
||||
# - os: linux
|
||||
# runner: ubuntu-latest
|
||||
runs-on: ${{ matrix.runner }}
|
||||
timeout-minutes: 90
|
||||
steps:
|
||||
- uses: https://data.forgejo.org/actions/checkout@v4.4.0
|
||||
- name: Build (Windows)
|
||||
if: matrix.os == 'windows'
|
||||
shell: pwsh
|
||||
env:
|
||||
TAURI_SIGNING_PRIVATE_KEY: ${{ secrets.TAURI_SIGNING_PRIVATE_KEY }}
|
||||
TAURI_SIGNING_PRIVATE_KEY_PASSWORD: ${{ secrets.TAURI_SIGNING_PRIVATE_KEY_PASSWORD }}
|
||||
run: ./scripts/build.ps1
|
||||
- name: Build (macOS / Linux)
|
||||
if: matrix.os != 'windows'
|
||||
env:
|
||||
TAURI_SIGNING_PRIVATE_KEY: ${{ secrets.TAURI_SIGNING_PRIVATE_KEY }}
|
||||
TAURI_SIGNING_PRIVATE_KEY_PASSWORD: ${{ secrets.TAURI_SIGNING_PRIVATE_KEY_PASSWORD }}
|
||||
run: |
|
||||
sh scripts/fetch-libmpv.sh
|
||||
npm ci
|
||||
npx tauri build
|
||||
- uses: https://data.forgejo.org/actions/upload-artifact@v4
|
||||
with:
|
||||
name: kaleido-${{ matrix.os }}
|
||||
path: src-tauri/target/release/bundle/
|
||||
|
|
|
|||
|
|
@ -48,5 +48,6 @@ for that file.
|
|||
|
||||
For macOS and Linux, build on those systems (`scripts/fetch-libmpv.sh`, then
|
||||
`npx tauri build`) and merge their bundles into the same feed with `KALEIDO_BUNDLES`.
|
||||
CI (`.forgejo/workflows/release.yml`) validates every push and builds installers for
|
||||
tags on runners for each enabled platform.
|
||||
CI (`.forgejo/workflows/release.yml`) validates every push and tag. Installers are
|
||||
built locally; `.forgejo/workflows/build-installers.yml` can build them in CI once
|
||||
runners exist for each platform, and only runs when started by hand.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue