Repository navigation
Release 0.7.0: update the Windows app automatically - #52
Merged
Merged
Conversation
EE installed by Setup on Windows reads SHA256SUMS of the latest GitHub release two minutes after it starts and then every hour. It downloads a newer installer into the updates folder, keeps it only if its SHA-256 matches that list and its version information names the release, and runs it silently once nobody has used the window for 10 minutes, no dialog is open and no change is being sent. Setup asks the running copy to quit as before and starts the new version with --after-update, which opens the window on the same pixel rectangle, maximized if it was, or stays in the notification area if it was hidden. - Core/Updates.cs holds the schedule, the checks on the download, the attempt and window placement records, and the retry rule: an installer that ends while EE still runs, or a download that fails its checks, waits a day. - Settings, About has Install updates automatically (on by default), the update state, Check for updates and Install now. With the setting off, nothing contacts GitHub until Check for updates. An installation for all users waits for Install now, because setup then needs administrator approval. - The window rectangle is saved and applied in screen pixels through Windows. A size in window units comes out wrong on a screen whose scaling differs from the main screen's: 1280 x 400 on a 100% rack screen became 2560 x 800 with the main screen at 200%. - Setup starts the app after an update only with /EEUPDATE, and it writes the Start with Windows entry only when the tasks were chosen. A silent upgrade used to apply the first installation's choice again, which turned the entry back on after the notification area menu had turned it off. - The package step in CI checks that the updater accepts the installer it built, runs the same silent upgrade over the installed copy, and checks that the sign-in entry stays off and that the new version starts and quits. - README, SECURITY.md, the desktop guide, docs/WORKFLOW.md and the changelog describe the update, including that it checks SHA256SUMS but not the build provenance attestation.
tools/check-repository.py accepts only the current version after "EE " in a source file, so the expected texts with a literal version would fail the check as soon as the version moves past 0.7.0.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
EE installed by Setup on Windows updates itself from this repository's releases. Releases already publish themselves when a version bump merges; this is the step that puts them on the computer.
SHA256SUMSof the latest release. A newer Windows installer is downloaded to%LOCALAPPDATA%\Etherlighting Evolved\updatesand kept only if its SHA-256 matches that list and its version information names the release.--after-update.The update checks
SHA256SUMSover HTTPS but not the build provenance attestation;SECURITY.mdsays what that covers. The macOS and Linux clients do not update themselves.Verification
SHA256SUMS, downloaded the 0.6.3 installer (75,947,857 bytes, SHA-25611e4d029…9135, the published value), accepted its version information and built the setup command. Setup was not run. This found that Inno Setup pads the version strings with spaces, which the product name comparison now ignores.installer.issunder another app ID:/EEUPDATEstarts the app with--after-update, a plain silent install does not, and a silent upgrade leaves the sign-in entry alone where the previous script wrote it again.tools/check-repository.pypass.Not tested: a complete automatic update on an installed copy, from the hourly check to the restarted window. The first one will be the update from 0.7.0 to the release after it.