Here’s an example of a simple IRC bot using Cinch:
require ‘cinch’
bot = Cinch::Bot.new do
configure do |c|
c.server = “irc.freenode.org”
c.channels = [“#cinch-bots”]
endon :message, “hello” do |m|
m.reply “Hello, #{m.user.nick}”
end
endbot.start
Just install using:
gem install cinch
https://github.com/cinchrb/cinch#readme
Getting Started (in Markdown): https://github.com/cinchrb/cinch/blob/master/docs/getting_started.md
and the docs: http://rubydoc.info/gems/cinch/frames
Other IRC Bot frameworks: https://www.ruby-toolbox.com/categories/irc_bots