curl, but tries to prettify json
Want to see pretty graphs? Log in now!
npm install jcurl
|8||downloads in the last week|
|18||downloads in the last month|
|Last Published By|
|Version||0.1.3 last updated 11 months ago|
|Keywords||json, curl, pretty|
Runs the thing named
curl on your system and pipes the output to a node script that attempts to
JSON.parse() the result and output it as pretty-printed JSON. If it can't, it just outputs whatever came out, unaltered.
Any params you pass are simply passed along wholesale to the
curl command on your system, so that in general you can just type "jcurl" in place of wherever you type "curl".
This isn't a replacement for curl, but rather just a tool that makes it easy to read JSON for testing and debugging purposes for people who are in the habit of typing curl commands.
Usage beyond curl
It also installs another command called
json-pretty, so that you can pipe anything you think is JSON through the same formatter that jcurl uses internally.
npm install -g jcurl # now jcurl in installed on your system # now json-pretty is installed on your system
# show json-formatted output jcurl http://example.com/foo.json # prettify a file on disk cat myfile.json | json-pretty