Skip to content

groomsy/flannel

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

19 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Flannel

A stylish log formatter for CocoaLumberjack

Version Platform

Requirements

CocoaLumberjack

Installation

Flannel is available through CocoaPods, to install it simply add the following line to your Podfile:

pod "Flannel"

Use

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];

Formatters and Example Log Statements

FLAVerboseLogFormatter

Log Statement (Code)

- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
{
	DDLogInfo(@"Application is launching.");
	return YES;
}

Log Statement (Output)

2014-03-25 13:28:07:263 AppDelegate (application:didFinishLaunchingWithOptions:)[Info]: Application is launching.

Author

Todd Grooms, todd.grooms@gmail.com

License

Flannel is available under the MIT license. See the LICENSE file for more info.