Update build.yml

This commit is contained in:
Forbirdden 2025-04-17 16:24:39 +05:00 committed by GitHub
parent e895b91741
commit c69548aa64
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -1,4 +1,4 @@
name: Build/release
name: Release
on:
push:
@ -6,28 +6,35 @@ on:
- v*
pull_request:
branches:
- electron-v3
- main
workflow_dispatch:
jobs:
release:
build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [linux-latest, windows-latest]
os: [ubuntu-latest, macos-latest, windows-latest]
steps:
- name: Check out Git repository
uses: actions/checkout@v4
- name: Checkout code
uses: actions/checkout@v4
- name: Install Node.js
uses: actions/setup-node@v4
with:
node-version: '20.x'
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 20.x
- name: Build/release Electron app
uses: samuelmeuli/action-electron-builder@v1.6.0
with:
github_token: ${{ secrets.github_token }}
release: ${{ startsWith(github.ref, 'refs/tags/v') }}
- name: Install dependencies
run: npm ci
- name: Build app
run: npm run build
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Upload artifacts
uses: actions/upload-artifact@v4
with:
name: builds-${{ matrix.os }}
path: dist/*