Open bassman-junk opened 9 months ago
Sorry, the format came out wrong. Here is a screenshot.
yeah, have a look at these: https://ttp.readthedocs.io/en/latest/Forming%20Results%20Structure/index.html#results-structure https://ttp.readthedocs.io/en/latest/Template%20Tag/Template%20Tag.html#results
Need to use <template name="r_cfg" results="per_template"> ...template goes here... </template>
plus when calling ttp parser object result need to add structure keyword e.g. parser.result(structure="dictionary")
, that combined should give you all dictionary output with no top list.
Is there a way to remove the '-' or list from the parent dict structure of the yaml output?
ex:
I would like for it to be as so: r_cfg: interfaces: intf: Loopback0 ip: !!python/object/apply:ipaddress.IPv4Interface