egghelp.org community Forum Index
[ egghelp.org home | forum home ]
egghelp.org community
Discussion of eggdrop bots, shell accounts and tcl scripts.
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

bind cron

 
Post new topic   Reply to topic    egghelp.org community Forum Index -> Scripting Help
View previous topic :: View next topic  
Author Message
ldevries
Voice


Joined: 23 Feb 2013
Posts: 12
Location: Great Falls

PostPosted: Sat Mar 16, 2013 11:31 am    Post subject: bind cron Reply with quote

I have a .tcl script that calls for a event on mar 19 @ 8:20am. I have the following entry:
Code:

bind cron - "20 08 19 03 *" do_hs_post

proc do_hs_post {min hour day month weekday} {
global stockchan
putserv "privmsg $stockchan :\0034Economic Event In 10 Minutes\017 - \00312Housing Market Index\017"
}

however, for some strange reason it is executing everyday. What am I doing wrong.


Last edited by ldevries on Sat Mar 16, 2013 3:44 pm; edited 1 time in total
Back to top
View user's profile Send private message
Madalin
Master


Joined: 24 Jun 2005
Posts: 310
Location: Constanta, Romania

PostPosted: Sat Mar 16, 2013 2:23 pm    Post subject: Reply with quote

You could try bind time

bind time - "min hour day month year" procname
_________________
https://github.com/MadaliNTCL - To chat with me: https://tawk.to/MadaliNTCL
Back to top
View user's profile Send private message Send e-mail Visit poster's website Yahoo Messenger
willyw
Revered One


Joined: 15 Jan 2009
Posts: 1175

PostPosted: Sat Mar 16, 2013 3:52 pm    Post subject: Re: bind cron Reply with quote

dutch1918 wrote:

...
however, for some strange reason it is executing everyday. What am I doing wrong.
...


In the partyline, do:
.binds *cron*
and see what you have listed.

Perhaps you have edited that bind, (and you used .rehash) and an old bind is still there?
If so, the solution is to do: .restart
Back to top
View user's profile Send private message
ldevries
Voice


Joined: 23 Feb 2013
Posts: 12
Location: Great Falls

PostPosted: Sat Mar 16, 2013 4:31 pm    Post subject: Reply with quote

thanks.. gave that a try and it did not post... I had
Code:

bind time - "55 16 16 03 *" do_test_post

proc do_test_post {min hour day month year} {
   global stockchan
   putserv "privmsg $stockchan :\0034Economic Event In 10 Minutes\017 - \00312test\017"
}

I confirmed witn .bind *time*

<STBot> TYPE FLAGS COMMAND HITS BINDING (TCL)
<STBot> time -|- 55 16 16 03 * 0 do_test_post


Last edited by ldevries on Sat Mar 16, 2013 4:57 pm; edited 1 time in total
Back to top
View user's profile Send private message
ldevries
Voice


Joined: 23 Feb 2013
Posts: 12
Location: Great Falls

PostPosted: Sat Mar 16, 2013 4:41 pm    Post subject: Re: bind cron Reply with quote

In the partyline, do:
.binds *cron*
and see what you have listed.

Perhaps you have edited that bind, (and you used .rehash) and an old bind is still there?
If so, the solution is to do: .restart[/quote]

I have the following to clear bind crons & time on .rehash which works
Code:

proc removeallbinds {bindtype} {
 foreach bind [binds $bindtype] {
 unbind [lindex $bind 0] [lindex $bind 1] [lindex $bind 2] [lindex $bind 4]
 }
}

removeallbinds cron
removeallbinds time
Back to top
View user's profile Send private message
ldevries
Voice


Joined: 23 Feb 2013
Posts: 12
Location: Great Falls

PostPosted: Sat Mar 16, 2013 5:34 pm    Post subject: Reply with quote

After doing some more research I found that march month is 02 not 03. Thus it works and the problem is now solved. Thanks for your help
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    egghelp.org community Forum Index -> Scripting Help All times are GMT - 4 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Forum hosting provided by Reverse.net

Powered by phpBB © 2001, 2005 phpBB Group
subGreen style by ktauber