Skip to content

Commit fd9d9e5

Browse files
authored
Merge pull request #3125 from JamesNK/patch-1
Improve analyzer predefined ruleset example
2 parents 51ec91d + d9244d0 commit fd9d9e5

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

docs/code-quality/analyzer-rule-sets.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
title: Analyzer rule sets
3-
ms.date: 07/20/2018
3+
ms.date: 04/22/2019
44
ms.topic: conceptual
55
helpviewer_keywords:
66
- "analyzers, rule sets"
@@ -19,7 +19,7 @@ If you're migrating from legacy "FxCop" static code analysis to Roslyn analyzers
1919

2020
## Use analyzer rule sets
2121

22-
After you [install a NuGet analyzer package](install-roslyn-analyzers.md), locate the predefined rule set in its *rulesets* directory, for example *%USERPROFILE%\\.nuget\packages\microsoft.codequality.analyzers\<version>\rulesets*. From there, you can drag and drop, or copy and paste, one or more of the rulesets to your Visual Studio project in **Solution Explorer**.
22+
After you [install a NuGet analyzer package](install-roslyn-analyzers.md), locate the predefined rule set in its *rulesets* directory. For example, if you referenced the `Microsoft.CodeAnalysis.FxCopAnalyzers` analyzer package then you can find its rulesets directory at *%USERPROFILE%\\.nuget\packages\microsoft.codeanalysis.fxcopanalyzers\\\<version>\rulesets*. From there, you can drag and drop, or copy and paste, one or more of the rulesets to your Visual Studio project in **Solution Explorer**.
2323

2424
To make a rule set the active rule set for analysis, right-click on the project in **Solution Explorer** and choose **Properties**. In the project property pages, select the **Code Analysis** tab. Under **Run this rule set**, select **Browse**, and then select the desired rule set that you copied to the project directory. Now you only see rule violations for those rules that are enabled in the selected rule set.
2525

@@ -52,4 +52,4 @@ The [Microsoft.CodeAnalysis.FxCopAnalyzers](https://www.nuget.org/packages/Micro
5252
- [Overview of .NET Compiler Platform analyzers](roslyn-analyzers-overview.md)
5353
- [Install analyzers](install-roslyn-analyzers.md)
5454
- [Use analyzers](use-roslyn-analyzers.md)
55-
- [Use rule sets to group code analysis rules](using-rule-sets-to-group-code-analysis-rules.md)
55+
- [Use rule sets to group code analysis rules](using-rule-sets-to-group-code-analysis-rules.md)

0 commit comments

Comments
 (0)