question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Question: suppressing all documentation rules a-la-cart in .globalconfig

See original GitHub issue

Is it possible to somehow suppress all documentation rules a-la-cart in .globalconfig / .editorconfig without explicitly naming each one of them?

So instead if this:

dotnet_diagnostic.SA0001.severity = none    # XmlCommentAnalysisDisabled
dotnet_diagnostic.SA1600.severity = none    # ElementsMustBeDocumented
dotnet_diagnostic.SA1601.severity = none    # PartialElementsMustBeDocumented
dotnet_diagnostic.SA1602.severity = none    # EnumerationItemsMustBeDocumented
... (~ 40 entries)

have rather something along the lines: (this documents the intent of the question and is not working solution)

dotnet_diagnostic.SA0001.severity = none    # XmlCommentAnalysisDisabled
dotnet_diagnostic.SA16*.severity = none      # https://documentation.help/StyleCop/Documentation%20Rules.html

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:6 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
sharwellcommented, Jan 31, 2022

@jdvor The category in the example won’t match any StyleCop diagnostics. To get the category, first locate and select an analyzer in Solution Explorer:

image

Then press <kbd>F4</kbd> to open the Properties window to see the category:

image

0reactions
sharwellcommented, Jan 31, 2022

Keep in mind that this might not be supported in the future:

dotnet_diagnostic.CS1591.severity = none    # Missing XML comment for publicly visible type or member

Trailing comments are not truly supported by the .editorconfig specification, so you’ll want to rewrite it like this:

# Missing XML comment for publicly visible type or member
dotnet_diagnostic.CS1591.severity = none
Read more comments on GitHub >

github_iconTop Results From Across the Web

Globablly Suppressing Stylecop Rules Not Working
I'm facing a similar problem. In the latest Visual Studio (version 16.7.3), none of the supression methods through Visual Studio are doing ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found