Go Back   FlashFXP Forums > > > >

Eggdrop All eggdrop related questions

Reply
 
Thread Tools Rate Thread Display Modes
Old 01-27-2014, 06:51 AM   #1
Hans_
Junior Member
 
Join Date: Feb 2012
Posts: 28
Default "easy" (i)TCL question?

Hi all,

as you know the topstats.tcl do not work anymore..my idea was to create a small script wich gets executed via the sheduler in ioftpd (wich works fine), it generates the file with the info i want.

so the next thing is to trigger an tcl or itcl file wich actualy reads that newly generated file for ex. stats.log via the ioftpd sheduler.

if some1 got any good ideas on how to do this?

basicly: open file, read and output each line to a specified channel(s)?

any help would be greatly appreciated
Hans_ is offline   Reply With Quote
Old 01-27-2014, 07:19 PM   #2
Yil
Too much time...
FlashFXP Beta Tester
ioFTPD Administrator
 
Join Date: May 2005
Posts: 1,194
Default

Since you want to output to IRC you'll want to do that via windrop. There are many ways to do that. You could format all the output in the textfile generated by your ioFTPD script and then just print that to a channel via windrop by reading it in and sending it to a channel. You could output the data in a raw form via ioFTPD and then have the windrop script format the output. Either way you might want to think about things like !stats <nick> or whatever to output just subsets of the data. That might mean having windrop format the output is a better plan. Either way, it shouldn't be that hard but you'll have to learn some TCL to do it.

For just learning TCL you might want to look at something like Komodo from ActiveState. It won't play well with ioFTPD or windrop but you can play with it to figure out how to read a file, parse data, format text output, etc and once you've got that working things should go smoother.

I don't really have a better method of debugging ioFTPD scripts than defining a new TCL site command and calling that with lots of output to the logfile that I watch in another window... Kind of annoying, but it's the same thing in windrop as well. Server processes suck to debug.
Yil is offline   Reply With Quote
Reply

Tags
file, ioftpd, itcl, sheduler, wich

Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -5. The time now is 03:51 PM.

Parts of this site powered by vBulletin Mods & Addons from DragonByte Technologies Ltd. (Details)