The bot running to bridge tildes as needed.
Go to file
Steve Dougherty 3e516c9d70 Whitespace. 2012-07-16 18:06:00 -04:00
.gitignore Initial config file implementation. Doesn't include nickname. 2012-03-03 01:41:51 -05:00
README.md Should likely use pip - distro packages can be outdated. 2012-03-14 11:17:14 -04:00
relaybot.config_sample Add experimental server password support. 2012-07-03 20:14:14 -04:00
relaybot.py Whitespace. 2012-07-16 18:06:00 -04:00
run.sh Support for and script to make it easier to run with twistd. 2012-03-02 22:16:43 -05:00

README.md

RelayBot

A two-way IRC bridge bot for bridging multiple arbitrary IRC channels. It is written in Python and uses Twisted. It is based off of relaybot, and aims to be less complicated by doing less.

This was written as I gutted relaybot while trying stop the second relay bot from failing to connect, preventing the relay from functioning. As such, it does not provide relaybot's support for runtime configuration changes or passworded channels. The design does not unduly impede the implementation of these abilities if need be. Unlike relaybot, RelayBot allows connecting to different ports on the same host simultaniously.

This distribution includes run.sh for easier control of the daemon.

Modes

  • Default: simple two-way relaying.
  • NickServ: authenticates with nickserv before joining channels.
  • FLIP: specialized mode for FLIP which removes the numbered suffix on outgoing usernames.

Requirements

  • Python 2.6.6-ish or higher
  • Twisted: pip install Twisted

Usage

Edit the sample config file as desired. If no local value exists for a section and the default is not defined, startup will fail.

sh run.sh start

Internals

On startup, the config file is read, and for each section the local entry is preferred over the default one. For each defined host, an instance of IRCRelay or a subclass thereof (depending on mode) connects to the host and joins the channel. Each instance relays events to the others though a global Communicator class with which it registers. When the bot recieves a message, if it is to the channel it relays it, and if it is a private message to the bot it replies directly to the sender with the content of info. If a message to the channel starts with the bot's name followed by a colon, it announces info to the channel.