From 2a654463c6467af26278e00bb1a9eecaf75c5b6d Mon Sep 17 00:00:00 2001 From: Andrew Throener Date: Wed, 27 Sep 2017 13:50:58 -0500 Subject: [PATCH] Added config.js for node -r --- config.js | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 config.js diff --git a/config.js b/config.js new file mode 100644 index 0000000..3d6b469 --- /dev/null +++ b/config.js @@ -0,0 +1,11 @@ +(function () { + var options = {} + process.argv.forEach(function (val, idx, arr) { + var matches = val.match(/^dotenv_config_(.+)=(.+)/) + if (matches) { + options[matches[1]] = matches[2] + } + }) + + require('./')(options); +})() \ No newline at end of file