Switch to installer to enable auto-updates

This commit is contained in:
Geomitron
2020-05-19 21:28:27 -04:00
parent ac22fb286d
commit 5cd488e5ef
8 changed files with 116 additions and 24 deletions

View File

@@ -32,7 +32,8 @@
<div *ngIf="settingsService.rateLimitDelay < 30" class="ui warning message">
<i class="exclamation circle icon"></i>
<b>Warning:</b> downloading files from Google with a delay less than about 30 seconds will eventually cause Google to
refuse download requests from this program for a few hours. If you can find a way around this limitation, contact Geo#8488 on discord.
refuse download requests from this program for a few hours. This can be avoided by authenticating with your Google account.
(this will be possible in a future update to Bridge)
</div>
<h3 class="ui header">Theme</h3>

View File

@@ -1,5 +1,22 @@
import { Component, OnInit, ChangeDetectorRef } from '@angular/core'
import { ElectronService } from '../../core/services/electron.service'
// import { autoUpdater, UpdateInfo } from 'electron-updater'
// autoUpdater.autoDownload = false
// autoUpdater.on('error', (err) => {})
// autoUpdater.on('checking-for-update', () => {})
// autoUpdater.on('update-available', (info: UpdateInfo) => {})
// autoUpdater.on('update-not-available', () => {})
// autoUpdater.on('download-progress', (progress) => {
// console.log(progress.bytesPerSecond, progress.percent, progress.transferred, progress.total)
// })
// autoUpdater.on('update-downloaded', (info: UpdateInfo) => {})
// autoUpdater.currentVersion // TODO: display this in the corner or on the about page?
// autoUpdater.logger = null
// autoUpdater.checkForUpdates()
// autoUpdater.downloadUpdate()
// autoUpdater.quitAndInstall(false) // By default; autoUpdater installs a downloaded update on the next program restart
// TODO: check for updates on initialization; show a button indicating a new version can be downloaded
@Component({
selector: 'app-toolbar',