Skip to content

Commit

Permalink
Env variable to control logger verbosity
Browse files Browse the repository at this point in the history
  • Loading branch information
mddub committed Oct 10, 2015
1 parent 6990043 commit 386a9de
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 3 additions & 1 deletion logger.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,7 @@
"use strict";

module.exports.log = function(str) {
console.log(new Date() + ' ' + str);
if (process.env['MINIMED_CONNECT_VERBOSE']) {
console.log(new Date() + ' ' + str);
}
};
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
},
"main": "index.js",
"scripts": {
"start": "node run.js"
"start": "MINIMED_CONNECT_VERBOSE=true node run.js"
},
"license": "MIT",
"dependencies": {
Expand Down

0 comments on commit 386a9de

Please sign in to comment.