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
34
35
36
37
38
39
40
41
42
43
44
//! Easy-to-use file logger that writes messages in **log-easy-style**.
//!
//! ## Format
//! Each entry is written as:
//!
//! ```text
//! [YYYY-MM-DD HH:MM:SS][LOG_LEVEL] Message
//! ```
//!
//! ## Example
//! ```rust,no_run
//! use log_easy::{Logger, LogLevel};
//!
//! let logger = Logger::new("app.log").with_level(LogLevel::Info);
//! logger.info("Application started");
//! logger.error("An error occurred");
//! ```
//!
//! ## Global macros
//! ```rust,no_run
//! use log_easy::{error, info, init_with, Logger, LogLevel};
//!
//! init_with(Logger::new("app.log").with_level(LogLevel::Info)).unwrap();
//! info!("Application started");
//! error!("An error occurred");
//! ```
//!
//! ## Error handling
//! The convenience methods (`info`, `warn`, etc.) are **non-intrusive** and never return errors.
//! If a write fails, the logger prints a message to stderr.
//!
//! If you need to handle errors explicitly, use the `try_*` methods (e.g. `try_info`).
pub use ;
/// Used by macros to access the global logger