mirror of
https://github.com/Chia-Network/chia-blockchain.git
synced 2026-08-24 02:24:23 -05:00
[CHIA-4294] Fixed Electron source install not working (#21105)
Fixed Electron source install not working
This commit is contained in:
@@ -33,6 +33,16 @@ try {
|
||||
$ErrorActionPreference = "SilentlyContinue"
|
||||
npm ci --loglevel=error
|
||||
npm audit fix
|
||||
|
||||
# Work around Electron's postinstall being silently skipped in the workspaces/
|
||||
# hoisted install, which leaves node_modules/electron present but without its
|
||||
# platform binary (no path.txt). Re-run Electron's own installer if needed.
|
||||
# Otherwise 'npm run electron' fails with "Electron failed to install correctly".
|
||||
if (-not (Test-Path "node_modules/electron/path.txt")) {
|
||||
Write-Output "Electron binary is missing; running Electron's install script."
|
||||
node node_modules/electron/install.js
|
||||
}
|
||||
|
||||
npm run build
|
||||
py ..\installhelper.py
|
||||
|
||||
|
||||
@@ -105,6 +105,16 @@ if [ ! "$CI" ]; then
|
||||
|
||||
npm ci
|
||||
npm audit fix || true
|
||||
|
||||
# Work around Electron's postinstall being silently skipped in the workspaces/
|
||||
# hoisted install, which leaves node_modules/electron present but without its
|
||||
# platform binary (no path.txt). Re-run Electron's own installer if needed.
|
||||
# Otherwise `npm run electron` fails with "Electron failed to install correctly".
|
||||
if [ ! -f node_modules/electron/path.txt ]; then
|
||||
echo "Electron binary is missing; running Electron's install script."
|
||||
node node_modules/electron/install.js
|
||||
fi
|
||||
|
||||
npm run build
|
||||
|
||||
# Set modified output of `chia version` to version property of GUI's package.json
|
||||
|
||||
Reference in New Issue
Block a user