Created
August 13, 2011 08:11
-
-
Save esride-apf/1143600 to your computer and use it in GitHub Desktop.
Sample MSBuild target to run static codeanalysis tool FxCop
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> | |
| <PropertyGroup> | |
| <BuildDependsOn>$(BuildDependsOn);FxCop</BuildDependsOn> | |
| <RebuildDependsOn>$(RebuildDependsOn);FxCop</RebuildDependsOn> | |
| </PropertyGroup> | |
| <Target Name="FxCop"> | |
| <Exec | |
| Command=""$(TargetDir)..\tools\FxCop\FxCopCmd.exe" /file:"$(TargetPath)" /project:"$(TargetDir)..\src\BuildOnly.FxCop" /directory:"$(TargetDir)..\lib\Microsoft" /dictionary:"$(TargetDir)..\src\FxCop.CustomDictionary.xml" /out:"$(TargetDir)$(ProjectName).FxCopReport.xml" /console /forceoutput /ignoregeneratedcode"> | |
| </Exec> | |
| <Message Text="FxCop finished." /> | |
| </Target> | |
| </Project> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment