Hacker Timesnew | past | comments | ask | show | jobs | submitlogin

  > 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 `|'


yeah, thats my bad, A recent addition and I must have copied too much of the command line when adding it.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: