| Crates.io | crontime |
| lib.rs | crontime |
| version | 0.4.0 |
| created_at | 2024-01-04 12:13:03.84007+00 |
| updated_at | 2024-12-26 10:44:36.155399+00 |
| description | cron expression -> time iterator |
| homepage | https://github.com/lsunsi/crontime |
| repository | https://github.com/lsunsi/crontime |
| max_upload_size | |
| id | 1088468 |
| size | 58,549 |
This library is intended to work as a cron expression parser. For now it yields an iterator of upcoming datetimes that follow the parsed expression, simple as that.
let now = datetime!(1917-11-07 00:00:00 UTC);
let ct = crontime::build(now, "0 1 * * * *").unwrap();
for dt in ct.take(3) {
println!("{dt}");
}
// 1917-11-07 0:01:00.0 +00:00:00
// 1917-11-07 1:01:00.0 +00:00:00
// 1917-11-07 2:01:00.0 +00:00:00