1.2 KiB
1.2 KiB
input
:
- The named pipe to talk as the bot.
bin/
:
raw
- Sends$1
to freenode.reply
- Uses env vars to send message$@
.result
- Like reply, but does not prependnick:
.privmsg
- Sends privmsg to$1
, with messageshift;$@
.notice
- Sends privmsg to$1
, with messageshift;$@
.action
- Sends ctcp action to$1
, with messageshift;$@
.ctcp
- Sends a ctcp query, returns the response.connect
- Connects to IRC, calls commands inirc/
, listens toinput
, and writes to log the file.hateweek/start
- Begins hateweek mode.hateweek/end
- Ends hateweek mode.hateweek/isnow
- Check to see if hateweek is now (returns 0 if now, 1 if not now).
log.txt
:
- The single file that has all of the logs.
- Uses the IRC format with a timestamp prepended.
irc/
:
- IRC commands are run as shell commands.
bin/
is in theirPATH
.- Set up env vars before calling various functions.
- Add data to log files if needed.
Env vars:
$acct
: NickServ account name, or\*
.$nick
$cmd
$where
$msg
/tmp/happybot/
:
- directory for temporary information
nick
- The bot's nick.acct
- Look up account name by nick.- Either a directory, or a file.