有谁知道,我将如何通过增加 FxCop 数量来获得 xml 或 html。
目前这是我的 fxcop cmd ,我在其中替换 {0} 和 {1} 并动态创建批处理文件并运行。
我得到了完整的 fxcop 警告,尽管在 cmd 提示符中我可以看到它显示了 fxcop 警告的增加数量。
fxcopcmd.exe /import:"c:\Standard.xml" /summary "/file:{0}" /searchgac /ignoreinvalidtargets /forceoutput /successfile /ignoregeneratedcode /saveMessagesToReport:Active
/r:-"C:\Program Files (x86)\Microsoft Visual Studio 10.0\Team Tools\Static Analysis Tools\FxCop\Rules\NamingRules.dll"
/r:+"C:\Program Files (x86)\Microsoft Visual Studio 10.0\Team Tools\Static Analysis Tools\FxCop\Rules\DesignRules.dll"
/r:+"C:\Program Files (x86)\Microsoft Visual Studio 10.0\Team Tools\Static Analysis Tools\FxCop\Rules\GlobalizationRules.dll"
/r:+"C:\Program Files (x86)\Microsoft Visual Studio 10.0\Team Tools\Static Analysis Tools\FxCop\Rules\InteroperabilityRules.dll"
/r:+"C:\Program Files (x86)\Microsoft Visual Studio 10.0\Team Tools\Static Analysis Tools\FxCop\Rules\MobilityRules.dll"
/r:+"C:\Program Files (x86)\Microsoft Visual Studio 10.0\Team Tools\Static Analysis Tools\FxCop\Rules\PerformanceRules.dll"
/r:+"C:\Program Files (x86)\Microsoft Visual Studio 10.0\Team Tools\Static Analysis Tools\FxCop\Rules\PortabilityRules.dll"
/r:+"C:\Program Files (x86)\Microsoft Visual Studio 10.0\Team Tools\Static Analysis Tools\FxCop\Rules\SecurityRules.dll"
/r:+"C:\Program Files (x86)\Microsoft Visual Studio 10.0\Team Tools\Static Analysis Tools\FxCop\Rules\UsageRules.dll"
/r:+"C:\Program Files (x86)\Microsoft Visual Studio 10.0\Team Tools\Static Analysis Tools\FxCop\Rules\DataflowRules.dll"
/r:+"C:\Program Files (x86)\Microsoft Visual Studio 10.0\Team Tools\Static Analysis Tools\FxCop\Rules\MaintainabilityRules.dll"
/r:+"C:\Program Files (x86)\Microsoft Visual Studio 10.0\Team Tools\Static Analysis Tools\FxCop\Rules\ReliabilityRules.dll"
/r:+"C:\Program Files (x86)\Microsoft Visual Studio 10.0\Team Tools\Static Analysis Tools\FxCop\Rules\SecurityTransparencyRules.dll"
/ruleid:-Microsoft.Design#CA1024 /ruleid:-Microsoft.Performance#CA1822
/ruleid:-Microsoft.Usage#CA2227
/out:"{1}"
我打算手动/XmlDiff 将 Xml 与标准 xml 进行比较并找出差异。
如果 FxCop 工具可靠地完成了同样的操作,那么我可以使用它。