cmd/prettylog/README.md
This is a basic CLI utility that will colorize and pretty print your structured JSON logs.
You can compile it or run it directly. The only issue is that by default Zerolog does not output to stdout
but rather to stderr so we must pipe stderr stream to this CLI tool.
These commands will redirect stderr to our prettylog tool and stdout will remain unaffected.
some_program_with_zerolog 2> >(prettylog)
go runsome_program_with_zerolog 2> >(go run cmd/prettylog/prettylog.go)
These commands will redirect stderr to stdout and then pipe it to our prettylog tool.
some_program_with_zerolog 2>&1 | prettylog
go runsome_program_with_zerolog 2>&1 | go run cmd/prettylog/prettylog.go