From f18da1b6e6fac8aa1e63977400e39c4774cbf5fe Mon Sep 17 00:00:00 2001 From: Eran Date: Fri, 25 Jul 2014 15:49:54 -0400 Subject: [PATCH] Update readme for new config strategy --- README.md | 31 ++++++++++++++++--------------- 1 file changed, 16 insertions(+), 15 deletions(-) diff --git a/README.md b/README.md index c588e96..356c5b3 100644 --- a/README.md +++ b/README.md @@ -3,22 +3,23 @@ skitty The Plug.dj bot for [Coding Soundtrack Lounge](http://plug.dj/coding-soundtrack-lounge/) that runs on Node.js ## How To Use - 1. Clone the Repo -2. Run ```npm install``` to get all the dependancies. -3. Copy appTemplate.js, create a new file and add your bots info and room info. +2. Run `npm install` to get all the dependancies. +3. Copy `config.example.js` to `config.js` and complete each field. + ``` js + module.exports = { + plug : { + room : 'room-name', + auth : 'usr-cookieue' + }, + mongo : 'mongodb://:@:/' + }; ``` - var model = { - room: '', //Name of Plug.dj room - auth: 'xxxxxxxxxxxxxxxxxxxxxxxxxxx=?_expires=xxxxxxxxxxxxxxxxxx==&user_id=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=', // Put your auth token here, it's the cookie value for usr - reconnectDelay: 1000, - reconnectAttempts: 5 - }, - ``` - - This is the file that you will run. - After you have your app.js file setup, go ahead and start it up on a node server. (from CLI in the root of the bot run "node app.js") + + To find your usr-cookie-value, check out [this](https://github.com/TATDK/plugapi/wiki/How-to-get-your-auth-token) tutorial. +4. Fire up [MongoDB](http://www.mongodb.org/) +5. Launch bot `node app.js` -If you frequent the room feel free to send me a pull request. -Have fun! +If you frequent the room and wish to contribute, feel free open a pull request or issue. +Have fun! \ No newline at end of file