Skip to content

Instantly share code, notes, and snippets.

@lkptrzk
Last active August 29, 2015 14:00
Show Gist options
  • Save lkptrzk/11057589 to your computer and use it in GitHub Desktop.
Save lkptrzk/11057589 to your computer and use it in GitHub Desktop.
node irc bot
// quick sketch based on http://davidwalsh.name/nodejs-irc
var Irc = require('irc')
var settings = {
channels: [
'#node.js'
],
server: 'irc.freenode.net',
botName: 'idlebot'
}
var bot = new Irc.Client(settings.server, settings.botName, {
channels: settings.channels
})
bot.addListener('message', function (from, to, text, message) {
console.log(Date())
console.dir(message)
})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment