aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--[-rwxr-xr-x].bash_profile0
-rw-r--r--.functions4
2 files changed, 1 insertions, 3 deletions
diff --git a/.bash_profile b/.bash_profile
index 7b15a81..7b15a81 100755..100644
--- a/.bash_profile
+++ b/.bash_profile
diff --git a/.functions b/.functions
index 833f5e6..0ae79c9 100644
--- a/.functions
+++ b/.functions
@@ -21,9 +21,7 @@ function httpcompression() {
function json() {
if [ -p /dev/stdin ]; then
# piping, e.g. `echo '{"foo":42}' | json`
- while read data; do
- python -mjson.tool <<< "$data" | pygmentize -l javascript
- done
+ python -mjson.tool | pygmentize -l javascript
else
# e.g. `json '{"foo":42}'`
python -mjson.tool <<< "$*" | pygmentize -l javascript