Skip to content

Commit

Permalink
Merge pull request #281 from akantsevoi/patch-1
Browse files Browse the repository at this point in the history
Add example of change logger options
  • Loading branch information
fpillet authored Feb 26, 2019
2 parents 85290a5 + 1a884eb commit 7c3255d
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions README.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -156,6 +156,21 @@ This will allow the traces to be received only by the computer of the user who c

*This only work when NSLogger has been added to your project using CocoaPods*.

## Set up logger options

For example if you don't want to disable OS_ACTIVITY_MODE for your scheme because you need that logs. And you wanna have only your logs in NSLogger in Swift call init function:

```Swift
func LoggerInit() {
let pointer = LoggerGetDefaultLogger()
var options = LoggerGetOptions(pointer)

options ^= UInt32(kLoggerOption_CaptureSystemConsole) // disable that option

LoggerSetOptions(pointer, options)
}
```

## Manual Framework Install

When using NSLogger without CocoaPods, add `LoggerClient.h`, `LoggerClient.m` and `LoggerCommon.h` (as well as add the `CFNetwork.framework` and `SystemConfiguration.framework` frameworks) to your iOS or Mac OS X application, then replace your *NSLog()* calls with *LogMessageCompat()* calls. We recommend using a macro, so you can turn off logs when building the distribution version of your application.
Expand Down

0 comments on commit 7c3255d

Please sign in to comment.