From e5af65a1aa1ed57ae76194b837ad6db2e00dbd33 Mon Sep 17 00:00:00 2001 From: NAmorim Date: Tue, 12 Oct 2021 16:27:53 +0100 Subject: [PATCH] Enable MacOS build Small corrections Enable CI releases --- .github/workflows/release_build.yml | 6 +++--- Platform/Client/taskManagerServer.js | 2 +- electron-wrapper.js | 8 ++++---- 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/.github/workflows/release_build.yml b/.github/workflows/release_build.yml index 7d3550a2fc..cbd424a2b9 100644 --- a/.github/workflows/release_build.yml +++ b/.github/workflows/release_build.yml @@ -11,16 +11,16 @@ jobs: strategy: matrix: - os: [windows-latest] + os: [windows-latest, macos-latest] steps: - name: Check out Git repository - uses: actions/checkout@v1 + uses: actions/checkout@v2 - name: Install Node.js, NPM and Yarn uses: actions/setup-node@v1 with: - node-version: 16 + node-version: 14 - name: Build/release Electron app uses: samuelmeuli/action-electron-builder@v1 diff --git a/Platform/Client/taskManagerServer.js b/Platform/Client/taskManagerServer.js index b0e3b61614..c645e497ba 100644 --- a/Platform/Client/taskManagerServer.js +++ b/Platform/Client/taskManagerServer.js @@ -63,7 +63,7 @@ //console.log('[INFO] Client -> Task Manager Server -> runTask -> Task Name = ' + message.event.taskName) //console.log('[INFO] Client -> Task Manager Server -> runTask -> Task Id = ' + message.event.taskId) - let path = './TaskServerRoot.js' + let path = global.env.BASE_PATH + '/TaskServerRoot.js' /* Workarround to avoid having the same debug port at the forked process which makes it crash. */ for (let i = 0; i < process.execArgv.length; i++) { diff --git a/electron-wrapper.js b/electron-wrapper.js index c1e3da4246..73aa9fe088 100644 --- a/electron-wrapper.js +++ b/electron-wrapper.js @@ -3,7 +3,7 @@ const {app, Menu, BrowserWindow} = require('electron') const path = require('path') const fs = require('fs') // To check for update on Github repo -const {autoUpdater} = require("electron-updater"); +const {autoUpdater} = require("electron-updater") // Enable non contribution mode (test) process.env.SA_MODE = 'gitDisable' @@ -23,11 +23,11 @@ run() function run() { if (process.env.PORTABLE_EXECUTABLE_DIR) { - process.env.PORTABLE_USER_DOCUMENTS = app.getPath("documents") - } + process.env.PORTABLE_USER_DOCUMENTS = app.getPath("userData") + } const { fork } = require('child_process') - fork(path.join(__dirname, './PlatformRoot.js'), ["noBrowser"]) + fork(path.join(__dirname, '/PlatformRoot.js'), ["noBrowser"]) server_ready = true if (app_ready) open()