put comments on key node instead

This commit is contained in:
Mike Farah
2022-10-27 15:27:37 +11:00
parent 7eccbe5902
commit fd79ac8603
8 changed files with 99 additions and 37 deletions
+2 -6
View File
@@ -154,9 +154,7 @@ will output
cool: things
more_stuff:
this:
is: a properties file # great huh
# things and stuff
another: a properties file # another thing
is: a properties file
```
## Merge from properties
@@ -175,10 +173,8 @@ yq '. *= load_props("../../examples/small.properties")' sample.yml
will output
```yaml
this:
is: a properties file # great huh
# things and stuff
is: a properties file
cool: ay
another: a properties file # another thing
```
## Load from base64 encoded file
+4 -2
View File
@@ -139,10 +139,12 @@ yq -p=props sample.properties
will output
```yaml
person:
name: Mike Wazowski # block comments come through
# block comments come through
# comments on values appear
name: Mike Wazowski
pets:
- cat # comments on array values appear
# comments on array values appear
- cat
food:
- pizza
```