No, because I like YAML's line-delimited format. I want to force
people to write config files that aren't messy by cramming
everything on a single line. =)
Well, YAML doesn't force you to write things in the line
delimited format, you can happily use braces and mush it all
together. (You do know that JSON is a subset of YAML, right?)
I'd be tempted to say that if you want a config file that you
have to delimit with lines, perhaps the Java properties file format
or the windows ini file format might be good. They're insanely easy
to parse, and are easier for people who don't know the format to
grok. (Complex YAML files are positively close to line noise, if
you don't know all the delimiters)
It's because of YAML's ability to mush it together I think the
standard is too big (among other things). And I do know JSON is a
subset.
The reason I don't like Java property files is that they are not
order-specific when you need that. Plus I just like using
indentation to denote scope. =)
And that line about complex YAML files being hard to read is why
I thought a subset of YAML (or something similar) which was
much simpler would be great to have.
You and your indentation addiction. I think I've figured out
what you want: PON. ;)
All kidding aside, it seems that it wouldn't be that hard to
implement what you want, since it would be semantically JSON, just
with a slightly different syntax.
ConfigObj using the 'unrepr' mode is pretty good for simple
config files. It is 'key' 'value' pairs and you use Python syntax
for the values (numbers, floats, lists, strings etc.)
In fact ConfigObj without 'unrepr' mode is pretty damn good for
config files...
10 comments so far
I think you want JSON.
9 months, 2 weeks ago by ajani.
No, because I like YAML's line-delimited format. I want to force people to write config files that aren't messy by cramming everything on a single line. =)
9 months, 2 weeks ago by brettsky.
Well, YAML doesn't force you to write things in the line delimited format, you can happily use braces and mush it all together. (You do know that JSON is a subset of YAML, right?)
I'd be tempted to say that if you want a config file that you have to delimit with lines, perhaps the Java properties file format or the windows ini file format might be good. They're insanely easy to parse, and are easier for people who don't know the format to grok. (Complex YAML files are positively close to line noise, if you don't know all the delimiters)
9 months, 2 weeks ago by ajani.
It's because of YAML's ability to mush it together I think the standard is too big (among other things). And I do know JSON is a subset.
The reason I don't like Java property files is that they are not order-specific when you need that. Plus I just like using indentation to denote scope. =)
And that line about complex YAML files being hard to read is why I thought a subset of YAML (or something similar) which was much simpler would be great to have.
9 months, 2 weeks ago by brettsky.
You and your indentation addiction. I think I've figured out what you want: PON. ;)
All kidding aside, it seems that it wouldn't be that hard to implement what you want, since it would be semantically JSON, just with a slightly different syntax.
9 months, 2 weeks ago by ajani.
Oh, and I'm all for simple formats, so now you have me wondering How hard could it be?
9 months, 2 weeks ago by ajani.
grah. It destroyed my silly %gt;TopGear< tags. (We'll see if the escapes go through)
9 months, 2 weeks ago by ajani.
I give up. enough replying to myself and adding noise.
9 months, 2 weeks ago by ajani.
Good point; it could just be JSON with line-delimited scope.
And your TopGear tags showed up in the email.
9 months, 2 weeks ago by brettsky.
ConfigObj using the 'unrepr' mode is pretty good for simple config files. It is 'key' 'value' pairs and you use Python syntax for the values (numbers, floats, lists, strings etc.)
In fact ConfigObj without 'unrepr' mode is pretty damn good for config files...
9 months, 2 weeks ago by voidspace.