greenbagels / greenbot

IRC bot written in C++
MIT License
5 stars 1 forks source link

greenbot

Coverity Scan Build Status Build Status

A configurable chat based bot written in C++.

Building

Prerequisites:

./configure
make
./greenbot

Adding modules

All that is required for a module is a header file in modules/inc that contains a class that implements the Callback class (defined in src/inc/bot.h). The implementation of the module can go in modules/ as a .cpp file and it will be automatically compiled. The configure script will scan the header files in modules/inc to generate a new header file src/inc/modules.h, which will allow the src/core.cpp to call the function LoadModules. This means you do not need to modify any existing code to add a module, simply drop in the new files.

In order for the files to be recognized they will need a header of the form

//MODULE:[ClassName]
//LIBS:-l[libname1] -l[libname2]

where [ClassName] is the name of the class that implements the Callback class and [libname] are any library dependencies the module has. If there are no library dependencies, you may omit the //LIBS line. Check out the modules currently added for examples.

Contact

If you need to directly contact someone you can join #greenbot on irc.rizon.net (someone is almost always there)

TODO