Skip to content

Commit

Permalink
Revert style for no_color to last working version
Browse files Browse the repository at this point in the history
  • Loading branch information
kzu committed Sep 2, 2024
1 parent 1df5465 commit 4f68f5f
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/dotnet-trx/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,9 @@
// Causes -v|--version to be added to help
config.SetApplicationVersion(ThisAssembly.Project.Version);

if (Environment.GetEnvironmentVariables().Contains("NO_COLOR"))
config.Settings.HelpProviderStyles = null;
if (Environment.GetEnvironmentVariables().Contains("NO_COLOR") &&
config.Settings.HelpProviderStyles?.Options is { } options)
options.DefaultValue = Style.Plain;
});

if (args.Contains("--version"))
Expand Down

0 comments on commit 4f68f5f

Please sign in to comment.