On 01/19/2012 10:42 AM, Kristóf Katus wrote: > On Thursday, January 19, 2012 04:19:50 PM Chris Evich wrote: >> I think because each variants block is treated as a new array >> "Dimension", so there's no way to "re-open" an already parsed one. I'll >> play with it a little more and see if I can find a solution. > > Hi Chris, > > I tried similar things before to those you suggested, they did not work. I was > thinking on some nice syntax with named variants blocks, something like > this: > > # original.cfg > number variants: > - 1: > - 2: > > alpha variants: > - a: > - b: > - c: > > # overwrites.cfg > include original.cfg > > # In my interpretation, this should only add a variant > # named "3" to the variants block "number" if it is > # not present in there at all: filters are already there > # for overwriting keys in an already existing variant... > number variants: > - 3: > > The above config should have exactly the same effect regarding the > contents of the generated dictionaries as this: > > variants: > - 1: > - 2: > - 3: > > variants: > - a: > - b: > - c: > > > Kristóf
It's an interesting idea. Perhaps some sort of pre-parser could be employed. It could coalesce all the variant definitions first, then hand-off to the existing parser. Otherwise, it would have to resolve "interesting" problems, such as overwritten dependencies. Either way, I think you'll probably find its just easier to make your own copy and 'include' chain to do you want :) We've tried to break them apart by topic to make doing this relatively easy. However if you have ideas for alternate schemes, we'll certainly listen. -- Chris Evich, RHCA, RHCE, RHCDS, RHCSS Quality Assurance Engineer e-mail: cevich + `@' + redhat.com o: 1-888-RED-HAT1 x44214 _______________________________________________ Autotest mailing list [email protected] http://test.kernel.org/cgi-bin/mailman/listinfo/autotest
