Here's what i have so far
Code: Select all
bind time - "00 00 24 7 *" procname
Code: Select all
bind time - "00 00 24 7 *" procname
Could that be the problem?mask matches 5 space separated integers of the form: "minute hour day month year". minute, hour, day, month have a zero padding so they are exactly two characters long; year is four characters.
Code: Select all
bind time - "00 00 24 7 *" week:ended
proc week:ended { minute hour day month year } {
putlog "END OF WEEK"
}
it means this:minute, hour, day, month have a zero padding so they are exactly two characters long;
Code: Select all
bind time - "00 00 24 07 *" week:ended
Code: Select all
bind cron - "0 0 * * 0" a_test_proc
#Triggers at 0:00 every sunday
That's why I said:nml375 wrote: ...
To trigger on every sunday however, you'll need to use the cron binding instead:
in my first response to him. Since he didn't comment on it, or even acknowledge it, I dropped back to simply trying to answer what he specifically asked.While you are there, you might like to find
bind cron
and read about it too.
I'm not sure what you are really trying to do, but it is possible that
bind cron
might suit your needs better.
Code: Select all
bad type, should be one of: act, away, bcst, bot, chat, chjn, chof, chon, chpt, ctcp, ctcr, dcc, disc, evnt, filt, flud, join, kick, link, load, mode, msg, msgm, need, nick, nkch, notc, note, part, pub, pubm, raw, rejn, sign, splt, time, topc, unld, wall
Code: Select all
bind time - "00 00 *" someproc
proc someproc {min hour day month year} {
if {[clock format [clock seconds] -format "%u"] == 7} {
#Today is sunday, so do something here...
}
}
COBRa wrote: ...
i presume its because i use 1.6.19
Is there no other way round it or should i upgrade ?
hi guys did some testing and the bind cron actioned the proc but on saturday and not sunday at midnight am i missing something ??nml375 wrote:G'evening Gents,
You will not be able to create a mask that will trigger on "sundays", mainly because there's no weekday-field in the mask. The "day" part refers to the day of month.
If you'd like the binding to trigger on a specific date, then that is obviously possible, however...
As mentioned throughout the thread, single-digit values must be prefixed by 0, month starts at 0, day of month starts at 1.
To trigger on every sunday however, you'll need to use the cron binding instead:Code: Select all
bind cron - "0 0 * * 0" a_test_proc #Triggers at 0:00 every sunday
Code: Select all
bind cron - "0 0 * * 7" a_test_proc
Code: Select all
bind cron - "0 0 * * 1" a_test_proc