Browse Source

Bump version 4.2.3

qortal-ui-dev
AlphaX-Projects 1 year ago committed by GitHub
parent
commit
c829b11587
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 204
      electron-builder.yml
  2. 41
      electron.js
  3. 4
      package-lock.json
  4. 6
      package.json

204
electron-builder.yml

@ -1,138 +1,66 @@
appId: "org.qortal.QortalUI" appId: "org.qortal.QortalUI"
productName: "Qortal UI" productName: "Qortal UI"
copyright: "Copyright © 2021 - 2023 Qortal" copyright: "Copyright © 2021 - 2023 Qortal"
# forceCodeSigning: false # forceCodeSigning: false
# nodeGypRebuild: false # nodeGypRebuild: false
compression: normal compression: normal
asar: true asar: true
afterPack: "./scripts/afterPack.js" afterPack: "./scripts/afterPack.js"
afterSign: "./scripts/notarize.js" afterSign: "./scripts/notarize.js"
files: files:
- from: "." - from: "."
to: "." to: "."
filter: filter:
- "electron.js" - "electron.js"
- "img/" - "img/"
- "node_modules/" - "node_modules/"
- "server.js" - "server.js"
- "package.json" - "package.json"
- "builtWWW/" - "builtWWW/"
- "config/" - "config/"
- "scripts/" - "scripts/"
- "build/" - "build/"
- "lib/*.js" - "lib/*.js"
- "locales/*.json" - "locales/*.json"
- "splash/" - "splash/"
- "crypto/" - "crypto/"
- "core/" - "core/"
- "plugins/" - "plugins/"
# Mac OS configuration # Linux configuration
mac: linux:
icon: "./img/icons/icns/256x256.icns" icon: "./img/icons/png/"
hardenedRuntime: true category: "Network"
gatekeeperAssess: false packageCategory: "Network"
entitlements: "./build/entitlements.mac.plist" desktop:
entitlementsInherit: "./build/entitlements.mac.plist" StartupWMClass: qortal-ui
category: "public.app-category.utilities" executableArgs:
asarUnpack: "**/*.node" - --no-sandbox
target: target:
- { target: dmg } - "deb"
- { target: pkg } - "AppImage"
# Config for OSX dmg deb:
dmg: artifactName: "Qortal-Setup-arm64.${ext}"
sign: false synopsis: "Qortal UI for Linux"
artifactName: "Qortal-Setup-macOS.${ext}" afterInstall: "./scripts/add-debian-apt-repo.sh"
icon: "./img/icons/icns/256x256.icns" afterRemove: "./scripts/uninstall-debian-conf.sh"
iconSize: 100
contents: appImage:
- x: 130 artifactName: "Qortal-Setup-arm64.${ext}"
y: 220
- x: 410 directories:
y: 220 output: dist
type: "link" buildResources: "./build/"
path: "/Applications"
publish:
# Config for OSX pkg provider: github
pkg: owner: Qortal
artifactName: "Qortal-Setup-macOS.${ext}" repo: qortal-ui
installLocation: "/Applications"
background: {
file: "./build/logo.png",
alignment: "bottomleft",
scaling: "none"
}
allowAnywhere: true
allowCurrentUserHome: true
allowRootDirectory: true
isVersionChecked: true
isRelocatable: false
overwriteAction: "upgrade"
# Windows configuration
win:
legalTrademarks: "QORTAL.ORG"
icon: "./img/icons/ico/256x256.ico"
target:
- "nsis"
# Config for the windows installer
nsis:
artifactName: "Qortal-Setup-win64.${ext}"
oneClick: false
perMachine: false
installerSidebar: "./img/win-installer-sidebar.bmp"
uninstallerSidebar: "./img/win-uninstaller-sidebar.bmp"
runAfterFinish: true
deleteAppDataOnUninstall: true
createDesktopShortcut: true
createStartMenuShortcut: true
# Linux configuration
linux:
icon: "./img/icons/png/"
category: "Network"
packageCategory: "Network"
desktop:
StartupWMClass: qortal-ui
executableArgs:
- --no-sandbox
- '--js-flags="--max-old-space-size=3584"'
target:
- "deb"
- "AppImage"
- "snap"
- "rpm"
deb:
artifactName: "Qortal-Setup-amd64.${ext}"
synopsis: "Qortal UI for Linux"
afterInstall: "./scripts/add-debian-apt-repo.sh"
afterRemove: "./scripts/uninstall-debian-conf.sh"
appImage:
artifactName: "Qortal-Setup-amd64.${ext}"
snap:
artifactName: "Qortal-Setup-amd64.${ext}"
synopsis: "Qortal UI for Linux"
rpm:
artifactName: "Qortal-Setup-amd64.${ext}"
directories:
output: dist
buildResources: "./build/"
publish:
provider: github
owner: Qortal
repo: qortal-ui

41
electron.js

@ -1,4 +1,18 @@
const { app, BrowserWindow, ipcMain, ipcRenderer, Menu, Notification, Tray, nativeImage, dialog, webContents, nativeTheme } = require('electron') const {
app,
BrowserWindow,
ipcMain,
ipcRenderer,
Menu,
Notification,
Tray,
nativeImage,
dialog,
webContents,
nativeTheme,
crashReporter
} = require('electron')
const { autoUpdater } = require('electron-updater') const { autoUpdater } = require('electron-updater')
const server = require('./server.js') const server = require('./server.js')
const log = require('electron-log') const log = require('electron-log')
@ -13,31 +27,42 @@ const fetch = require('node-fetch')
const execFile = require('child_process').execFile const execFile = require('child_process').execFile
const exec = require('child_process').exec const exec = require('child_process').exec
const spawn = require('child_process').spawn const spawn = require('child_process').spawn
const homePath = app.getPath('home')
const downloadPath = app.getPath('downloads')
const store = new Store()
crashReporter.start({
productName: 'Qortal-UI',
uploadToServer: false
})
const myMemory = os.totalmem() const myMemory = os.totalmem()
app.commandLine.appendSwitch('enable-experimental-web-platform-features')
if (myMemory > 16000000000) { if (myMemory > 16000000000) {
app.commandLine.appendSwitch('js-flags', '--max-old-space-size=8192') app.commandLine.appendSwitch('js-flags', '--max-old-space-size=8192')
log.info("Memory Size Is 16GB Using JS Memory Heap Size 8GB") log.info("Memory Size Is 16GB Using JS Memory Heap Size 8GB")
} else if (myMemory > 12000000000) { } else if (myMemory > 12000000000) {
app.commandLine.appendSwitch('js-flags', '--max-old-space-size=6144') app.commandLine.appendSwitch('js-flags', '--max-old-space-size=6144')
log.info("Memory Size Is 12GB Using JS Memory Heap Size 6GB") log.info("Memory Size Is 12GB Using JS Memory Heap Size 6GB")
} else { } else if (myMemory > 7000000000) {
app.commandLine.appendSwitch('js-flags', '--max-old-space-size=4096') app.commandLine.appendSwitch('js-flags', '--max-old-space-size=4096')
log.info("Memory Size Is 8GB Using JS Memory Heap Size 4GB") log.info("Memory Size Is 8GB Using JS Memory Heap Size 4GB")
} else {
app.commandLine.appendSwitch('js-flags', '--max-old-space-size=2048')
log.info("Memory Size Is 4GB Using JS Memory Heap Size 2GB")
} }
app.commandLine.appendSwitch('enable-experimental-web-platform-features')
app.commandLine.appendSwitch('disable-renderer-backgrounding')
app.commandLine.appendSwitch('enable-gpu-rasterization', true)
app.commandLine.appendSwitch('disable-http-cache') app.commandLine.appendSwitch('disable-http-cache')
app.disableHardwareAcceleration() app.commandLine.appendSwitch('log-file', 'qortal-ui.log')
app.commandLine.appendSwitch('enable-logging')
app.enableSandbox() app.enableSandbox()
electronDl() electronDl()
process.env['APP_PATH'] = app.getAppPath() process.env['APP_PATH'] = app.getAppPath()
const homePath = app.getPath('home')
const downloadPath = app.getPath('downloads')
const store = new Store()
autoUpdater.autoDownload = false autoUpdater.autoDownload = false
autoUpdater.autoInstallOnAppQuit = false autoUpdater.autoInstallOnAppQuit = false
autoUpdater.logger = log autoUpdater.logger = log

4
package-lock.json generated

@ -1,12 +1,12 @@
{ {
"name": "qortal-ui", "name": "qortal-ui",
"version": "4.2.2", "version": "4.2.3",
"lockfileVersion": 3, "lockfileVersion": 3,
"requires": true, "requires": true,
"packages": { "packages": {
"": { "": {
"name": "qortal-ui", "name": "qortal-ui",
"version": "4.2.2", "version": "4.2.3",
"license": "GPL-3.0", "license": "GPL-3.0",
"dependencies": { "dependencies": {
"@hapi/hapi": "21.3.2", "@hapi/hapi": "21.3.2",

6
package.json

@ -1,6 +1,6 @@
{ {
"name": "qortal-ui", "name": "qortal-ui",
"version": "4.2.2", "version": "4.2.3",
"description": "Qortal Project - decentralize the world - Data storage, communications, web hosting, decentralized trading, complete infrastructure for the future blockchain-based Internet", "description": "Qortal Project - decentralize the world - Data storage, communications, web hosting, decentralized trading, complete infrastructure for the future blockchain-based Internet",
"keywords": [ "keywords": [
"QORT", "QORT",
@ -19,11 +19,11 @@
"dev": "node server.js", "dev": "node server.js",
"prebuild": "node -p \"'export const UI_VERSION = ' + JSON.stringify(require('./package.json').version) + ';'\" > core/src/redux/app/version.js", "prebuild": "node -p \"'export const UI_VERSION = ' + JSON.stringify(require('./package.json').version) + ';'\" > core/src/redux/app/version.js",
"build-dev": "node --max-old-space-size=8192 build.js", "build-dev": "node --max-old-space-size=8192 build.js",
"build": "NODE_ENV=production node --max-old-space-size=8192 build.js", "build": "NODE_ENV=production node build.js",
"server": "NODE_ENV=production node --max-old-space-size=8192 server.js", "server": "NODE_ENV=production node --max-old-space-size=8192 server.js",
"watch": "node --max-old-space-size=8192 watch.js", "watch": "node --max-old-space-size=8192 watch.js",
"watch-inline": "node --max-old-space-size=8192 watch-inline.js", "watch-inline": "node --max-old-space-size=8192 watch-inline.js",
"start-electron": "NODE_ENV=production electron --js-flags=--max-old-space-size=8192 .", "start-electron": "NODE_ENV=production electron .",
"build-electron": "electron-builder build --publish never", "build-electron": "electron-builder build --publish never",
"deploy-electron": "electron-builder build --win --publish never", "deploy-electron": "electron-builder build --win --publish never",
"release": "NODE_ENV=production electron-builder build --publish never", "release": "NODE_ENV=production electron-builder build --publish never",

Loading…
Cancel
Save