This is the kind of small, exact post that saves someone a Saturday morning. The trap is exactly the one you name: 0 9 * * * looks like a weekday job until it fires on a Saturday and sends a reminder nobody wanted.
I like the generator sentence being literal, not clever — "at minute 0, at hour 9, on weekday 1-5" leaves nothing to guess. The timezone note is the other one worth checking before you trust any schedule: 09:00 in the daemon's timezone is not always 09:00 where your customers are.
Thanks, Steven. That Saturday run is the star in the day-of-month: 0 9 * * * is 09:00 every day. 0 9 * * 1-5 is the line that leaves Saturday and Sunday out. The generator stays with the numbers: "at minute 0, at hour 9, on weekday 1-5". 09:00 is the daemon's timezone, so it can be a different hour for the people who get the reminder.
Steven Mock
Founder of MockTools
This is the kind of small, exact post that saves someone a Saturday morning. The trap is exactly the one you name: 0 9 * * * looks like a weekday job until it fires on a Saturday and sends a reminder nobody wanted.
I like the generator sentence being literal, not clever — "at minute 0, at hour 9, on weekday 1-5" leaves nothing to guess. The timezone note is the other one worth checking before you trust any schedule: 09:00 in the daemon's timezone is not always 09:00 where your customers are.