zslayton / cron

A cron expression parser in Rust
Apache License 2.0
376 stars 69 forks source link

Need documentation for supported cron expressions #119

Closed mTsBucy1 closed 1 year ago

mTsBucy1 commented 1 year ago

I was trying to use this crate to parse crontab expression as generated by https://crontab.guru/ or as documented by wikipedia article https://en.wikipedia.org/wiki/Cron#Cron_expression. In particular do neither of them include the second field. However, this crate accepts only expressions with 6 or 7 field (following the Oracle conventions https://docs.oracle.com/cd/E12058_01/doc/doc.1014/e12030/cron_expressions.htm). This discrepancy should at least be documented. Other non-standard extensions, such as the optional year and the @ shorthands should also be mentioned.

Addtionally, I would still like to use the second-less expression and I've noticed there was once an issue #5 about the optional seconds field, I guess it was dropped in favour of the optional year field. Is there any possibility of support for this adding this?

Thanks for your work!

mTsBucy1 commented 1 year ago

I've noticed this is essentially a duplicate of https://github.com/zslayton/cron/issues/37#issuecomment-399622075, sorry for this, but I would still appreciate a quick README / Docs.rs comment.