You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
17 lines
410 B
17 lines
410 B
|
7 months ago
|
/*
|
||
|
|
* nconf-hierarchical-file-argv.js: Test fixture for using optimist defaults and a file store with nconf.
|
||
|
|
*
|
||
|
|
* (C) 2011, Nodejitsu Inc.
|
||
|
|
* (C) 2011, Sander Tolsma
|
||
|
|
*
|
||
|
|
*/
|
||
|
|
|
||
|
|
var path = require('path'),
|
||
|
|
nconf = require('../../../lib/nconf');
|
||
|
|
|
||
|
|
nconf.argv();
|
||
|
|
nconf.add('file', {
|
||
|
|
file: path.join(__dirname, '../hierarchy/hierarchical.json')
|
||
|
|
});
|
||
|
|
|
||
|
|
process.stdout.write(nconf.get('something') || 'undefined');
|