mirror of
https://github.com/sparkle-project/Sparkle
synced 2026-11-23 04:34:27 +00:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
d5222353e6 | ||
|
|
2657a41d55 | ||
|
|
08d3ff747d | ||
|
|
fedb22e224 | ||
|
|
8293c3c6ae | ||
|
|
181f813b01 | ||
|
|
a10a974609 | ||
|
|
f8572f79cb | ||
|
|
2b54753090 | ||
|
|
2db2fffab9 | ||
|
|
035bfc4919 | ||
|
|
48fc202f36 | ||
|
|
28ff3069ff | ||
|
|
795ce1278d | ||
|
|
6ac853271d | ||
|
|
7e5e91888f | ||
|
|
b0d29ae798 | ||
|
|
09bbf9fdc6 | ||
|
|
f2bd7ea2b2 | ||
|
|
35deefdc0c | ||
|
|
3e53979236 | ||
|
|
f8971098be | ||
|
|
efd1840f35 | ||
|
|
17dbdf98e1 | ||
|
|
79f110a17b | ||
|
|
5ab0baf84c | ||
|
|
578dac0ad7 | ||
|
|
920b5bac5e | ||
|
|
9ae7224a47 | ||
|
|
685be61bc3 | ||
|
|
9be76d3d5a | ||
|
|
f9b534a6b6 | ||
|
|
9453761aef |
No files matched your search
@@ -1,9 +1,20 @@
|
||||
# 1.22.0a1
|
||||
# 1.22.0
|
||||
|
||||
* Enabled "Hardened Runtime" build option for Apple's notarization requirement
|
||||
* Add delegate methods to suppress update alerts (George Nachman)
|
||||
* Disambiguate signing error messages (Nate Weaver)
|
||||
* Fix warnings when using modules (nivekkagicom)
|
||||
* Improved error when running from translocated location (Michael Buckley)
|
||||
* Add phased rollout feature (#1381) (Fabian Jäger)
|
||||
* Ignore non-standard permissions in delta updates instead of failing the build (Kornel Lesiński)
|
||||
* Notify user when installed version is newer than the latest in the appcast (CoreCode)
|
||||
* Block-based alternatives to `NSInvocation`-based delegate methods (Fabian Jäger)
|
||||
* Pass item to updaterShouldShowUpdateAlertForScheduledUpdate delegate method (George Nachman)
|
||||
* Separate the ed25519 sources into a new static library (Tony Arnold)
|
||||
* Correction of Czech localization inconsistency (#1403) (vojtakonarik)
|
||||
* Disambiguate signing error messages (Nate Weaver)
|
||||
* Use `XMLNode.Options.nodePrettyPrint` in `generate_appcast` instead of trying to add whitespace manually (fumoboy007)
|
||||
* Annotate SUHost for nullability (Michael Buckley)
|
||||
* Use SUAVAILABLE macro (Christiaan Hofman)
|
||||
* Fix warnings when using modules (nivekkagicom)
|
||||
|
||||
# 1.21.3
|
||||
|
||||
|
||||
@@ -32,6 +32,7 @@ PRODUCT_BUNDLE_IDENTIFIER = org.sparkle-project.Sparkle.${PRODUCT_NAME:rfc1034id
|
||||
|
||||
GCC_PREPROCESSOR_DEFINITIONS_COMMON = SPARKLE_NORMALIZE_INSTALLED_APPLICATION_NAME=$(SPARKLE_NORMALIZE_INSTALLED_APPLICATION_NAME) SPARKLE_AUTOMATED_DOWNGRADES=$(SPARKLE_AUTOMATED_DOWNGRADES) SPARKLE_APPEND_VERSION_NUMBER=$(SPARKLE_APPEND_VERSION_NUMBER) SPARKLE_BUNDLE_IDENTIFIER=\"$(SPARKLE_BUNDLE_IDENTIFIER)\" SPARKLE_RELAUNCH_TOOL_NAME=\"$(SPARKLE_RELAUNCH_TOOL_NAME)\" SPARKLE_FILEOP_TOOL_NAME=\"$(SPARKLE_FILEOP_TOOL_NAME)\"
|
||||
|
||||
ENABLE_HARDENED_RUNTIME = YES;
|
||||
CLANG_ENABLE_OBJC_ARC = YES
|
||||
GCC_ENABLE_PASCAL_STRINGS = NO
|
||||
GCC_NO_COMMON_BLOCKS = YES;
|
||||
|
||||
+1
-1
@@ -1,6 +1,6 @@
|
||||
Pod::Spec.new do |s|
|
||||
s.name = "Sparkle"
|
||||
s.version = "1.21.3"
|
||||
s.version = "1.22.0"
|
||||
s.summary = "A software update framework for macOS"
|
||||
s.description = "Sparkle is an easy-to-use software update framework for Cocoa developers."
|
||||
s.homepage = "http://sparkle-project.org"
|
||||
|
||||
@@ -784,6 +784,8 @@
|
||||
5D1AF58F0FD767AD0065DB48 /* libxml2.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; name = libxml2.dylib; path = usr/lib/libxml2.dylib; sourceTree = SDKROOT; };
|
||||
5D1AF5990FD767E50065DB48 /* libz.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; name = libz.dylib; path = usr/lib/libz.dylib; sourceTree = SDKROOT; };
|
||||
5F1510A11C96E591006E1629 /* testnamespaces.xml */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xml; path = testnamespaces.xml; sourceTree = "<group>"; };
|
||||
5FA8757822C7A12C00FC6A2F /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/InfoPlist.strings; sourceTree = "<group>"; };
|
||||
5FA8757922C7A12C00FC6A2F /* en */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = en; path = en.lproj/MainMenu.xib; sourceTree = "<group>"; };
|
||||
610134710DD250470049ACDF /* SUUpdateDriver.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SUUpdateDriver.h; sourceTree = "<group>"; };
|
||||
610134720DD250470049ACDF /* SUUpdateDriver.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SUUpdateDriver.m; sourceTree = "<group>"; };
|
||||
610134790DD2541A0049ACDF /* SUProbingUpdateDriver.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SUProbingUpdateDriver.h; sourceTree = "<group>"; };
|
||||
@@ -858,8 +860,6 @@
|
||||
61B5F90209C4CEE200B25A18 /* Sparkle Test App.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = "Sparkle Test App.app"; sourceTree = BUILT_PRODUCTS_DIR; };
|
||||
61B5F90409C4CEE200B25A18 /* TestApplication-Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = "TestApplication-Info.plist"; sourceTree = "<group>"; };
|
||||
61B5F92409C4CFC900B25A18 /* main.m */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = "<group>"; };
|
||||
61B5F92B09C4CFD800B25A18 /* English */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.strings; name = English; path = English.lproj/InfoPlist.strings; sourceTree = "<group>"; };
|
||||
61B5F92D09C4CFD800B25A18 /* English */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = English; path = English.lproj/MainMenu.xib; sourceTree = "<group>"; };
|
||||
61B5FB9409C4F04600B25A18 /* SUAppcast.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SUAppcast.h; sourceTree = "<group>"; };
|
||||
61B5FB9509C4F04600B25A18 /* SUAppcast.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SUAppcast.m; sourceTree = "<group>"; };
|
||||
61B5FC3F09C4FD4000B25A18 /* WebKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = WebKit.framework; path = System/Library/Frameworks/WebKit.framework; sourceTree = SDKROOT; };
|
||||
@@ -1014,8 +1014,8 @@
|
||||
buildActionMask = 2147483647;
|
||||
files = (
|
||||
EA4311FC229D65E400A5503D /* libbsdiff.a in Frameworks */,
|
||||
EA4311BD229D5FF000A5503D /* libed25519.a in Frameworks */,
|
||||
5AE13FBD1E0DA39B000D2C2C /* libbz2.tbd in Frameworks */,
|
||||
EA4311BD229D5FF000A5503D /* libed25519.a in Frameworks */,
|
||||
5AAD006C1E0C2DBF00AF411E /* libxar.tbd in Frameworks */,
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
@@ -1032,8 +1032,8 @@
|
||||
isa = PBXFrameworksBuildPhase;
|
||||
buildActionMask = 2147483647;
|
||||
files = (
|
||||
EA4311FD229D65FC00A5503D /* libbsdiff.a in Frameworks */,
|
||||
5D06E9050FD68D7D005AE3F6 /* Foundation.framework in Frameworks */,
|
||||
EA4311FD229D65FC00A5503D /* libbsdiff.a in Frameworks */,
|
||||
5D06E8FF0FD68D6D005AE3F6 /* libbz2.dylib in Frameworks */,
|
||||
5D1AF58B0FD7678C0065DB48 /* libxar.1.dylib in Frameworks */,
|
||||
5D1AF5900FD767AD0065DB48 /* libxml2.dylib in Frameworks */,
|
||||
@@ -1045,9 +1045,9 @@
|
||||
isa = PBXFrameworksBuildPhase;
|
||||
buildActionMask = 2147483647;
|
||||
files = (
|
||||
EA4311FE229D660B00A5503D /* libbsdiff.a in Frameworks */,
|
||||
14732BD119610A1200593899 /* AppKit.framework in Frameworks */,
|
||||
14732BD019610A0D00593899 /* Foundation.framework in Frameworks */,
|
||||
EA4311FE229D660B00A5503D /* libbsdiff.a in Frameworks */,
|
||||
721CF1AB1AD764EB00D9AC09 /* libbz2.dylib in Frameworks */,
|
||||
721CF1AA1AD7647000D9AC09 /* libxar.1.dylib in Frameworks */,
|
||||
14652F8019A9740F00959E44 /* Security.framework in Frameworks */,
|
||||
@@ -1060,9 +1060,9 @@
|
||||
isa = PBXFrameworksBuildPhase;
|
||||
buildActionMask = 2147483647;
|
||||
files = (
|
||||
EA4311E5229D644700A5503D /* libed25519.a in Frameworks */,
|
||||
14950073195FCE4E00BC5B5B /* AppKit.framework in Frameworks */,
|
||||
14950072195FCE4B00BC5B5B /* Foundation.framework in Frameworks */,
|
||||
EA4311E5229D644700A5503D /* libed25519.a in Frameworks */,
|
||||
61B5F90F09C4CF3A00B25A18 /* Sparkle.framework in Frameworks */,
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
@@ -1088,12 +1088,12 @@
|
||||
isa = PBXFrameworksBuildPhase;
|
||||
buildActionMask = 2147483647;
|
||||
files = (
|
||||
EA4311FF229D662600A5503D /* libbsdiff.a in Frameworks */,
|
||||
EA4311E4229D643300A5503D /* libed25519.a in Frameworks */,
|
||||
1495006E195FCE1100BC5B5B /* AppKit.framework in Frameworks */,
|
||||
1495006F195FCE1800BC5B5B /* Foundation.framework in Frameworks */,
|
||||
61177A1F0D1112E900749C97 /* IOKit.framework in Frameworks */,
|
||||
EA4311FF229D662600A5503D /* libbsdiff.a in Frameworks */,
|
||||
5D06E8FD0FD68D6B005AE3F6 /* libbz2.dylib in Frameworks */,
|
||||
EA4311E4229D643300A5503D /* libed25519.a in Frameworks */,
|
||||
5D1AF58A0FD7678C0065DB48 /* libxar.1.dylib in Frameworks */,
|
||||
5D1AF82B0FD768180065DB48 /* libz.dylib in Frameworks */,
|
||||
61B5F8F709C4CEB300B25A18 /* Security.framework in Frameworks */,
|
||||
@@ -1128,12 +1128,12 @@
|
||||
5AB8F19F214DA72000A1187F /* generate_keys */,
|
||||
5A5ADED7214EDE4900DF0099 /* sign_update */,
|
||||
55C14BB7136EEF1500649790 /* Autoupdate.app */,
|
||||
EA4311EA229D651300A5503D /* libbsdiff.a */,
|
||||
EA4311A0229D5FBC00A5503D /* libed25519.a */,
|
||||
61B5F90209C4CEE200B25A18 /* Sparkle Test App.app */,
|
||||
612279D90DB5470200AB99EA /* Sparkle Unit Tests.xctest */,
|
||||
8DC2EF5B0486A6940098B216 /* Sparkle.framework */,
|
||||
726B2B5D1C645FC900388755 /* UI Tests.xctest */,
|
||||
EA4311A0229D5FBC00A5503D /* libed25519.a */,
|
||||
EA4311EA229D651300A5503D /* libbsdiff.a */,
|
||||
);
|
||||
name = Products;
|
||||
sourceTree = "<group>";
|
||||
@@ -1183,13 +1183,13 @@
|
||||
089C1665FE841158C02AAC07 /* Framework Resources */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
E1D4DDF821C1C5F8003D32E7 /* DarkAqua.css */,
|
||||
8DC2EF5A0486A6940098B216 /* Sparkle-Info.plist */,
|
||||
61AAE8220A321A7F00D8810D /* Sparkle.strings */,
|
||||
55C14BDA136EF20D00649790 /* SUAutomaticUpdateAlert.xib */,
|
||||
55C14BD8136EF00C00649790 /* SUStatus.xib */,
|
||||
55C14BF0136EF26100649790 /* SUUpdateAlert.xib */,
|
||||
55C14C05136EF2C700649790 /* SUUpdatePermissionPrompt.xib */,
|
||||
E1D4DDF821C1C5F8003D32E7 /* DarkAqua.css */,
|
||||
);
|
||||
name = "Framework Resources";
|
||||
sourceTree = "<group>";
|
||||
@@ -2031,14 +2031,9 @@
|
||||
};
|
||||
buildConfigurationList = 1DEB91B108733DA50010E9CD /* Build configuration list for PBXProject "Sparkle" */;
|
||||
compatibilityVersion = "Xcode 6.3";
|
||||
developmentRegion = English;
|
||||
developmentRegion = en;
|
||||
hasScannedForEncodings = 1;
|
||||
knownRegions = (
|
||||
English,
|
||||
Japanese,
|
||||
French,
|
||||
German,
|
||||
Italian,
|
||||
zh_TW,
|
||||
en,
|
||||
ca,
|
||||
@@ -2160,13 +2155,13 @@
|
||||
isa = PBXResourcesBuildPhase;
|
||||
buildActionMask = 2147483647;
|
||||
files = (
|
||||
E1D4DDF921C1C5F8003D32E7 /* DarkAqua.css in Resources */,
|
||||
61AAE8280A321A7F00D8810D /* Sparkle.strings in Resources */,
|
||||
55C14BEE136EF20D00649790 /* SUAutomaticUpdateAlert.xib in Resources */,
|
||||
615AE3D00D64DC40001CA7BD /* SUModelTranslation.plist in Resources */,
|
||||
55C14BEF136EF21700649790 /* SUStatus.xib in Resources */,
|
||||
55C14C04136EF26100649790 /* SUUpdateAlert.xib in Resources */,
|
||||
55C14C19136EF2C700649790 /* SUUpdatePermissionPrompt.xib in Resources */,
|
||||
E1D4DDF921C1C5F8003D32E7 /* DarkAqua.css in Resources */,
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
};
|
||||
@@ -2746,7 +2741,7 @@
|
||||
1A985A3A1C5C32A50001163A /* da */,
|
||||
1A985A341C5C329E0001163A /* de */,
|
||||
1A985A531C5C32BD0001163A /* el */,
|
||||
61B5F92B09C4CFD800B25A18 /* English */,
|
||||
5FA8757822C7A12C00FC6A2F /* en */,
|
||||
1A985A3B1C5C32A60001163A /* es */,
|
||||
1A985A3C1C5C32A70001163A /* fi */,
|
||||
1A985A331C5C329D0001163A /* fr */,
|
||||
@@ -2782,7 +2777,7 @@
|
||||
61B5F92C09C4CFD800B25A18 /* MainMenu.xib */ = {
|
||||
isa = PBXVariantGroup;
|
||||
children = (
|
||||
61B5F92D09C4CFD800B25A18 /* English */,
|
||||
5FA8757922C7A12C00FC6A2F /* en */,
|
||||
);
|
||||
name = MainMenu.xib;
|
||||
sourceTree = "<group>";
|
||||
|
||||
@@ -0,0 +1,8 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
||||
<plist version="1.0">
|
||||
<dict>
|
||||
<key>IDEDidComputeMac32BitWarning</key>
|
||||
<true/>
|
||||
</dict>
|
||||
</plist>
|
||||
Vendored
+2
-2
@@ -62,9 +62,9 @@ static NSString *SPUURLRequestNetworkServiceTypeKey = @"SPUURLRequestNetworkServ
|
||||
- (void)encodeWithCoder:(NSCoder *)coder
|
||||
{
|
||||
[coder encodeObject:self.url forKey:SPUURLRequestURLKey];
|
||||
[coder encodeInteger:self.cachePolicy forKey:SPUURLRequestCachePolicyKey];
|
||||
[coder encodeInteger:(NSInteger)self.cachePolicy forKey:SPUURLRequestCachePolicyKey];
|
||||
[coder encodeDouble:self.timeoutInterval forKey:SPUURLRequestTimeoutIntervalKey];
|
||||
[coder encodeInteger:self.networkServiceType forKey:SPUURLRequestNetworkServiceTypeKey];
|
||||
[coder encodeInteger:(NSInteger)self.networkServiceType forKey:SPUURLRequestNetworkServiceTypeKey];
|
||||
|
||||
if (self.httpHeaderFields != nil) {
|
||||
[coder encodeObject:self.httpHeaderFields forKey:SPUURLRequestHttpHeaderFieldsKey];
|
||||
|
||||
Vendored
+8
-2
@@ -152,8 +152,14 @@
|
||||
{
|
||||
NSBundle *bundle = host.bundle;
|
||||
assert(bundle != nil);
|
||||
|
||||
NSString *normalizedAppPath = [[[bundle bundlePath] stringByDeletingLastPathComponent] stringByAppendingPathComponent:[NSString stringWithFormat:@"%@.%@", [host objectForInfoDictionaryKey:(__bridge NSString *)kCFBundleNameKey], [[bundle bundlePath] pathExtension]]];
|
||||
|
||||
NSString * baseBundleName = [host objectForInfoDictionaryKey:@"SUBundleName"];
|
||||
|
||||
if (baseBundleName == nil) {
|
||||
baseBundleName = [host objectForInfoDictionaryKey:(__bridge NSString *)kCFBundleNameKey];
|
||||
}
|
||||
|
||||
NSString *normalizedAppPath = [[[bundle bundlePath] stringByDeletingLastPathComponent] stringByAppendingPathComponent:[NSString stringWithFormat:@"%@.%@", baseBundleName, [[bundle bundlePath] pathExtension]]];
|
||||
|
||||
// Roundtrip string through fileSystemRepresentation to ensure it uses filesystem's Unicode normalization
|
||||
// rather than arbitrary Unicode form from Info.plist - #1017
|
||||
|
||||
Vendored
+5
-1
@@ -126,7 +126,7 @@
|
||||
alert.messageText = SULocalizedString(@"You're up-to-date!", "Status message shown when the user checks for updates but is already current or the feed doesn't contain any updates.");
|
||||
|
||||
if (self.latestAppcastItemComparisonResult == NSOrderedDescending ) { // this means the user is a 'newer than latest' version. give a slight hint to the user instead of wrongly claiming this version is identical to the latest feed version.
|
||||
alert.informativeText = [NSString stringWithFormat:SULocalizedString(@"%@ %@ is currently the newest version available.\n(You are currently running version %@.)", nil), [self.host name], self.latestAppcastItem.versionString, [self.host displayVersion]];
|
||||
alert.informativeText = [NSString stringWithFormat:SULocalizedString(@"%@ %@ is currently the newest version available.\n(You are currently running version %@.)", nil), [self.host name], self.latestAppcastItem.displayVersionString, [self.host displayVersion]];
|
||||
}
|
||||
else {
|
||||
alert.informativeText = [NSString stringWithFormat:SULocalizedString(@"%@ %@ is currently the newest version available.", nil), [self.host name], [self.host displayVersion]];
|
||||
@@ -165,6 +165,7 @@
|
||||
{
|
||||
self.updateAlert = nil;
|
||||
[self.host setObject:nil forUserDefaultsKey:SUSkippedVersionKey];
|
||||
id<SUUpdaterPrivate> updater = self.updater;
|
||||
switch (choice) {
|
||||
case SUInstallUpdateChoice:
|
||||
[self didDismissAlertPermanently:NO forItem:item];
|
||||
@@ -178,6 +179,9 @@
|
||||
break;
|
||||
|
||||
case SUSkipThisVersionChoice:
|
||||
if ([[updater delegate] respondsToSelector:@selector(updater:userDidSkipThisVersion:)]) {
|
||||
[[updater delegate] updater:self.updater userDidSkipThisVersion:self.updateItem];
|
||||
}
|
||||
[self didDismissAlertPermanently:YES forItem:item];
|
||||
[self.host setObject:[self.updateItem versionString] forUserDefaultsKey:SUSkippedVersionKey];
|
||||
[self abortUpdate];
|
||||
|
||||
Vendored
+23
@@ -37,6 +37,7 @@ NSString *const SUUpdaterAppcastNotificationKey = @"SUUpdaterAppCastNotification
|
||||
|
||||
@interface SUUpdater () <SUUpdaterPrivate>
|
||||
@property (strong) NSTimer *checkTimer;
|
||||
@property (assign) BOOL shouldRescheduleOnWake;
|
||||
@property (strong) NSBundle *sparkleBundle;
|
||||
|
||||
- (instancetype)initForBundle:(NSBundle *)bundle;
|
||||
@@ -59,6 +60,7 @@ NSString *const SUUpdaterAppcastNotificationKey = @"SUUpdaterAppCastNotification
|
||||
|
||||
@synthesize delegate;
|
||||
@synthesize checkTimer;
|
||||
@synthesize shouldRescheduleOnWake;
|
||||
@synthesize userAgentString = customUserAgentString;
|
||||
@synthesize httpHeaders;
|
||||
@synthesize driver;
|
||||
@@ -113,6 +115,9 @@ static NSString *const SUUpdaterDefaultsObservationContext = @"SUUpdaterDefaults
|
||||
if (self) {
|
||||
[self registerAsObserver];
|
||||
}
|
||||
|
||||
[NSWorkspace.sharedWorkspace.notificationCenter addObserver:self selector:@selector(receiveSleepNote) name:NSWorkspaceWillSleepNotification object:NULL];
|
||||
[NSWorkspace.sharedWorkspace.notificationCenter addObserver:self selector:@selector(receiveWakeNote) name:NSWorkspaceDidWakeNotification object:NULL];
|
||||
|
||||
id updater = [sharedUpdaters objectForKey:[NSValue valueWithNonretainedObject:bundle]];
|
||||
if (updater)
|
||||
@@ -294,6 +299,24 @@ static NSString *const SUUpdaterDefaultsObservationContext = @"SUUpdaterDefaults
|
||||
self.checkTimer = [NSTimer scheduledTimerWithTimeInterval:delayUntilCheck target:self selector:@selector(checkForUpdatesInBackground) userInfo:nil repeats:NO]; // Timer is non-repeating, may have invalidated itself, so we had to retain it.
|
||||
}
|
||||
|
||||
- (void)receiveSleepNote
|
||||
{
|
||||
if (self.checkTimer)
|
||||
{
|
||||
[self.checkTimer invalidate];
|
||||
self.checkTimer = nil;
|
||||
self.shouldRescheduleOnWake = YES;
|
||||
}
|
||||
else
|
||||
self.shouldRescheduleOnWake = NO;
|
||||
}
|
||||
|
||||
- (void)receiveWakeNote
|
||||
{
|
||||
if (self.shouldRescheduleOnWake) // the reason for rescheduling the update-check timer is that NSTimer does behave as if the time the Mac spends asleep did not exist at all, which can significantly prolong the time between update checks
|
||||
[self scheduleNextUpdateCheck];
|
||||
}
|
||||
|
||||
- (void)checkForUpdatesInBackground
|
||||
{
|
||||
BOOL automatic = [self automaticallyDownloadsUpdates];
|
||||
|
||||
Vendored
+7
@@ -141,6 +141,13 @@ SU_EXPORT extern NSString *const SUUpdaterAppcastNotificationKey;
|
||||
*/
|
||||
- (void)updaterDidNotFindUpdate:(SUUpdater *)updater;
|
||||
|
||||
/*!
|
||||
Called when the user clicks the Skip This Version button.
|
||||
|
||||
\param updater The SUUpdater instance.
|
||||
*/
|
||||
- (void)updater:(SUUpdater *)updater userDidSkipThisVersion:(SUAppcastItem *)item;
|
||||
|
||||
/*!
|
||||
Called immediately before downloading the specified update.
|
||||
|
||||
|
||||
Vendored
+1
-1
@@ -8,7 +8,7 @@
|
||||
|
||||
"%@ %@ is currently the newest version available." = "%1$@ %2$@ est la version la plus récente disponible.";
|
||||
|
||||
"%@ %@ is currently the newest version available.\n(You are currently running version %@.)" = "%1$@ %2$@ est la version la plus récente disponible.\n(You are currently running version %3$@.)";
|
||||
"%@ %@ is currently the newest version available.\n(You are currently running version %@.)" = "%1$@ %2$@ est la version la plus récente disponible.\n(vous utilisez actuellement la version %3$@)";
|
||||
|
||||
/* Description text for SUUpdateAlert when the update is downloadable. */
|
||||
"%@ %@ is now available--you have %@. Would you like to download it now?" = "%1$@ %2$@ est disponible ; vous utilisez la version %3$@. Voulez-vous le télécharger maintenant ?";
|
||||
|
||||
Vendored
+1
-1
@@ -8,7 +8,7 @@
|
||||
|
||||
"%@ %@ is currently the newest version available." = "%1$@ %2$@は現在入手できる最新バージョンです。";
|
||||
|
||||
"%@ %@ is currently the newest version available.\n(You are currently running version %@.)" = "%1$@ %2$@は現在入手できる最新バージョンです。\n(You are currently running version %3$@.)";
|
||||
"%@ %@ is currently the newest version available.\n(You are currently running version %@.)" = "%1$@ %2$@は現在入手できる最新バージョンです。\n(現在使用中のバージョンは%3$@です。)";
|
||||
|
||||
/* Description text for SUUpdateAlert when the update is downloadable. */
|
||||
"%@ %@ is now available--you have %@. Would you like to download it now?" = "%1$@ %2$@が入手できます(使用中のバージョンは%3$@です)。今すぐダウンロードしますか?";
|
||||
|
||||
Vendored
+1
-1
@@ -6,7 +6,7 @@
|
||||
|
||||
"%@ %@ is currently the newest version available." = "%1$@ %2$@ é a versão mais recente disponível.";
|
||||
|
||||
"%@ %@ is currently the newest version available.\n(You are currently running version %@.)" = "%1$@ %2$@ é a versão mais recente disponível.\n(You are currently running version %3$@.)";
|
||||
"%@ %@ is currently the newest version available.\n(You are currently running version %@.)" = "%1$@ %2$@ é a versão mais recente disponível.\n(Você está usando a versão %3$@.)";
|
||||
|
||||
/* Description text for SUUpdateAlert when the update is downloadable. */
|
||||
"%@ %@ is now available--you have %@. Would you like to download it now?" = "%1$@ %2$@ está disponível – sua versão é %3$@. Deseja transferi-lo agora?";
|
||||
|
||||
File renamed without changes.
File renamed without changes.
@@ -93,7 +93,11 @@ class ArchiveItem: CustomStringConvertible {
|
||||
|
||||
var feedURL:URL? = nil;
|
||||
if let feedURLStr = infoPlist["SUFeedURL"] as? String {
|
||||
feedURL = URL(string: feedURLStr);
|
||||
feedURL = URL(string: feedURLStr)
|
||||
if feedURL?.pathExtension == "php" {
|
||||
feedURL = feedURL!.deletingLastPathComponent()
|
||||
feedURL = feedURL!.appendingPathComponent("appcast.xml")
|
||||
}
|
||||
}
|
||||
|
||||
try self.init(version: version,
|
||||
|
||||
+34
-12
@@ -25,22 +25,39 @@ func printUsage() {
|
||||
)
|
||||
}
|
||||
|
||||
func loadPrivateKeys(_ privateDSAKey: SecKey?) -> PrivateKeys {
|
||||
func loadPrivateKeys(_ privateDSAKey: SecKey?, _ privateEdString: String?) -> PrivateKeys {
|
||||
var privateEdKey: Data?;
|
||||
var publicEdKey: Data?;
|
||||
var item: CFTypeRef?;
|
||||
let res = SecItemCopyMatching([
|
||||
kSecClass as String: kSecClassGenericPassword,
|
||||
kSecAttrService as String: "https://sparkle-project.org",
|
||||
kSecAttrAccount as String: "ed25519",
|
||||
kSecAttrProtocol as String: kSecAttrProtocolSSH,
|
||||
kSecReturnData as String: kCFBooleanTrue,
|
||||
] as CFDictionary, &item);
|
||||
if res == errSecSuccess, let encoded = item as? Data, let keys = Data(base64Encoded: encoded) {
|
||||
var keys: Data?
|
||||
|
||||
// private + public key is provided as argument
|
||||
if let privateEdString = privateEdString {
|
||||
if privateEdString.count == 128, let data = privateEdString.data(using: .utf8) {
|
||||
keys = data
|
||||
} else {
|
||||
print("Warning: Private key not found in the argument. Please provide a valid key.");
|
||||
}
|
||||
}
|
||||
// get keys from kechain instead
|
||||
else {
|
||||
let res = SecItemCopyMatching([
|
||||
kSecClass as String: kSecClassGenericPassword,
|
||||
kSecAttrService as String: "https://sparkle-project.org",
|
||||
kSecAttrAccount as String: "ed25519",
|
||||
kSecAttrProtocol as String: kSecAttrProtocolSSH,
|
||||
kSecReturnData as String: kCFBooleanTrue,
|
||||
] as CFDictionary, &item);
|
||||
if res == errSecSuccess, let encoded = item as? Data, let data = Data(base64Encoded: encoded) {
|
||||
keys = data
|
||||
} else {
|
||||
print("Warning: Private key not found in the Keychain (\(res)). Please run the generate_keys tool");
|
||||
}
|
||||
}
|
||||
|
||||
if let keys = keys {
|
||||
privateEdKey = keys[0..<64];
|
||||
publicEdKey = keys[64...];
|
||||
} else {
|
||||
print("Warning: Private key not found in the Keychain (\(res)). Please run the generate_keys tool");
|
||||
}
|
||||
return PrivateKeys(privateDSAKey: privateDSAKey, privateEdKey: privateEdKey, publicEdKey: publicEdKey);
|
||||
}
|
||||
@@ -53,6 +70,7 @@ func main() {
|
||||
}
|
||||
|
||||
var privateDSAKey: SecKey? = nil;
|
||||
var privateEdString: String? = nil;
|
||||
|
||||
// this was typical usage for DSA keys
|
||||
if args.count == 3 || (args.count == 4 && args[1] == "-f") {
|
||||
@@ -98,13 +116,17 @@ func main() {
|
||||
exit(1)
|
||||
}
|
||||
}
|
||||
// private + public EdDSA keys are provided via command line argument
|
||||
else if args.count == 4 && args[1] == "-s" {
|
||||
privateEdString = args[2]
|
||||
}
|
||||
else if args.count != 2 {
|
||||
printUsage()
|
||||
exit(1)
|
||||
}
|
||||
|
||||
let archivesSourceDir = URL(fileURLWithPath: args.last!, isDirectory: true)
|
||||
let keys = loadPrivateKeys(privateDSAKey)
|
||||
let keys = loadPrivateKeys(privateDSAKey, privateEdString)
|
||||
|
||||
do {
|
||||
let allUpdates = try makeAppcast(archivesSourceDir: archivesSourceDir, keys: keys, verbose:verbose);
|
||||
|
||||
Reference in new issue
Block a user