Last active
June 23, 2021 16:51
-
-
Save niqdev/bb0544f6c0879c4dc63dbd7eb439ae17 to your computer and use it in GitHub Desktop.
jq stringify JSON
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#cat example.json | |
#{ | |
# "myKey": "myValue", | |
# "myArray": [ | |
# "hello", | |
# "world" | |
# ] | |
#} | |
cat example.json | jq -c | jq -R | |
jq tostring example.json | |
#"{\"myKey\":\"myValue\",\"myArray\":[\"hello\",\"world\"]}" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment