-#CamperBot! [![Join the chat at https://gitter.im/FreeCodeCamp/camperbot](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/FreeCodeCamp/camperbot) [![Stories in Ready](https://badge.waffle.io/FreeCodeCamp/camperbot.png?label=ready&title=Ready)](https://waffle.io/FreeCodeCamp/camperbot)
+#CamperBot
-This is a full featured bot for [Gitter.im/FreeCodeCamp](https://gitter.im/orgs/FreeCodeCamp/rooms) chat rooms.
+[![Join the chat at https://gitter.im/FreeCodeCamp/camperbot](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/FreeCodeCamp/camperbot) [![Stories in Ready](https://badge.waffle.io/FreeCodeCamp/camperbot.png?label=ready&title=Ready)](https://waffle.io/FreeCodeCamp/camperbot)
CamperBot was originally created by for [Free Code Camp](http://www.freecodecamp.com) by [@dcsan](https://github.com/dcsan) at [RIKAI Labs](mailto:dc@rikai.co), and is now maintained by our open source community.
+-[Chat with us!](https://github.com/FreeCodeCamp/camperbot/#chat-with-us)
##Introducing CamperBot!
-CamperBot is a full featured chat bot for [Gitter.im](https://gitter.im) developed to integrate with the chat rooms for [FreeCodeCamp — the largest online coding bootcamp in the world](http://www.freecodecamp.com/), where it serves more than 60,000 campers.
+
+CamperBot is a full featured chat bot for [Gitter.im](https://gitter.im)
+developed to integrate with the chat rooms for
+[FreeCodeCamp — the largest online coding bootcamp in the world](http://www.freecodecamp.com/)
+, where it serves more than 60,000 campers.
###Github Wiki Search
-You can search for articles in a projects github wiki![](https://freecodecamp.github.io/camperbot/images/anims/find.gif)
+
+You can search for articles in a projects github wiki
-The `dot.env` file you copied above contains login info. This is using the shared "demobot" account so you may find yourself in a chatroom with other people using the same ID!
-To setup your own gitter login info, you should create your own Gitter API key on their developer site, and replace the info in that `.env` file. Get your own API keys for gitter from: [https://developer.gitter.im/apps](https://developer.gitter.im/apps)
+The `dot.env` file you copied above contains login info.
+This is using the shared "demobot" account so you may find yourself in a
+chatroom with other people using the same ID!
-For more settings info, checkout the `AppConfig.js` and `RoomData.js` files. These define which rooms the bot will listen in to.
+To setup your own gitter login info, you should create your own Gitter API key
+on their developer site, and replace the info in that `.env` file.
+For more settings info, checkout the `AppConfig.js` and `RoomData.js` files.
+These define which rooms the bot will listen in to.
You may chat with us in the CamperBot Dev chat room if you have problems. [camperbot chatroom](https://gitter.im/FreeCodeCamp/camperbot).
###Running tests
-There are other commands in `bin` for running tests with the right config files etc
-To run the tests with the right configs
-```sh
-bin/test.sh
-```
+Tests are located in the `test/` folder can be run, along with linting,
+by running `gulp`.
+This is a watch task that will rerun whenever a `.js` file changes.
##Wiki Content
-The wiki content is pulled in from FCC's wiki using a git submodule. But then we just copy it and commit it back to the main app as submodules are nasty to deal with on production servers.
+
+The wiki content is pulled in from FCC's wiki using a git submodule.
+But then we just copy it and commit it back to the main app as submodules
+are nasty to deal with on production servers.
```sh
bin/wiki-update.sh
@@ -138,23 +174,35 @@ bin/wiki-update.sh
##System Overview
###data/RoomData.js
+
The list of rooms your bot is going to join.
To start with create your own bot, a test room to enter and debug in.
-This needs to be changed so you would only join your own rooms, otherwise developers will get into a situation where everyone is joining the same rooms and the bots go crazy talking to each other!
+This needs to be changed so you would only join your own rooms, otherwise
+developers will get into a situation where everyone is joining the same
+rooms and the bots go crazy talking to each other!
###lib/bot/BotCommands.js
-This is where you add things that the bot can do. Some commands are broken into separate files such as `cmds/thanks.js` and `cmds/update.js`.
-Each command gets a `input` which is a blob of data including what the user entered, and a bot instance.
+
+This is where you add things that the bot can do. Some commands are broken
+into separate files such as `cmds/thanks.js` and `cmds/update.js`.
+Each command gets a `input` which is a blob of data including what the user
+entered, and a bot instance.
###KBase.js
+
The Knowledge base. This is an interface to all the data in the wiki.
###RoomMessages.js
-This is for static messages that are fired based on regex matches. If you just want to add some basic responses, this is the place to edit.
+
+This is for static messages that are fired based on regex matches.
+If you just want to add some basic responses, this is the place to edit.
###How to add a new Bot Command
-Look at `BotCommands`, `echo` function. This is an example of a command being called. Anytime a user types a line starting with `echo` that will get passed to this function in input.
+
+Look at `BotCommands`, `echo` function. This is an example of a command being
+called. Anytime a user types a line starting with `echo` that will get passed
+to this function in input.
```js
echo:function(input, bot) {
@@ -163,7 +211,8 @@ echo: function(input, bot) {
}
```
-The input object contains `keyword` and `params` fields. If you type `echo this` you'll get
+The input object contains `keyword` and `params` fields.
+If you type `echo this` you'll get
```js
//input
@@ -226,6 +275,7 @@ In `RoomMessages.js` we also have a table of regex and matching functions.
## Environment Notes
### wiki data
+
We use git submodules for some wiki data. to get these submodules you would do:
-Have a look at the [HelpWanted](https://github.com/FreeCodeCamp/camperbot/issues?q=is%3Aopen+label%3A%22help+wanted%22) label issues and consider making some first steps!
-The labels, P1 = priority one, and 'S' means a small task, so good places to start.
0 comments on commit
dc88209