This is the new home of the egghelp.org community forum.
All data has been migrated (including user logins/passwords) to a new phpBB version.


For more information, see this announcement post. Click the X in the top right-corner of this box to dismiss this message.

Eggdrop and Pisg

Old posts that have not been replied to for several years.
Locked
T
The Mad One
Voice
Posts: 15
Joined: Sun Oct 06, 2002 12:31 pm

Eggdrop and Pisg

Post by The Mad One »

I'm using pisg to make html stats off the eggdrop logs and are updated at 12am every day, i want the bot to announce when the stats have been updated by pisg. A couple of days ago i was given this script and has been said to of worked but it does not with me i was wondering if someone could look at it and see if theres anything wrong with it:

Code: Select all

#!/bin/sh
 
/path/to/pisg --silent
  
time="`tail /path/to/generated/webpage/index.html -n 5 | grep -i stats | tr '[:upper:]' '[:lower:]'`"
 
#This is for the bot-announce
( echo ChangeMeToBotOwner
  sleep 1
  echo ChangeMeToPassword
  sleep 1
  echo ".say #KOD A new day is upon us. #KOD channel-$time. Please visit URL"
  sleep 1
  echo ".q"  ) | telnet localhost 6456
the top bit that starts pisg and gets the time from the generated html page i am not really bothered with i just need a bash script or a tcl script that i can put on the bot or crontab so it announces the update every day.

thanks
p
ppslim
Revered One
Posts: 3914
Joined: Sun Sep 23, 2001 8:00 pm
Location: Liverpool, England

Post by ppslim »

There are several reason why this may not work, most of them configuration related.

You will need to change the telnet command at the bottom, to reflect the hostname and port of the eggdrop you are connecting to.

Next you will need to makesure the username and password are correct, so it can loggin to the bot.

Also, make sure that the path to psig is corrct.

This isn't the bext way to go abotu this, but it should work.
T
The Mad One
Voice
Posts: 15
Joined: Sun Oct 06, 2002 12:31 pm

Post by The Mad One »

yer i changed my login/password and pisg path but i wasnt going to give them away on this form :)

the telnet local host bit im not sure about, what should it be? the ip of the bot? or the address that i use to log onto ssh with putty?
T
The Mad One
Voice
Posts: 15
Joined: Sun Oct 06, 2002 12:31 pm

Post by The Mad One »

ok so its the bot ip i tested it by putting the telnet command into putty

but it doesnt seem to work ive changed the code so its like this im not really bother about the time:

Code: Select all

#/local/bash

../pisg/pisg --silent 

#This is for the bot-announce
( echo The_Mad_O
  sleep 1
  echo password
  sleep 1
  echo ".say #kod A new day is upon us. Please visit http://thunder.pyroshells.com/~WeOwn/channelstats/qnetkod.html for the channel stats."
  sleep 1
  echo ".q"  ) | telnet 138.121.46.93 port
now the script definatly starts pisg but i get these to errors after starting it:

[WeOwn@thunder (~/pisg)]$ ./pisgbot
: command not found
: command not found
138.121.46.93: servname not supported for ai_socktype
[WeOwn@thunder (~/pisg)]$

any ideas cause i havnt a clue what that means
Locked