gdritter repos ndbl / 3de5969
Added paragraph on regularity/data properties to readme Getty Ritter 10 years ago
1 changed file(s) with 15 addition(s) and 3 deletion(s). Collapse all Expand all
3333 [TOML](https://github.com/mojombo/toml), both of which are significantly
3434 more complicated than NDBL.
3535
36 For incredibly basic configurations—in particular, if you do not use
37 grouping at all—an NDBL file is also an executable BASH file which
38 defines a slew of environment variables.
36 One major advantage of NDBL over other other configuration formats is that
37 the NDBL grammar is a _regular language_, meaning it can be parsed in
38 constant space by a finite state machine. While not intended for data
39 storage, NDBL does possess the two qualities which are important for a
40 data storage format: it is _self-describing_, meaning that you are
41 guaranteed to be able to derive the internal representation of the
42 external (serialized) document, and it is _round-tripping_, meaning that if
43 we serialize an internal representation to a document and then convert
44 back to an internal representation, we will obtain an identical internal
45 representation. Note, for example, that neither XML or YAML necessarily
46 have this property in practice.
47
48 As a pleasant but unintended side effect, an executable bash file that
49 does nothing but define environment variables is trivially an NDBL
50 file.
3951
4052 Structure of an NDBL Document
4153 -----------------------------