|
|
|
|
|
by egwynn
3999 days ago
|
|
> alias json='| python -m json.tool'
Is the beginning pipe intended? If I just run 'python -m json.tool' then it starts reading from stdin by itself (and works as intended). And with the pipe, I can’t seem to make the alias work. $ echo '{ "foo": 1234}' | json
-bash: syntax error near unexpected token `|'
$ json
-bash: syntax error near unexpected token `|'
|
|