From 1bdb7e75d13dcdc7caed7b8cec8134eeb9a7df92 Mon Sep 17 00:00:00 2001 From: SteveLauC Date: Wed, 6 Dec 2023 09:48:50 +0800 Subject: [PATCH] chore: update deprecated merge_imports && fmt (#327) --- .rustfmt.toml | 2 +- benches/rotation.rs | 6 ++++-- .../rolling_file/policy/compound/roll/fixed_window.rs | 3 +-- 3 files changed, 6 insertions(+), 5 deletions(-) diff --git a/.rustfmt.toml b/.rustfmt.toml index 7d2cf549..e86028b1 100644 --- a/.rustfmt.toml +++ b/.rustfmt.toml @@ -1 +1 @@ -merge_imports = true +imports_granularity="Crate" diff --git a/benches/rotation.rs b/benches/rotation.rs index de108dab..4167331f 100644 --- a/benches/rotation.rs +++ b/benches/rotation.rs @@ -1,5 +1,7 @@ -use std::thread; -use std::time::{Duration, Instant}; +use std::{ + thread, + time::{Duration, Instant}, +}; use lazy_static::lazy_static; use tempfile::{tempdir, TempDir}; diff --git a/src/append/rolling_file/policy/compound/roll/fixed_window.rs b/src/append/rolling_file/policy/compound/roll/fixed_window.rs index 43611617..340ddd05 100644 --- a/src/append/rolling_file/policy/compound/roll/fixed_window.rs +++ b/src/append/rolling_file/policy/compound/roll/fixed_window.rs @@ -12,8 +12,7 @@ use std::{ path::{Path, PathBuf}, }; -use crate::append::env_util::expand_env_vars; -use crate::append::rolling_file::policy::compound::roll::Roll; +use crate::append::{env_util::expand_env_vars, rolling_file::policy::compound::roll::Roll}; #[cfg(feature = "config_parsing")] use crate::config::{Deserialize, Deserializers};