Skip to content

Add documentation on warnnotaserror switch #7585

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

Merged
merged 1 commit into from
Mar 2, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions docs/msbuild/msbuild-command-line-reference.md
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,7 @@ MSBuild.exe [Switches] [ProjectFile]
|-version|-ver|Display version information only. The project isn't built.|
|@`file`||Insert command-line switches from a text file. If you have multiple files, you specify them separately. For more information, see [Response files](../msbuild/msbuild-response-files.md).|
|-warnAsError[:`code`[`;code2`]|-err[`:code`[`;code2`]|List of warning codes to treats as errors. Use a semicolon or a comma to separate multiple warning codes. To treat all warnings as errors, use the switch with no values. When a warning is treated as an error the target continues to execute as if it was a warning but the overall build fails.<br/><br/>Example: `-err:MSB4130`|
|-warnNotAsError[:`code`[`;code2`]|-noerr[`:code`[`;code2`]|List of warning codes that should not be promoted to errors. Specifically, if the warnAsError switch is set to promote all warnings to errors, error codes specified with warnNotAsError are not promoted. This has no effect if warnAsError is not set to promote all warnings to errors. Use a semicolon or a comma to separate multiple warning codes. <br/><br/>Example: `-noerr:MSB4130`|
|-warnAsMessage[:`code`[`;code2`]|-noWarn[:`code`[`;code2`]|List of warning codes to treats as low importance messages. Use a semicolon or a comma to separate multiple warning codes.<br/><br/>Example: `-noWarn:MSB3026`|

### Switches for loggers
Expand Down