https://github.com/imp/chrono-humanize-rs
Human friendly time expressions. This is a mirror of the upstream, found at
https://github.com/imp/chrono-humanize-rs
Last synced: 12 months ago
JSON representation
Human friendly time expressions. This is a mirror of the upstream, found at
- Host: GitHub
- URL: https://github.com/imp/chrono-humanize-rs
- Owner: imp
- License: apache-2.0
- Created: 2016-07-11T15:28:23.000Z (almost 10 years ago)
- Default Branch: master
- Last Pushed: 2022-08-17T16:52:08.000Z (almost 4 years ago)
- Last Synced: 2025-04-05T14:11:20.094Z (over 1 year ago)
- Language: Rust
- Homepage: https://gitlab.com/imp/chrono-humanize-rs
- Size: 75.2 KB
- Stars: 10
- Watchers: 1
- Forks: 4
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE-APACHE
Awesome Lists containing this project
README
## Chrono Humanize - Make your text time representation human appealing
Build status
branch | status
:-------|:------:
master| [](https://travis-ci.org/imp/chrono-humanize-rs)
develop| [](https://travis-ci.org/imp/chrono-humanize-rs)
## Quick Start
```rust
use chrono::{Local, Duration};
use chrono_humanize::HumanTime;
let dt = Local::now() + Duration::days(35);
let ht = HumanTime::from(dt);
let english = format!("{}", ht);
assert_eq!("in a month", english);
```