// TODO: // 1. Handle quoted strings, including line breaks, so that this: // foo = "bar // baz" // parses to {foo:"bar\n baz"} // 2. Escape with \, so that this: // foo = bar\ // \"baz // parses to {foo:"bar\n \"baz"} exports.parse = function(d) { var ini = {'-':{}}; var section = '-'; var lines = d.split('\n'); for (var i=0; i