|
|
@@ -1,7 +1,7 @@
|
|
|
use std::collections::HashMap;
|
|
|
use std::fmt::Debug;
|
|
|
use std::io;
|
|
|
-use chrono::{Datelike, Timelike, Utc};
|
|
|
+use chrono::{Datelike, FixedOffset, Timelike, Utc};
|
|
|
use tracing::{Event, Subscriber, warn};
|
|
|
use tracing_appender::non_blocking::WorkerGuard;
|
|
|
use tracing_subscriber::{fmt, Layer};
|
|
|
@@ -17,10 +17,10 @@ struct LocalTimer;
|
|
|
|
|
|
impl FormatTime for LocalTimer {
|
|
|
fn format_time(&self, w: &mut Writer<'_>) -> std::fmt::Result {
|
|
|
- let now = Utc::now();
|
|
|
+ let now = Utc::now().with_timezone(&FixedOffset::east_opt(8 * 3600).unwrap());
|
|
|
write!(
|
|
|
w,
|
|
|
- "{:02}-{:02} {:02}:{:02}:{:02}.{}",
|
|
|
+ "{:04}-{:02} {:02}:{:02}:{:02}.{:03}",
|
|
|
now.month(),
|
|
|
now.day(),
|
|
|
now.hour(),
|