crontab icon indicating copy to clipboard operation
crontab copied to clipboard

Human-readable crons?

Open egeersoz opened this issue 2 years ago • 2 comments

Can support be added to convert Crons to human-readable strings? e.g. "Every Sunday at 6:00PM"

Ideally, this should also work with different timezones, e.g. you should be able to specify the timezone of the cron, and the target, e.g. if the Cron is UTC and you want it displayed in CST, it should be possible to do so.

egeersoz avatar Feb 15 '24 17:02 egeersoz

Are you asking to convert text to cron expressions or the other way around?

Converting text to cron expression sounds quite complicated and I‘m not sure if that would have a place in this library.

Converting cron to text should be a lot simpler and could help users understand their expressions.

In either case, I‘m open to explore the possibility, but will not have the time to do so myself. If you‘d like to explore this, you‘d have to document the desired and detailed behaviour theoretically and also be willing to provide a PR later.

What use case do you have for this feature?

maennchen avatar Feb 15 '24 22:02 maennchen

Need to be able to convert cron expressions to human-readable strings. Basically, what Crontab.guru does.

egeersoz avatar Feb 19 '24 19:02 egeersoz