Skip to content

Commit

Permalink
fixup! align more with community standards non-empty value requirement
Browse files Browse the repository at this point in the history
  • Loading branch information
samypr100 committed Jun 4, 2024
1 parent 1c451f6 commit affba38
Showing 1 changed file with 11 additions and 3 deletions.
14 changes: 11 additions & 3 deletions crates/uv/src/settings.rs
Original file line number Diff line number Diff line change
Expand Up @@ -46,10 +46,18 @@ impl GlobalSettings {
Self {
quiet: args.quiet,
verbose: args.verbose,
color: if args.no_color || std::env::var_os("NO_COLOR").is_some() {
color: if args.no_color
|| std::env::var_os("NO_COLOR")
.filter(|v| !v.is_empty())
.is_some()
{
ColorChoice::Never
} else if std::env::var_os("FORCE_COLOR").is_some()
|| std::env::var_os("CLICOLOR_FORCE").is_some()
} else if std::env::var_os("FORCE_COLOR")
.filter(|v| !v.is_empty())
.is_some()
|| std::env::var_os("CLICOLOR_FORCE")
.filter(|v| !v.is_empty())
.is_some()
{
ColorChoice::Always
} else {
Expand Down

0 comments on commit affba38

Please sign in to comment.