summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJules Laplace <jules@okfoc.us>2015-09-04 22:49:50 -0400
committerJules Laplace <jules@okfoc.us>2015-09-04 22:49:50 -0400
commitc609f54f161901098cdcd3739b3591e486ceb238 (patch)
tree391d4696931c12e25676351d6a714915a9425640
parent43cc797baac3b5e82552c3c6b1e57350d6384598 (diff)
instructions
-rw-r--r--README23
-rw-r--r--lib/bucky.js3
2 files changed, 21 insertions, 5 deletions
diff --git a/README b/README
index 1b2ad43..810d9d3 100644
--- a/README
+++ b/README
@@ -1,9 +1,22 @@
bucky
=====
-1. npm install
-2. install mysql (used for main database)
-3. install mongodb (used for sessions)
-4. copy .env-sample to .env and edit the values
-5. run `node index`
+# npm install
+# brew install mysql (used for main database)
+# brew install mongodb (used for sessions)
+# set up the mysql database:
+mysql -uroot
+CREATE USER 'carbon'@'localhost' IDENTIFIED BY 'the_password';
+CREATE DATABASE bucky;
+USE bucky;
+GRANT ALL PRIVILEGES ON bucky.* TO 'carbon'@'localhost';
+
+# copy .env-sample to .env and edit the values to correspond
+# load up a copy of bucky
+
+mysql -u carbon -p bucky < bucky-20150903.sql
+
+# node index
+
+Server will be running at http://lvh.me:5000/
diff --git a/lib/bucky.js b/lib/bucky.js
index 6022bb2..9ec28f4 100644
--- a/lib/bucky.js
+++ b/lib/bucky.js
@@ -13,7 +13,10 @@ var bucky = module.exports = {
ensureCommentCountsForThreads: function (req, res, next){
var ids = res.threads.pluck("id")
db.getCommentCounts(ids).then(function(counts){
+ var lookup = {}
console.log(counts)
+ counts.forEach(function(count){
+ })
next()
})
},