call_logger 1.0.1

A logger that calls another application for every logged item
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
use call_logger::CallLogger;
use log::{info, LevelFilter};

/// Echo a log message to the console
///
/// ```
/// cargo run --example log_echo
/// ```
fn main() {
    let _ = CallLogger::new()
        .with_level(LevelFilter::Info)
        .echo()
        .init();

    // The call to echo will be written to stdout and then the log line will be
    // written to the default call target which is `echo`.
    info!("msg");
}