sparkle-project / Sparkle

A software update framework for macOS
https://sparkle-project.org
Other
7.37k stars 1.05k forks source link

Pre-warm installs before relaunch #2421

Closed zorgiepoo closed 1 year ago

zorgiepoo commented 1 year ago

Move a lot of the installation work to be done during the first phase of installation (when possible), before the target app needs to be terminated. For the common case where the old and new bundles are on the same volume, the final phase of installation requiring a restart is now just an atomic swap.

Also move the termination listener to the agent app which resolves some launch/CI failures we've been seeing.

Misc Checklist

Only bug fixes to regressions or security fixes are being backported to the 1.x (master) branch now. If you believe your change is significant enough to backport, please also create a separate pull request against the master branch.

Testing

I tested and verified my change by using one or multiple of these methods:

Tested installing update on same volume and on different volume. Tested app quit termination works in all cases.

macOS version tested: 14.0 Beta (23A5312d) 13.5 (22G74) 10.14 VM

zorgiepoo commented 1 year ago

The change to move listening for app termination to the agent here is an important one to prioritize. Seems like we may get launch failures otherwise in CI and it doesn't seem specific to this pull request.