Skip to content

Commit

Permalink
feat: 日志时间精确到秒
Browse files Browse the repository at this point in the history
  • Loading branch information
shadow3aaa committed Nov 4, 2024
1 parent 6b6ba4c commit a03cc73
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,6 @@ fn log_format(
now: &mut DeferredNow,
record: &Record<'_>,
) -> Result<(), io::Error> {
let time = now.format("%Y-%m-%d %H:%M");
let time = now.format("%Y-%m-%d %H:%M:%S");
write!(write, "[{time}] {}: {}", record.level(), record.args())
}

0 comments on commit a03cc73

Please sign in to comment.