Skip to content

Instantly share code, notes, and snippets.

@jhrcz
Last active August 29, 2015 14:16
Show Gist options
  • Save jhrcz/3c027f1bafa91e37c548 to your computer and use it in GitHub Desktop.
Save jhrcz/3c027f1bafa91e37c548 to your computer and use it in GitHub Desktop.
reformat-json-pipe
curl --header "PRIVATE-TOKEN: xxxx" "https://mygitlab/api/v3/projects/mynamespace%252Fmyproject" -s \
| python -msimplejson.tool
curl --header "PRIVATE-TOKEN: xxxx" "https://mygitlab/api/v3/projects/mynamespace%252Fmyproject" -s \
| python -c 'import sys; import simplejson as json; print json.dumps( json.loads( sys.stdin.read() ), sort_keys=False, indent=4); '
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment