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

feat: add log file support #1813

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

jokresner
Copy link

This PR adds two new flags to enable logging to a file. See #1716

Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

Congratulations on opening your first pull request! We'll get back to you as soon as possible. In the meantime, please make sure you've updated the documentation to reflect your changes and have added test automation as needed. Thanks! 🙏🏼

Copy link
Member

@simskij simskij left a comment

Choose a reason for hiding this comment

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

I like this, and would be happy to merge it after one change: enabling logging to a file should still log to stdout as well.

Copy link

codecov bot commented Nov 12, 2023

Codecov Report

Attention: 8 lines in your changes are missing coverage. Please review.

Comparison is base (76f9cea) 70.55% compared to head (8ea89ce) 70.56%.

❗ Current head 8ea89ce differs from pull request most recent head 07d200b. Consider uploading reports for the commit 07d200b to get more accurate results

Files Patch % Lines
internal/flags/flags.go 63.63% 7 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1813      +/-   ##
==========================================
+ Coverage   70.55%   70.56%   +0.01%     
==========================================
  Files          26       26              
  Lines        2493     2511      +18     
==========================================
+ Hits         1759     1772      +13     
- Misses        633      638       +5     
  Partials      101      101              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

jokresner and others added 2 commits January 8, 2024 16:49
add multi writer to support both file output and std out
@jokresner
Copy link
Author

Sorry for my late replay. I've added a multi writer to support both outputs.

@IvanRibakov
Copy link

@simskij Could you please take another look at this PR?

@jokresner jokresner requested a review from simskij April 17, 2024 12:50
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