Macro bones_framework::setup_logs

source ยท
macro_rules! setup_logs {
    () => { ... };
    ($settings:ident) => { ... };
    ($app_namespace:expr) => { ... };
    ($app_ns1:expr, $app_ns2:expr, $app_ns3:expr) => { ... };
}
Expand description

setup_logs is a macro for initializing logging in bones.

It wraps a call to super::setup_logging (see docs for details on configuration options).

Warning: There may be issues if not called in root scope of app (e.g. in main()). Macro expands to: let _guard = setup_logging(...);, if _guard is dropped, any logging to file system will stop (console logging unimpacted).

Usage for log defaults (logging to file system included):

use bones_framework::prelude::*;
setup_logs!("org", "fishfolk", "jumpy");

Usage for log defaults (without logging to file system):

use bones_framework::prelude::*;
setup_logs!();