Banter
The IRC protocol implemented as a Ruby mixin.
Description
irc-helpers is a collection of Modules that you can include in your classes so you can:
- Generate IRC messages:
privmsg "#ruby", "Hi #ruby!" # => PRIVMSG #ruby :Hi #ruby!
. - Look up numeric replies by constant:
RPL_WELCOME # => :"001"
.
Convenient!
Installation
gem install irc-helpers
Usage
require "irc/rfc2812"
class Bot
include IRC::RFC2812::Commands
include IRC::RFC2812::Constants
def ()
case .command
when RPL_MYINFO then join "#ruby"
when RPL_BOUNCE then "..."
end
end
# ...
end
Documentation
TODO: A link to additional documentation.
Contributing
TODO: A contribution workflow.
LICENSE
See the LICENSE file.