azza-bazoo / prettycron

Display cron runspecs in human-readable format
GNU Lesser General Public License v3.0
122 stars 62 forks source link

Specific date with day of week specified is incorrect #20

Open toddllm opened 8 years ago

toddllm commented 8 years ago

Example:

Cron expression: 5 5 20 1 3 Human readable: 05:05 on the 20th and every Wed in Jan

This will only run on the 20th of January that falls on a Wednesday. Not every Wednesday in January.

pekeler commented 8 years ago

The implementation is correct for the popular Vixie cron. http://crontab.org:

The day of a command's execution can be specified by two fields -- day of month, and day of week. If both fields are restricted (ie, aren't *), the command will be run when either field matches the current time.