Skip to content

Instantly share code, notes, and snippets.

@nlacasse
Created December 6, 2010 20:21
Show Gist options
  • Save nlacasse/730882 to your computer and use it in GitHub Desktop.
Save nlacasse/730882 to your computer and use it in GitHub Desktop.
walnuts
var jerk = require('jerk');
var options = {
server: 'iriecycle.net',
port: 6600,
nick: 'walnuts',
user: {
username: 'walnuts',
hostname: 'walnuts',
realname: 'walnuts',
servername: 'walnuts'
}
};
var walnuts = jerk(function(j) {
j.watch_for(/walnuts/i, function(message) {
message.say(message.user + ': Thats me! Walnuts!!!');
})
}).connect(options);
// HACKS. The first of these join()s is ignored, but needed for the second to work
setTimeout(function () {
walnuts.join('#italisvital');
}, 1000);
setTimeout(function () {
walnuts.join('#italisvital');
}, 5000);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment