cli: allow map values in --params arguments
authorSimon Marchi <simon.marchi@efficios.com>
Thu, 15 Aug 2019 04:00:15 +0000 (00:00 -0400)
committerPhilippe Proulx <eeppeliteloop@gmail.com>
Sat, 17 Aug 2019 00:12:13 +0000 (20:12 -0400)
This patch makes it possible to use map values in --params arguments.
For example:

    --params 'a={hi="mlady",mapping={tete="epaule",genou="orteil"}}'

The chosen syntax uses curly braces to delimit the map.  It uses an
equal sign between the key an value, to be consistent with the syntax of
the implicit map at the top-level of `--params` values.

Speaking of which: it's not done in this patch, but it should be
possible to make the new function a bit more generic and re-use it for
parsing the top-level dict of `--params` values.

Change-Id: I1400ff6a2cf6c9132a9c5dd731a462f43225146b
Signed-off-by: Simon Marchi <simon.marchi@efficios.com>
Reviewed-on: https://review.lttng.org/c/babeltrace/+/1936
Tested-by: jenkins <jenkins@lttng.org>
Reviewed-by: Philippe Proulx <eeppeliteloop@gmail.com>

No differences found
This page took 0.025318 seconds and 4 git commands to generate.