summary refs log tree commit diff
path: root/bin
diff options
context:
space:
mode:
authorFranck Cuny <franck.cuny@gmail.com>2016-11-21 20:36:53 -0800
committerFranck Cuny <franck.cuny@gmail.com>2016-11-21 20:36:53 -0800
commit6c057bc4660fb0dadd20649b0f53437cb1019cd0 (patch)
tree303d90da1f8510c46454169e1d072b87b94e2093 /bin
parent[tmux] Add tmux back (again) (diff)
downloademacs.d-6c057bc4660fb0dadd20649b0f53437cb1019cd0.tar.gz
[bin] Dummy script to prettify JSON output.
Diffstat (limited to '')
-rwxr-xr-xbin/json-pretty10
1 files changed, 10 insertions, 0 deletions
diff --git a/bin/json-pretty b/bin/json-pretty
new file mode 100755
index 0000000..e536fd0
--- /dev/null
+++ b/bin/json-pretty
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+URL=$1
+
+if [[ -z "${URL}" ]]; then
+  echo "usage: $0 <URL>"
+  exit 1
+fi
+
+curl -s "${1}" | python -m json.tool