|
1 | 1 | --- |
2 | | -title: Contribute docs for .NET code analysis rules to the .NET docs repository |
| 2 | +title: Contribute docs for .NET code analysis rules |
3 | 3 | description: This article describes the process for contributing to the articles and code samples for .NET code analysis rules in the .NET docs repository. |
4 | 4 | author: mavasani |
5 | 5 | ms.author: mavasani |
6 | 6 | ms.topic: contributor-guide |
7 | 7 | ms.service: learn |
8 | 8 | ms.custom: external-contributor-guide |
9 | | -ms.date: 06/17/2025 |
| 9 | +ms.date: 03/17/2026 |
10 | 10 | --- |
11 | | -# Contribute docs for .NET code analysis rules to the .NET docs repository |
| 11 | +# Contribute docs for .NET code analysis rules |
12 | 12 |
|
13 | | -.NET compiler platform (Roslyn) analyzers inspect your C# or Visual Basic code for code quality and code style issues. Starting in .NET 5.0, these analyzers are [included with the .NET SDK](/dotnet/fundamentals/code-analysis/overview). |
| 13 | +.NET compiler platform (Roslyn) analyzers inspect your C# or Visual Basic code for code quality and code style issues. These analyzers are [included with the .NET SDK](/dotnet/fundamentals/code-analysis/overview). |
14 | 14 |
|
15 | 15 | - [Code quality analysis ("CAxxxx" rules)](/dotnet/fundamentals/code-analysis/overview#code-quality-analysis): |
16 | | - - Implemented [here](https://github.com/dotnet/roslyn-analyzers/tree/main/src/NetAnalyzers) in `dotnet/roslyn-analyzers` repo. |
| 16 | + - Implemented in the [dotnet/sdk](https://github.com/dotnet/sdk/tree/main/src/Microsoft.CodeAnalysis.NetAnalyzers) repo (previously implemented in `dotnet/roslyn-analyzers` repo). |
17 | 17 | - Documented [here](https://github.com/dotnet/docs/blob/main/docs/fundamentals/code-analysis/quality-rules) in the `dotnet/docs` repo. See [Contribute docs for 'CAxxxx' rules](#contribute-docs-for-caxxxx-rules). |
18 | 18 | - [Code style analysis ("IDExxxx" rules)](/dotnet/fundamentals/code-analysis/overview#code-style-analysis): |
19 | | - - Implemented [here](https://github.com/dotnet/roslyn/tree/main/src/Analyzers) in `dotnet/roslyn` repo. |
| 19 | + - Implemented in the [dotnet/roslyn](https://github.com/dotnet/roslyn/tree/main/src/Analyzers) repo. |
20 | 20 | - Documented [here](https://github.com/dotnet/docs/blob/main/docs/fundamentals/code-analysis/style-rules) in the `dotnet/docs` repo. See [Contribute docs for 'IDExxxx' rules](#contribute-docs-for-idexxxx-rules). |
21 | 21 |
|
22 | 22 | ## Contribute docs for 'CAxxxx' rules |
23 | 23 |
|
24 | 24 | Please follow the following steps to contribute documentation for code quality analysis rules to the [dotnet/docs](https://github.com/dotnet/docs) repo: |
25 | 25 |
|
26 | | -1. Determine `Rule ID` and `Category`: Ensure that you know the 'CAxxxx' rule ID and category for the rule to be documented. This means either your CA analyzer has been merged into [dotnet/roslyn-analyzers](https://github.com/dotnet/roslyn-analyzers) repo or you have an open PR with an approved ID and category that has been assigned to the rule. |
| 26 | +1. Determine `Rule ID` and `Category`: Ensure that you know the 'CAxxxx' rule ID and category for the rule to be documented. This means either your CA analyzer has been merged into the [dotnet/sdk](https://github.com/dotnet/sdk) repo or you have an open PR with an approved ID and category that has been assigned to the rule. |
27 | 27 | 2. Add rule doc: |
28 | 28 | 1. Clone an existing CA rule file under [root](https://github.com/dotnet/docs/blob/main/docs/fundamentals/code-analysis/quality-rules) folder, say `ca1000.md`, and rename it. |
29 | 29 | 2. Update the content of the file appropriately. |
|
0 commit comments