Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New option and command line argument to ignore some keys #57

Merged
merged 6 commits into from Mar 30, 2019

Conversation

maxme
Copy link
Contributor

@maxme maxme commented Mar 27, 2019

I love pino and pino-pretty but I really don't care about the pid and hostname on my dev machine. I added a new option --ignore to customize the output.

Example use:

$ echo '{"level":30,"time":1522431328992,"msg":"hello world","pid":42,"hostname":"foo","v":1, "name":"pou"}' | node bin.js -ti pid,hostname,name
[2018-03-30 17:35:28.992 +0000] INFO : hello world

Note: I added a few tests

Copy link
Member

@mcollina mcollina left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@mcollina
Copy link
Member

@mcollina
Copy link
Member

Good work!

bin.js Outdated Show resolved Hide resolved
@maxme maxme changed the title New option and comand line arguement to ignore some keys New option and command line argument to ignore some keys Mar 27, 2019
Copy link
Member

@jsumners jsumners left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@jsumners jsumners merged commit 8fb8ca8 into pinojs:master Mar 30, 2019
@jsumners
Copy link
Member

https://github.com/pinojs/pino-pretty/releases/tag/v2.6.0

@maxme maxme deleted the feature/ignore-some-keys branch March 31, 2019 07:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants