pretty-duration 0.1.1

Rust library that takes a duration and returns a string that is prettier to read for a human. The format of the duration can be customized in a short and long format and can be localized.
Documentation
1
2
3
4
5
6
7
8
9
10
#[derive(Copy, Clone)]
pub struct DurationBins {
    pub years: u16,
    pub months: u8,
    pub days: u8,
    pub hours: u8,
    pub minutes: u8,
    pub seconds: u8,
    pub milliseconds:u16,
}