requirejs.config({
baseUrl: 'lib',
paths: {
hackbot: '../hackbot',
underscorish: 'underscorish',
chatbuilder: 'http://chatbuilder.hackreactor.com/ChatBuilder'
}
});
Getting Started With Hackbot
requirejs.config({
baseUrl: 'lib',
paths: {
hackbot: '../hackbot',
underscorish: 'underscorish',
chatbuilder: 'http://chatbuilder.hackreactor.com/ChatBuilder'
}
});
Define dependencies
requirejs(['hackbot/robot', 'chatbuilder'], function(){
Launch your Hackbot:
Create a Robot instance and give it a name;
load scripts defined in script.js
and start the robot adapter, thats it.
robot = new Robot(Chat.username != 'anonymous' ? Chat.username : null);
robot.load();
robot.run();
});
Hackbot is heavily inspired by Hubot and its architecture is “almost” identical. For other scripts to be ported to hackbot you can then check the hubot scripts cataloge