tracing-print
A simple println
-like format for tracing-subscriber
.
Prints the message field of an event and no others. Formats the message according to log level:
ERROR
: redWARN
: yellowINFO
: no formattingDEBUG
: blueTRACE
: dim
Usage
let layer = layer
.event_format;
Example
Run this example: cargo run --example simple
!;
warn!;
info!;
debug!;
trace!;
// Functions as a newline
info!;
// Other keys than message won't be displayed
info!;
// Format macros work like normal
info!;
// Extra ANSI colors can also be applied
info!;
error!
error
Looks like this: