PDA

View Full Version : help me to SCHEDULED REQUEST ANNOUNCING in IRC


glory4
02-02-2004, 02:17 AM
i want to announcing about request content in IRC channel. scheduled intermittently.
example script like below

[schedule]
IRCrequest = 0,10,20,30,40,50 * * * EXEC ..\scripts\ioA\ioA.exe Request

but this command is not function.
I know that it is normal ..:D
ioA.exe isn't have request command
who are help me to making this function

!requests command in IRC is rarely used

if scheduled request announcing is making. it can used in IRC channel by many people :p

Mouton
02-02-2004, 02:02 PM
using ioFTPD scheduler won't work.
use a bind - time ... in your ioBanana...
I'm pretty sure u can find the syntax somewhere...
And for the procedure called on that bind, use the same as the !siterequests bind - pub ... line

glory4
02-02-2004, 11:51 PM
i can't understand your comment
please. teach to me more easily..

1. iobanana.ini(in ioftpd) have not "bind"(?)
2. iobanana.tcL(in eggdrop script) have "bind"...
but it is used by below pattern
"bind pub - [set ioss(cmdpre)] nukes nukesalias"
there is no bind time example (etc. bine time - is not be)
3. i think that modified iobanana.ini does not cause
scheduled annoncing..
so. i'm understand your comment totaly

i just want that
automatically request content announcing in irc channel with interval(30min or 1hour)

recently, my ioftpd and windrop's request fuction is well working
site request, site reqfilled, site reqdel(in FTP), !requests(in irc) function working well. etc...
!requests
[ CURRENT REQUESTS ] :
[ REQUEST ] there is currently no request.

Mouton
02-03-2004, 12:49 PM
ioBanana.tcl

copy the bind pub - ... requests

and change the bind pub for bind time

ask google for the right syntax for bind time - ...
"eggdrop bind time" should do.

glory4
02-03-2004, 09:54 PM
i'm testing now whether if it is stable method or not
when i think that is stable.. i will open this method

glory4
02-03-2004, 10:17 PM
add to iobanana.TCL in windrop's script
bind time - "* * * * *" siterequests
; 5 star mean <min> <hour> <date> <month> <year>
; if you want to announcing per 10min "?0 * * * *"
; if you want to announcing per hour.. "00 * * * *"
; if you want to announcing per day.. "00 00 * * *"
; 0 is non-specific
; if you want to announcing per 30min, add two line to iobanana.tcl
; .... bind time - "00 * * * *" siterequests
; .... bind time - "30 * * * *" siterequests

add below text.. too!
#siterequests for irc announcing#
proc siterequests {min hour day month year} {
global ioss
set status [catch { set ee [::ftp::Quote $ioss(ftp) SITE request] } result]
if {$status == 1 || $ioss(ftp_error)=="Not connected!"} {putlog "$result"; ftp_force_login; return}
set lines [split $ee \n]
######## set lines [lreplace $lines 0 1]
######## set lines [lreplace $lines end-2 end]
sndall "ioss" $ioss(t_request_header)
set go 0
foreach line $lines {
set lbit [regexp -inline -- "200- *(\[^ \]*) (.*) *$ioss(reqsplitter) *(.*) *" $line]
if {[llength $lbit]==0} {continue}
set number [lindex $lbit 1]
set name [lindex $lbit 2]; regsub -all -- { } $name {} name
set req [lindex $lbit 3]; regsub -all -- { } $req {} req
set output $ioss(t_request_body)
set output [replacevar $output "%number" "$number"]
set output [replacevar $output "%request" "$req"]
set output [replacevar $output "%name" "$name"]
sndall "ioss" $output
incr go
}
if {$go == 0} {
sndall "ioss" $ioss(t_request_no)
}
}
; except 1,2 line ... text is same to iobanana's request (req123)
; iobanan(19)'s syntax is mismatch to new ioa(1.0.?)'s syntax.
so, i delete two "set lines" for function by ########

Mouton
02-04-2004, 10:13 AM
as i said, simply replicating the requests bind would work if u already use ioBanana.tcl

bind pub - [set ioBvar(cmdpre)]requests reqalias

is already there, so u add your bind time like this:

bind time - "* * * * *" reqalias

so the same proc will be called on !requests and on timer...

glory4
02-04-2004, 10:14 PM
i can prove this problem hardly :(
but i'm not think that is waste the time

if i have a time, i hope to study about TCL language(?)

your last comment is not working.. :confused:

my test script(?)
bind time - "?0 * * * *" reqalias
bind time - "?5 * * * *" requests (for testing)
is not working

but
bind time - "00 * * * *" siterequests( see above)
is working ;)

can your comment good working by other method changing?? :confused:

Mouton
02-05-2004, 03:56 PM
now that i think about it....
bind time and bind pub probably don't require the same parameters in proc definitions.
so u would need a reqalias2... but eh... it works your way, keep it :)