Permalink
Browse files

Move around files into a way that makes more sense

  • Loading branch information...
1 parent 7faab45 commit 9d2a21cc07bb9269fa5b22ba650eec7f2582873f @skalnik committed Dec 31, 2011
Showing with 26 additions and 26 deletions.
  1. +1 −1 Procfile
  2. +22 −3 app.coffee
  3. +0 −22 bin/server
  4. +3 −0 routes.coffee
View
2 Procfile
@@ -1 +1 @@
-web: ./node_modules/.bin/coffee bin/server
+web: ./node_modules/.bin/coffee app.coffee
View
25 app.coffee 100644 → 100755
@@ -1,3 +1,22 @@
-module.exports = (app) ->
- app.get '/', (req, res) ->
- res.json {response: 'Success!'}, 200
+express = require 'express'
+
+app = express.createServer();
+
+routes = require('./routes')(app)
+
+app.configure ->
+ app.use express.logger()
+ app.use express.bodyParser()
+ app.use express.methodOverride()
+ app.use app.router
+
+app.configure 'development', ->
+ app.use express.errorHandler({ dumpExceptions: true, showStack: true })
+
+app.configure 'production', ->
+ app.use express.errorHandler()
+
+port = process.env.PORT || 3000
+
+app.listen port, ->
+ console.log "Listening on #{port}"
View
22 bin/server
@@ -1,22 +0,0 @@
-express = require 'express'
-
-app = express.createServer();
-
-routes = require('../app')(app)
-
-app.configure ->
- app.use express.logger()
- app.use express.bodyParser()
- app.use express.methodOverride()
- app.use app.router
-
-app.configure 'development', ->
- app.use express.errorHandler({ dumpExceptions: true, showStack: true })
-
-app.configure 'production', ->
- app.use express.errorHandler()
-
-port = process.env.PORT || 3000
-
-app.listen port, ->
- console.log "Listening on #{port}"
View
3 routes.coffee
@@ -0,0 +1,3 @@
+module.exports = (app) ->
+ app.get '/', (req, res) ->
+ res.json {response: 'Success!'}, 200

0 comments on commit 9d2a21c

Please sign in to comment.