StyleChecker 2.2.0

dotnet add package StyleChecker --version 2.2.0
                    
NuGet\Install-Package StyleChecker -Version 2.2.0
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="StyleChecker" Version="2.2.0">
  <PrivateAssets>all</PrivateAssets>
  <IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets>
</PackageReference>
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="StyleChecker" Version="2.2.0" />
                    
Directory.Packages.props
<PackageReference Include="StyleChecker">
  <PrivateAssets>all</PrivateAssets>
  <IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets>
</PackageReference>
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add StyleChecker --version 2.2.0
                    
#r "nuget: StyleChecker, 2.2.0"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package StyleChecker@2.2.0
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=StyleChecker&version=2.2.0
                    
Install as a Cake Addin
#tool nuget:?package=StyleChecker&version=2.2.0
                    
Install as a Cake Tool

StyleChecker

StyleChecker is another code style checking and refactoring tool similar to NetAnalyzers, StyleCop Analyzers, SonarLint, Roslynator, etc. It uses the .NET Compiler Platform ("Roslyn") to analyze the C# source code of .NET projects and outputs diagnostics of rule violations. And when used with IDEs such as Visual Studio, it provides as many code fixes as possible. Note that you should use this tool with other Roslyn analyzers, as it contains only complementary or niche analyzers.

Get started

StyleChecker is available as the NuGet-logo NuGet package.

Install StyleChecker to your project with Visual Studio

  1. Open Package Manager Console. (Open your project with Visual Studio, and select Tools ➜ NuGet Package Manager ➜ Package Manager Console.)
  2. Enter the command Install-Package StyleChecker in the Package Manager Console.

Install StyleChecker to your project with .NET CLI

  • Enter the command dotnet add package StyleChecker with the console.

Diagnostics

See the list of diagnostics.

Customize configuration

You can customize some analyzers to change their behaviors by placing the configuration file StyleChecker.xml at the project root. The XML Schema Definition file config.v1.xsd of the configuration file and a sample of the configuration file are available in the directory StyleChecker/StyleChecker/nuget/samples/ of the source tree (or in ~/.nuget/packages/stylechecker/VERSION/samples/ if you installed StyleChecker with the NuGet package). Note that StyleChecker does not use the XML Schema Definition file. But it helps you edit StyleChecker.xml with the text editor that can validate XML documents (for example, Visual Studio IDE, Visual Studio Code, and so on).

Create your own StyleChecker.xml file, place it at your project root, and add the AdditionalFiles element to the .csproj file in your project as follows:

<ItemGroup>
  <AdditionalFiles Include="StyleChecker.xml" />
</ItemGroup>

Alternatively, in Visual Studio, you can set the value "C# analyzer additional file" to the Build Action property. You can change this property from Solution Explorer ➜ Right Click on the StyleChecker.xml ➜ Properties ➜ Advanced ➜ Build Action.

There are no supported framework assets in this package.

Learn more about Target Frameworks and .NET Standard.

This package has no dependencies.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
2.2.0 359 2 months ago
2.2.0-beta 915 3 months ago
2.2.0-alpha 175 3 months ago
2.1.0 1,434 5 months ago
2.1.0-beta 125 6 months ago
2.1.0-alpha 148 6 months ago
2.0.3 148 6 months ago
2.0.3-beta 100 6 months ago
2.0.3-alpha 109 6 months ago
2.0.2 864 7 months ago
2.0.2-beta 96 7 months ago
2.0.2-alpha 153 8 months ago
2.0.1 6,762 8/13/2024
2.0.1-beta 126 8/11/2024
2.0.1-alpha 115 8/6/2024
2.0.0 287 5/17/2024
2.0.0-beta 123 5/13/2024
2.0.0-alpha 100 5/11/2024
1.0.27 27,997 8/18/2020
1.0.26 657 6/16/2020
1.0.25 1,393 3/28/2020
1.0.24 1,453 6/24/2019
1.0.23 1,074 5/15/2019
1.0.22 963 4/7/2019
1.0.21 779 3/15/2019
1.0.20 955 2/19/2019
1.0.19 784 2/3/2019
1.0.18 1,095 1/18/2019
1.0.17 941 12/8/2018
1.0.16 860 11/30/2018
1.0.15 909 11/22/2018
1.0.14 962 11/3/2018
1.0.13 882 10/31/2018
1.0.12 920 10/26/2018
1.0.11 886 10/23/2018
1.0.10 855 10/21/2018
1.0.9 913 10/14/2018
1.0.8 914 10/5/2018
1.0.7 905 9/24/2018
1.0.6 942 9/7/2018
1.0.5 973 9/2/2018
1.0.4 959 8/30/2018
1.0.3 990 8/13/2018
1.0.2 1,069 7/25/2018
1.0.1 1,056 7/24/2018
1.0.0 1,063 7/24/2018