fix a run bug

This commit is contained in:
Neale Pickett 2011-09-20 10:39:41 -05:00
parent 12d1b626a8
commit da716ad947
2 changed files with 18 additions and 2 deletions

View File

@ -19,6 +19,21 @@ join () {
raw "JOIN $1" raw "JOIN $1"
} }
cobalt () {
case "$1" in
air)
w3m -dump -cols 9999 'http://environweb.lanl.gov/Teom/teom30s.asp?MasterSiteID=211&offset=0' 2> /dev/null | \
awk '/.:..:.. .M/ {print "Los Alamos Air: " $5 "μg/m³ at " $2; exit}'
;;
nachos)
echo "aieeeee"
;;
*)
return 1
;;
esac
}
out=$(tempfile) out=$(tempfile)
case $command in case $command in
@ -33,6 +48,7 @@ case $command in
PRIVMSG) PRIVMSG)
case "$forum" in case "$forum" in
\#*) \#*)
cobalt "$text" || \
$ircdir/firebot "$text" || \ $ircdir/firebot "$text" || \
$ircdir/whuffie $botdir/whuffie.cdb "$text" || \ $ircdir/whuffie $botdir/whuffie.cdb "$text" || \
$ircdir/infobot $botdir/factoids.cdb "$text" $ircdir/infobot $botdir/factoids.cdb "$text"

4
run
View File

@ -11,6 +11,6 @@ if [ ! -d "$botdir" ]; then
fi fi
while true; do while true; do
$botdir/connect $d/connect-handler $botdir $botdir/connect $ircdir/connect-handler $botdir
sleep 5 sleep 5
done done