Registry / utility / chrono-humanize

chrono-humanize

JSON →
library0.2.3rscratesunverified

Human-friendly time expressions - similar to Python arrow.humanize

# Cargo.toml [dependencies] chrono-humanize = "0.2.3"
INSTALL
IMPORT
SIG · CHRONO-HUMANIZE
C
chrono-humanize
utilityrustv0.2.3
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

HumanTime
use chrono_humanize::HumanTime;

Formats a duration as a human-readable string.

use chrono_humanize::HumanTime; use chrono::Utc; fn main() { let now = Utc::now(); let earlier = now - chrono::Duration::hours(2); println!("{}", HumanTime::from(earlier)); }
Debug
Known issues

No known issues recorded.

Upgrade
Version history
0.2.3latest on crates.io
Audit
Dependencies

No dependency data recorded yet.

Agent activity
6 hits · last 30 days
node
6
Resources
chrono-humanize — cargo add chrono-humanize · libregistry