mirror of
https://github.com/nealey/irc-bot
synced 2025-01-08 20:30:36 -07:00
20 lines
294 B
Bash
Executable file
20 lines
294 B
Bash
Executable file
#! /bin/sh -e
|
|
|
|
botdir=$1
|
|
ircdir=$(dirname $0)
|
|
export botdir ircdir
|
|
|
|
# UCSPI wants communication on fd7
|
|
if [ -n "$PROTO" ]; then
|
|
fd=7
|
|
else
|
|
fd=1
|
|
fi
|
|
|
|
$botdir/login 1>& $fd
|
|
|
|
if [ -p $botdir/fifo ]; then
|
|
fifo="-f $botdir/fifo"
|
|
fi
|
|
|
|
exec $ircdir/dispatch $fifo $ircdir/irc $botdir/handler
|