Add note on WarningsAsErrors (#81451)
authorMichal Strehovský <MichalStrehovsky@users.noreply.github.com>
Wed, 1 Feb 2023 08:22:59 +0000 (17:22 +0900)
committerGitHub <noreply@github.com>
Wed, 1 Feb 2023 08:22:59 +0000 (17:22 +0900)
docs/workflow/README.md

index 519ab64..7b8c696 100644 (file)
@@ -87,3 +87,7 @@ And how to measure performance:
 
 * [Benchmarking workflow for dotnet/runtime repository](https://github.com/dotnet/performance/blob/master/docs/benchmarking-workflow-dotnet-runtime.md)
 * [Profiling workflow for dotnet/runtime repository](https://github.com/dotnet/performance/blob/master/docs/profiling-workflow-dotnet-runtime.md)
+
+## Warnings as Errors
+
+The repo build treats warnings as errors. Dealing with warnings when you're in the middle of making changes can be annoying (e.g. unused variable that you plan to use later). To disable treating warnings as errors, set the `WarningsAsErrors` environment variable to `false` before building. This variable will be respected by both the `build.sh`/`build.cmd` root build scripts and builds done with `dotnet build` or Visual Studio. Some people may prefer setting this environment variable globally in their machine settings.