From 2a099cb59486e5463bdf667496720bedf79e3aee Mon Sep 17 00:00:00 2001 From: William Duyck Date: Fri, 20 Jun 2014 13:20:02 +0100 Subject: [PATCH] udpate docs --- package.json | 2 +- readme.md | 68 +++++++++++++++++++++++++++++++++++++++++++++++----- 2 files changed, 63 insertions(+), 7 deletions(-) diff --git a/package.json b/package.json index 48946b0..9bdf445 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "thunderhug", - "version": "0.0.9", + "version": "0.0.10", "description": "A call for proposals app that uses Google Spreadsheets to store sessions and keep out of your way.", "scripts": { "test": "grunt test", diff --git a/readme.md b/readme.md index b8c671f..606149d 100644 --- a/readme.md +++ b/readme.md @@ -2,13 +2,59 @@ A call for proposals app that uses Google Spreadsheets to store sessions and keep out of your way. -## Usage +## Setup +### Install +Grab yourself a copy of ThunderHug, best bet is to grab the master branch as +this is being kept for working builds ;) - // information to come w/ app +```sh -### Public API + $ npm install + $ cp config.dist.json config.json -#### /api/all +``` + +### Configure +ThudnerHug allows for multiple types of config, however for local development +its easiest to use config.json (created during install). + +```json + + { + // the key for the spreadsheet the data lives in + "GOOGLE_KEY": "", + + // google account user name so ThunderHug can access protected sheets + "GOOGLE_USER": "", + + // password for google account + "GOOGLE_USER_PASS": "", + + // how often to run checks for new sessions (set to 1hr by default) + "POLL_INTERVAL": 3600000, + + // what column name contains flags indicating public data + "PUBLIC_FLAG": "reviewed", + + // a prefix for redis keys + "REDIS_PREFIX": "thunderhug", + + // default port to run on + "PORT": 4000 + } + +``` + +**All settings are required** for ThunderHug to run. Make sure these are set +before attempting to run the server. + +### Run +In a production environment use `node server.js` however for development you can +launch the server (and relaunch when changes occur) automagically using `grunt` + +## Public API + +### /api/all Returns all session proposals that have been reviewed along with metadata about what possible tracks there are, possible session formats, and how many proposals have been made so far (inc. unreviewed). @@ -51,7 +97,7 @@ have been made so far (inc. unreviewed). ] } -#### /api/:track_slug +### /api/:track_slug Returns all session proposals for the given track, along with metadata about the requested track, all possible session formats, and how many proposals have been made for this track (inc. unreviewed). @@ -87,7 +133,17 @@ made for this track (inc. unreviewed). ## Deploy (heroku) - // information to come w/ app +```sh + + git push heroku master + heroku config:set GOOGLE_KEY='' + heroku config:set GOOGLE_USER='' + heroku config:set GOOGLE_USER_PASS='' + heroku config:set POLL_INTERVAL=360000 + heroku config:set PUBLIC_FLAG='reviewed' + heroku config:set REDIS_PREFIX='thunderhug' + +``` ## License This Source Code Form is subject to the terms of the Mozilla Public License,