heroku logs output w/
The stuff before the JSON in
heroku logs output has to be cut off for
bunyan to work.
$ heroku logs | sed -l 's/.*app\[web\..*\]\: //' | bunyan
-l makes the output buffered by line.
alias bunyan-heroku="sed -l 's/.*app\[web\..*\]\: //' | bunyan"
$ heroku logs --tail | bunyan-heroku -o short
awk, but found a better
for which a credit goes to @kennbrodhagen.
One might not want to see the non-bunyan log output that comes from
In that case, pipe through grep:
alias buh="grep --line-buffered --color=none 'app\[web.\d\+\]' | sed -l 's/.*app\[web\..*\]\: //' | bunyan"