Merge branch 'master' into ui-separation-and-xpc

This commit is contained in:
Zorg committed 2017-01-07 23:26:57 -05:00
commit 005a9a069e
4 files changed
+6 -4

No files matched your search

+1
View File
@@ -35,6 +35,7 @@ if [ "$ACTION" = "" ] ; then
# because missing dSYMs in a release build SHOULD trigger a build failure
if [ "$CONFIGURATION" = "Release" ] ; then
cp -R "$CONFIGURATION_BUILD_DIR/BinaryDelta.dSYM" "$CONFIGURATION_BUILD_DIR/staging/bin"
cp -R "$CONFIGURATION_BUILD_DIR/generate_appcast.dSYM" "$CONFIGURATION_BUILD_DIR/staging/bin"
cp -R "$CONFIGURATION_BUILD_DIR/Sparkle Test App.app.dSYM" "$CONFIGURATION_BUILD_DIR/staging"
cp -R "$CONFIGURATION_BUILD_DIR/sparkle.app.dSYM" "$CONFIGURATION_BUILD_DIR/staging"
cp -R "$CONFIGURATION_BUILD_DIR/Sparkle.framework.dSYM" "$CONFIGURATION_BUILD_DIR/staging"
+1 -1
View File
@@ -23,7 +23,7 @@ class DeltaUpdate {
class func create(from: ArchiveItem, to: ArchiveItem, archivePath: URL) throws -> DeltaUpdate {
var applyDiffError: NSError? = nil;
if (!createBinaryDelta(from.appPath.path, to.appPath.path, archivePath.path, .beigeMajorVersion, true, &applyDiffError)) {
if (!createBinaryDelta(from.appPath.path, to.appPath.path, archivePath.path, .beigeMajorVersion, false, &applyDiffError)) {
throw applyDiffError!;
}
+3 -2
View File
@@ -47,7 +47,6 @@ func writeAppcast(appcastDestPath: URL, updates: [ArchiveItem]) throws {
XMLNode.Options.nodeLoadExternalEntitiesNever,
XMLNode.Options.nodePreserveCDATA,
XMLNode.Options.nodePreserveWhitespace,
XMLNode.Options.nodePreservePrefixes,
];
doc = try XMLDocument(contentsOf: appcastDestPath, options: Int(options.rawValue));
} catch {
@@ -160,5 +159,7 @@ func writeAppcast(appcastDestPath: URL, updates: [ArchiveItem]) throws {
}
let options = XMLNode.Options.nodeCompactEmptyElement;
try doc.xmlData(withOptions:Int(options.rawValue)).write(to: appcastDestPath);
let docData = doc.xmlData(withOptions:Int(options.rawValue));
let _ = try XMLDocument(data: docData, options:0); // Verify that it was generated correctly, which does not always happen!
try docData.write(to: appcastDestPath);
}
+1 -1
View File
@@ -31,7 +31,7 @@ func unarchive(itemPath:URL, archiveDestDir: URL, callback: @escaping (Error?) -
}, progressBlock: nil)
} else {
_ = try? fileManager.removeItem(at: itemCopy);
callback(makeError(code: .unarchivingError, "Can't create a hardlink to \(itemCopy)"));
callback(makeError(code: .unarchivingError, "Not a supported archive format: \(itemCopy)"));
}
} catch {
_ = try? fileManager.removeItem(at: tempDir);