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.

sending privmsgs from shell.

Old posts that have not been replied to for several years.
Locked
K
KeMiJohN
Voice
Posts: 1
Joined: Mon Oct 10, 2005 8:10 am

sending privmsgs from shell.

Post by KeMiJohN »

is it possible to send a PRIVMSG from the linux shell?

or maybe make a shell script that is executed with 2 parameters, (nick and message) and then sends $message to $nick via a PRIVMSG?
User avatar
demond
Revered One
Posts: 3073
Joined: Sat Jun 12, 2004 9:58 am
Location: San Francisco, CA
Contact:

Post by demond »

Code: Select all

#!/bin/sh
# This line continues for Tcl, but is a single line for 'sh' \
exec tclsh "$0" ${1+"$@"}
set s [socket irc.server.com 6667]
puts $s "nick foo\nuser bar x x moo"
puts $s "privmsg [lindex $argv 0] :[join [lrange $argv 1 e]]"
puts $s quit
close $s
(this might not work on servers that send ping cookie on connect and expect reply, registering client upon receiving it)
connection, sharing, dcc problems? click <here>
before asking for scripting help, read <this>
use

Code: Select all

 tag when posting logs, code
Locked