diff --git a/README.md b/README.md index 173e0bc..184a92a 100644 --- a/README.md +++ b/README.md @@ -1,20 +1,20 @@ # parse string to std::time::Duration -[![Chrono GitHub Actions](https://github.com/baoyachi/duration-str-rs/workflows/build/badge.svg)](https://github.com/baoyachi/duration-str-rs/actions?query=workflow%3Abuild) +[![Chrono GitHub Actions](https://github.com/baoyachi/duration-str-rs/actions/workflows/check.yml/badge.svg)](https://github.com/baoyachi/duration-str-rs/actions?query=workflow%3Abuild) [![Crates.io](https://img.shields.io/crates/v/duration-str.svg)](https://crates.io/crates/duration-str) [![Docs.rs](https://docs.rs/duration-str/badge.svg)](https://docs.rs/duration-str) -Parse string to `Duration` . The String value unit support for one of:[y,mon,w,d,h,m,s] -- y:Year. Support string value: ["y" | "year" | "Y" | "YEAR" | "Year"]. e.g. 1y -- mon:Month.Support string value: ["mon" | "MON" | "Month" | "month" | "MONTH"]. e.g. 1mon -- w:Week.Support string value: ["w" | "W" | "Week" | "WEEK" | "week"]. e.g. 1w -- d:Day.Support string value: ["d" | "D" | "Day" | "DAY" | "day"]. e.g. 1d -- h:Hour.Support string value: ["h" | "H" | "Hour" | "HOUR" | "hour"]. e.g. 1h -- m:Minute.Support string value: ["m" | "M" | "Minute" | "MINUTE" | "minute"]. e.g. 1m -- m:Second.Support string value: ["s" | "S" | "Second" | "SECOND" | "second"]. e.g. 1s +Parse string to `Duration` . The String value unit support for one of:`[y,mon,w,d,h,m,s]` +- y:Year. Support string value: `["y" | "year" | "Y" | "YEAR" | "Year"]`. e.g. 1y +- mon:Month.Support string value:` ["mon" | "MON" | "Month" | "month" | "MONTH"]. e.g. 1mon +- w:Week.Support string value: `["w" | "W" | "Week" | "WEEK" | "week"]`. e.g. 1w +- d:Day.Support string value: `["d" | "D" | "Day" | "DAY" | "day"]`. e.g. 1d +- h:Hour.Support string value: `["h" | "H" | "Hour" | "HOUR" | "hour"]`. e.g. 1h +- m:Minute.Support string value: `["m" | "M" | "Minute" | "MINUTE" | "minute"]`. e.g. 1m +- m:Second.Support string value: `["s" | "S" | "Second" | "SECOND" | "second"]`. e.g. 1s -Also,`duration_str` support time duration simple calcaute(+,*). See example: +Also,`duration_str` support time duration simple evaluation(+,*). See example: ## example diff --git a/src/lib.rs b/src/lib.rs index 81621a1..9a21fe4 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -16,7 +16,7 @@ //! //! - m:Second.Support string value: ["s" | "S" | "Second" | "SECOND" | "second"]. e.g. 1s //! -//! Also,`duration_str` support time duration simple calcaute(+,*). See example: +//! Also,`duration_str` support time duration simple evaluation(+,*). See example: //! //! # Example //!