Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
67 changes: 67 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
name: Build and Release

on:
push:
branches: [main, feat/build-package]
pull_request:
branches: [main]
workflow_dispatch:

jobs:
build:
strategy:
matrix:
os: [macos-latest, windows-latest]
include:
- os: macos-latest
platform: darwin
- os: windows-latest
platform: win32

runs-on: ${{ matrix.os }}

steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: "20"
cache: "npm"

- name: Install dependencies
run: npm ci

- name: Build Electron app
run: npm run make
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Upload artifacts
uses: actions/upload-artifact@v4
with:
name: ${{ matrix.platform }}-build
path: out/make/**/*

release:
needs: build
runs-on: ubuntu-latest
if: github.ref == 'refs/heads/main'

steps:
- name: Download all artifacts
uses: actions/download-artifact@v4

- name: Create Release
uses: softprops/action-gh-release@v1
with:
tag_name: v${{ github.run_number }}
name: Release ${{ github.run_number }}
draft: true
files: |
**/*.zip
**/*.exe
**/*.dmg
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
36 changes: 8 additions & 28 deletions forge.config.js
Original file line number Diff line number Diff line change
@@ -1,45 +1,25 @@
const { FusesPlugin } = require('@electron-forge/plugin-fuses');
const { FuseV1Options, FuseVersion } = require('@electron/fuses');
const { FusesPlugin } = require("@electron-forge/plugin-fuses");
const { FuseV1Options, FuseVersion } = require("@electron/fuses");

module.exports = {
packagerConfig: {
asar: true,
platform: ["darwin", "win32"],
},
rebuildConfig: {},
makers: [
{
name: '@electron-forge/maker-squirrel',
config: {},
},
{
name: '@electron-forge/maker-zip',
platforms: ['darwin'],
config: {
arch: 'universal'
}
},

{
name: '@electron-forge/maker-deb',
config: {},
},
{
name: '@electron-forge/maker-rpm',
config: {},
name: "@electron-forge/maker-zip",
platforms: ["darwin"],
},
{
name: '@electron-forge/maker-dmg',
platforms: ['darwin'],
config: {
title: 'ilr_file_creator',
arch: 'universal',
overwrite: true
}
name: "@electron-forge/maker-zip",
platforms: ["win32"],
},
],
plugins: [
{
name: '@electron-forge/plugin-auto-unpack-natives',
name: "@electron-forge/plugin-auto-unpack-natives",
config: {},
},
// Fuses are used to enable/disable various Electron functionality
Expand Down
Loading