From 8bb28c6590284355b21279c0ad53d54833afd26e Mon Sep 17 00:00:00 2001 From: Brent Simmons Date: Wed, 31 May 2017 09:27:07 -0700 Subject: [PATCH 1/4] Update README. --- README.md | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 186caa992..8223f8c0a 100644 --- a/README.md +++ b/README.md @@ -1 +1,9 @@ -# Evergreen \ No newline at end of file +# Evergreen + +It’s a feed reader for MacOS. + +No, it doesn’t support JSON Feed yet. It’s [on the to-do list](https://github.com/brentsimmons/Evergreen/issues/20). + +It’s also not actually usable at this point. + +More info: [https://ranchero.com/evergreen/](https://ranchero.com/evergreen/) \ No newline at end of file From 41ced601278224e0be09f2691ea4f51d051d7475 Mon Sep 17 00:00:00 2001 From: Daniel Jalkut Date: Wed, 31 May 2017 13:48:03 -0400 Subject: [PATCH 2/4] Remove "Mac Developer" code signing build setting on the application target. Theoretically you could keep using Mac Developer for the debug builds, but for the Release build at least, let the Developer ID identity setting come through to ensure build products are Gatekeeper-approved. --- Evergreen.xcodeproj/project.pbxproj | 2 -- 1 file changed, 2 deletions(-) diff --git a/Evergreen.xcodeproj/project.pbxproj b/Evergreen.xcodeproj/project.pbxproj index 0a466c04c..c15b4d914 100644 --- a/Evergreen.xcodeproj/project.pbxproj +++ b/Evergreen.xcodeproj/project.pbxproj @@ -1362,7 +1362,6 @@ buildSettings = { ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; - CODE_SIGN_IDENTITY = "Mac Developer"; COMBINE_HIDPI_IMAGES = YES; DEVELOPMENT_TEAM = M8L2WTLA8W; FRAMEWORK_SEARCH_PATHS = ( @@ -1383,7 +1382,6 @@ buildSettings = { ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; - CODE_SIGN_IDENTITY = "Mac Developer"; COMBINE_HIDPI_IMAGES = YES; DEVELOPMENT_TEAM = M8L2WTLA8W; FRAMEWORK_SEARCH_PATHS = ( From a8adf60165628167044fce11bdeb9638fa26404c Mon Sep 17 00:00:00 2001 From: Daniel Jalkut Date: Wed, 31 May 2017 15:19:05 -0400 Subject: [PATCH 3/4] Generate a placeholder app icon by rendering the Emoji Evergreen glyph. --- Evergreen/AppDelegate.swift | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/Evergreen/AppDelegate.swift b/Evergreen/AppDelegate.swift index 8816edd44..4a62eb04b 100644 --- a/Evergreen/AppDelegate.swift +++ b/Evergreen/AppDelegate.swift @@ -40,10 +40,40 @@ class AppDelegate: NSObject, NSApplicationDelegate, NSUserInterfaceValidations { super.init() } + private func evergreenImage() -> NSImage? { + var image: NSImage? = nil + let imageWidth = 1024 + let imageHeight = 1024 + let imageSize = NSMakeSize(CGFloat(imageWidth), CGFloat(imageHeight)) + + if let drawingContext = CGContext(data: nil, width: imageWidth, height: imageHeight, bitsPerComponent: 8, bytesPerRow: 0, space: CGColorSpaceCreateDeviceRGB(), bitmapInfo: CGImageAlphaInfo.premultipliedFirst.rawValue) { + + let graphicsContext = NSGraphicsContext(cgContext: drawingContext, flipped: false) + NSGraphicsContext.saveGraphicsState() + NSGraphicsContext.setCurrent(graphicsContext) + + let targetRect = NSRect(origin: NSZeroPoint, size: imageSize) + NSString(string: "🌲").draw(in: targetRect, withAttributes: [NSFontAttributeName: NSFont.systemFont(ofSize: 1000)]) + + NSGraphicsContext.restoreGraphicsState() + + if let coreImage = drawingContext.makeImage() { + image = NSImage(cgImage: coreImage, size: imageSize) + } + } + + return image + } + // MARK: NSApplicationDelegate func applicationDidFinishLaunching(_ note: Notification) { + if let appIconImage = evergreenImage() { + appIconImage.setName("NSApplicationIcon") + NSApplication.shared().applicationIconImage = appIconImage + } + registerDefaults() currentTheme = themeLoader.defaultTheme From 24d6d1e499acbf1a7821d1695294ae9eb2930d9e Mon Sep 17 00:00:00 2001 From: Daniel Jalkut Date: Wed, 31 May 2017 15:29:50 -0400 Subject: [PATCH 4/4] I think that to get Developer ID working reliably you have to turn off "Automatic Code Signing." Let's give this one a spin ... --- Evergreen.xcodeproj/project.pbxproj | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Evergreen.xcodeproj/project.pbxproj b/Evergreen.xcodeproj/project.pbxproj index c15b4d914..24e101eda 100644 --- a/Evergreen.xcodeproj/project.pbxproj +++ b/Evergreen.xcodeproj/project.pbxproj @@ -826,7 +826,7 @@ 849C645F1ED37A5D003D8FC0 = { CreatedOnToolsVersion = 8.2.1; DevelopmentTeam = M8L2WTLA8W; - ProvisioningStyle = Automatic; + ProvisioningStyle = Manual; }; 849C64701ED37A5D003D8FC0 = { CreatedOnToolsVersion = 8.2.1; @@ -1286,7 +1286,6 @@ CLANG_WARN_SUSPICIOUS_MOVE = YES; CLANG_WARN_UNREACHABLE_CODE = YES; CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; - CODE_SIGN_IDENTITY = "Developer ID Application"; COPY_PHASE_STRIP = NO; DEBUG_INFORMATION_FORMAT = dwarf; DEVELOPMENT_TEAM = M8L2WTLA8W; @@ -1336,7 +1335,6 @@ CLANG_WARN_SUSPICIOUS_MOVE = YES; CLANG_WARN_UNREACHABLE_CODE = YES; CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; - CODE_SIGN_IDENTITY = "Developer ID Application"; COPY_PHASE_STRIP = NO; DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; DEVELOPMENT_TEAM = M8L2WTLA8W; @@ -1362,6 +1360,7 @@ buildSettings = { ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CODE_SIGN_IDENTITY = "Developer ID Application"; COMBINE_HIDPI_IMAGES = YES; DEVELOPMENT_TEAM = M8L2WTLA8W; FRAMEWORK_SEARCH_PATHS = ( @@ -1382,6 +1381,7 @@ buildSettings = { ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CODE_SIGN_IDENTITY = "Developer ID Application"; COMBINE_HIDPI_IMAGES = YES; DEVELOPMENT_TEAM = M8L2WTLA8W; FRAMEWORK_SEARCH_PATHS = (