From 44fd4eedbbba9d28efd301c554f611c08f26a3ca Mon Sep 17 00:00:00 2001 From: FivePixels Date: Wed, 13 Mar 2019 02:32:48 -0500 Subject: Removed Carthage --- .../LaunchAtLogin/LaunchAtLoginHelper/Info.plist | 28 ---------------------- .../LaunchAtLoginHelper.entitlements | 8 ------- .../LaunchAtLogin/LaunchAtLoginHelper/main.swift | 25 ------------------- 3 files changed, 61 deletions(-) delete mode 100644 Carthage/Checkouts/LaunchAtLogin/LaunchAtLoginHelper/Info.plist delete mode 100644 Carthage/Checkouts/LaunchAtLogin/LaunchAtLoginHelper/LaunchAtLoginHelper.entitlements delete mode 100644 Carthage/Checkouts/LaunchAtLogin/LaunchAtLoginHelper/main.swift (limited to 'Carthage/Checkouts/LaunchAtLogin/LaunchAtLoginHelper') diff --git a/Carthage/Checkouts/LaunchAtLogin/LaunchAtLoginHelper/Info.plist b/Carthage/Checkouts/LaunchAtLogin/LaunchAtLoginHelper/Info.plist deleted file mode 100644 index a075677..0000000 --- a/Carthage/Checkouts/LaunchAtLogin/LaunchAtLoginHelper/Info.plist +++ /dev/null @@ -1,28 +0,0 @@ - - - - - CFBundleExecutable - $(EXECUTABLE_NAME) - CFBundleIdentifier - $(PRODUCT_BUNDLE_IDENTIFIER) - CFBundleInfoDictionaryVersion - 6.0 - CFBundleName - $(PRODUCT_NAME) - CFBundlePackageType - APPL - CFBundleShortVersionString - 1.0.0 - CFBundleVersion - 1 - LSMinimumSystemVersion - $(MACOSX_DEPLOYMENT_TARGET) - NSHumanReadableCopyright - MIT © Sindre Sorhus - LSBackgroundOnly - - NSPrincipalClass - NSApplication - - diff --git a/Carthage/Checkouts/LaunchAtLogin/LaunchAtLoginHelper/LaunchAtLoginHelper.entitlements b/Carthage/Checkouts/LaunchAtLogin/LaunchAtLoginHelper/LaunchAtLoginHelper.entitlements deleted file mode 100644 index 852fa1a..0000000 --- a/Carthage/Checkouts/LaunchAtLogin/LaunchAtLoginHelper/LaunchAtLoginHelper.entitlements +++ /dev/null @@ -1,8 +0,0 @@ - - - - - com.apple.security.app-sandbox - - - diff --git a/Carthage/Checkouts/LaunchAtLogin/LaunchAtLoginHelper/main.swift b/Carthage/Checkouts/LaunchAtLogin/LaunchAtLoginHelper/main.swift deleted file mode 100644 index ad7fd4f..0000000 --- a/Carthage/Checkouts/LaunchAtLogin/LaunchAtLoginHelper/main.swift +++ /dev/null @@ -1,25 +0,0 @@ -import Cocoa - -final class AppDelegate: NSObject, NSApplicationDelegate { - func applicationDidFinishLaunching(_ notification: Notification) { - let bundleId = Bundle.main.bundleIdentifier! - // TODO: Make this more strict by only replacing at the end - let mainBundleId = bundleId.replacingOccurrences(of: "-LaunchAtLoginHelper", with: "") - - // Ensure the app is not already running - guard NSRunningApplication.runningApplications(withBundleIdentifier: mainBundleId).isEmpty else { - NSApp.terminate(nil) - return - } - - let pathComponents = (Bundle.main.bundlePath as NSString).pathComponents - let mainPath = NSString.path(withComponents: Array(pathComponents[0...(pathComponents.count - 5)])) - NSWorkspace.shared.launchApplication(mainPath) - NSApp.terminate(nil) - } -} - -private let app = NSApplication.shared -private let delegate = AppDelegate() -app.delegate = delegate -app.run() -- cgit v1.2.3