-
Edit It may be more appropriate to refer to as 'node name' or 'selector value'
what syntax do I need to provide dasel to updating this.attribute to 'newvalue'
this command breaks out ths,file,this,attribute in to separate nodes. I was hoping the '\' character would solve this but it didn't help. Any suggestions? |
Beta Was this translation helpful? Give feedback.
Answered by
TomWright
May 18, 2021
Replies: 1 comment 1 reply
-
You just need to escape the dot. The backslash does do this, but you are putting in the wrong place. The backslash needs to come before the character you want to escape. E.g. echo 'this.file:
- this.attribute: value' | dasel put string -p yaml '.this\.file.[0].this\.attribute' newvalue this.file:
- this.attribute: newvalue |
Beta Was this translation helpful? Give feedback.
1 reply
Answer selected by
TomWright
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
You just need to escape the dot. The backslash does do this, but you are putting in the wrong place. The backslash needs to come before the character you want to escape.
E.g.