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

Replace printing with logging #67

Merged

Conversation

Azrenbeth
Copy link
Contributor

Builds on #66

The output from the manual tool is unchanged (since the logging is set to have no preamble)
but will allow the autocompressor to ignore some of the output, and format it nicely

This allows other packages that use the compressor to control what
and how the libary prints.
@Azrenbeth Azrenbeth force-pushed the azren/replace_printing_with_logging branch from ac9fef2 to 94fca17 Compare September 27, 2021 10:39
@Azrenbeth Azrenbeth marked this pull request as ready for review September 27, 2021 10:39
src/main.rs Outdated
log_builder.init();
} else {
// If COMPRESSOR_LOG_LEVEL was set then use that
env_logger::Builder::from_env("COMPRESSOR_LOG_LEVEL").init();
Copy link
Member

Choose a reason for hiding this comment

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

As discussed, let's use standard RUST_LOG

Suggested change
env_logger::Builder::from_env("COMPRESSOR_LOG_LEVEL").init();
env_logger::init();

And RUST_LOG above

@Azrenbeth Azrenbeth merged commit b8e323c into matrix-org:main Sep 27, 2021
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

2 participants