What is it?
Jarvis is a Node.js bot that strives to emulates the functionality of J.A.R.V.I.S. from the Iron Man movie series. Some of its commands can be found in commands.js.
How can I install Jarvis?
Clone this repository and then run
npm install to install the server's dependencies. Finally, run
node server.js to fire up the server and navigate your web browser to
How can I help?
First, enter your new command into
commands.coffee. The data that the user passed to the command can be accessed by the
exports.myAwesomeCommand = (query, res) -> # Do something awesome.
Next, add your command's trigger, prefixed by an exclamation point, into the
server.coffee. You will need to call the function you just created in the previous step. Also, note that the data the user passed to the command is the
messageparameter for the command's function. The
resvariable allows the function to send its output back to the user.
when '!yourAwesomeCommandTrigger' then commands.myAwesomeCommand message, res
Finally, add your command's documentation into the object returned by
help.coffeeas the following:
myAwesomeCommand: 'This is a description of myAwesomeCommand. `!yourAwesomeCommandTrigger query`'