'How to correctly merge dict with anchor in YAML
Please help merge dict with anchor in YAML to files, I try to do this but YAML return wrong result. Thanks for help
common_files: &common_files
- file_path: "link -1"
content_pattern:
- "text"
- "text"
one: "zoo"
two: "foo"
three: "fii"
- file_path: "link -2"
content_pattern:
- "text"
- "text"
one: "zoo"
two: "foo"
three: "fii"
files:
- <<: *common_files
- file_path: "link-3"
content_pattern:
- "text"
- "text"
one: "zoo"
two: "foo"
three: "fii"
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
