2009/8/19 Vladimir 'phcoder' Serbinenko <phco...@gmail.com>: >>> To have level or tree-like model you can use '.' as a name separator >>> it will make the system uniform with current FreeBSD booting. >> >> XML/CSS is not the easiest format to work with but a bunch of >> variables which represent a tree is not nice either. >> >> However, apt has settings format that allows to specify variables both >> separately and as trees (using {} nested blocks). >> > Do you mean sth like > set root { > branch { > value = key; > } > } > ? > This would effectively promote 'set' to a keyword of grub-sh scripting > language but I'm ok with this.
Yes, something like that. I am not sure how the configuration parser currently works and what are the implications of adding this syntax. But having a shorthand set root.branch { value1=key1; value2=key2; value3=key3; } for set root.branch.value1=key1; set root.branch.value2=key2; set root.branch.value3=key3; is good for several reasons. At the very least it reduces typing, enhances readability somewhat, and allows for more modular construction of multilevel menus or such. apt uses :: for separator (not .) and any :: can be replaced with { and has to be closed with } then. Thanks Michal _______________________________________________ Grub-devel mailing list Grub-devel@gnu.org http://lists.gnu.org/mailman/listinfo/grub-devel