Flatten autoupdater hooks
This commit is contained in:
@ -5,6 +5,7 @@ on:
|
||||
push:
|
||||
branches:
|
||||
- main
|
||||
- pierremtb/update-download-progress-flatten
|
||||
release:
|
||||
types: [published]
|
||||
schedule:
|
||||
|
||||
23
src/main.ts
23
src/main.ts
@ -268,19 +268,20 @@ app.on('ready', () => {
|
||||
|
||||
autoUpdater.on('update-available', (info) => {
|
||||
console.log('update-available', info)
|
||||
autoUpdater.prependOnceListener('download-progress', (progress) => {
|
||||
// For now, we'll send the version to the loading toast start.
|
||||
console.log('update-download-start', {
|
||||
version: info.version,
|
||||
})
|
||||
mainWindow?.webContents.send('update-download-start', progress)
|
||||
})
|
||||
})
|
||||
|
||||
autoUpdater.on('download-progress', (progress) => {
|
||||
// TODO: in a future PR (https://github.com/KittyCAD/modeling-app/issues/3994)
|
||||
// send this data to mainWindow to show a progress bar for the download.
|
||||
console.log('download-progress', progress)
|
||||
autoUpdater.prependOnceListener('download-progress', (progress) => {
|
||||
// For now, we'll send the version to the loading toast start.
|
||||
console.log('update-download-start', {
|
||||
version: '',
|
||||
})
|
||||
mainWindow?.webContents.send('update-download-start', progress)
|
||||
})
|
||||
|
||||
autoUpdater.on('download-progress', (progress) => {
|
||||
// TODO: in a future PR (https://github.com/KittyCAD/modeling-app/issues/3994)
|
||||
// send this data to mainWindow to show a progress bar for the download.
|
||||
console.log('download-progress', progress)
|
||||
})
|
||||
|
||||
autoUpdater.on('update-downloaded', (info) => {
|
||||
|
||||
Reference in New Issue
Block a user