This commit is contained in:
Andrew Gundersen 2021-04-15 12:12:41 -05:00
commit 0f18d8fca2
2 changed files with 21 additions and 2 deletions

View file

@ -1,6 +1,6 @@
{ {
"name": "Crimata", "name": "Crimata",
"version": "0.9.4", "version": "0.9.5",
"private": true, "private": true,
"description": "Cross-platform messenger application built with electron, vue3, and TS.", "description": "Cross-platform messenger application built with electron, vue3, and TS.",
"author": { "author": {

View file

@ -30,7 +30,24 @@ const isDev = require('electron-is-dev');
message: 'A new version has been downloaded. Restart to update.' message: 'A new version has been downloaded. Restart to update.'
} }
autoUpdater.on('checking-for-update', () => {
console.log("Checking for update...")
})
autoUpdater.on('update-available', () => {
console.log("Update available.")
})
autoUpdater.on('download-progress', function (progress: any) {
console.log(`Downloading update: ${progress.percent}`)
})
autoUpdater.on('error', (err: any) => {
console.log(String(err))
})
autoUpdater.on('update-downloaded', () => { autoUpdater.on('update-downloaded', () => {
console.log("Update downloaded.")
dialog.showMessageBox(dialogConfig).then((returnValue) => { dialog.showMessageBox(dialogConfig).then((returnValue) => {
if (returnValue.response === 0) autoUpdater.quitAndInstall() if (returnValue.response === 0) autoUpdater.quitAndInstall()
}) })
@ -40,9 +57,11 @@ const isDev = require('electron-is-dev');
setInterval(() => { setInterval(() => {
autoUpdater.checkForUpdatesAndNotify() autoUpdater.checkForUpdatesAndNotify()
}, 120000) }, 5000)
console.log('Starting Crimata electron app.'); console.log('Starting Crimata electron app.');
initApp(isDev); initApp(isDev);
})(); })();
https://gitlab.com/crimata/electron-app/-/package_files/9495519/download