Skip to content

Commit 7da8994

Browse files
committed
refactor: [#116] extract logging into dedicated module
- Create new logging module with init_tracing function - Move init_tracing from lib.rs to logging.rs - Re-export logging module in lib.rs - Improves module organization and separation of concerns
1 parent 8048ea8 commit 7da8994

File tree

2 files changed

+14
-11
lines changed

2 files changed

+14
-11
lines changed
Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,10 @@
11
pub mod command;
22
pub mod detector;
33
pub mod errors;
4+
pub mod logging;
45
pub mod manager;
56

67
pub use detector::*;
78
pub use errors::*;
9+
pub use logging::*;
810
pub use manager::*;
9-
10-
/// Initialize tracing with default configuration
11-
pub fn init_tracing() {
12-
tracing_subscriber::fmt()
13-
.with_target(true)
14-
.with_thread_ids(false)
15-
.with_thread_names(false)
16-
.with_level(true)
17-
.with_max_level(tracing::Level::INFO)
18-
.init();
19-
}
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
//! Logging configuration for the dependency installer
2+
3+
/// Initialize tracing with default configuration
4+
pub fn init_tracing() {
5+
tracing_subscriber::fmt()
6+
.with_target(true)
7+
.with_thread_ids(false)
8+
.with_thread_names(false)
9+
.with_level(true)
10+
.with_max_level(tracing::Level::INFO)
11+
.init();
12+
}

0 commit comments

Comments
 (0)