Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

DDLog(CocoaLumberjack) message in console

I want to replace NSLog with CocoaLumberjack, and I follow the GettingStarted, then add

DDLogError(@"This is an error.");
DDLogWarn(@"This is a warning.");
DDLogInfo(@"This is just a message.");
DDLogVerbose(@"This is a verbose message.");

but why there is no log message in XCode's console?

like image 587
Mil0R3 Avatar asked Dec 04 '22 10:12

Mil0R3


1 Answers

Lumberjack is a generic logging framework. You have to config it to use one (or more) specific log outputs. E.g., for Apple's console, you have to use:

[DDLog addLogger:[DDASLLogger sharedInstance]];

For terminal:

[DDLog addLogger:[DDTTYLogger sharedInstance]];
like image 102
Matthias Avatar answered Dec 27 '22 03:12

Matthias