Pretty print curl -i – Rob Allen’s DevNotes

What I would like to do is pretty print the body if it’s JSON or XML so that it’s easier to read. There are some tools out there, like jq which will format JSON, but they can’t seem to cope if the first part of the string is not JSON: To make this easier, you can add to your ~/.curlrc.


View original article


Posted

in

by

Tags:

Comments

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Discover more from try {} except

Subscribe now to keep reading and get access to the full archive.

Continue reading