-
Notifications
You must be signed in to change notification settings - Fork 22
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
ExcludeFromStyleCop not respected by the VS extension #53
Comments
It is the AssemblyInfo.cs file ? |
Yes, it is. We actually have AssemblyInfo split into two - common between projects (which is added as link) and project-specific which is added in a standard way. The issue occurs for both files. |
@MT-PL-SWF-Dev I can't reproduce this issue, could you send me a zip of your solution, and projects (with AssemblyInfo only). You can remove all other cs files from your personal code this is just to try on my side |
I enclose a zip with sample project and some print screens in main directory. I hope this helps. |
I found this explicit code for links: var isLinkProperty = item.Properties.Item("IsLink");
if (isLinkProperty != null && bool.Parse(isLinkProperty.Value.ToString()))
{
// The ProjectItem is a linked file to we'll assume these haven't got
// ExcludeFromStyleCop in the proj file
return true;
} I don't want to remove this code so I think the best solution is to add a new parameter. |
How does the linked file differ from a regular one? Both are tested against StyleCop violations, so I would actually assume the other way around - that it may have ExcludeFromStyleCop attribute. |
ExcludeFromStyleCop works fine for project's build.
But when using "Run StyleCop (Rescan All)" from the VS extension on a solution level it still raises warnings, e.g.:
SA1633 : CSharp.Documentation : The file has no header, the header Xml is invalid, or the header is not located at the top of the file.
I have installed the extension directly from nuget.
The text was updated successfully, but these errors were encountered: