3dgenstudio-mirror/.github/workflows/desktop-build.yml
2026-07-10 11:37:25 +02:00

66 lines
1.9 KiB
YAML

name: Desktop build
# Builds downloadable installers for Windows, macOS and Linux.
# - Push a tag like v1.3.3 to produce artifacts (and, if configured, a Release).
# - Or run manually from the Actions tab (workflow_dispatch).
on:
push:
tags:
- 'v*'
workflow_dispatch:
jobs:
build:
strategy:
fail-fast: false
matrix:
include:
- os: windows-latest
script: dist:win
- os: macos-latest
script: dist:mac
- os: ubuntu-latest
script: dist:linux
runs-on: ${{ matrix.os }}
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up Node
uses: actions/setup-node@v4
with:
node-version: 20
cache: npm
- name: Install dependencies
run: npm ci
# electron-builder rebuilds native modules (sqlite3) for Electron's ABI.
# The hosted runners already include the required build toolchains.
- name: Build installers
run: npm run ${{ matrix.script }}
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# macOS signing/notarization (optional): add these repo secrets to
# produce a signed, notarized .dmg. Without them the build still
# succeeds but the app is unsigned.
# CSC_LINK: ${{ secrets.MAC_CSC_LINK }}
# CSC_KEY_PASSWORD: ${{ secrets.MAC_CSC_KEY_PASSWORD }}
# APPLE_ID: ${{ secrets.APPLE_ID }}
# APPLE_APP_SPECIFIC_PASSWORD: ${{ secrets.APPLE_APP_SPECIFIC_PASSWORD }}
# APPLE_TEAM_ID: ${{ secrets.APPLE_TEAM_ID }}
- name: Upload installers
uses: actions/upload-artifact@v4
with:
name: 3dgenstudio-${{ matrix.os }}
path: |
release/*.exe
release/*.dmg
release/*.zip
release/*.AppImage
release/*.deb
if-no-files-found: warn