Write
Updates all the matching nodes of path expression in a yaml file to the supplied value.
yq w <yaml_file> <path_expression> <new value>Basic
b:
c: 2yq w sample.yaml b.c catb:
c: catUpdating files in-place
yq w -i sample.yaml b.c catFrom STDIN
cat sample.yaml | yq w - b.c blahAdding new fields
Appending value to an array field
Multiple Documents
Update a single document
Update all documents
Writing Anchors
Writing Aliases
Updating only styles/tags without affecting values
Using a script file to update
Last updated