|
|
@ -22,23 +22,23 @@ impl Log for Logger {
|
|
|
|
|
|
|
|
|
|
|
|
let (msg, _level) = match record.level() {
|
|
|
|
let (msg, _level) = match record.level() {
|
|
|
|
Level::Error => (
|
|
|
|
Level::Error => (
|
|
|
|
format!("{} {} {}", ts.white().bold(), "ERR".red(), record.args()),
|
|
|
|
format!("{} {} {}", ts.white().dimmed(), "ERR".red(), record.args()),
|
|
|
|
3,
|
|
|
|
3,
|
|
|
|
),
|
|
|
|
),
|
|
|
|
Level::Warn => (
|
|
|
|
Level::Warn => (
|
|
|
|
format!("{} {} {}", ts.white().bold(), "WRN".purple(), record.args()),
|
|
|
|
format!("{} {} {}", ts.white().dimmed(), "WRN".purple(), record.args()),
|
|
|
|
4,
|
|
|
|
4,
|
|
|
|
),
|
|
|
|
),
|
|
|
|
Level::Info => (
|
|
|
|
Level::Info => (
|
|
|
|
format!("{} {} {}", ts.white().bold(), "INF".cyan(), record.args()),
|
|
|
|
format!("{} {} {}", ts.white().dimmed(), "INF".cyan(), record.args()),
|
|
|
|
6,
|
|
|
|
6,
|
|
|
|
),
|
|
|
|
),
|
|
|
|
Level::Debug => (
|
|
|
|
Level::Debug => (
|
|
|
|
format!("{} {} {}", ts.white().bold(), "DBG".yellow(), record.args()),
|
|
|
|
format!("{} {} {}", ts.white().dimmed(), "DBG".yellow(), record.args()),
|
|
|
|
7,
|
|
|
|
7,
|
|
|
|
),
|
|
|
|
),
|
|
|
|
Level::Trace => (
|
|
|
|
Level::Trace => (
|
|
|
|
format!("{} {} {}", ts.white().bold(), "TRC".green(), record.args()),
|
|
|
|
format!("{} {} {}", ts.white().dimmed(), "TRC".green(), record.args()),
|
|
|
|
0,
|
|
|
|
0,
|
|
|
|
),
|
|
|
|
),
|
|
|
|
};
|
|
|
|
};
|
|
|
|