forfuturellc / mmtc-ke

Mobile Money Transaction Cost in Kenya
https://mmtc.forfuture.tech
MIT License
4 stars 2 forks source link

Dev experience #10

Closed BransonGitomeh closed 8 years ago

BransonGitomeh commented 8 years ago
branie@branie-Inspiron-3521 ~/Desktop/mmtc-ke $ npm start

> mmtc-ke@0.1.0 start /home/branie/Desktop/mmtc-ke
> forever app.js

warn:    --minUptime not set. Defaulting to: 1000ms
warn:    --spinSleepTime not set. Your script will exit if it does not stay up for at least 1000ms
info: server listening

so i run the app and therez some basic info that we can add, port ?? whats that downtime thing?...

i have an app with some cool console logging we can borrow from

like

...
[nodemon] watching 43 files
http://localhost:8080/webpack-dev-server/
webpack result is served from /
content is served from /home/branie/Desktop/Genesis
12:15:38.310Z  INFO core: Innitialized Cors support
12:15:38.326Z  INFO core: Configuring body-parser
12:15:38.625Z  INFO core: Aquiring a Waterline instance
12:15:38.626Z  INFO core: reading all collections
12:15:38.640Z  INFO core: Collections 'disk Adapter' && 'safe Migration'
12:15:38.640Z  INFO core: Innitializing waterline...
12:15:40.413Z  INFO core: Backend config complete, next()
12:15:40.413Z  INFO core: Confuguring all routes
12:15:40.502Z  INFO core: Attemting to start server
12:15:40.546Z  INFO core: Api  :smile: @-> http://localhost:3000

so we can generally know whats happening when the app is working /restarting

GochoMugo commented 8 years ago

I forgot to add a script for starting the application in devmode. It will be:

DEBUG=mmtc-ke:* node app.js

Note: Add documentation ( issue #9 ): starting application in devmode

BransonGitomeh commented 8 years ago

npm run mmtc is easy and straightforward

BransonGitomeh commented 8 years ago

leave npm start/ node app.js to server deployment

GochoMugo commented 8 years ago

Yeah! start will be for production mode while start-dev will be for development mode. It feels more conventional that way, don't you think?

BransonGitomeh commented 8 years ago

aam :-) anything that does that in one command , and doesn't feel like i'm starting a bomb in debug mode, is alright

GochoMugo commented 8 years ago

Added in v0.2.0