Merge branch 'master' of https://github.com/AvianFlu/nconf
This commit is contained in:
commit
1b47f58343
3 changed files with 3 additions and 2 deletions
|
@ -22,7 +22,7 @@ Using nconf is easy; it is designed to be a simple key-value store with support
|
|||
nconf = require('nconf');
|
||||
|
||||
//
|
||||
// Setup nconf to user the 'file' store and set a couple of values;
|
||||
// Setup nconf to use the 'file' store and set a couple of values;
|
||||
//
|
||||
nconf.use('file', { file: 'path/to/your/config.json' });
|
||||
nconf.set('database:host', '127.0.0.1');
|
||||
|
|
|
@ -122,6 +122,7 @@ File.prototype.loadSync = function (callback) {
|
|||
}
|
||||
|
||||
if (err) {
|
||||
err.message = "Error parsing your JSON configuration file."
|
||||
throw err;
|
||||
}
|
||||
|
||||
|
|
2
usage.js
2
usage.js
|
@ -3,7 +3,7 @@ var fs = require('fs'),
|
|||
nconf = require('./lib/nconf');
|
||||
|
||||
//
|
||||
// Setup nconf to user the 'file' store and set a couple of values;
|
||||
// Setup nconf to use the 'file' store and set a couple of values;
|
||||
//
|
||||
nconf.use('file', { file: path.join(__dirname, 'config.json') });
|
||||
nconf.set('database:host', '127.0.0.1');
|
||||
|
|
Loading…
Reference in a new issue