The Daily WTF
A true confession: I absolutely cannot successfully edit a crontab file without spending a lot of time reading docs on what all the little date/time/interval flags mean. Partially, it’s just that I don’t do it very often, but mainly the information flies right out of my head once I’ve done it. I can absolutely understand why someone might want to write a little helper program to help themselves manage their crontab.
I just can’t understand why they’d write this one, sent to us Beorn. We’ll have to take this one in chunks, because it’s 18,905 lines.
We’ll start with the function dayofweek, so you can get a sense of the pattern that gets used. Here’s the first if condition for its core logic:
if (this.myObject.chkBoxMonday.Checked) { k = 0; pauto_day_of_week = k.ToString(); serie = true; if (this.myObject.chkBoxTuesday.Checked) { ktransit = 1; serie = true; } else { k =
To read the full article click on the 'post' link at the top.