Skip to content

Instantly share code, notes, and snippets.

@bakkdoor
Created November 24, 2010 13:21
Show Gist options
  • Save bakkdoor/713642 to your computer and use it in GitHub Desktop.
Save bakkdoor/713642 to your computer and use it in GitHub Desktop.
A sample of how the FancyIRC lib could work.
bot = FancyIRC Client new: {
configuration: {
nickname: "fancy_irc"
server: "irc.freenode.net"
port: 6667
channels: ["#fancy"]
}
on: 'channel pattern: /^hello/ do: |msg| {
msg reply: $ "Hello to you too, " ++ (msg author) ++ "?"
}
}
bot connect
bot["#fancy"] send: "Hello, Fancy team. This is a fancy-written irc client =)"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment