Skip to content

Commit 6bdbc7e

Browse files
authored
debug: use jiff instead of chrono (#30)
2 parents f88f92f + bbe0d9d commit 6bdbc7e

File tree

4 files changed

+16
-231
lines changed

4 files changed

+16
-231
lines changed

Cargo.lock

Lines changed: 13 additions & 224 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@ dirs = "6.0"
1313
clap = { version = "4.0", features = ["derive"] }
1414
num_cpus = "1.16"
1515
ctrlc = "3.4"
16-
chrono = "0.4"
1716
log = "0.4"
1817
env_logger = "0.11"
1918
thiserror = "2.0"
2019
anyhow = "1.0"
20+
jiff = "0.2.13"

src/cli/debug.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,7 @@ pub fn run_debug(config: &AppConfig) -> Result<(), AppError> {
1212
println!("Version: {}", env!("CARGO_PKG_VERSION"));
1313

1414
// Current date and time
15-
let formatted_time = chrono::Local::now().format("%Y-%m-%d %H:%M:%S");
16-
println!("Timestamp: {formatted_time}");
15+
println!("Timestamp: {}", jiff::Timestamp::now());
1716

1817
// Kernel information
1918
if let Ok(kernel_info) = get_kernel_info() {

src/main.rs

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -133,10 +133,7 @@ fn main() -> Result<(), AppError> {
133133
);
134134

135135
// Format timestamp in a readable way
136-
println!(
137-
"Current Time: {}",
138-
chrono::Local::now().format("%Y-%m-%d %H:%M:%S")
139-
);
136+
println!("Current Time: {}", jiff::Timestamp::now());
140137

141138
format_section("CPU Global Info");
142139
println!(

0 commit comments

Comments
 (0)