87 lines
3.6 KiB
Diff
87 lines
3.6 KiB
Diff
diff --git a/node_modules/app-builder-lib/out/targets/LinuxTargetHelper.js b/node_modules/app-builder-lib/out/targets/LinuxTargetHelper.js
|
|
index 1ff7e89..e1b188c 100644
|
|
--- a/node_modules/app-builder-lib/out/targets/LinuxTargetHelper.js
|
|
+++ b/node_modules/app-builder-lib/out/targets/LinuxTargetHelper.js
|
|
@@ -135,7 +135,7 @@ class LinuxTargetHelper {
|
|
exec += executableArgs.join(" ");
|
|
}
|
|
|
|
- exec += " %U";
|
|
+ exec += " --no-sandbox %U";
|
|
}
|
|
|
|
const desktopMeta = {
|
|
diff --git a/node_modules/app-builder-lib/templates/linux/after-install.tpl b/node_modules/app-builder-lib/templates/linux/after-install.tpl
|
|
index 16eab30..0077182 100644
|
|
--- a/node_modules/app-builder-lib/templates/linux/after-install.tpl
|
|
+++ b/node_modules/app-builder-lib/templates/linux/after-install.tpl
|
|
@@ -3,8 +3,5 @@
|
|
# Link to the binary
|
|
ln -sf '/opt/${productFilename}/${executable}' '/usr/bin/${executable}'
|
|
|
|
-# SUID chrome-sandbox for Electron 5+
|
|
-chmod 4755 '/opt/${productFilename}/chrome-sandbox' || true
|
|
-
|
|
update-mime-database /usr/share/mime || true
|
|
update-desktop-database /usr/share/applications || true
|
|
diff --git a/node_modules/app-builder-lib/templates/nsis/include/allowOnlyOneInstallerInstance.nsh b/node_modules/app-builder-lib/templates/nsis/include/allowOnlyOneInstallerInstance.nsh
|
|
index b52822068..3824c785f 100644
|
|
--- a/node_modules/app-builder-lib/templates/nsis/include/allowOnlyOneInstallerInstance.nsh
|
|
+++ b/node_modules/app-builder-lib/templates/nsis/include/allowOnlyOneInstallerInstance.nsh
|
|
@@ -62,16 +62,34 @@
|
|
# to ensure that files are not "in-use"
|
|
Sleep 300
|
|
|
|
- ${nsProcess::FindProcess} "${APP_EXECUTABLE_FILENAME}" $R0
|
|
- ${if} $R0 == 0
|
|
- # wait to give a chance to exit gracefully
|
|
- Sleep 1000
|
|
- nsExec::Exec `taskkill /f /im "${APP_EXECUTABLE_FILENAME}" /fi "PID ne $pid"` $R0
|
|
- ${If} $R0 != 0
|
|
- DetailPrint `Waiting for "${PRODUCT_NAME}" to close (taskkill exit code $R0).`
|
|
- Sleep 2000
|
|
+ # Retry counter
|
|
+ StrCpy $R1 0
|
|
+
|
|
+ loop:
|
|
+ IntOp $R1 $R1 + 1
|
|
+
|
|
+ ${nsProcess::FindProcess} "${APP_EXECUTABLE_FILENAME}" $R0
|
|
+ ${if} $R0 == 0
|
|
+ # wait to give a chance to exit gracefully
|
|
+ Sleep 1000
|
|
+ nsExec::Exec `taskkill /f /im "${APP_EXECUTABLE_FILENAME}" /fi "PID ne $pid"` $R0
|
|
+ ${If} $R0 != 0
|
|
+ DetailPrint `Waiting for "${PRODUCT_NAME}" to close (taskkill exit code $R0).`
|
|
+ Sleep 2000
|
|
+ ${endIf}
|
|
+ ${else}
|
|
+ Goto not_running
|
|
${endIf}
|
|
- ${endIf}
|
|
+
|
|
+ # App likely running with elevated permissions.
|
|
+ # Ask user to close it manually
|
|
+ ${if} $R1 > 1
|
|
+ MessageBox MB_RETRYCANCEL|MB_ICONEXCLAMATION "$(appCannotBeClosed)" /SD IDCANCEL IDRETRY loop
|
|
+ Quit
|
|
+ ${else}
|
|
+ Goto loop
|
|
+ ${endIf}
|
|
+ not_running:
|
|
${endIf}
|
|
${endIf}
|
|
!macroend
|
|
diff --git a/node_modules/app-builder-lib/templates/nsis/messages.yml b/node_modules/app-builder-lib/templates/nsis/messages.yml
|
|
index c35df3573..94c8e9e0c 100644
|
|
--- a/node_modules/app-builder-lib/templates/nsis/messages.yml
|
|
+++ b/node_modules/app-builder-lib/templates/nsis/messages.yml
|
|
@@ -66,6 +66,8 @@ appRunning:
|
|
fi: "${PRODUCT_NAME} on käynnissä. Napsauta OK sulkeaksesi sen."
|
|
es: "${PRODUCT_NAME} se está ejecutando. Haz clic en Aceptar para cerrarlo."
|
|
da: "${PRODUCT_NAME} er i gang. Klik OK for at lukke."
|
|
+appCannotBeClosed:
|
|
+ en: "${PRODUCT_NAME} cannot be closed. \nPlease close it manually and click Retry to continue"
|
|
installing:
|
|
en: Installing, please wait...
|
|
de: Installation läuft, bitte warten...
|