1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
//! Example
//!
//! ```no_run
//! # #[macro_use]
//! # extern crate slog;
//! # fn main() -> Result<(), Box<std::error::Error>> {
//! // Read the configuration from environment and build slog drain.
//! let drain = slog_env_cfg::drain_from_env()?;
//! // Use the darin to create a logger as usual.
//! let root = slog::Logger::root(drain, o!());
//! // Log something!
//! info!(root, "formatted: {}", 1; "log-key" => true);
//! # Ok(())
//! # }
//! ```

#![warn(rust_2018_idioms)]

mod error;
pub use error::*;

mod env;
pub use env::*;

mod config;
pub use config::*;

mod standard;
pub use standard::*;

pub use slog::Drain;

pub type Logger = slog::Logger<dyn slog::Drain<Ok = (), Err = slog::Never>>;