Created
September 26, 2012 12:49
-
-
Save leovandriel/3787815 to your computer and use it in GitHub Desktop.
A Minimal PonyDebugger setup in Objective-C
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
// A Minimal PonyDebugger setup in Objective-C | |
// Add these lines to application:didFinishLaunchingWithOptions: and add the | |
// PonyDebugger and SocketRocket libs/frameworks to your project. Read the | |
// Quick Start at https://github.com/square/PonyDebugger#quick-start | |
// For on-device debugging, use `ponyd serve -i 0.0.0.0` and replace `localhost`. | |
// Author: Leonard van Driel, 2012 | |
#if DEBUG | |
PDDebugger *debugger = (PDDebugger *)[NSClassFromString(@"PDDebugger") defaultInstance]; | |
[debugger connectToURL:[NSURL URLWithString:@"ws://localhost:9000/device"]]; | |
[debugger enableNetworkTrafficDebugging]; | |
[debugger forwardAllNetworkTraffic]; | |
[debugger enableCoreDataDebugging]; | |
[debugger addManagedObjectContext:self.managedObjectContext withName:@"MOC"]; | |
#endif |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment