All Projects → IngmarStein → SMJobKit

IngmarStein / SMJobKit

Licence: Apache-2.0 License
Swift API for SMJobBless and friends

Programming Languages

swift
15916 projects
ruby
36898 projects - #4 most used programming language
objective c
16641 projects - #2 most used programming language
Rich Text Format
576 projects
c
50402 projects - #5 most used programming language

SMJobKit

Using SMJobBless and friends is rather… painful. SMJobKit does everything in its power to alleviate that and get you back to writing awesome macOS apps.

SMJobKit is more than just a framework/library to link against. It gives you:

  • A Xcode target template for SMJobBless-ready launchd services, completely configured for proper code signing!

  • A client abstraction that manages installing/upgrading your app's service(s).

  • A service library that pulls in as little additional code as possible. Less surface area for security vulnerabilities!

Project Configuration

To get started, pull the SMJobKit project into your own project or workspace. Have your application depend on the SMJobKit framework, and hit build. In addition to building the framework, this also causes the Xcode template to install its self into ~/Library/Developer/Xcode/Templates.

Next, you should set up your service helper/target: Add a new SMJobKit Service target to the project. This is relatively configuration-heavy, so you should probably build it right away to make sure everything is properly configured (and your code signing certificates are in order). You may want to review the template's documentation for an in-depth explanation of what it is doing for you.

Finally, you need to add a Copy Files build phase to your application target. The destination should be "Wrapper" with a subpath of Contents/Library/LaunchServices. Add the service's built product to the list. Make sure you add a dependency on your service target!

And, hopefully, that's all you need to do in order to configure your project!

Client Abstraction

You'll want to create a subclass of Client in your application, and override serviceIdentifier at the very least.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].