This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
lazy var managedObjectModel: NSManagedObjectModel = { | |
// The managed object model for the application. | |
let modelURL = NSBundle.mainBundle().URLForResource("<appName>", withExtension: "momd")! | |
let managedObjectModel = NSManagedObjectModel(contentsOfURL: modelURL)! | |
// Check is we are running as test or not | |
let environment = NSProcessInfo.processInfo().environment as [String : AnyObject] | |
let isTest = (environment["XCInjectBundle"] as? String)?.pathExtension == "xctest" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
extension String { | |
func replace(regularExpression: NSRegularExpression, transform: (String) -> String) -> String { | |
var output = "" | |
var lastMatchedLocation = self.startIndex | |
let rangeAll = NSMakeRange(0, countElements(self)); | |
regularExpression.enumerateMatchesInString(self, options: NSMatchingOptions(0), range: rangeAll) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
### Keybase proof | |
I hereby claim: | |
* I am lludo on github. | |
* I am lludo (https://keybase.io/lludo) on keybase. | |
* I have a public key whose fingerprint is BDF9 D7B7 6560 FBAE DE1D FA0E 8B90 0769 6A4C 38AB | |
To claim this, I am signing this object: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@interface __class__ () | |
@property (nonatomic, strong) UIView *rootNibView; | |
@end | |
@implementation __class__ | |
- (id)initWithFrame:(CGRect)frame { | |
self = [super initWithFrame:frame]; | |
if (self) { | |
[self loadView]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Configuration | |
KEYCHAIN_PASSWORD = <Pa$$w0rd> | |
WORKSPACE_FILE_NAME = <PongMadness> | |
SCHEME_NAME = <PongMadness Beta> | |
APP_NAME = <PongMadness-Beta> | |
# Update library dependencies | |
echo Building Dependencies |