Commit Graph
4099 Commits
Author SHA1 Message Date
Zorg bb3a2e299e Don't show installer progress if installer already displays progress 2016-04-09 15:29:18 -04:00
Zorg 33bd47cd1f Fix deprecated API warning for -[NSData initWithBase64Encoding:] 2016-04-09 14:55:55 -04:00
Zorg 61ed9920b4 Use NSURL's checkResourceIsReachableAndReturnError: instead of FSRef's
Fixes deprecated API warning in DMG unarchiver code
2016-04-09 14:44:32 -04:00
Zorg f528f6b2ba Fix warnings for bspatch 2016-04-09 14:36:16 -04:00
Zorg 5f253e8c64 Fix not showing download update initiation when applying delta update fails 2016-04-09 13:43:47 -04:00
Zorg 00cdab1766 s/updateInProgress/canCheckForUpdates/ 2016-04-09 13:22:48 -04:00
Zorg e14077ee9a s/SUUpdaterController/SUStandardUpdaterController/ 2016-04-09 13:21:29 -04:00
Zorg e5b5952287 Avoid probing the installer multiple times 2016-04-09 12:53:49 -04:00
Zorg c80015bf99 Move invoking showCanCheckForUpdates: outside of this completion 2016-04-09 12:35:23 -04:00
Zorg 1bb301e82a Change updateInProgress to canCheckForUpdates
This more accurately reflects its intended purpose. From the beginning,
the user cannot check for updates until the updater is ready;
however this doesn't mean that the update is in progress.
2016-04-09 11:39:02 -04:00
Zorg 933504263a Use Autoupdate's icon for installer progress tool 2016-04-09 01:05:11 -04:00
Zorg 233fa268b5 Add tool for showing installer progress
This tool is only launched if a certain amount of time has passed,
and if we're allowed to show UI
2016-04-09 00:36:09 -04:00
Zorg c178e34d8f Remove unused headers from SUStatusController 2016-04-07 23:07:27 -04:00
Kornel bdb3dd8c36 Merge pull request #790 from zorgiepoo/no-auth-cleanup
Don't bring up an authorized dialog during cleanup
2016-04-04 14:41:25 +01:00
Zorg c8ff1c0453 Don't bring up an authorized dialog during cleanup
If permissions are abnormal during cleanup or somewhere along the lines, it may be
possible to bring up authorization dialog that is not really needed. Prevent this from happening.

We would want to restrict authorization from being possible anyway when not needed.
2016-04-04 01:54:02 -04:00
Zorg 97a8568491 Add service for remote message port
This allows the updater to communicate to the installer without an additional entitlement
2016-04-04 01:18:15 -04:00
Zorg c4800182a2 Simplify testing for writable permissions to host path
Before there was always lag when checking for updates the first time.
This helps improve consistency.
2016-04-03 21:30:59 -04:00
Zorg b22d2c2568 Make menu item validation work in the test app 2016-04-03 20:06:56 -04:00
Zorg 44a61b830e Move debug warning up in initializer because it spawns really often.. 2016-04-03 20:04:56 -04:00
Zorg 6dedd8309f Handle multiple live remote port connections better
This also should fix a bug where sometimes an update could not be resumed
2016-04-03 19:56:29 -04:00
Zorg 32c687ed79 Make SURemoteMessagePort operations asynchronous 2016-04-03 17:05:56 -04:00
Zorg d7cca8a594 Check if runningApplication is nil for errors.. 2016-04-02 12:17:54 -04:00
Zorg 116c8ea8b7 Supply NSWorkspaceLaunchNewInstance when launching AutoUpdate
I don't think it actually matters since we are launching a copy we created, but
sounds like the right thing to do anyway.
2016-04-02 12:12:48 -04:00
Kornel bb40663d37 Merge pull request #789 from Eitot/patch
Remove SUEnableAutomaticChecksKeyOld and SUCheckAtStartup constants
2016-04-02 12:18:45 +01:00
Zorg 38a69cee5b Launch AutoUpdate via LaunchServices again.
I was being stupid for trying to launch the executable rather than the app.
2016-04-02 05:34:31 -04:00
Zorg a3a2310952 Fix Appcast unit tests 2016-04-02 02:14:54 -04:00
Zorg e03607a2d6 Only use SUFileManager in debug mode for the test app
This way we don't have to export it in release mode
2016-04-02 00:10:20 -04:00
Zorg 51e1e1c646 More care to handling invalidation logic 2016-04-01 23:58:32 -04:00
Zorg d5cd64159c Handle error handling for update downloader connection 2016-04-01 23:45:59 -04:00
Zorg 0b19d8d7fd Add error handling cleanup to Appcast Downloader connection 2016-04-01 23:22:52 -04:00
Zorg 92e5c30c0d Move SUUnarchiver.h from private to project 2016-04-01 22:51:10 -04:00
Zorg 9b1d441194 Add warning that Sparkle shouldn't be used when built in Debug
This is for several reasons: ATS, very short default update timer intervals, ...
2016-04-01 22:45:46 -04:00
Zorg e74a397152 Add downloader XPC services for sandboxed apps
ATS exceptions now need to be included in the appcast & update downloader services - *shrugs*.
I've a run script configured to disable ATS for release builds.
2016-04-01 22:41:12 -04:00
Zorg 9525b156a2 Export classes that we are using publicly so release build compiles 2016-04-01 22:36:42 -04:00
Zorg e7f85bb40f Add testing writability as part of SUInstallerLauncher
This is necessary for detecting if automatic updates are possible in a sandboxed environment
2016-04-01 18:56:20 -04:00
Eitot b8588543cf Remove SUEnableAutomaticChecksKeyOld and SUCheckAtStartup constants 2016-04-02 00:07:20 +02:00
Zorg 5c08e0a1d1 Add InstallerLauncher XPC Service
This allows Sparkle to be used as-is in a sandboxed application,
without needing to place Sparkle into its own XPC service.

Currently the main app may need to set a global mach service lookup exception
and a client download exception, however this can be fixed by creating a couple more
services. Testing for disk writability will need be done in a service too.
2016-04-01 17:54:12 -04:00
Zorg ee77bf59d5 IB is not smart enough to parse Nullable attribute 2016-04-01 17:41:28 -04:00
Zorg 009de37415 Remove references to status controller from AutoUpdate 2016-04-01 15:17:18 -04:00
Zorg e0e93e3edf Remove old periodic timer code 2016-04-01 15:15:11 -04:00
Zorg 60fcbe4f88 Call -fileManagerByPreservingAuthorizationRights during cleanup
Since cleanup may be invoked after 2nd stage failed for example.
2016-04-01 15:12:50 -04:00
Zorg c9f66cdeff Don't bring up an authorized dialog during cleanup
If permissions are abnormal during cleanup or somewhere along the lines, it may be
possible to bring up authorization dialog that is not really needed. Prevent this from happening.

We would want to restrict authorization from being possible anyway when not needed.
2016-04-01 15:06:47 -04:00
Zorg 32edf6cc5d Add temporary hack for bringing up authorization dialog right away if needed later 2016-04-01 14:11:30 -04:00
Zorg 941ae6481f Read the allowsUI flag again for performing installation work
Also some code cleanup. In the future, we may want to figure out authorization
before extraction even occurs.
2016-04-01 13:55:34 -04:00
Zorg e0b3a128b0 Revert 3 stage installation..
Just do all installation in 3rd stage at the moment and reconsider this idea..
Doing any work prior to finishing the installation that requires keeping files in
a temporary directory for potentially a long time turns not to probably not be a great idea.
Unfortunately I don't think trying to keep the files up to date every some interval is a _great_ idea.
I will need to rethink this some more.
2016-03-31 00:53:01 -04:00
Zorg 9e6f376285 Add periodic timer for preventing temporary file cleanup
This is inevitable if we stick to a three stage installation.
The other direction to consider is to defer most installation until after the app terminated,
although that may have disadvantages of its own.

One important addition is touching the new app recursively before moving it in a temp directory.
This is important because archives can preserve modification & access times, but we don't want that.
2016-03-29 01:15:39 -04:00
Zorg 5c624eccbe Fix issues with unit tests 2016-03-27 22:58:41 -04:00
Zorg e792798294 Forgot to invoke download receive response/progress user driver callbacks 2016-03-27 22:29:23 -04:00
Zorg 08696841c2 Fix bug where generic error dialog was shown when no update was found 2016-03-27 21:57:06 -04:00
Zorg 0b94f56f7f Rename some user driver delegate methods 2016-03-27 19:03:28 -04:00