2013-08-14 22:43:35 +00:00
|
|
|
## Synopsis
|
|
|
|
|
2013-08-29 14:37:51 +00:00
|
|
|
`auto-updater` module is a simple wrap around the Sparkle framework, it
|
|
|
|
provides auto update service for the application.
|
2013-08-14 22:43:35 +00:00
|
|
|
|
2013-08-29 14:37:51 +00:00
|
|
|
Before using this module, you should edit the `Info.plist` following
|
|
|
|
https://github.com/andymatuschak/Sparkle/wiki.
|
2013-08-14 22:43:35 +00:00
|
|
|
|
|
|
|
## Event: will-install-update
|
|
|
|
|
|
|
|
* `event` Event
|
|
|
|
* `version` String
|
|
|
|
* `continueUpdate` Function
|
|
|
|
|
2013-08-29 14:37:51 +00:00
|
|
|
This event is emitted when the update is found and going to be installed.
|
|
|
|
Calling `event.preventDefault()` would pause it, and you can call
|
|
|
|
`continueUpdate` to continue the update.
|
2013-08-14 22:43:35 +00:00
|
|
|
|
|
|
|
## Event: ready-for-update-on-quit
|
|
|
|
|
|
|
|
* `event` Event
|
|
|
|
* `version` String
|
|
|
|
* `quitAndUpdate` Function
|
|
|
|
|
2013-08-29 14:37:51 +00:00
|
|
|
This event is emitted when user chose to delay the update until the quit.
|
|
|
|
Calling `quitAndUpdate()` would quit the application and install the update.
|
2013-08-14 22:43:35 +00:00
|
|
|
|
|
|
|
## autoUpdater.setFeedUrl(url)
|
|
|
|
|
|
|
|
* `url` String
|
|
|
|
|
|
|
|
## autoUpdater.setAutomaticallyChecksForUpdates(flag)
|
|
|
|
|
|
|
|
* `flag` Boolean
|
|
|
|
|
|
|
|
## autoUpdater.setAutomaticallyDownloadsUpdates(flag)
|
|
|
|
|
|
|
|
* `flag` Boolean
|
|
|
|
|
|
|
|
## autoUpdater.checkForUpdates()
|
|
|
|
|
|
|
|
## autoUpdater.checkForUpdatesInBackground()
|