I’d like to be able to add a dictionary item to a list item.
For example:
my_list:
- first_list_item:
color: blue
country: us - second_list_item:
stuff: blah
What I’m trying to do is add to a list item like adding “state” below to the first list item.
my_list:
- first_list_item:
color: blue
country: us
state: va
- second_list_item:
stuff: blah
I’ve used + to add a new list item. I’ve used combine to add a new dictionary item. But combining them seems to be eluding me and I’ve not found a solution online yet.
FYI, I’m using with_nested to compare two lists and determine what should be added to which item. That part is working. it’s the set_fact part that I can’t seem to work out.