Code: Select all
set sfile "/home/user/public_html/stats.html"
set schan "#channel"
bind time - "?5*" stime
proc stime {mi ho da mo yr} {
 webstats $::schan
} 
proc webstats c {
 set f [open $::sfile w]
 puts $f "<html><body><head>"
 puts $f "<title>channel stats for $c</title></head>"
 puts $f "$c [llength [chanlist $c]] users ([strftime "%H:%M, %m/%d/%Y"])<br>"
 foreach u [lsort -dict [chanlist $c]] {
  puts $f "$u<br>"
 }
 puts "</body></html>"
 close $f
 putlog "Updated html stats for $c" 
}
Code: Select all
bind time - "?1*" stime Code: Select all
"?5 *"simply 1 * is enough^DooM^ wrote:to execute every minute change "?5 *" to "* *"
wouldn't "1 *" execute the proc once every hour at 1 minute past?De Kus wrote: PS:simply 1 * is enough^DooM^ wrote:to execute every minute change "?5 *" to "* *".
Code: Select all
"* *"Code: Select all
"1 *"Code: Select all
bind time - "*" stimeI meant 1 "*", not *1 *" (last one would never be true because [string match "1 *" "01 xx xx xx xxxx"] == 0).^DooM^ wrote:wouldn't "1 *" execute the proc once every hour at 1 minute past?