Skip to content

Instantly share code, notes, and snippets.

@rsms
Created October 27, 2010 19:01
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save rsms/649715 to your computer and use it in GitHub Desktop.
Save rsms/649715 to your computer and use it in GitHub Desktop.
// using a node-native Script with a new context, one can retrieve that context thus eliminating the need for "exports":
database = {
host: 'localhost', port: 1234
// unixsocket: '/tmp/foo.sock'
}
debug = true
log_level = exports.debug ? 2 : 1
cats = ['joe', 'bastard', 'busta']
[database]
host: localhost
port: 1234
#unixsocket: /tmp/foo.sock
[general]
debug: true
log_level: 2
cats: 'joe','bastard','busta'
exports.database = {
host: 'localhost', port: 1234
// unixsocket: '/tmp/foo.sock'
}
exports.debug = true
exports.log_level = exports.debug ? 2 : 1
exports.cats = ['joe', 'bastard', 'busta']
{
"database": {
"host": "localhost",
"port": 1234
},
"debug": true,
"log_level": 2,
"cats": ['joe', 'bastard', 'busta'],
}
database:
host: localhost
port: 1234
// unixsocket: /tmp/foo.sock
debug: true
log_level: 2
cats:
- joe
- bastard
- busta
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment