Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
WIP: Add a summary() function for configuration summarization
This has been requested multiple times in the mesa/xorg community, and apparently in the GStreamer community as well. This is a very simple function that takes a single dictionary as an argument, that dictionary may define scalar or container values which will be printed as summaries. It treats nested dictionaries as another level of configuration options, which allows grouping options together. For example: ```meson sec1 = {'driver' : 'foobar', 'OS' : 'Linux', 'API' : 1.7} ... sec2 = {'driver' : 'dive comp', 'OS' : 'Minix', 'API' : 1.1.2} summary({ 'Backend' : 'OpenGL', 'Server' : sec1, 'Client' : sec2, }) ``` Which would print something like: ```txt Configuration Summary: Backend = OpenGL Server: driver = foobar OS = Linux API = 1.7 Client: driver = dive comp OS = Minix API = 1.1.2 ``` Fixes mesonbuild#757
- Loading branch information