A stylish log formatter for CocoaLumberjack
Flannel is available through CocoaPods, to install it simply add the following line to your Podfile:
pod "Flannel"
Create an instance of one of the loggers in Flannel (as of 1.0.1, there is only FLAVerboseLogFormatter
) and set this instance as the log formatter for your loggers.
FLAVerboseLogFormatter *formatter = [[FLAVerboseLogFormatter alloc] init];
[[DDASLLogger sharedInstance] setLogFormatter:formatter];
[[DDTTYLogger sharedInstance] setLogFormatter:formatter];
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
{
DDLogInfo(@"Application is launching.");
return YES;
}
2014-03-25 13:28:07:263 AppDelegate (application:didFinishLaunchingWithOptions:)[Info]: Application is launching.
Todd Grooms, [email protected]
Flannel is available under the MIT license. See the LICENSE file for more info.