dotnet / dotnet/msbuild

Avoid setting Console colors when it would be redundant

Open
#1,825 0 comments 0 reactions 0 assignees View on GitHub
triaged
Dominant language
C#
Stars
5.5k
Forks
1.5k
Avg merge
1d 8h
Merged PRs (30d)
141

Description

Before running the setter, [`SetColor`](https://github.com/Microsoft/msbuild/blob/be1489dc9fb0103adff65e85209f83199b5aa10a/src/Build/Logging/BaseConsoleLogger.cs#L405-L416) could have an "if not already that color" check.

This would reduce calls when multiple messages wish to set the console to the same color.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.