infinitered / gluegun

A delightful toolkit for building TypeScript-powered command-line apps.
MIT License
2.96k stars 147 forks source link

Logging functionality #161

Open skellock opened 7 years ago

skellock commented 7 years ago

It would be great to have file logging functionality.

Winston seems popular.

Install it on as logging on the context.

skellock commented 7 years ago

I like pino but that’s for structured logging. Which would be preferable imho. Just need to add a viewer command to humanize it.

jamonholmgren commented 7 years ago

I love the idea of structured logging. It's 2017, why are we still logging strings...

skellock commented 7 years ago

hash tag fact

ekryski commented 6 years ago

👍 👍 over here. Pretty big fan of Winston since it's pretty easy to also pump those logs to other locations via their adapters (ie. mongod, elasticsearch, papertrail, etc.) but we've also used Bunyan a lot so Pino looks good, seems to combine the best of both.

Most of the log forwarding and aggregation we now do at the container level. A little bit harder for open source since you can't enforce containers and they don't really make sense here but it looks like just pumping the output through node my_badass_cli | pino -l gives decent human readable logs.

jamonholmgren commented 6 years ago

Pushing this one out beyond 2.0.0.

yordis commented 5 years ago

I would no recommend Wiston package due to the lack of maintains. This is a good alternative https://github.com/pinojs/pino