Skip to content

Commit 6bdc2c3

Browse files
author
Tomek Rembacz
committed
Do not install update on app quit
1 parent f84a953 commit 6bdc2c3

File tree

3 files changed

+7
-0
lines changed

3 files changed

+7
-0
lines changed

main.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,7 @@ const sendStatusToWindow = (text, type, data) => {
6464
}
6565

6666
// updater events
67+
autoUpdater.autoInstallOnAppQuit = false;
6768
autoUpdater.on('update-available', info => { sendStatusToWindow('Update available', 'available', { ...info }); });
6869
autoUpdater.on('update-not-available', info => { sendStatusToWindow('Update not available.', 'not-available', { ...info }); });
6970
autoUpdater.on('error', err => { sendStatusToWindow('Error in auto-updater. ' + err, 'error'); });

package.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@
1616
"author": "Tomasz Rembacz <mm@mm85.org>",
1717
"license": "MIT",
1818
"build": {
19+
"appId": "com.diff.checker",
20+
"compression": "maximum",
1921
"win": {
2022
"target": "nsis-web",
2123
"icon": "assets/icons/icon.ico"

renderer.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,10 @@ ipcRenderer.on('update-info', function (event, message, type, data) {
3030
progressBar.value = percent;
3131
progressBarValue.textContent = percent + "%";
3232
toggleClass(progressBarDynamic, 'hidden', true);
33+
if (percent === 100) {
34+
progressBarMessage.textContent = "Downloading package..";
35+
toggleClass(progressContainer, 'hidden');
36+
}
3337
break;
3438
case 'downloaded':
3539
progressBarMessage.textContent = message + ' (' + data.version + ')';

0 commit comments

Comments
 (0)