-
Notifications
You must be signed in to change notification settings - Fork 2
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
Update Rust crate env_logger to 0.11 #5
Open
renovate
wants to merge
1
commit into
master
Choose a base branch
from
renovate/env_logger-0.x
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
renovate
bot
force-pushed
the
renovate/env_logger-0.x
branch
5 times, most recently
from
August 31, 2021 15:07
7bc1cfb
to
50960b9
Compare
renovate
bot
force-pushed
the
renovate/env_logger-0.x
branch
2 times, most recently
from
September 1, 2021 10:44
4989c06
to
7b2538d
Compare
renovate
bot
force-pushed
the
renovate/env_logger-0.x
branch
from
September 13, 2021 06:25
7b2538d
to
edf0e28
Compare
renovate
bot
force-pushed
the
renovate/env_logger-0.x
branch
from
October 4, 2021 03:14
edf0e28
to
7457daf
Compare
renovate
bot
force-pushed
the
renovate/env_logger-0.x
branch
from
October 16, 2021 18:29
7457daf
to
d971712
Compare
renovate
bot
force-pushed
the
renovate/env_logger-0.x
branch
2 times, most recently
from
November 3, 2021 22:05
9e2feb6
to
9111559
Compare
renovate
bot
force-pushed
the
renovate/env_logger-0.x
branch
from
November 15, 2021 04:56
9111559
to
db6c49b
Compare
renovate
bot
force-pushed
the
renovate/env_logger-0.x
branch
2 times, most recently
from
December 12, 2021 10:59
a628738
to
f7a41ec
Compare
renovate
bot
force-pushed
the
renovate/env_logger-0.x
branch
from
December 20, 2021 03:52
f7a41ec
to
d244898
Compare
renovate
bot
force-pushed
the
renovate/env_logger-0.x
branch
from
January 3, 2022 03:43
d244898
to
d232c4a
Compare
renovate
bot
force-pushed
the
renovate/env_logger-0.x
branch
from
May 1, 2022 12:03
d232c4a
to
f0c0b95
Compare
renovate
bot
force-pushed
the
renovate/env_logger-0.x
branch
from
May 9, 2022 03:18
f0c0b95
to
982939c
Compare
renovate
bot
force-pushed
the
renovate/env_logger-0.x
branch
from
June 6, 2022 04:15
982939c
to
47edd28
Compare
renovate
bot
force-pushed
the
renovate/env_logger-0.x
branch
from
June 20, 2022 05:18
47edd28
to
b94f667
Compare
renovate
bot
force-pushed
the
renovate/env_logger-0.x
branch
from
July 4, 2022 02:57
b94f667
to
64623ec
Compare
renovate
bot
force-pushed
the
renovate/env_logger-0.x
branch
from
July 18, 2022 05:23
64623ec
to
283a2af
Compare
renovate
bot
force-pushed
the
renovate/env_logger-0.x
branch
from
August 1, 2022 03:20
283a2af
to
a8f9bf1
Compare
renovate
bot
force-pushed
the
renovate/env_logger-0.x
branch
from
August 15, 2022 05:29
a8f9bf1
to
b9a4938
Compare
renovate
bot
force-pushed
the
renovate/env_logger-0.x
branch
2 times, most recently
from
September 5, 2022 04:57
916310e
to
f20675f
Compare
renovate
bot
force-pushed
the
renovate/env_logger-0.x
branch
2 times, most recently
from
September 19, 2022 05:46
be542c4
to
5d3cfbf
Compare
renovate
bot
force-pushed
the
renovate/env_logger-0.x
branch
2 times, most recently
from
June 29, 2024 08:12
72ddb98
to
7951fc5
Compare
renovate
bot
force-pushed
the
renovate/env_logger-0.x
branch
2 times, most recently
from
July 9, 2024 06:13
1a84acb
to
6b71178
Compare
renovate
bot
force-pushed
the
renovate/env_logger-0.x
branch
from
July 16, 2024 07:38
6b71178
to
03aba08
Compare
renovate
bot
force-pushed
the
renovate/env_logger-0.x
branch
2 times, most recently
from
July 30, 2024 09:39
5b34e89
to
6f480b7
Compare
renovate
bot
force-pushed
the
renovate/env_logger-0.x
branch
2 times, most recently
from
August 13, 2024 08:33
8d9f61a
to
0d2d3c4
Compare
renovate
bot
force-pushed
the
renovate/env_logger-0.x
branch
2 times, most recently
from
August 27, 2024 06:31
ae5b048
to
9c2677a
Compare
renovate
bot
force-pushed
the
renovate/env_logger-0.x
branch
2 times, most recently
from
September 10, 2024 07:37
bdafbf4
to
a0a7bd1
Compare
renovate
bot
force-pushed
the
renovate/env_logger-0.x
branch
2 times, most recently
from
September 24, 2024 07:15
5cae35d
to
0e6fdce
Compare
renovate
bot
force-pushed
the
renovate/env_logger-0.x
branch
from
October 1, 2024 06:15
0e6fdce
to
0c103ae
Compare
renovate
bot
force-pushed
the
renovate/env_logger-0.x
branch
2 times, most recently
from
October 9, 2024 13:23
a1f0061
to
37ea737
Compare
renovate
bot
force-pushed
the
renovate/env_logger-0.x
branch
2 times, most recently
from
October 22, 2024 08:09
f6b3b28
to
0f07f63
Compare
renovate
bot
force-pushed
the
renovate/env_logger-0.x
branch
from
October 24, 2024 21:27
0f07f63
to
ec685f5
Compare
renovate
bot
force-pushed
the
renovate/env_logger-0.x
branch
2 times, most recently
from
November 12, 2024 06:02
3121d65
to
444d524
Compare
renovate
bot
force-pushed
the
renovate/env_logger-0.x
branch
from
November 19, 2024 06:52
444d524
to
34ea85d
Compare
renovate
bot
force-pushed
the
renovate/env_logger-0.x
branch
2 times, most recently
from
December 3, 2024 06:24
04f9a50
to
9b8060c
Compare
renovate
bot
force-pushed
the
renovate/env_logger-0.x
branch
2 times, most recently
from
December 17, 2024 08:00
9c5f5ca
to
9f1be66
Compare
renovate
bot
force-pushed
the
renovate/env_logger-0.x
branch
from
December 24, 2024 08:29
9f1be66
to
29c3bcb
Compare
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR contains the following updates:
0.3
->0.11
Release Notes
rust-cli/env_logger (env_logger)
v0.11.5
Compare Source
v0.11.4
Compare Source
v0.11.3
Compare Source
Features
unstable-kv
v0.11.2
Compare Source
v0.11.1
Compare Source
Fixes
Target::Pipe
v0.11.0
Compare Source
Migration Guide
env_logger::fmt::Style:
The bespoke styling API, behind
color
, was removed, in favor of accepting anyANSI styled string and adapting it to the target stream's capabilities.
Possible styling libraries include:
env_logger::fmt::style
custom_format.rs
uses
anstyle
viaFormatter::default_level_style
Breaking Change
env_logger::fmt::Formatter::style
env_logger::fmt::Formatter::default_styled_level
env_logger::fmt::Style
env_logger::fmt::Color
env_logger::fmt::StyledValue
env_logger::filter
in favor ofenv_filter
Compatibility
MSRV changed to 1.71
Features
NO_COLOR
andCLICOLOR_FORCE
, see https://bixense.com/clicolors/Fixes
is_test(true)
v0.10.2
Compare Source
Performance
Fixes
color
is disabledv0.10.1
Compare Source
Performance
Documentation
RUST_LOG
documentationv0.10.0
Compare Source
MSRV changed to 1.60 to hide optional dependencies
Fixes
atty
tois-terminal
Breaking Changes
To open room for changing dependencies:
termcolor
feature tocolor
atty
feature toauto-color
v0.9.3
Compare Source
v0.9.2
Compare Source
v0.9.1
Compare Source
v0.9.0
Compare Source
Breaking Changes
Improvements
v0.8.4
: 0.8.4Compare Source
Improvements:
Target::Pipe
)Bug fixes:
env_logger::Builder
s methods, as documentedv0.8.3
: 0.8.3Compare Source
New features:
Builder::format_suffix
) [#192]Improvements:
Bug fixes:
rust-toolchain
whose presence caused issues for a few people)v0.8.2
: 0.8.2Compare Source
Fixed a panic on io errors when writing to stdout / stderr (#184).
v0.8.1
: 0.8.1Compare Source
Update links in the documentation that were pointing to the old repository location.
v0.8.0
: 0.8.0Compare Source
Breaking changes:
Improvements:
Deprecations:
env_logger::from_env
has been deprecated in favor ofenv_logger::Builder::from_env
This release raises the minimum supported Rust version to 1.41.0.
v0.7.1
: 0.7.1Compare Source
Key Changes
Contributions
v0.7.0
: 0.7.0Compare Source
Key Changes
Changes to minimum Rust
The minimum version of Rust required has been set at
1.31.0
. We may change this in patch versions, but will always flag it in the release notes here.You can always check the
.travis.yml
file to see the current minimum supported version.Contributions
v0.6.2
: 0.6.2Compare Source
Key Changes
Contributions
v0.6.1
: 0.6.1Compare Source
Key Changes
cargo test
stdout
Contributions
More Details
Builder::is_test
The
is_test
method can be used in tests to make sure logs are captured bycargo test
the same wayprintln!
is:There are performance implications of using
is_test
though, so it should be avoided outside of unit tests.v0.6.0
: 0.6.0Compare Source
Key Changes
log
optional (but enabled by default)Breaking Changes
log
. That means compilingenv_logger
withdefault-features=false
will result in a different experience than in0.5.x
.Contributions
-Z minimal-versions
on CIMore Details
Disabling dependencies
Using
default-features=false
will disable all dependencies ofenv_logger
besideslog
. This will reduce compile times and alter the default format by disabling colours and timestamps.Disabling default dependencies is the recommended way to use
env_logger
for libraries that only need it for logging in tests.v0.5.13
: 0.5.13Compare Source
Key Changes
Contributions
More Details
Formatter::default_level_style
The style used in the default format for printing level names can be fetched using the new
default_level_style
method on aFormatter
. The below example will format just the record message using the style of its level:v0.5.12
: 0.5.12Compare Source
Key Changes
Contributions
More Details
Builder::default_format_timestamp_nanos
The
Builder::default_format_timestamp_nanos
method can be used to toggle the precision of timestamps in the default format. When set totrue
, timestamps will include a 6-digit nanosecond component like2018-02-14T00:28:07.000000000Z
.Formatter::precise_timestamp
Custom formats can get a precise timestamp instead of the default by calling the
precise_timestamp
method instead of the existingtimestamp
one.v0.5.11
: 0.5.11Compare Source
Key Changes
termcolor
to1.0
rustc
to1.20.0
Changes to minimum Rust
The minimum version of Rust required has been set at
1.20.0
. We may change this in patch versions, but will always flag it in the release notes here.You can always check the
.travis.yml
file to see the current minimum supported version.Contributions
v0.5.10
: 0.5.10Compare Source
Key Changes
regex
to1.0
.Contributions
v0.5.9
: 0.5.9Compare Source
Key Changes
Contributions
More Details
filter_module
andfilter_level
Adds two new methods to
Builder
andfilter::Builder
that are specific cases of the existingfilter
method:filter_module
adds a directive for the given module. It's the same asfilter(Some(module), level)
filter_level
adds a directive for all modules. It's the same asfilter(None, level)
v0.5.8
: 0.5.8Compare Source
Key Changes
Contributions
More Details
Env::filter_or
andEnv::write_style_or
Default values for environment variables can be specified on the
Env
type using thefilter_or
andwrite_style_or
methods. The default value is a string in the same format as the environment variable:In usage:
DEFAULT_FILTER_ENV
andDEFAULT_WRITE_STYLE_ENV
Two new constants are publicly exported that correspond to the default environment variable names used for the filters and style preferences.
v0.5.7
: 0.5.7Compare Source
Contributions
v0.5.6
: 0.5.6Compare Source
Key Changes
termcolor::Color
API so it's no longer a public dependencyContributions
More Details
This patch fixes an issue that slipped through
0.5.0
where thetermcolor::Color
type was re-exported instead of redefined.This is a potentially breaking change
Instead of re-exporting
termcolor::Color
, we now redefine the same API inenv_logger
. The potential breakage is if anyone was relying on the fact thatenv_logger::Color
andtermcolor::Color
were equivalent types. This was only obvious from the source, and a survey of public code usingenv_logger
and call for comment hasn't revealed any code relying on this.v0.5.5
: 0.5.5Compare Source
Key Changes
Contributions
More Details
Builder::default_format_*
The default format can be easily tweaked by conditionally enabling/disabling parts of it in the main
Builder
. The API looks like:Calling
default_format_*
will store whether or not we want to include those parts of the log, without affecting a custom format. That means:Is the same as:
Setting a custom format won't clobber any values passed to
default_format_*
methods. That means:Is the same as:
Builder::from_default_env
A new
from_default_env
method that's a convenient way of callingfrom_env(env_logger::Env::default())
.v0.5.4
: 0.5.4Compare Source
Key Changes
humantime
instead ofchrono
for formatting timestampsChanges to minimum Rust
The minimum version of Rust required has been set at
1.18.0
. We may change this in patch versions, but will always flag it in the release notes here.You can always check the
.travis.yml
file to see the current minimum supported version.New Dependencies
humantime
for formatting timestamps. This replaces the dependency onchrono
Contributions
v0.5.3
: 0.5.3Compare Source
Key Changes
set_intense(true)
to produce a lighter color, andset_intense(false)
to produce the default color.Contributions
fmt::Style::set_intense
v0.5.2
: 0.5.2Compare Source
Key Changes
stdout
/stderr
is a tty and write styles accordingly. This fixes an issue with color control characters showing up logs piped to filesNew Dependencies
atty
for interrogatingstdout
/stderr
Contributions
v0.5.1
: 0.5.1Compare Source
Key Changes
Contributions
v0.5.0
: 0.5.0Compare Source
NOTE: These release notes are collected from the
0.5.0-rc.1
and0.5.0-rc.2
release notes.Key Changes
Breaking Changes
LogTarget
has been renamed toTarget
LogBuilder
has been renamed toBuilder
Builder::format
method now accepts aF: Fn(&mut Formatter, &Record) -> Result<()> + Sync + Send
. This is the new formatting API that writes into aFormatter
instead of producing an ownedString
Builder::init
will panic if the logger can't be initialised. A newBuilder::try_init
method has been added with the same semantics as the oldBuilder::init
methodNew Dependencies
chrono
for the timestamptermcolor
for record buffering and colorsContributions
log
/ deny debug impls, missing docs, and warnings.Thanks to everybody who helped make this release of
env_logger
happen!More Details
Disabling colors
Adds a new builder property for whether or not to include colors. By default this is controlled by the
RUST_LOG_STYLE
environment variable, but it can be overridden.Setting this environment variable to
never
will disable colors and other styles:$ export RUST_LOG_STYLE=never $ ./my-app
Valid values are:
auto
(or missing/invalid) will decide whether or not the terminal supports colorsalways
will always use colorsnever
will never use colorsIn order to support multiple environment variables, I've refactored our
from_env
functions to accept a genericT: Into<Env>
, whereEnv
is a container for the environment variables we care about. These methods can now be called in a few ways:This lets us add new environment variables in the future without potentially breaking people. But it does mean if you're overriding all environment variables that new ones could slip in without you noticing.
Using alternative environment variables
Since we use two environment variables to configure the logger we need an ergonomic way to pass different combinations of those variables to
from_env
methods. This PR adds anEnv
type with builder methods for naming environment variables:With a few
From
conversions, the above is also equivalent to:Whether or not we want to keep these conversions is up for discussion.
Writing colors
The color API has been refactored and made public so you can use them in your own formats:
This saves you from having to split the writes into multiple calls and juggle
Result
types.Writing timestamps
Call the
timestamp
method on aFormatter
to get an opaque timestamp that can be logged. It'll be written in an RFC3339 format:v0.4.3
Compare Source
v0.4.2
Compare Source
v0.4.1
Compare Source
v0.4.0
Compare Source
Configuration
📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR was generated by Mend Renovate. View the repository job log.