This story on HackerNoon has a decentralized backup on Sia.
Transaction ID: _-hUaQy_APCgpjOSbVBCiKI-oGRahFBxZXi7X7kUasg
Cover

Quickly JSON.parse() on command line

Written by @garciaj.uk | Published on 2017/5/30

TL;DR
I was trying to get some data out of etcd (kubernetes) and i found the value was returned as a string:

I was trying to get some data out of etcd (kubernetes) and i found the value was returned as a string:

you can see the quotes in the beginning, so after playing with sed for a bit , getting me nowhere , i discovered the -r flag of jq so…

As you can see now you have a json object back that we can pass back to jq:

just that.

Thank you.

[story continues]


Written by
@garciaj.uk
Sr App Engineer

Topics and
tags
json|kubernetes|docker|linux|javascript
This story on HackerNoon has a decentralized backup on Sia.
Transaction ID: _-hUaQy_APCgpjOSbVBCiKI-oGRahFBxZXi7X7kUasg