mirror of
https://github.com/sparkle-project/Sparkle
synced 2026-11-29 05:24:26 +00:00
Make binary delta version 4 the default (#2668)
This commit is contained in:
2 files changed
+11
-4
No files matched your search
@@ -22,7 +22,7 @@
|
||||
|
||||
// Note: the framework bundle version must be bumped, and generate_appcast must be updated to compare it,
|
||||
// when we add/change new major versions and defaults. Unit tests need to be updated to use new versions too.
|
||||
SUBinaryDeltaMajorVersion SUBinaryDeltaMajorVersionDefault = SUBinaryDeltaMajorVersion3;
|
||||
SUBinaryDeltaMajorVersion SUBinaryDeltaMajorVersionDefault = SUBinaryDeltaMajorVersion4;
|
||||
SUBinaryDeltaMajorVersion SUBinaryDeltaMajorVersionLatest = SUBinaryDeltaMajorVersion4;
|
||||
SUBinaryDeltaMajorVersion SUBinaryDeltaMajorVersionFirst = SUBinaryDeltaMajorVersion1;
|
||||
SUBinaryDeltaMajorVersion SUBinaryDeltaMajorVersionFirstSupported = SUBinaryDeltaMajorVersion2;
|
||||
|
||||
@@ -283,13 +283,20 @@ func makeAppcasts(archivesSourceDir: URL, outputPathURL: URL?, cacheDirectory ca
|
||||
// Decide the most appropriate delta version
|
||||
let deltaVersion: SUBinaryDeltaMajorVersion
|
||||
if let frameworkVersion = item.frameworkVersion {
|
||||
switch standardComparator.compareVersion(frameworkVersion, toVersion: "2010") {
|
||||
switch standardComparator.compareVersion(frameworkVersion, toVersion: "2041") {
|
||||
case .orderedSame:
|
||||
fallthrough
|
||||
case .orderedDescending:
|
||||
deltaVersion = .version3
|
||||
deltaVersion = .version4
|
||||
case .orderedAscending:
|
||||
deltaVersion = .version2
|
||||
switch standardComparator.compareVersion(frameworkVersion, toVersion: "2010") {
|
||||
case .orderedSame:
|
||||
fallthrough
|
||||
case .orderedDescending:
|
||||
deltaVersion = .version3
|
||||
case .orderedAscending:
|
||||
deltaVersion = .version2
|
||||
}
|
||||
}
|
||||
} else {
|
||||
deltaVersion = SUBinaryDeltaMajorVersionDefault
|
||||
|
||||
Reference in new issue
Block a user