Updated Auto Update Internals (markdown)
parent
d002a31253
commit
702185d980
|
@ -14,10 +14,11 @@ Stable builds will default to the `stable` track for updates, dev builds downloa
|
|||
|
||||
To check for updates, Dolphin can hit the following API endpoint on `dolphin-emu.org`:
|
||||
|
||||
GET /update/check/v0/<track>/<hash>
|
||||
GET /update/check/v1/<track>/<hash>/<system>
|
||||
|
||||
* `<track>` is the update track the user wants to follow (see previous section).
|
||||
* `<hash>` is the SHA1 hash of the current Dolphin version.
|
||||
* `<system>` is a short identifier of the operating system (or build flavor) to get artifacts for
|
||||
|
||||
This returns a JSON object with the following parameters:
|
||||
|
||||
|
@ -105,3 +106,12 @@ The updater is in charge of fetching the two manifests, diff-ing their contents,
|
|||
Since these lists are fully generated from the manifest, before replacing or deleting any file, the updater can first check whether these files have been manually modified by the user. If that is the case, the modified contents are backed up to a `.bak` file before replacing / deleting. Only files present in the manifest are touched -- anything else that a user might have added manually to their directory is not touched (`portable.txt`, `User/`, ...).
|
||||
|
||||
Downloaded contents are cached in a `TempUpdate` directory within the Dolphin install directory while the update process is going on. The updater is responsible for cleaning what it downloaded after execution, and remove the `TempUpdate` directory if it is empty.
|
||||
|
||||
## Update protocol versions changelog
|
||||
|
||||
The update check protocol is versioned to allow for forward and backward compatibility. Older versions of the protocol need to be maintained for older Dolphin versions to continue supporting auto-updates. It is sufficient to support auto-updating from `vN` only to the first version of Dolphin that supports `vN+1`, i.e. requiring the user to update in multiple steps is acceptable. But when possible, keeping compatibility all the way is preferred.
|
||||
|
||||
This is the list of existing update protocol versions and what changes they introduced:
|
||||
|
||||
* `v1` (added 2019-02-06): Added the `<system>` information to support macOS auto-update.
|
||||
* `v0` (added 2018-03-23): Initial version.
|
Loading…
Reference in New Issue