5 files changed +35
-20
lines changed Original file line number Diff line number Diff line change @@ -55,11 +55,11 @@ hex = "0.4.3"
55
55
hmac = " 0.12.1"
56
56
home = " 0.5.11"
57
57
http-auth = { version = " 0.1.10" , default-features = false }
58
- humantime = " 2.1.0"
59
58
ignore = " 0.4.23"
60
59
im-rc = " 15.1.0"
61
60
indexmap = " 2.7.1"
62
61
itertools = " 0.14.0"
62
+ jiff = { version = " 0.2.3" , default-features = false , features = [ " std" ] }
63
63
jobserver = " 0.1.32"
64
64
lazycell = " 1.3.0"
65
65
libc = " 0.2.169"
@@ -176,11 +176,11 @@ hex.workspace = true
176
176
hmac.workspace = true
177
177
home.workspace = true
178
178
http-auth.workspace = true
179
- humantime.workspace = true
180
179
ignore.workspace = true
181
180
im-rc.workspace = true
182
181
indexmap.workspace = true
183
182
itertools.workspace = true
183
+ jiff.workspace = true
184
184
jobserver.workspace = true
185
185
lazycell.workspace = true
186
186
libgit2-sys.workspace = true
Original file line number Diff line number Diff line change @@ -79,7 +79,7 @@ fn setup_logger() -> Option<ChromeFlushGuard> {
79
79
. with ( fmt_layer)
80
80
. with ( profile_layer) ;
81
81
registry. init ( ) ;
82
- tracing:: trace!( start = humantime :: format_rfc3339 ( std :: time :: SystemTime :: now( ) ) . to_string( ) ) ;
82
+ tracing:: trace!( start = jiff :: Timestamp :: now( ) . to_string( ) ) ;
83
83
profile_guard
84
84
}
85
85
Original file line number Diff line number Diff line change @@ -102,12 +102,9 @@ impl fmt::Display for FileTimeDiff {
102
102
fn fmt ( & self , f : & mut fmt:: Formatter < ' _ > ) -> fmt:: Result {
103
103
let s_diff = self . new_time . seconds ( ) - self . old_time . seconds ( ) ;
104
104
if s_diff >= 1 {
105
- fmt:: Display :: fmt (
106
- & humantime:: Duration :: from ( std:: time:: Duration :: from_secs ( s_diff as u64 ) ) ,
107
- f,
108
- )
105
+ fmt:: Display :: fmt ( & jiff:: SignedDuration :: from_secs ( s_diff) , f)
109
106
} else {
110
- // format nanoseconds as it is, humantime would display ms, us and ns
107
+ // format nanoseconds as it is, jiff would display ms, us and ns
111
108
let ns_diff = self . new_time . nanoseconds ( ) - self . old_time . nanoseconds ( ) ;
112
109
write ! ( f, "{ns_diff}ns" )
113
110
}
Original file line number Diff line number Diff line change @@ -15,7 +15,7 @@ use cargo_util::paths;
15
15
use std:: collections:: HashMap ;
16
16
use std:: io:: { BufWriter , Write } ;
17
17
use std:: thread:: available_parallelism;
18
- use std:: time:: { Duration , Instant , SystemTime } ;
18
+ use std:: time:: { Duration , Instant } ;
19
19
20
20
/// Tracking information for the entire build.
21
21
///
@@ -117,7 +117,7 @@ impl<'gctx> Timings<'gctx> {
117
117
( pkg_desc, targets)
118
118
} )
119
119
. collect ( ) ;
120
- let start_str = humantime :: format_rfc3339_seconds ( SystemTime :: now ( ) ) . to_string ( ) ;
120
+ let start_str = jiff :: Timestamp :: now ( ) . to_string ( ) ;
121
121
let profile = bcx. build_config . requested_profile . to_string ( ) ;
122
122
let last_cpu_state = if enabled {
123
123
match State :: current ( ) {
0 commit comments