添加electorn-updater 依赖项,解决自动更新中静默安装时,闪退的问题

This commit is contained in:
gaoshuaixing
2021-02-26 11:10:49 +08:00
parent 2861796415
commit 95f68f2179
2 changed files with 4 additions and 1 deletions

View File

@@ -33,6 +33,8 @@ exports.setup = function () {
autoUpdater.on('update-downloaded', (info) => {
sendStatusToWindow('Update downloaded');
// quit and update
MAIN_WINDOW.destroy();
app.quit();
autoUpdater.quitAndInstall();
});

View File

@@ -1,6 +1,6 @@
{
"name": "electron-egg",
"version": "1.8.0",
"version": "1.8.1",
"description": "A fast, desktop software development framework",
"main": "main.js",
"softName": "electron-egg",
@@ -112,6 +112,7 @@
"egg-view-ejs": "^2.0.0",
"electron-is": "^3.0.0",
"electron-log": "^4.2.2",
"electron-updater": "^4.3.5",
"get-port": "^5.1.1",
"glob": "^7.1.6",
"lodash": "^4.17.11",