[Eug-lug] crontab - last day of month

Bob Miller kbob at jogger-egg.com
Mon Nov 20 12:31:04 PST 2006


Matthew Jarvis wrote:

> One suggestion was to run it for 28, 29, 30, 31 and then determine some 
> other way if it's really the last day of the month...

That's not a bad idea.

0 1 28-31 * * [ "`date +%m`" != "`date +%m --date=tomorrow`" ] && run-end-of-month-job

-- 
Bob Miller                              K<bob>
                                        kbob at jogger-egg.com


More information about the EUGLUG mailing list