Sen descrición

Alexei Sorokin f301397589 Fix PEP 8 compliance %!s(int64=8) %!d(string=hai) anos
.gitignore 1b1e5ff428 initial commit %!s(int64=8) %!d(string=hai) anos
AUTHORS 1b1e5ff428 initial commit %!s(int64=8) %!d(string=hai) anos
LICENSE 1b1e5ff428 initial commit %!s(int64=8) %!d(string=hai) anos
README.md 3f2e2c3ff4 Update README.md %!s(int64=8) %!d(string=hai) anos
example.ini c94ef4e3a1 Add [Shared] to config, with 'prefix' and 'owner' opts %!s(int64=8) %!d(string=hai) anos
hybridbot.py f301397589 Fix PEP 8 compliance %!s(int64=8) %!d(string=hai) anos
requirements.txt 451765625f Port to modern irc module %!s(int64=8) %!d(string=hai) anos

README.md

hybridbot

Hybridbot is a bot that relays messages from a IRC channel to an XMPP MUC and vice versa. First of all, you need to install sleekxmpp and irc.

su -c "pip install sleekxmpp irc"
# or
su -c "pip install -r requirements.txt"

It's configuration is simple, you have to create a config file per relay, as this example (remember to change the values):

[Shared]
prefix   = .
owner    = somebody

[IRC]
channel  = #daemons
nick     = pasarela
server   = chat.freenode.net
port     = 6667

[XMPP]
jid      = becario@daemons.cf
password = goodpassword
muc      = testeando@salas.daemons.cf
nick     = pasarela

Most of it is pretty obvious, the only two lines that need explanation are the ones in Shared.

The option "prefix" is a string that gets prefixed before the command like "!help" if prefix=!.

The option "owner" is a string that will be printed when issuing the ".help" command. It can be just something like "drymer on XMPP MUC" or just a name, your choice.

To execute it, just do:

python hybridbot.py myconfig.ini

Or if the config file is named "config.ini", just do:

python hybridbot.py

And on the MUC or the IRC channel, you can issue two commands, ".help" and ".users".