pmcore::routines::logger

Function setup_log

Source
pub fn setup_log(settings: &Settings) -> Result<()>
Expand description

Setup logging for the library

This function sets up logging for the library. It uses the tracing crate, and the tracing-subscriber crate for formatting.

The log level is defined in the configuration file, and defaults to INFO.

If log_out is specifified in the configuration file, a log file is created with the specified name.

If not, the log messages are written to stdout.