diff --git a/package.json b/package.json
index 4f90403..8810d20 100644
--- a/package.json
+++ b/package.json
@@ -15,6 +15,7 @@
"passport-local": "^1.0.0",
"pg": "^4.4.3",
"serve-favicon": "^2.3.0",
+ "socket.io": "^1.5.1",
"sqlite3": "^3.0.8",
"winston": "^2.1.1"
},
diff --git a/server.js b/server.js
index 838929f..3b7b73d 100644
--- a/server.js
+++ b/server.js
@@ -140,6 +140,16 @@ app.get('/logout', function(req, res){
res.redirect('/');
});
-app.listen(3000, function() {
+var http = require('http').Server(app);
+var io = require('socket.io')(http);
+
+io.on('connection', function(socket){
+ //winston.info('a user connected');
+ socket.on('cm-save', function(msg){
+ winston.info(msg);
+ });
+});
+
+http.listen(3000, function() {
winston.info("Started on PORT 3000");
});
diff --git a/views/index.hbs b/views/index.hbs
index fc1aa0b..a5492f3 100644
--- a/views/index.hbs
+++ b/views/index.hbs
@@ -16,6 +16,7 @@
+