service key as true JSON
The problem
Cloud Foundry CLI delivers service-key command capable to print credentials. Unfortunately printing credentials to the terminal is not always secure. Additionally the response of this CLI is not parseable because of the text Getting key ... for service instance ... as ...
Yes, the solution is very simple now - just removing few lines with a script like this cf service-key $SK $SK-key | sed -n '2,$p' but still - since we talk about CLI it would be nice to make it a standard feature with some parameter like --parseable ( like in npm commands )
Desired solution
Instead of the script like this
cf service-key $SK $SK-key | sed -n '2,$p' | jq .credentials
I'd like to run something like
cf service-key $SK $SK-key --parseable | jq .credentials